Using a node--add .tpl.php file I can implement a jQuery javascript call such as
var fieldTitle = $('#edit-title');
function titleChange() {window.alert(fieldTitle.val());}
fieldTitle.change( titleChange );
which creates an alert each time the title value is changed. As such, I know that I can obtain the form values from the edit form from where my script is being placed; however, I am unable to obtain the value from the text field which used CKEditor.
By using the #id for the text field, I can use .change() and have interactions occur as users type into the field. However, I'm unable to obtain the actual value from the text field. I've tried every ID of every tag nested in the field's div and used console.log() to output the field instance, the .val(), and even .html() with no success in even finding the value of the text typed into the ckeditor text area.
The only information on the internet that I was able to find appears to involve obtaining the value from ckeditor using CKEDITOR.instances however the console log error that occurs for any script involving this is "CKEDITOR" is not defined.
Does anyone know how to obtain a value from the CKEditor text area in Drupal using jQuery?