单击提交按钮时,ipad刷新选项卡

时间:2022-11-09 01:51:32

actually m using desktop and ipad..in desktop browser when i click on submit button the page in ipad browser should get refreshed... suppose in desktop browser i have created a file test1.php

实际上我使用桌面和ipad ..在桌面浏览器中,当我点击提交按钮时,ipad浏览器中的页面应该刷新...假设在桌面浏览器中我创建了一个文件test1.php

<input type="submit" value= "submit"/>

when i click on submit button the page in ipad should get refreshed that is refresh.php

当我点击提交按钮时,ipad中的页面应该刷新,即refresh.php

i have tried the following code

我试过以下代码

<a href="rand_num.php" onclick="window.open(this.href, this.href); return false">link</a>

this works fine in desktop browser but the same in ipad is not getting refreshed

这在桌面浏览器中工作正常但在ipad中相同并没有得到刷新

1 个解决方案

#1


0  

If you are using an submit button just to refresh a page, you could use this:

如果您使用提交按钮只是为了刷新页面,您可以使用:

<form target='test1.php'>
    <input type='text' name='text1'>
    <input type='button' value='submit'>
</form>

This will refresh the page, going to, lets say test1.php?text1=[whatever your text may be] You can then use php to retrieve the value as $_GET['text1']

这将刷新页面,转到,让我们说test1.php?text1 = [无论你的文本是什么]你可以使用php来检索值为$ _GET ['text1']

#1


0  

If you are using an submit button just to refresh a page, you could use this:

如果您使用提交按钮只是为了刷新页面,您可以使用:

<form target='test1.php'>
    <input type='text' name='text1'>
    <input type='button' value='submit'>
</form>

This will refresh the page, going to, lets say test1.php?text1=[whatever your text may be] You can then use php to retrieve the value as $_GET['text1']

这将刷新页面,转到,让我们说test1.php?text1 = [无论你的文本是什么]你可以使用php来检索值为$ _GET ['text1']