Analysis.php ----------->
mysql_select_db('johnt_core');
$query = "SELECT * FROM companies WHERE symbol='$tsx'";
$result = mysql_query($query)
or die ("Could not execute query");
while ($row = mysql_fetch_array($result))
mysql_select_db('johnt_core');
$query = "SELECT * FROM companies WHERE symbol='$tsx2'";
$result = mysql_query($queries)
or die ("Could not execute query");
while ($now = mysql_fetch_array($desult))
if($tsx)
{
extract($row);
}
if($tsx2)
{
extract($now);
}
CHART ROOM ----------->
mysql_select_db('johnt_core')
or die ("Could not select database");
$query = "SELECT symbol, company FROM companies WHERE exchange='toronto'";
$result = mysql_query($query)
or die ("Could not select Toronto.");
mysql_select_db('johnt_core')
or die ("Could not select database");
$queries = "SELECT symbol, company FROM companies WHERE exchange='NYSE'";
$desult = mysql_query($queries)
or die ("Could not select Toronto.");
<form action="analysis.php" method="post">
<select name="tsx"><option selected value="default">-- Our Picks --</option>
<?php
while ($row = mysql_fetch_array($result))
{
extract($row);
echo "<option value='$symbol'>$company";
}
?></select><input type="image" SRC="submit.jpg" value="tsx"></td></form>
<form action="analysis.php" method="post">
<select name="tsx2"><option selected value="default">-- Our Picks --</option>
<?php
while ($now = mysql_fetch_array($desult))
{
extract($now);
echo "<option value='$symbol'>$company";
}
?></select><input type="image" SRC="submit.jpg" value="tsx2"></td></form>
I am trying this now and only ONE submit button is actually working, and when I submit the first value it says 'Could not execute query'.
Thanks again for all your help.