$(function () {
    //编辑器自定义
    $("#content_txt").xheditor({
        width: 680,
        height: 180,
        skin: 'nostyle',
        tools: '|,Bold,Italic,Underline,Strikethrough,|,Separator,Blocktag,Fontface,FontSize,FontColor,BackColor,|,Align,List,Outdent,Indent,Separator,|,SelectAll,Removeformat,Print,Preview,Fullscreen,/,|,Cut,Copy,Paste,Pastetext,|,Link,Unlink,Img,Flash,Media,Flv,Table,Emot,Code,|,Quote,map,Page,Source,About',
        //图片上传
        upBtnText: '上传',
        upImgUrl: "Ajax/EditUpload.ashx?com=pic&immediate=1",
        upImgExt: "jpg,jpeg,gif,png,bmp",

        //Flash上传
        upFlashUrl: "Ajax/EditUpload.ashx?com=flash&immediate=1",
        upFlashExt: "swf",

        //视频上传
        upMediaUrl: "Ajax/EditUpload.ashx?com=media&immediate=1",
        upMediaExt: "flv"
    });

    //提交判断
    $("form").submit(function () {
        $("input[type='text'],input[type='password'],textarea").trigger("blur");
        $("select").trigger("change");

        ///新增方法填写在此///

        /////

        if ($("form span").hasClass("ico-error")) {
            $("input:submit").attr("disabled", false);
            $("input:submit").next("span").attr("class", "point ico-error R");
            $("input:submit").next("span").text("请按照提示正确操作，检查各项填写");
            setInterval(delSubmitBtnMsg, 3000);
            return false;
        } else {
            $("input:submit").attr("disabled", true);
            $("input:submit").next("span").attr("class", "Q");
            $("input:submit").next("span").html("<img src=\"Images/Loading.gif\" align=\"middle\" /> 正在保存…");
        }
    });

});