27
Oct
08

Tugas Pemrograman Web

Scriptnya :

<html>
<head>
<title>Tugas Web(Membuat Form)</title>
<script type=”text/javascript”>
function pesan(){
if (document.reg.nama.value == “” && document.reg.nim.value == “” && document.reg.alamat.value == “”)
{
alert(“Namanipun Mboten Wonten isine !!!\nNim Kosong !!!\nAlamat Kosong !!!”)
}else if (document.reg.nim.value == “” && document.reg.alamat.value == “”)
{
alert(“Nimpun Mboten Wonten isine !!!\nAlamat Kosong !!!”)
}else if (document.reg.nama.value == “” && document.reg.alamat.value == “”)
{
alert(“Namanipun Mboten Wonten isine !!!\nAlamat Kosong !!!”)
}else if (document.reg.nama.value == “” && document.reg.nim.value == “”)
{
alert(“Namanipun Mboten Wonten isine!!!\nNim Kosong !!!”)
}else if (document.reg.nama.value == “”)
{
alert(“Namanipun Mboten Wonten isine !!!”)
}else if (document.reg.nim.value == “”)
{
alert(“Nimpun Mboten Wonten isine !!!”)
}else if (document.reg.alamat.value == “”)
{
alert(“Alamat Mboten Wonten !!!”)
}else {
alert(“Data Berhasil Dimasukan !\nNama :”+document.reg.nama.value+”\nNim :”+document.reg.nim.value+”\nAlamat :”+document.reg.alamat.value )
} }

</script>
</head>
<body>
<table width=”450″ border=”1″ align=”center” bordercolor=”#000000″>
<tr>
<td bgcolor=”#CCCCCC”><div align=”center”><font color=”#000000″><strong> FORM REGISTRASI </strong></font></div></td>
</tr>
<tr>
<td>
<form name=”reg”><table width=”440″ border=”0″ cellpadding=”1″>
<tr>
<td width=”107″><font color=”#000000″><strong>Nama</strong></font></td>
<td width=”21″><strong>:</strong></td>
<td width=”317″><input name=”nama” type=”text” size=”40″></td>
</tr>
<tr>
<td><font color=”#000000″><strong>Nim</strong></font></td>
<td><strong>:</strong></td>
<td><input name=”nim” type=”text” size=”25″></td>
</tr>
<tr>
<td><font color=”#000000″><strong>Alamat</strong></font></td>
<td><strong>:</strong></td>
<td><textarea name=”alamat”></textarea></td>
</tr>
<tr>
<td>&nbsp;</td>
<td>&nbsp;</td>
<td><input name=”masuk” type=”submit” id=”masuk” value=”Masuk” onClick=”pesan()”>
<input type=”reset” name=”Reset” value=”Batal”></td>
</tr>
</table>
</form></td>
</tr>
</table>
</body>
</html>

dan gambarnya :


0 Responses to “Tugas Pemrograman Web”



  1. Leave a Comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s


 

October 2008
M T W T F S S
    Dec »
 12345
6789101112
13141516171819
20212223242526
2728293031  

Follow

Get every new post delivered to your Inbox.