2012- 5- 4
|
#3
|
|
متميزة بكلية التربية بالجبيل
|
رد: حلول الميد ترم للغة الjava و html لاستاذه أ.أسماء
هذا للي مايفتح معها الملف هنا الاكواد للكويز الاول
كود PHP:
<html> <head> <script language="javascript"> function con(m) { if(m.length==8) { window.alert("your ID is write"); document.write("<center>your ID is :<font color='violet'><b>"+m+"</font></b><br>"); document.write("******************************</center>"); document.title="my ID is"+m; } else { window.alert("your ID is wrong"); window.location.href="a.html"; }} </script> </head> <body> <script language="javascript"> s=window.prompt("enter your ID which contains 8 numbers",""); con(s); </script> <center><table border="3"> <tr><td align="center"> <form name="f1"> <font size="6" color="yellow">choose the color of page </font><br> <input type="button" name="b1" value="red" onClick="document.bgColor=this.value"><input type="button" name="b2" value="green"onClick="document.bgColor=this.value"><input type="button" name="b3" value="blue" onClick="document.bgColor=this.value"> <br></form> <img name="g" src="1.jpg" border="4" hieght="100" width="100" onMouseOver="document.g.src='2.jpg'" onMouseOut="document.g.src='1.jpg'"></td></tr></table></center> </body> </html>
وهذا الكويز ال2
كود PHP:
<html> <head> <script language="javascript"> function con(m) { t=12345; r=54321; if(t==m || r==m) { window.alert("welcome in your page"); document.write("<center>your password is :<font color='violet'><b>"+m+"</font></b><br>"); document.write("******************************</center>"); window.status="password of this page is"+m; } else { window.alert("sorry,you can not view this page"); window.location.href="quiz 2.html"; }} </script> </head> <body> <script language="javascript"> s=window.prompt("enter the password please",""); con(s); </script> <center><table border="3"> <tr><td align="center"> <form name="f1"> <input type="text" name="t1"> <input value="location" type="button" onMouseOver="document.f1.t1.value=document.URL"><br> <font size="6" color="orange">choose the color of page </font><br> <input type="radio" name="b1" value="red" onClick="document.bgColor=this.value,document.f1.t1.value=this.value"><input type="radio" name="b2" value="green"onClick="document.bgColor=this.value,document.f1.t1.value=this.value"><input type="radio" name="b3" value="blue" onClick="document.bgColor=this.value, document.f1.t1.value=this.value"> <br> </form> </body> </html>
ولاتنسون تحطون صورتين معها بفايل عشان يضبط
وحده اسمها 1
والثانيه اسمها 2
|
|
|
|
|
|