douguai6716 2016-10-17 10:42
浏览 301

重定向不起作用/警告没有显示

cant seem to make this work. i want to go back to the form after submitting. but it just displays

**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

and also the alert does not pop up. or it will not pop up because there is an error?

my php

if (mysqli_query($con,$sql))
    {
        ?><script>
            alert('Saved Successfully!');
            window.location = ".../cnc/makerForm.php";
        </script><?php
    }

my 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>
  • 写回答

2条回答 默认 最新

  • duankan6894 2016-10-17 10:46
    关注

    This error means that the file you are targetting does not exist. As pointed out in the comment, it is most probably because you write ... instead .. in the redirect path declaration window.location = ".../cnc/makerForm.php";.

    评论

报告相同问题?

悬赏问题

  • ¥15 关于#hadoop#的问题
  • ¥15 (标签-Python|关键词-socket)
  • ¥15 keil里为什么main.c定义的函数在it.c调用不了
  • ¥50 切换TabTip键盘的输入法
  • ¥15 可否在不同线程中调用封装数据库操作的类
  • ¥15 微带串馈天线阵列每个阵元宽度计算
  • ¥15 keil的map文件中Image component sizes各项意思
  • ¥20 求个正点原子stm32f407开发版的贪吃蛇游戏
  • ¥15 划分vlan后,链路不通了?
  • ¥20 求各位懂行的人,注册表能不能看到usb使用得具体信息,干了什么,传输了什么数据