gpt4 book ai didi

php - 带有“提交”按钮的 IE 错误

转载 作者:行者123 更新时间:2023-12-01 05:38:27 25 4
gpt4 key购买 nike

我为我的 Fantasy Football 网站创建了一个团队 build 者。它在 Chrome 和 Firefox 上运行良好,但在 IE 上运行不佳。当我按下 IE 上的提交按钮之一时,整个页面会在该框架中重新加载,而不是该框架中的内容。

测试站点链接:http://fantasysoccerpro.com/project/test-ny/

IE错误截图:http://fantasysoccerpro.com/iebug.jpg

//SELECT GOALKEEPER//

$database = "wp_fsprowpdatatable_3";
$goalkeeper="SELECT * FROM `fantasys_fspro`. `$database` where POSITION = 'G'";
$gk = mysqli_query( $con, $goalkeeper );
?>

<!-- Example row of columns -->

<form method="post" action=" ">


<select name="gk_">
<option>----------Please Select G----------</option>
<?php while($gkrow = mysqli_fetch_array($gk))
{ ?>
<option value="<?php echo $gkrow['wdt_ID'];?>"> <?php echo $gkrow['player'];?></option>
<?php }?>
</select>
</div>


<button type="submit" class="btn btn-info" name="register" >Submit</button>


</form>
<?php
if(isset($_POST["register"]))
{

$gk_=$_POST["gk_"];

if ($gk_ > "0") {$selectedgk=$gk_;
}}

//UPDATE TABLE WITH GOALKEEPER//


$sql = "UPDATE $pw
SET PLAYER= (SELECT PLAYER
FROM $database
WHERE wdt_ID=$gk_) WHERE id = 1";

if ($gk_ > "0") {

if ($con->query($sql) === TRUE) {

} else {
echo "Error updating record: " . $con->error;
}}

$sql = "UPDATE $pw
SET SALARY= (SELECT SALARY
FROM $database
WHERE wdt_ID=$gk_) WHERE id = 1";

if ($gk_ > "0") {

if ($con->query($sql) === TRUE) {

} else {
echo "Error updating record: " . $con->error;
}}

$sql = "UPDATE $pw
SET PROJECTION= (SELECT PROJECTION
FROM $database
WHERE wdt_ID=$gk_) WHERE id = 1";

if ($gk_ > "0") {

if ($con->query($sql) === TRUE) {

} else {
echo "Error updating record: " . $con->error;
}}

最佳答案

在您的 iframe 中,您有一个表单,其操作属性由单个空格组成。 Internet Explorer 将此解释为应该发布到页面根目录而不是 iframe 源的表单。按照 @chiliNUT 的建议,完全删除操作属性来解决您的问题。

关于php - 带有“提交”按钮的 IE 错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32473457/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com