日期:2014-05-20  浏览次数:20878 次

帮我看看这两段代码有没有错,关于留言本的回复留言
只贴出一部分代码,目前,我可以测试到,
                           alert(textarea1);
                           alert(id);

这两句代码,显示出来的值,都是正常的,但接下来的jquery和webservice,因为我不大会,所以不懂判断,求高手指点。目前,从下面的代码,运行,除了弹出
                           alert(textarea1);
                           alert(id);
这两句之外,点击回复留言,根本没反应,也没报错。


 function replyData() { //回复留言函数
                           id = id2;
                           //alert(id);
                           //var textarea1 = getEditorHTMLContents(FCKeditor1);
                          var textarea1 = CKEDITOR.instances.content.getData();
                          alert(textarea1);
                           alert(id);

                           //var editor = CKEDITOR.replace("content");
                           //alert(editor.getData());
                            //document.getElementById("id")
                           $.ajax({
                               type: "POST",
                               cache: false,
                               url: "WebService.asmx/Update", /* 注意后面的名字对应CS的方法名称 */

                               data: { "id": id, "textarea1": textarea1 }, /* 注意参数的格式和名称 */
                               contentType: "application/x-www-form-urlencoded",