close ad
WARNING: Do Not Install the DREAMWEAVER CC 2017 or 2018 Update »
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

retrieving value of CKEditor instance with javascript (jquery)

Thread began 5/20/2013 8:03 am by CraigR | Last modified 2/05/2015 3:58 am by CraigR | 12330 views | 6 replies

CraigRBeta Tester

retrieving value of CKEditor instance with javascript (jquery)

I have a page with a form to create a group email campaign, and the client would now like the option to preview the email before it is sent.
Using jquery, I am passing the values of my form fields into an ajax request and setting a couple of session variables, which I then use in my email preview.
The subject field in the form is just a text field and I am setting the subject session variable like so...

$.ajax({
type: 'POST',
url: 'setmailsession.php',
data: { subject: $('#emailsubject').val() }
})
which seems straightforward, as the subject text field has an id of ‘emailsubject’
However, I cannot retrieve the content of the text message from ckeditor.
The text editor doesn’t seem to have an id, but is named editorField, and there is only one instance of it, so I tried (amongst other things) document.getElementsByName('editorField').item(0).value, but no value is returned.
Grateful if anyone can tell me, how do I retrieve the value of the text editor field with js ?

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...