Hi all. I'm working on a database for school and I'm working between two computers, my laptop at home and my desktop at work. Now my code works fine on my desktop but when I moved it over to the laptop the two drop down select boxes aren't being created. The only real big difference here is that the desktop is XP and the laptop is windows 7 64bit. I'm using WAMP on both computer but I don't know if 32bit vs 64bit is causing the problem or what. I'm not getting any errors or anything the drop downs just aren't there when I run it on the laptop.
<?php
ini_set('session.cache_limiter','private');
session_start();
@mysql_connect($_SESSION['hostname'],$_SESSION['username'],$_SESSION['password']) or die(@mysql_error());
@mysql_select_db($_SESSION['db']) or die(@mysql_error());
$select = '';
$status=mysql_query("SELECT sid,status FROM status");
$section=mysql_query("select sectionID, Section from section");
?>
<html>
<body>
<form name="addBooks" method="post" action="http://localhost/Catalogue/php/addBooks.php">
<table>
<tr>
<td>Title:</td>
<td><input type = "text" name = "title" size = "15"></td>
</tr>
<tr>
<td>Author:</td>
<td><input type = "text" name = "author" size = "15"></td>
</tr>
<tr>
<td>ISBN:</td>
<td><input type = "text" name = "ISBN" size = "15"></td>
</tr>
<tr>
<td>Catalogue Number:</td>
<td><input type = "text" name = "libref" size = "15"></td>
</tr>
<tr>
<td>Series:</td>
<td><input type = "text" name = "series" size = "15"></td>
</tr>
<tr>
<td>Volume Number:</td>
<td><input type = "text" name = "volume" size = "15"></td>
</tr>
<tr>
<td>Publisher:</td>
<td><input type = "text" name = "publisher" size = "15"></td>
</tr>
<tr>
<td>Year Published:</td>
<td><input type = "text" name = "year" size = "15"></td>
</tr>
<tr>
<td>Status:</td>
<td>
<?php
if(mysql_num_rows($status)){
$select= '<select name="status">';
while($rs=mysql_fetch_array($status)){
$select.='<option value="'.$rs['sid'].'">'.$rs['status'].'</option>';
}
}
$select.='</select>';
echo $select;
?> </td>
</tr>
<tr>
<td>Section:</td>
<td>
<?php
if(mysql_num_rows($section)){
$select= '<select name="section"><option value =0>Choose';
while($rs=mysql_fetch_array($section)){
$select.='<option value="'.$rs['sectionID'].'">'.$rs['Section'].'</option>';
}
}
$select.='</select>';
echo $select;
?> </td>
</tr>
<tr>
<td>Summary:</td>
<td><textarea name = "Summary" rows="10" cols="30"></textarea></td>
</tr>
<tr>
<td colspan ="2"><td><input type="submit" name ="submitbutton" value = "Add Book"></input></td>
</tr>
</table>
</form>
</body>
</html>