500 error caused by js post? ? ?
大家讲道理
大家讲道理 2017-05-16 13:05:09
0
3
673

The server installation uses oneinstack one-click installation package, lnmpa (Linux + Nginx + MySQL + PHP + Apache)
The program is discuz3.2
A 500 error was caused during post submit,
The error picture is as follows, I feel that it is caused by forum_post.js, but this js file has not been modified, and I don’t know why. . . Then, the relevant js code for lines 185 and 165 is as follows

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); ///////This line is 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(); /////This line is 185
}
大家讲道理
大家讲道理

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

reply all(3)
过去多啦不再A梦

500 is a back-end problem, and then you said you were affected by the post. In essence,


nizhel

This is get. Check if there are any problems with the back-end processing. Are all the parameters of get normal?

伊谢尔伦

You should check the Response of the corresponding request in Network->XHR after opening the console to see what the actual return content is?

左手右手慢动作

500 is not a backend problem

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template