echo '<form method="post" action="mod_slots.php">';
include 'details.php';
$data = mysql_query(" SELECT * FROM user_pokemon_db WHERE user_id = '".$id."' ");
while($rows = mysql_fetch_array($data))
{
$team = $rows['team'];
if($team > 0 && $team < 7)
{
$pkmn_id = $rows['pkmn_id'];
$path = mysql_query(" SELECT path FROM pokemons WHERE pk_id = '".$pkmn_id."' ");
$poke = mysql_result($path, 0, "path");
echo $poke;
echo "<br />";
$level = $rows['level'];
echo $level;
echo "<br />";
$exp = $rows['exp'];
echo $exp;
echo "<br />";
echo '<input type="radio" name="change1" value="'.$i.'" />';
echo "<br />";
$i++;
}
}
$j = 1;
include 'details.php';
$data = mysql_query(" SELECT * FROM user_pokemon_db WHERE user_id = '".$id."' ");
while($rows = mysql_fetch_array($data))
{
$pkmn_id = $rows['pkmn_id'];
$path = mysql_query(" SELECT path FROM pokemons WHERE pk_id = '".$pkmn_id."' ");
$poke = mysql_result($path, 0, "path");
echo $poke;
echo "<br />";
$level = $rows['level'];
echo $level;
echo "<br />";
$exp = $rows['exp'];
echo $exp;
echo "<br />";
echo '<input type="radio" name="change2" value="'.$j.'" />';
echo "<br />";
echo "<br />";
}
echo '<input type="submit" value="Change Selected" />';
echo '</form>';
我使用过一个表格,其中有2个带有差异名称的收音机:change1和change2。 我想在下一个操作页面上检索它。 下一页:
<?php
session_start();
$c1 = $_POST['change1'];
$c2 = $_POST['change2'];
echo $c1;
echo $c2;
?>
我能够检索change1的值而不是change2,它的常量为“1”???