【发布时间】:2013-10-09 07:41:03
【问题描述】:
这是我的代码:
var fd = new FormData(document.querySelector('#form-step1'));
var xhr = new XMLHttpRequest();
xhr.open('POST', '/Handlers/newAccount_handler.php', true);
xhr.send(fd); // this line is causing a 500 Internal Server Error and the data is not saved to the MySQL table
为什么最后一行会导致 500 Internal Server Error?代码有什么问题吗?还是我需要先登录才能看到?
【问题讨论】:
-
你确定 '/Handlers/newAccount_handler.php' 是正确的位置。给我们您的服务器文件树。
标签: javascript mysql xml xmlhttprequest