2016-10-17 8 views
1

カントがこの作業を行うようです。私は提出した後にフォームに戻って行きたい。それだけで表示されます。リダイレクトが機能していない/アラートが表示されない

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

「...」とは何ですか?私は思っただけです..);) – nospor

答えて

-1

このエラーは、標的にされているファイルが存在しないことを意味します。コメントで指摘されているように、リダイレクトパス宣言window.location = ".../cnc/makerForm.php";に...代わりに...を記述しているためです。

+0

はい、私は..しかし、同じエラー – phloxangrex

+0

www://site.com/cnc/makerForm.phpのような絶対パスを試してください – jacobdo

+0

まだ同じエラー – phloxangrex

0

ありがとうございました。 私のコードで私は何が間違っているのか分かっています。私のフォームのファイルは間違っています。

関連する問題