just to add to this form part of my question. The select is (was) working from the index.php it is the displying of results.
I am going to post all the code so if any of you guys can spot where I have gone wrond it will really help me
index.php<?
require ("header.php");
?>
<div id="diagonal">
<a href="index.php">
<img src="images/bb1.gif" width="70" height="69" alt="Some Meaning">
</a>
</div>
<TABLE>
<TR>
<TD align="left" valign="top" class="leftfill">
<div class="image">
<!-- Include Left Menu Options Here -->
<table width="146" border="0" cellpadding ="0" cellspacing="0">
<tr class="navTable"><td class="bgColorDark" height="18"><span class="Header">
Search</span></td></tr><tr><td>
<form action='/companies.php' method='POST' name='CompanySearch'>
<input type='hidden' name='Search' value='YES' />
<input type='hidden' name='CompanySearch' value='Simple' />
<input type='text' class='menuForm' name='ANY' value='Keywords'
maxlength='40' size='13' />
<?
require("connection.php");
mysql_connect("$DBHost","$DBUser","$DBPass");
echo "<select name=\"CityID\" size=\"1\" class='menuForm'>";
$result=mysql_query("$DBName","SELECT City, CityID FROM city ORDER BY City");
while ($row = mysql_fetch_row($result)) {
echo "<option value=\"$row[1]\"> $row[0] </option>";
}
echo "</select>";
?>
<?
echo "<select name=\"Category\" size=\"1\" class='menuForm'>";
$result=mysql_query("$DBName","SELECT Category, CategoryID FROM category ORDER BY Category");
while ($row = mysql_fetch_array($result)) {
echo "<option value=\"$row[1]\"> $row[0] </option>";
}
echo "</select>";
?>
</td>
</tr>
<tr class="navTable">
<td class="bgColorMid">
<table cellpadding="0" cellspacing="0" border="0" width="100%"><tr><td valign="bottom"></td>
<td align="right">
<a href="companies.php" class="submitButton">Search</a>
<a href="companies.php" class="submitButton">
<img src="search.gif" border="0" align="absmiddle" vspace="1" hspace="1"></a>
</tr></table>
</td>
</tr>
</form>
</table>
<?
$result=mysql("$DBName","SELECT City, CityID FROM city ORDER BY City");
echo "Select a City:<br><br>";
echo "<ul>";
while ($row = mysql_fetch_row($result)) {
$City=$row[0];
$CityID=$row[1];
echo "<li><a href='$Relative/$City/index.php?CI=$CityID'>$City</a></li>";
}
echo "</ul>";
?>
</div>
</TD>
<!--END OF LEFT HAND SIDE COLUMN -->
<!--BEGINNING OF MIDDLE COLUMN -->
<TD align="left" valign="top" class="grayfill">
<!-- BEGINNING MIDDLE TABLE -->
<div class="subheader"> Punters Power they're your rights...
</div>
<div class="frontPageContentBox">
<div class="textNormal">
Perhaps the most important aspect of the way we live is the quality of life. The quality of our lives can be influenced by complex factors and simple ones too.
<br>
For instance a Shop Assistant by being courteous can put a smile on your face and make you feel good for the rest of the day.</div>
<br />
</div>
<!--STARTS MAIN MIDDLE CONTENT PAGE STARTS STARTS HERE-->
<!--ENDS MAIN MIDDLE CONTENT PAGE ENDS ENDS HERE-->
<!-- Middle TD ends here -->
</TD>
<TD align="left" valign="top" class="rightfill">
<!-- BEGINNING RIGHT HAND SIDE TABLE WITH LINKS IN AND STYLE iT CSS -->
<span class="subheader">
</span>
<div class="atext">
</div>
<br clear="ALL">
<!-- END RIGHT HAND SIDE TABLE WITH LINKS IN AND STYLE iT CSS

-->
<div class="ffheader">
<b>Useful Links</b>
</div>
<div class="resource"><a href="/#.php"></a></DIV>
<div class="resource"><a href="/#.php"></a></DIV>
</TD>
</TR>
</TABLE>
<?
require ("footer.php");
?>
companies.php
<?
require ("header.php");
?>
<div id="diagonal">
<a href="index.php">
<img src="images/bb1.gif" width="60" height="60" alt="Some Meaning">
</a>
</div>
<TABLE>
<TR>
<TD align="left" valign="top" class="leftfill">
<div class="image">
<?
require("Cart.php");
mysql_connect("$DBHost","$DBUser","$DBPass");
$result=mysql("$DBName","SELECT Category, CategoryID FROM category ORDER BY Category");
echo "<ul>";
while ($row = mysql_fetch_row($result)) {
$Cat=$row[0];
$CatID=$row[1];
echo"<li><a href='$Relative/items.php?CA=$CatID'>$Cat</a></li>";
}
echo "</ul>";
?>
</div>
</TD>
<!--END OF LEFT HAND SIDE COLUMN -->
<!--BEGINNING OF MIDDLE COLUMN -->
<TD align="left" valign="top" class="grayfill">
<!-- BEGINNING MIDDLE TABLE -->
<?
mysql_connect("$DBHost","$DBUser","$DBPass");
$result=mysql_query("SELECT items.ItemSKU, items.ItemName,
items.ItemDescription, items.PostCode, items.Category, items.CityID, items.CTelephone, items.ItemID FROM items WHERE Category='$CA' ORDER BY itemName");
if (!$result) echo mysql_error();
else {
}
while ($row=mysql_fetch_row($result)) {
$IS=$row['ItemSKU'];
$IN=$row['ItemName'];
$ID=$row['ItemDescription'];
$IC=$row['PostCode'];
$Ca=$row['Category'];
$City=$row['CityID'];
$SC=$row['CTelephone'];
$II=$row['ItemID'];
//echo "<b>Here is a description of $IN...<br><br>";
echo "<div class='subheader'> $IN ";
echo "</div>";
echo "<div class='frontPageContentBox'>";
echo "<TABLE cellpadding=5 cellspacing=3 width=\"100%\" border=2>";
echo "<TR>";
/* Image will be here */
echo "<TD valign=\"top\" align=\"left\" width='30' class=\"grayborder\">";
echo "<img src=\"$Relative/images/s".$II."\">";
echo "</TD>";
/* Image will END here */
echo "<TD valign=\"top\" align=\"left\" class=\"company\">";
echo "<B></B><BR>";
echo "$IC<BR>";
echo "t: $SC<BR>";
echo "f: $CFax<BR>";
echo "e: $CompanyEmail<BR>";
echo "w: $WebAddress";
echo "</TD>";
echo "<TD valign=\"top\" align=\"left\" class=\"companydesc\">";
echo "<BR>";
echo "<BR>";
echo "<A href=\"show_image.php?II=$II&CA=$CA\">more info ...</A>";
echo "</TD>";
echo "</TR>";
echo "</TABLE>";
echo "<BR>\n\n";
echo "</div>";
}
print_r($CityID);
?>
<!-- Middle TD ends here -->
</TD>
<TD align="left" valign="top" class="rightfill">
<!-- BEGINNING RIGHT HAND SIDE TABLE WITH LINKS IN AND STYLE iT CSS -->
<span class="subheader">
</span>
<br><br>
<div class="atext">
</div>
<br clear="ALL">
<br>
<!-- END RIGHT HAND SIDE TABLE WITH LINKS IN AND STYLE iT CSS

-->
<br>
<div class="ffheader">
<b>Useful Links</b>
</div>
</TD>
</TR>
</TABLE>
<?
require ("footer.php");
?>