Php 签出页面选择一个传递地址
我有一个结账页面,其中列出了用户的地址。其格式如下:Php 签出页面选择一个传递地址,php,Php,我有一个结账页面,其中列出了用户的地址。其格式如下: <form action="confirm.php" method="post" name="checkout"> <?php do { ?> <div class="panel panel-default" style="padding:0"> <div class="panel-heading"> <h4 class="panel
<form action="confirm.php" method="post" name="checkout">
<?php do { ?>
<div class="panel panel-default" style="padding:0">
<div class="panel-heading">
<h4 class="panel-title">
<a data-toggle="collapse" data-parent="#accordion" href="#collapse<?php echo $row_Address['ID'] ?>">
<?php echo $row_Address['FirstName'] ?> <?php echo $row_Address['LastName'] ?>, <?php echo $row_Address['City'] ?> <?php echo $row_Address['Pincode'] ?></a>
</h4>
</div>
<div id="collapse<?php echo $row_Address['ID'] ?>" class="panel-collapse collapse">
<div class="panel-body">
<p>
<?php echo $row_Address['FirstName']; ?> <?php echo $row_Address['LastName']; ?><br><?php echo $row_Address['Address1']; ?><br><?php echo $row_Address['Address2']; ?><br><?php echo $row_Address['City']; ?><br><?php echo $row_Address['State']; ?><br><?php echo $row_Address['Country']; ?><br><?php echo $row_Address['Pincode']; ?>
<br>
<strong>Email:</strong> <?php echo $row_Address['Pincode']; ?><br>
<strong> Phone:</strong> <?php echo $row_Address['Phone']; ?>
<br>
<br>
<button id="<?php echo $row_Address['ID']; ?>" type="submit" class="btn custombutton button--isi btn-primary">deliver to this address</button>
</p>
</div>
</div>
</div>
<?php } while ($row_Address = mysql_fetch_assoc($Address)); ?>
<!-- repeat address -->
</form>
电子邮件:
电话:
简单的方法是将$row\u Address['ID']
作为隐藏值传递
<input type="hidden" name="customid" value="<?php echo $row_Address['ID']; ?> />
简单的方法是将$row\u Address['ID']
作为隐藏值传递
<input type="hidden" name="customid" value="<?php echo $row_Address['ID']; ?> />
我也这么做了。但不起作用。页面转到confirm.php您在confirm.php
上得到的值是多少?我想我必须在重复区域内移动表单。这样做&添加以下内容有帮助`但隐藏元素没有帮助!`与隐藏值相比,这是相当危险的。因为人们可以很容易地更改传递到url中的值。我也这么做了。但不起作用。页面转到confirm.php您在confirm.php
上得到的值是多少?我想我必须在重复区域内移动表单。这样做&添加以下内容有帮助`但隐藏元素没有帮助!`与隐藏值相比,这是相当危险的。因为可以很容易地更改传递到url中的值。