I can't figure out what's wrong with my code. When I open it up using a web browser nothing comes up. I don't even get an error message. Can someone please tell me what I am doing wrong.
<?
//connect to database and select database
$connection = mysql_connect("localhost","root","netops") or die ("couldn't connect to the database.");
$db = mysql_select_db("intranet",$connection) or die ("couldn't select DB.");
//SQL Select statement and execute query
$sql = "SELECT ticketnumber, sitename FROM cablerequest ORDER BY ticketnumber ASC";
$sql_result = mysql_query($sql,$connection) or die ("could not execute query");
if (!$sql_result){
echo "<p>Could not get list!";
} else {
echo "
<HTML>
<HEAD>
<TITLE>System Outage Monitor: Close a Ticket</TICKET>
</HEAD>
<BODY>
<h1>Select a ticket to close</h1>
<FORM method=\"POST\" action=\"show_deloutage.php\">
<table cellspacing=5 cellpadding=5>
<tr>
<td align=right><strong>Ticket Number / Site Name:</strong></td>
<td valign=top>
<select=\"sel_record\">
<option value=\"\">--Select--</option>
";
while ($row = mysql_fetch_array($sql_result)){
$ticketnumber = $row["ticketnumber"];
$sitename = $row["sitename"];
echo "
<option value=\"$ticketnumber\">$ticketnumber : $sitename</option>
";
}
echo "
</select>
</td>
</tr>
<tr>
<td align=center colspan=2><INPUT type=\"submit\" value\"Select Ticket\"></td>
</tr>
</table>
</form>
</body>
</html>
";
}
?>