cleditor problem with jquery ui effect()?

。_饼干妹妹 提交于 2019-12-12 02:26:44

问题


I'm using cleditor on one of my sites and I have run into a problem. When I use effect to animate some divs cleditor's wysiwyg editor stops working. The editor itself shows but I cant type anything into it. I can view/edit the source on the editor just fine.

Code I use to toggle between divs:

function emailwizardplace(pold, pnew) {
    $("#wizard-" + pold).hide();
    $("#wizard-" + pnew).effect('slide');
    //$("#wizard-" + pnew).show(); <= This works without problems
}

Code for calling cleditor:

$("#tmessage").cleditor({
    width: 680,
    height: 400
});

As always any help is appreciated.


回答1:


This seems to be a problem with the interaction between CLEditor and jQuery.UI. Have you tried this?

$("#tmessage").cleditor()[0].disable(false).refresh();

There's quite a bit of discussion in google groups on this problem. Here's one link that outlines the problem and what others have done. https://groups.google.com/forum/?fromgroups#!topic/cleditor/6W36CyPsaVU

Hope this helps.




回答2:


function emailwizardplace(pold, pnew) {
    $("#wizard-" + pold).hide();
    $("#wizard-" + pnew).effect('slide');
    $("#wizard-" + pnew).show('slide',function(){
        $("#tmessage").cleditor({
            width: 680,
            height: 400
        });
    });
};

You have to place the call for the cleditor inside the .show()



来源:https://stackoverflow.com/questions/7538715/cleditor-problem-with-jquery-ui-effect

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!