2013-02-25 43 views
0

好的,這裏是問題,我通過單選按鈕將表單數據發送到PayPal結帳,但它在第一次上傳php文件並採用正確的值時起作用,但如果您返回並選擇說出下一個單選按鈕並提交它,然後將提交信息更改爲您在發送之前發送的值?發送表單數據到PayPal結賬

<table class="procut_item" border="0" cellpadding="4"> 
<tr> 
<td width="auto"><h4>Product test</h4></td> 
<td width="auto"><form method="post" action="process.php"> 
<input type="hidden" name="itemprice" value="10" /> 
<input type="hidden" name="itemQty" value="1" /> 
Size:<input type="radio" name="itemname" value="1">10 x 10</select> 
<input class="dw_button" type="submit" name="submitbutt" value="Buy" />  
</td> 
<tr> 

<tr> 
<td width="auto"><h4>Product test</h4></td> 
<td width="auto"><form method="post" action="process.php"> 
<input type="hidden" name="itemprice" value="30" /> 
<input type="hidden" name="itemQty" value="1" /> 
Size:<input type="radio" name="itemname" value="1">10 x 10</select> 
<input class="dw_button" type="submit" name="submitbutt" value="Buy" />  
</td> 
<tr> 

</table> 

回答

0

隨着看到所有的代碼,它是如何被處理的,我的第一個猜測是,你usnig相同的變量名,它是壓倒一切的首位。如果尚未使用數組,則可以創建一個數組,或者通過向其添加數字來增加變量名。

+0

我無法更改變量名稱,因爲如果我關閉了輸入字段的每個部分,它也會阻止我選擇多項選擇,因爲它設置爲付款結算檢出。 – 2013-03-01 22:55:17