如何根據點擊哪個發佈按鈕,將POST數據從我的表單發送到兩個不同的頁面?使用2個按鈕從一個表單發送POST數據
我的「導出」按鈕將POST數據發送到「export.php」,但「Graphique」按鈕必須將POST數據發送到「graphique.php」頁面。
這裏是我的代碼:
<form name="TCAgregat" class="TCAgregat" action="export.php" method="post">
<input type="hidden" name="daco" value="<?php echo $DConso; ?>"></input>
<input type="hidden" name="CNS" value="<?php echo $CNewCentres; ?>"></input>
<input type=submit border="0" class="EXP" name="exp" value="EXPORT" />
<input type=submit border="0" class="DCB" name="dcb" value="GRAPHIQUE" />
</form>
我怎樣才能做到這一點?
把他們分開電子表格? – 2013-05-03 09:41:38
或者使用帶查詢字符串的javascript或acnhor標籤 – asprin 2013-05-03 09:41:51
在此處使用ajax .. – 2013-05-03 09:41:59