Main navigation
Product navigation
Main content
CKEditor 4
Overview
Demo
Accessibility Checker
Add-ons
Documentation
Download
Pricing
More
Home
WYSIWYG Editors
CKEditor 4
CKEditor 5
Image upload
CKFinder
Easy Image
Collaboration
Comments
New
Track changes
New
Collaborative editing
Pricing
Case studies
New
Documentation
Help center
Blog
Contact us
The forum operates in
read-only
mode. Please head to
StackOverflow
for support.
Forums
CKEditor
Support
Last post
Thu, 09/15/2005 - 02:55
#1
nrx2005
Joined:
02/09/2005
Posts:
1
accessing image object in the editor
in need to access the image object that i selected by a click in order to modify it by a javascript in an other page
Thu, 09/15/2005 - 02:55
#2
el_barto
Joined:
14/09/2005
Posts:
4
RE: accessing image object in the editor
var oEditor = window.parent.InnerDialogLoaded() ;
var FCK = oEditor.FCK ;
var oImg = FCK.Selection.GetSelectedElement() ;
alert(oImg.getAttribute('src',0));
You can modify the attributes almost the same way
oImg.setAttribute('src','mypathtoimage/image.gif',0);
Twitter
Facebook
Facebook
Instagram
Medium
Linkedin
GitHub
Arrow down
Phone
Menu
Close icon
Check
RE: accessing image object in the editor
var FCK = oEditor.FCK ;
var oImg = FCK.Selection.GetSelectedElement() ;
alert(oImg.getAttribute('src',0));
You can modify the attributes almost the same way
oImg.setAttribute('src','mypathtoimage/image.gif',0);