Created
December 4, 2017 14:56
-
-
Save tisuchi/e1033d6245a61f4ac1aed040ac99c4f6 to your computer and use it in GitHub Desktop.
This is the view details page. I consider that it's called index.php
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html> | |
| <head><title>View Details</title></head> | |
| <head> | |
| <meta name="viewport" content="width=device-width, initial-scale=1"> | |
| <style> | |
| div.container | |
| { | |
| width: 100%; | |
| border: 1px gray; | |
| } | |
| header, footer | |
| { | |
| padding: 1em; | |
| color: white; | |
| background-color: grey; | |
| clear: left; | |
| text-align: center; | |
| } | |
| body{ | |
| background-color: #F5DEB3; | |
| <!--#CCCCCC #FFFFFF--> | |
| } | |
| table, th, td, tr | |
| { | |
| border: 1px solid black; | |
| border-collapse: collapse; | |
| table-layout: initial ; | |
| } | |
| th, td , tr | |
| { | |
| padding: 1px; | |
| text-align: center;; | |
| } | |
| th | |
| { | |
| text-align: center; | |
| } | |
| </style> | |
| </head> | |
| <header> | |
| <div class="container"> | |
| <h1> View Aduan </h1> | |
| <div class="bg"></div> | |
| <p><center> | |
| <img src="bersekutu.jpg" alt="mpm image" width="90" height="100"> | |
| <img src="jata.jpg" alt="mpm image" width="100" height="100"> | |
| <img src="MPM.png" alt="mpm image" width="100" height="100"> | |
| <img src="IIUM_Logo.png" alt="mpm image" width="350" height="100"> | |
| </p></center> | |
| <input type="button" value="BACK TO MAINPAGE" onclick="window.location.href='index.php'" /> | |
| </header> | |
| <article><p> | |
| <body> | |
| <form name="form" action="" method="post"> | |
| <table style= "width:100%" border= "1"> | |
| <!--<table id="dataTable" style= "width:100%" border= "1">--> | |
| <?php | |
| include "connect.php"; | |
| $query = "SELECT * FROM aduan ORDER BY dateReceive ASC"; | |
| $result = mysql_query($query); | |
| echo "<br><br>"; | |
| echo "<table border=\"1\" width=\"100%\">"; | |
| echo "<tr> | |
| <td><b>REFERENCE NO</b></td> | |
| <td><b>DATE OF RECEIVE</td> | |
| <td><b>DETAILS</td> | |
| <td><b>INVESTIGATING DATE</td> | |
| <td><b>INVESTIGATING OFFICER</td> | |
| <td><b>FEEDBACK FROM OFFICER</td> | |
| <td><b>EDIT</td><td><b>DELETE</b></td></tr> "; | |
| if($result){ | |
| while($row=mysql_fetch_array($result)) | |
| { | |
| $referenceNo=$row['referenceNo']; | |
| $dateReceive=$row['dateReceive']; | |
| $details=$row['details']; | |
| $investDate=$row['investDate']; | |
| $investofficer=$row['investofficer']; | |
| $feedback=$row['feedback']; | |
| echo "<tr> | |
| <td>$referenceNo</td> | |
| <td>$dateReceive</td> | |
| <td>$details</td> | |
| <td>$investDate</td> | |
| <td>$investofficer</td> | |
| <td>$feedback</td> | |
| <td><a href=\"edit.php?id=$referenceNo\"> Edit </a></td> | |
| <td><a href=\"delete.php?id=$referenceNo\" onclick=\"return confirm('Are you sure?');\"> Delete </a> | |
| </td> | |
| </tr>"; | |
| } | |
| } | |
| echo "</table>"; | |
| ?> | |
| </table> | |
| <?php | |
| if(isset($_SESSION['msg'])) | |
| { | |
| //echo ""$_SESSION['msg']; | |
| echo "<script language=\"JavaScript\">alert(\"".$_SESSION["msg"]."\");</script>"; | |
| unset($_SESSION['msg']); | |
| } | |
| ?> | |
| </p></article> | |
| <footer> | |
| <p>Copyright [email protected]</p> | |
| <p>Jabatan Perlesenan dan Penguatkuasaan</p> | |
| <p>Majlis Perbandaran Muar Johor Darul Takzim</p> | |
| <p>Karung Berkunci no.516 84009 Muar</p> | |
| <p>Johor Darul Takzim</p> | |
| </footer> | |
| </div> | |
| </body> | |
| </html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment