หน้าแรก เว็บ http://www.npol2.ob.tc/

วันพฤหัสบดีที่ 28 พฤศจิกายน พ.ศ. 2556

Grade By P20T4l

  1. <html>
  2. <head>
  3.         <title>~ Grade By P20T4L ~</title>
  4. </head>
  5. <body bgcolor="#3498DB">
  6. <table border=0 width="100%" height="70%">
  7.         <tr>
  8.                 <td align=center >
  9.                         <img src="http://designmodo.github.io/Flat-UI/images/icons/svg/retina.svg"><br>
  10.                         <font color="#BDC3C7" size="50">! GRADE BY P20T4L !</font>
  11.                         <form action="" method="POST">
  12.                         <input type="text" name="grade" placeholder="Score 0-100">
  13.                         <input type="submit" value="Submit" >
  14.                         </form>
  15.                         <font color="#ECF0F1">YOU GRADE IS : </font>
  16.                         <?php
  17.  
  18.                                 if($_POST["grade"]>100)
  19.                                 {
  20.                                         echo "<font color='#E74C3C'>Invalid</font> ";
  21.                                 }
  22.                                 elseif($_POST["grade"]>79)
  23.                                 {
  24.                                         echo "A";
  25.                                 }      
  26.                                 elseif ($_POST["grade"]>74)
  27.                                 {
  28.                                         echo "B+";
  29.                                 }
  30.                                 elseif ($_POST["grade"]>69) {
  31.                                         echo "B";
  32.                                 }
  33.                                 elseif ($_POST["grade"]>64) {
  34.                                         echo "C+";
  35.                                 }
  36.                                 elseif ($_POST["grade"]>59) {
  37.                                         echo "C";
  38.                                 }
  39.                                 elseif ($_POST["grade"]>54) {
  40.                                         echo "D+";
  41.                                 }
  42.                                 elseif ($_POST["grade"]>49) {
  43.                                         echo "D";
  44.                                 }
  45.                                 elseif ($_POST["grade"]>0)
  46.                                 {
  47.                                         echo "E";
  48.                                 }
  49.                                 else
  50.                                 {
  51.                                         echo "<font color='#E74C3C'>Invalid</font>";
  52.                                 }
  53.                          ?>
  54.                 </td>
  55.         </tr>
  56. </table>
  57.  
  58. </body>
  59. </html>