I'm having some trouble using pass
to pass variables to my CKFinder3 (ASP) connector when using CKEditor4.
I create my editor instance with:
CKFinder.setupCKEditor( myEditor, {
pass: 'testVar',
testVar: 'nooice',
...
});
but the variable just doesn't seem to make it over to CKFinder.
If I add this code to the CKFinder config directly it does work though:
config.pass = 'testVar';
config.testVar = 'nooice';
That's great, but the values I want to pass will be dynamic, so I need to pass them in when I call .setupCKEditor()
on the page. I've also tried using connectorInfo: 'testVar=nooice'
, but that doesn't work either.
Has anyone run into this? I found a great answer and example on this question, How to pass query string parameters in ckeditor for the picture (ckfinder) button?, but the described solution is basically what I'm doing and has no affect for me.
I have been able to get this working in a CKEditor5 test using:
ClassicEditor.create( document.querySelector( '#bodyContent' ), {
ckfinder: {
uploadUrl: '/ckfinder3/connector?command=QuickUpload&type=Images&responseType=json',
options: {
pass: 'testVar',
testVar: 'nooice'
}
},
...
} );
But I cannot figure it out in CKEditor4.