Hello - thanks for viewing:
Here's what I want to accomplish: The problem I am having/trying to avoid, is I don't want query_update to execute when the page is loaded. Rather, I would like it to execute after the form is submitted which will also provide the function with the required variables for a sucessful update.
Thanks For The Help! Jeff
$variable = jeff;
$record_id = MSFT;
print "
<form action=\"runUpdate\" method=\"POST\">
Company Name
<input type=\"text\" name=\"input\">
<input type=\"submit\" value=\"Update Record\" class=\"pushbutton\"></form>";
function Update()
{
$query_update = mysql_query( "UPDATE market_research SET company_name = '$input' WHERE symbol = '$record_id'" );
if ( $query_update )
{
print "SUCCESS";
}
else
{
print "ERROR";
}
}