似乎无法完成这项工作。我想在提交后返回到表单。但它只是显示
**Object not found!**
The requested URL was not found on this server. The link on the referring page seems to be wrong or outdated. Please inform the author of that page about the error.
If you think this is a server error, please contact the webmaster.
**Error 404**
localhost
Apache/2.4.17 (Win32) OpenSSL/1.0.2d PHP/5.6.23
并且警报也不会弹出。 或者因为有错误而不会弹出?
我的PHP
if (mysqli_query($con,$sql))
{
?><script>
alert('Saved Successfully!');
window.location = ".../cnc/makerForm.php";
</script><?php
}
我的html
<div class="w3-border">
<h6 class = "w3-grey trbl-padding-5 trbl-margin">Maker</h6>
<a class="w3-btn-floating w3-pale-yellow" onclick="return toggleMakerBox('iframe_makerForm')">+</a>
<iframe height="400px" width="100%" src="makerForm.php" style="display:none;" name="iframe_makerForm" id="iframe_makerForm"></iframe>
</div>
最佳答案
谢谢你们。 我现在知道我的代码出了什么问题。我表单中的文件拼写错误。
关于javascript - 重定向不起作用/警报无显示,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40084303/