htmlArea

A directory of browser-based WYSIWYG editors

  MAIN
INDEX
SEARCH
POSTS
WHO'S
ONLINE
LOG
IN

Home: htmlArea 2: htmlArea 2 & 3 archive (read only): htmlArea v2.0:
Change Background Color [Javascript]


The htmlArea 2 & 3 editors have been discontinued.

We've made these forums available as a read-only reference and knowledge-base for people using or developing editors based on htmlArea 2 or 3.

Anyone who is interested in taking over version 2 or 3 is free to do so. All we ask is that you choose a new name that doesn't have "htmlarea" in it to avoid confusion with this site. We'll even give you a link in the directory to make it easier for people to find you. If you are developing or hosting an htmlArea based-editor under a new name, please submit it to our directory.

 


Animatic
Novice

Jan 4, 2005, 1:35 AM

Post #1 of 2 (2571 views)
Shortcut
Change Background Color [Javascript] Can't Post

<form name=" .... " action ="....." method = ".....">
Name: <input type="text" name="....">
Address: <input type="text" name="....">
<input type="button" onclick="checkValues();" value="send data" name="....">

It's only an example ... but after clicking the send button, the input data has to be checked. Those fields, which are consisting wrong data should be shown in another background color.

Thats no problem at the upper example. But if I have got an html area in it, I don't know how to change the color after the editor has been generated.
I have read some/many of the Threads postet befor about this issue and tried some of the given answers, but I couldn't get it working.

... excuse my bad english, its not my native language.


Animatic
Novice

Jan 12, 2005, 3:52 AM

Post #2 of 2 (2511 views)
Shortcut
Re: [Animatic] Change Background Color [Javascript] [In reply to] Can't Post

Problem solved.

editor.js:

function editor_changeBG(objname, color){

var editor_obj = document.all["_" +objname+ "_editor"]; // html editor object
var editdoc = editor_obj.contentWindow.document;

var editdoc = editor_obj.contentWindow.document;
editdoc.body.style.backgroundColor = color;
}

 
 
 


Search for (options)