90% of users can view and interact with a PHP page just fine. A few users get an error message: File Not Found.
The URL is http://topicalbiomedics.com/products/storesnearyou2.php .
Any thoughts?
The code is simple:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=ISO-8859-1">
<meta name="generator" content="Adobe GoLive 6">
<title>Stores Near You</title>
<link href="../stylesheet.css" rel="stylesheet" media="screen">
<script type="text/javascript" language="JavaScript">
function changeScreenSize(w,h)
{
window.resizeTo( w,h )
}
</script>
</head>
<body bgcolor="ffe7b2" onload="changeScreenSize(350,600)">
<h3><span class="orange">Stores Near You</span><span class="eleven"><br>
<br>
</span></h3>
<form action="http://topicalbiomedics.com/products/storesnearyou2.php" method="get" name="FormName">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td align="right"><span class="eleven">Select a State:</span></td>
<td><select name="stateName" size="1">
<option>-------</option>
<option value="CA">California</option>
<option value="CO">Colorado</option>
<option value="CT">Connecticut</option>
<option value="DE">Delaware</option>
<option value="FL">Florida</option>
<option value="IL">Illinois</option>
<option value="IN">Indiana</option>
<option value="ME">Maine</option>
<option value="MD">Maryland</option>
<option value="MA">Massachusetts</option>
<option value="MO">Missouri</option>
<option value="NH">New Hampshire</option>
<option value="NJ">New Jersey</option>
<option value="NY">New York</option>
<option value="NV">Nevada</option>
<option value="NC">North Carolina</option>
<option value="OH">Ohio</option>
<option value="OK">Oklahoma</option>
<option value="OR">Oregon</option>
<option value="PA">Pennsylvania</option>
<option value="RI">Rhode Island</option>
<option value="VT">Vermont</option>
<option value="VA">Virginia</option>
</select></td>
</tr>
<tr>
<td align="right"><span class="eleven">Then click:</span></td>
<td><input type="submit" value="Submit" border="0"></td>
</tr>
</table>
<h3><span class="eleven"> </span></h3>
</form>
<?php
// Connect to the database server
$dbcnx = @mysql_connect("localhost",
"topicalbiomedics", "password");
if (!$dbcnx) {
echo( "<P>Unable to connect to the " .
"database server at this time.</P>" );
exit();
}
// Select the Stores database
if (! @mysql_select_db("topicalbiomedicsdb") ) {
echo( "<P>Unable to locate the store " .
"database at this time.</P>" );
exit();
}
?></p>
<P>Here are all the stores selling our products in the state you selected. If you don't see a store near you, please call in your order at 1-800-537-7246 or visit our <a href="http://tpr4pain.com/cgi-bin/miva?Order/order.mv+">online store</a>.</P>
<BLOCKQUOTE>
<?php
// Request the store names of all the stores
$result = mysql_query(
"SELECT StoreName1, StoreName2 , StoreAddress , StoreCity ,
StoreState , StoreZip , StorePhone
FROM tblStores WHERE StoreState = '$stateName'
ORDER BY tblStores.StoreZip");
if (!$result) {
echo("<P>Error performing query: " .
mysql_error() . "</P>");
exit();
}
// Display the name of each store in a paragraph
while ( $row = mysql_fetch_array($result) ) {
if ( ( $row["StoreName2"] == "")) {
echo("<P>" . stripslashes($row["StoreName1"]) . "<br>");
} else {
echo("<P>" . stripslashes($row["StoreName2"]) . "<br>");
}
echo( $row["StoreAddress"] . "<br>");
echo( $row["StoreCity"] . ", ");
echo( $row["StoreState"] . " ");
$zip = $row["StoreZip"];
echo( substr($zip, 0, 5) . "<br>");
echo( $row["StorePhone"] . "</P>");
}
?></p>
</body>
</html>