gpt4 book ai didi

javascript - 验证 FCKeditor

转载 作者:搜寻专家 更新时间:2023-11-01 04:20:42 26 4
gpt4 key购买 nike

FCKeditor 如何使用 javascript 验证必填字段。

最佳答案

试试这个,

var EditorInstance = FCKeditorAPI.GetInstance('message') ; 
if(EditorInstance.EditorDocument.body.innerText.length<=0)
{
alert("This firld is mandatory");
EditorInstance.EditorDocument.body.focus();
return false;
}

来源:

http://dreamtechworld.wordpress.com/2008/12/06/validating-firld-in-fckeditor-using-javascript/

关于javascript - 验证 FCKeditor,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3757964/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com