says, I am possible
By: admin
25 Mar 2011While writing an selinium test I came across an problem while adding text to the ckEditor instance thorugh the test. And after a long search and research I got the below solution.
Command works is runscript() :
Usage : runscript(script);
Example :
runScript(CKEDITOR.instances["edit-body"].setData('<p>testContent</p>'); );
where "edit-body", is the instance name of the loaded ckdeditor.
Hope this helps someone. :)
About Me
I am : Open source developer.
I love : Drupal & CiviCRM !!
Work : Consultant @ Capgemini
3 Responses to Adding Content in CKEditor Instance Thorugh Selinuim Test
blacknight (not verified)
Thursday, September 8, 2011 - 21:47 reply
Hi,
I tried this piece of code with Selenium. But when i try this i get an error as "CKEDITOR is not defined".
What am i doing wrong here? Can you please help me?
admin
Friday, September 9, 2011 - 10:52 reply
Are you able to see the editor instance while the test in running ??
I think before the command add a wait of few seconds. So that the editor is loaded properly before our command is run.
Guest (not verified)
Thursday, January 19, 2012 - 06:03 reply
HI,
This page wsa very useful and i got an idea how to deal with ckeditor using selenium IDE but i am unable to find out instance of ck editor i have placed the code can please help me out
thank you
sam
Rich Text Editor
Post new comment