javascript - js post引起的500錯誤? ? ?
大家讲道理
大家讲道理 2017-05-16 13:05:09
0
3
620

伺服器安裝使用的是oneinstack一鍵安裝套件,lnmpa(Linux + Nginx+ MySQL+ PHP+ Apache)
程式是discuz3.2
在post submit時引起了500錯誤,
錯誤圖片如下,感覺是forum_post.js引起的,但並沒有修改這個js文件,也不知道為什麼。 。 。然後,185行和165行相關js程式碼如下

function checkpostrule_post(theform) {
    if(!seccodecheck && !secqaacheck && !theform.sechash) {
        var x = new Ajax();
        x.get('forum.php?mod=ajax&action=checkpostrule&ac=' + postaction + '&inajax=yes', function(s) {
            if(s) {
                ajaxinnerhtml($('seccheck'), s);
                evalscript(s);
                seccodecheck = true;
            } else {
                postsubmit(theform);  ///////这行是165
            }
        });
    } else {
        postsubmit(theform);
    }
}

function postsubmit(theform) {
    if($(editorid + '_attachlist')) {
        $('postbox').appendChild($(editorid + '_attachlist'));
        $(editorid + '_attachlist').style.display = 'none';
    }
    if($(editorid + '_imgattachlist')) {
        $('postbox').appendChild($(editorid + '_imgattachlist'));
        $(editorid + '_imgattachlist').style.display = 'none';
    }
    hideMenu();

    theform.replysubmit ? theform.replysubmit.disabled = true : (theform.editsubmit ? theform.editsubmit.disabled = true : theform.topicsubmit.disabled = true);
    theform.submit(); /////这行是185
}
大家讲道理
大家讲道理

光阴似箭催人老,日月如移越少年。

全部回覆(3)
过去多啦不再A梦

500 是後端問題, 然後你說你是post 影響的 實質上


nizhel

你這裡是get吧 看看 後端處理的有沒有問題 get的參數是不是都正常

伊谢尔伦

應該在打開控制台後查看Network->XHR中對應請求的Response
看看真實返回內容是啥?

左手右手慢动作

500不是後端問題嗎

熱門教學
更多>
最新下載
更多>
網站特效
網站源碼
網站素材
前端模板
關於我們 免責聲明 Sitemap
PHP中文網:公益線上PHP培訓,幫助PHP學習者快速成長!