Hello,
I would like to have a feature: when I put thumbs into URL, I want automaticly create a link.
But I can not find a way, how to map txtURL at link part of Image. Can anybody to put me a solution?
At fckeditor\plugins\image\dialogs\image.js I have:
I would like to have a feature: when I put thumbs into URL, I want automaticly create a link.
But I can not find a way, how to map txtURL at link part of Image. Can anybody to put me a solution?
At fckeditor\plugins\image\dialogs\image.js I have:
{id:'txtUrl',type:'text',label:'',
onChange:function(){
var v=this.getDialog(),
w=this.getValue();
if(w.length>0){
if (w.indexOf('/_thumbs/')>0){
var urlOrig = w.replace('_thumbs/','');
document.getElementById('120_textInput').value=urlOrig;
//but this is not working after some times...
}
v=this.getDialog();
var x=v.originalElement;v.preview.removeStyle('display');
x.setCustomData('isReady','false');
var y=CKEDITOR.document.getById('ImagePreviewLoader');
if(y)y.setStyle('display','');
x.on('load',t,v);x.on('error',u,v);x.on('abort',u,v);x.setAttribute('src',w);s.setAttribute('src',w);
v.preview.setAttribute('src',s.$.src);i(v);
}
else if(v.preview){
v.preview.removeAttribute('src');
v.preview.setStyle('display','none');
}
},
Re: How to map url input at image form
CKEDITOR.dialog.getCurrent().setValueOf("Link", "txtUrl",urlOrig);