logicslab
asked on
tinyMCE with Text Area
In a php page i have three textarea, and many client create four more(I done it with DOM). And i want to assign tinyMCE to all the text areas, that was sucessfull. But the issue is i can't get the values from the textarea using javascript.
When i used this command alert(document.getElementB yId('txt1' ).value);
the result is empty, but the textarea having value. When i post the page i got the values from all textarea. But i need client side validation to check datas are entered in textarea.
Pls help
When i used this command alert(document.getElementB
the result is empty, but the textarea having value. When i post the page i got the values from all textarea. But i need client side validation to check datas are entered in textarea.
Pls help
ASKER
Hi quetzal22
thank you for your quick reply.
One more question about tinyMCE. How can i add Mathematical Symbols to textarea using tinyMCE?
thank you for your quick reply.
One more question about tinyMCE. How can i add Mathematical Symbols to textarea using tinyMCE?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you very much
http://tinymce.moxiecode.com/examples/example_06.php
it seems that if your textarea has name="myEditor" then you will need to do:
var ed = tinyMCE.get('content');
//then to find out the value of it
alert( ed.getContent() );
//then if you want to change the value of it
ed.setContent('Hello');