The top frame is pure HTML for banners and logos, no big deal there.
The left frame is an HTML page that will have multiple drop-down boxes and a submit button that should pass $_POST variables to the right frame.
Left frame:
Code: Select all
<html>
<head>
<meta http-equiv="Content-Language" content="en-us">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title>New Page 4</title>
<base target="contents">
</head>
<body>
<form method="POST">
<select name="equipment_type" id="equipment_type">
<option value="junk">-------------------</option>
<option value="%">All Equipment Types</option>
<option value="E911">E911 Cables</option>
</select>
<select name="project" id="project">
<option value="junk">-------------------</option>
<option value="%">All Projects</option>
<option value="Ericsson">Ericsson</option>
</select>
<INPUT TYPE="SUBMIT" VALUE="Submit">
<p>You should call up main.php here</p>
</body>
</html>Code: Select all
<html>
<head>
<meta http-equiv="Content-Language" content="en-us">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title>New Page 4</title>
<base target="contents">
</head>
<body>
<p>This is the main.php file</p>
<?
if ($_POST['equipment_type'] != 'junk')
{
echo "<script type=\"text/javascript\">document.getElementById('equipment_type').value = '{$_POST['equipment_type']}'; </script>";
}
if ($_POST['project'] != 'junk')
{
echo "<script type=\"text/javascript\">document.getElementById('project').value = '{$_POST['project']}'; </script>";
}
$username="acscable_client";
$password="cat7";
$database="acscable_tmobile";
mysql_connect(localhost,$username,$password);
@mysql_select_db($database) or die( "Unable to select database");
$query="select * from tmobile where equipment_type like '".$_POST["equipment_type"]."' AND project like '".$_POST["project"]."'";
$result=mysql_query($query);
$num=mysql_numrows($result);
mysql_close();
$i=0;
while ($i < $num)
{
$region=mysql_result($result,$i,"region");
$manu_part_num=mysql_result($result,$i,"manu_part_num");
$acs_part_num=mysql_result($result,$i,"acs_part_num");
$equipment_type=mysql_result($result,$i,"equipment_type");
$project=mysql_result($result,$i,"project");
$description=mysql_result($result,$i,"description");
$picture=mysql_result($result,$i,"photo");
echo "<br><br><img src=\"$picture\" align=\"left\"></img><br><b>Region:</b> $region <br><b>Manufacturer Part #:</b> $manu_part_num<br><b>ACS Part #:</b> $acs_part_num<br><b>Equipment Type</b>: $equipment_type<br><b>Project:</b> $project<br><b>Description:</b> $description<br><br><br><br><br><br><hr><br>";
$i++;
}
?>
</body>
</html>This can all be seen at:
http://acscable.com/test/index.html
I really have no idea what to do next. I know what to do logically thinking, but not how to actually do it. TIA