Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $yn;
- mysql_connect("localhost", "root", "jack24") or die(mysql_error());
- mysql_select_db("mcv") or die(mysql_error());
- $result = mysql_query("SELECT * FROM Codes")
- or die(mysql_error());
- $row = mysql_fetch_array( $result );
- // Print out the contents of the entry
- if ($row['Used'] == 1) {
- $yn = "Yes";
- }
- else{
- $yn = "No";
- }
- ?>
- <html>
- <head>
- <title>Minecraft Codes</title>
- <style type="text/css">
- tbody {
- display: table-row-group;
- vertical-align: middle;
- border-color: inherit;
- }
- tr {
- display: table-row;
- vertical-align: inherit;
- border-color: inherit;
- }
- th {
- border: 1px solid #C3C3C3;
- padding: 3px;
- vertical-align: top;
- width: 20%;
- background-color: #E5EECC;
- }
- table.reference {
- background-color: white;
- border: 1px solid #C3C3C3;
- border-collapse: collapse;
- width: 50%;
- }
- table.reference td {
- border: 1px solid #C3C3C3;
- padding: 3px;
- vertical-align: top;
- width: 20%;
- }
- table, th, td, input, textarea {
- font-size: 100%;
- }
- body, p, h1, h2, h3, h4, table, td, th, ul, ol, textarea, input {
- font-family: verdana,helvetica,arial,sans-serif;
- }
- </style>
- </head>
- <body>
- <center>
- <br />
- <h1><u>Minecraft Server VIP Codes</u></h1>
- <br />
- <table class="reference">
- <tr>
- <th>Code</th>
- <th>Used?</th>
- </tr>
- <?php echo "<tr><td>".$row['Code']."</td><td>".$yn."</td></tr>"; ?>
- </table>
- </center>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement