Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $servername = "localhost";
- $username = "root";
- $password = "";
- $dbname = "class";
- // Create connection
- $conn = new mysqli($servername, $username, $password, $dbname);
- // Check connection
- if ($conn->connect_error) {
- die("Connection failed: " . $conn->connect_error);
- }
- $sql = "SELECT ctracking, cname, cemail, crport, cdport, clocation, cdestination FROM demo";
- $result = $conn->query($sql);
- if ($result->num_rows > 0) {
- // output data of each row
- while($row = $result->fetch_assoc()) {
- echo "ctracking: " . $row["ctracking"]. " - Name: " . $row["cname"]. " - Email: " . $row["cemail"]. " - Port: " . $row["crport"]. " - Dport: " . $row["cdport"]." - Location: " . $row["clocation"]. " - Destination: " . $row["cdestination"]. "<br>";
- }
- } else {
- echo "0 results";
- }
- $conn->close();
- ?>
- <html>
- <head>
- <title> Static Page</title>
- </head>
- <body>
- <form action="making.php" method="post" />
- <h1>Britchi Tracking</h1>
- <p>
- Costumers Name (required) <br/>
- <input type="text" name="search" placeholder="Emmanuel John"' . '" size="70"/>
- </p>
- <p><input type="submit" name="csearch" value="Search"></p>
- </form>
- <form action="http://localhost/wordpress">
- <input type="submit" value="Go to Home Page">
- </form
- </body>
- </html>
Add Comment
Please, Sign In to add comment