JAVA日报
php(ex01c.php)
<?php
if(isset($_GET['ID'])&&isset($_GET['sex'])&&isset($_GET['hobby'])&&isset($_GET['area'])&&isset($_GET['ect'])){
$ID = $_GET['ID'];
$sex = $_GET['sex'];
$hobby = $_GET['hobby'];
$area = $_GET['area'];
$ect = $_GET['ect'];
}
?>
<div style="position: absolute;height: 60%;width: 70%;left: 20%;top: 15%">
<form action="ex01b.php?act=update<?php echo '&ID='.$ID.'&sex='.$sex.'&hobby='.$hobby.'&area='.$area.'&ect='.$ect?>" method="post">
<table border="1" style="height: 100%;width: 100%">
<tr>
<td style="text-align: center" colspan="3">
修改个人信息
</td>
</tr>
<tr>
<td>真实姓名:</td>
<td colspan="2"><input name="name" type="text" value="<?php echo $ID;?>"></td>
</tr>
<tr>
<td>性别:</td>
<td><input type="radio" name="sex" value="男" <?php if($sex=='男'){echo 'checked';}?>>男<input type="radio" name="sex" value="女" <?php if($sex=='女'){echo 'checked';}?>>女</td>
</tr>
<tr>
<td>兴趣爱好:</td>
<td colspan="2"><input name="hobby" type="text" value="<?php echo $hobby?>"></td>
</tr>
<tr>
<td>家庭住址:</td>
<td colspan="2">
<select name="area">
<option >请选择你的居住区域</option>
<option value="亚洲" <?php if($area=='亚洲'){echo 'selected';}?>>亚洲</option>
<option value="欧洲" <?php if($area=='欧洲'){echo 'selected';}?>>欧洲</option>
</select>
</td>
</tr>
<tr>
<td>
备注:
</td>
<td colspan="2">
<textarea name="ect">
<?php echo $ect?>
</textarea>
</td>
</tr>
<tr>
<td colspan="3" style="text-align: center">
<input type="submit" value="修改">
</td>
</tr>
</table>
</form>
</div>