htmlArea

A directory of browser-based WYSIWYG editors

  MAIN
INDEX
SEARCH
POSTS
WHO'S
ONLINE
LOG
IN

Home: WYSIWYG Forums: WYSIWYG Editor Discussion:
Using heading in stead of font size


 


rkorebrits
New User

Sep 10, 2005, 3:22 AM

Post #1 of 2 (16784 views)
Shortcut
Using heading in stead of font size Can't Post

My htmlarea currently has the following code for the font size:

this.fontsizes = {
"1 (8 pt)": "1",
"2 (10 pt)": "2",
"3 (12 pt)": "3",
"4 (14 pt)": "4",
"5 (18 pt)": "5",
"6 (24 pt)": "6",
"7 (36 pt)": "7"
};

if (btnName == "fontsize") {
toolbar += '<select id="_' +objname+ '_FontSize" onChange="editor_action(this.id)" unselectable="on" style="margin: 1 2 0 0; font-size: 12px;">';
for (var fontsize in config.fontsizes) {
toolbar += '<option value="' +config.fontsizes[fontsize]+ '">' +fontsize+ '</option>'
}
toolbar += '</select>\n';
continue;
}

// FontSize
else if (cmdID == 'FontSize' && val) {
//alert('je pas nu de grootte aan');
editdoc.execCommand(cmdID,0,val);
}

Which result in tags like <font size=5>text</font>
But i am looking for code to make this output: <h1>Text</h1>
What do i need to do to archieve this?


rkorebrits
New User

Sep 10, 2005, 11:56 AM

Post #2 of 2 (16777 views)
Shortcut
Re: [rkorebrits] Using heading in stead of font size [In reply to] Can't Post

problem is solved with htmlarea3

 
 
 


Search for (options)