-
Bug
-
Resolution: Fixed
-
Later
-
5.3.0
-
None
-
Security Level: Jimmy
-
None
-
None
steps to reproduce
- load the attached zul
- insert a comment with the context menu
current result
TypeError: jq(...).cleditor is not a function
zssex.Richtextbox<._init()
zssex.wpd:19
zssex.Richtextbox<.bind_/<()
zssex.wpd:19
zssex.wpd:19:118
Because js file loading order might be different from time to time, this issue sometimes doesn't happen. You need to reload the page several times to reproduce it.
expected result
no error
root cause
- the jQuery object passed to CLEditor plugin might be another version of jQuery instead of zk bundled jQuery depending on js file loading order. So the function cleditor() might not be availiable on jq
solution
always pass jq to CLEditor plugin to avoid being overridden by another jQuery library. In the last line of jqery.cleditor.js, replace jQuery with jq. Plese refer to attached jqery.cleditor.js
(function ($) { //============== // jQuery Plugin //============== $.cleditor = { //... } })(jq);
workaround
call noConflict(). Please refer to jq-noConflict.js
- relates to
-
ZK-3209 tbeditor fails when including another jQuery script
- Closed
-
KEIKAI-638 including another jQuery causes color picker not working
- Closed