<html>
<head>
<title>For</title>
</head>
<body>
<link rel="stylesheet" href="for.css">
<form method="post">
<table align="center">
<tr>
<center>
<h1>DAFTAR JURUSAN SISWA</h1>
<h2>Smkn 4 Bandung</h2>
</center>
<td>Masukan Jumlah Siswa : <input type="text" name="in"></td>
<td><input type="submit" name="ok" value="OK"></td>
</tr>
</table>
</form>
<br>
<table align="center">
<tr>
<?php
if (isset($_POST['ok'])) :
for ($i=1; $i <= $_POST['in'] ; $i++) :
?>
<td>
Nama : <input type="text" name="nama">
</td>
<td>
Jurusan :
<input type="radio" value="rpl" name="jurusan<?php echo $i?>">RPL
<input type="radio" value="tkj" name="jurusan<?php echo $i?>">TKJ
<input type="radio" value="mm" name="jurusan<?php echo $i?>">MM
<input type="radio" value="av" name="jurusan<?php echo $i?>">AV
<input type="radio" value="titl" name="jurusan<?php echo $i?>">TITL
<input type="radio" value="toi" name="jurusan <?php echo $i?>">TOI
</td>
</tr>
<?php
endfor;
endif;
?>
</table>
<center>
<p>
<input type="button" name="submit" value="Submit">
</p>
</center>
</body>
</html>