我有一个select
里面有输入的表格。更改后,将option
处理表单(使用 php)并在<form>
. 怎么做?
这是我的 html 表单代码:
<tr>
<td>
<form name="group" id="form1" method="post">
<select name="group" id="group" onChange="something()">
<?php foreach ($userGroups['data'] as $groups) {
echo "<option value=\"".$groups['id']."\">".$groups['name']."</option>";
}?>
</select>
</form>
</td>
</tr>
<tr>
<td>
<?php //PROCESSING THE FORM
if ($_POST) {
$groupId = $_POST['group'];
$groupmember = $facebook->api('/'.$groupId.'/members');
$membergroup = $groupmember['data'];
foreach ($membergroup as $membergroups) {
$membergroupsname = $membergroups['name'];
}
}
?>
<!---- THE PLACE WHERE $membergroupsname DISPLAYED ------>
</td>
</tr>
任何帮助将不胜感激..谢谢