|
|
# 11 |
|
משתמש - היכל התהילה
|
ב"ה
123 ו 1 האינדקסים מתחילים מ-0 כמו מערך.
__________________
קו ישר, כי אפשר גם אחרת |
|
|
|
# 12 |
|
חבר וותיק
|
מוזר שזה לא עובד..
אני אביא את הקוד המלא: HTML קוד:
<span> <select id="fontname" onchange="fontname(this)"> <option value="Arial" selected="selected">Arial</option> <option value="Courier New">Courier New</option> <option value="Georgia">Georgia</option> <option value="Tahoma">Tahoma</option> <option value="Times New Roman">Times New Roman</option> <option value="Verdana">Verdana</option> <option value="otherfont" style="color:#626262;">אחר...</option> </select> </span> HTML קוד:
function fontname(fontname_i) {
var fontname = fontname_i[fontname_i.selectedIndex].value;
if(fontname != "none") {
if(fontname == "otherfont") {
otherfont();
}
else {
document.getElementById('editor').focus();
document.execCommand('fontname',false,fontname);
document.getElementById('editor').focus();
}
}
else {
document.getElementById('editor').focus();
}
}
|
|
|
|
# 13 |
|
חבר וותיק
|
הקפצה. (יש אישור)
|
|
|
|
# 14 |
|
תודה על תרומתך.
|
שאלה : אם הבנתי נכון, אתה מעוניין שבעת בחירה איזהשהו ערך מתוך ה SELECT, אז הוא יפעיל פונקציה מסוייימת על הערך נכון ?
אם כן יש לי סקריפט דיי דומה שאני משתמש בו הרבה זמן, מאד מאד פשוט ואני אדביק אותו פה. רק תאשר לי שזה נכון מה שאמרתי |
|
|
|
# 15 |
|
משתמש - היכל התהילה
|
קוד:
<script>
function fontname(fontname_i) {
var fontname = fontname_i.value;
if(fontname != "none") {
if(fontname == "otherfont") {
otherfont();
}
else {
document.getElementById('editor').focus();
document.execCommand('fontname',false,fontname);
document.getElementById('editor').focus();
}
}
else {
document.getElementById('editor').focus();
}
}
</script>
<span>
<select id="fontname" onchange="fontname(this)">
<option value="Arial" selected="selected">Arial</option>
<option value="Courier New">Courier New</option>
<option value="Georgia">Georgia</option>
<option value="Tahoma">Tahoma</option>
<option value="Times New Roman">Times New Roman</option>
<option value="Verdana">Verdana</option>
<option value="otherfont" style="color:#626262;">àçø...</option>
</select>
</span>
__________________
קו ישר, כי אפשר גם אחרת |
|
|
|
# 16 |
|
חבר וותיק
|
לא עובד..
RS324 אשמח לראות את הקוד שלך. |
|
![]() |
| חברים פעילים הצופים באשכול זה: 1 (0 חברים ו- 1 אורחים) | |
| כלים לאשכול | |
| תצורת הצגה | |
|
|