From: ryanne cruz <ryanne.cruz@up.edu.ph>
To: pgsql-php@postgresql.org <pgsql-php@postgresql.org>
Subject: Re: delayed passing of values in form
Date: Tue, 18 Mar 2003 20:00:03 +0800
Message-ID: <1047988803.3e770a438abf9@mail.up.edu.ph> (raw)
hi list.
i have a script with a delayed passing of values in the form. for example, i
chose the year 2003 and ticked the radio button for households. when i look at
the link, the variables are not yet passed to the maindemoutputmap script. i
tried displaying the values of the variables and they came up correctly. if i
choose another year or radio button, what i'll see is the previous options
selected (the previous values assigned to the variables).
if my explanation is hard to understand, you colud go to this site to see what
i mean:
http://www.philenergydb.upd.edu.ph/maindemoutputmap.php?prid=1
i ahve also included part of the script:
echo "<form method=\"post\"
action=\"maindemoutputmap.php?prid=".$prid."&module=demand"."&year=".$year."&tag=".$tag."&table4=".$table4."&dtag=1\";>";
echo "<font size='2' face=\"Verdana\"><b>Choose energy source:
</b></font>";
echo "<tr><td align=center><select name=\"tag\">";
idcombomodel("esourceid", "esource", "energysource", $primarylink);
echo " </select></td></tr>";
echo "</td></tr>";
echo "<tr><td height=\"10\" valign=\"center\" align=\"center\">";
//echo "<form method=\"post\"
action=\"$root/maindemoutputmap.php?prid=".$prid."&module=demand"."&year=".$year."&tag=".$tag."&table4=".$table4."&dtag=1\";>";
echo "<font size='2' face=\"Verdana\"><b>Choose year of desired record:
</b></font>";
echo "</td></tr><tr><td align=center><select name=\"year\">";
populate_year($primarylink);
echo " </select>";
echo "</td></tr>";
echo "<tr><td align=\"center\" valign=\"center\" height=\"10\"><font
size=\"2\" face=\"Verdana\"><b>Summary for Year $year</b></font></td></tr>";
echo "<td height=\"10\" align=center><font size=\"2\"
face=\"Verdana\"><i>$esource</i></font></td>";
echo "<td height=20></td>";
echo "<tr><table>";
//echo "<form method=\"post\"
action=\"$root/maindemoutputmap.php?prid=".$prid."&module=demand"."&year=".$year."&tag=".$tag."&table4=".$table4."&dtag=1\";>";
//echo "<tr><td height=10></td></tr><tr><td align=\"center\"
height=\"15\"><font face=\"Arial, Helvetica, sans-serif\" color=\"#CD853F\"
size=\"2\">LAYERS</font></td></tr>";
echo "<tr><td height=\"10\" valign=\"center\" align=\"center\">";
echo "<tr><td width=65></td><td align=\"left\">
<font face=\"Verdana, Arial, Helvetica, sans-serif\" size=\"2\">No. of
households</font></td>
<td align=\"right\"><input type=\"radio\" name=\"table4\"
value=\"households\"></td><td width=40></td></tr>";
echo "<tr><td width=65></td><td align=\"left\">
<font face=\"Verdana, Arial, Helvetica, sans-serif\"
size=\"2\">Installations</font></td>
<td align=\"right\"><input type=\"radio\" name=\"table4\"
value=\"installs\"></td><td width=40></td></tr>";
echo "<tr><td width=65></td><td align=\"left\">
<font face=\"Verdana, Arial, Helvetica, sans-serif\"
size=\"2\">Consumption</font></td>
<td align=\"right\"><input type=\"radio\" name=\"table4\"
value=\"consumption\"></td></tr>";
echo "<td align=\"center\" colspan=\"100%\" width=\"50%\"><input
type=\"submit\" value=\"SUBMIT!\"> </td></tr></form>";
echo "<table align=center><tr><td height=10></td></tr><tr><td align=\"center\"
><font face=\"Arial, Helvetica, sans-serif\" color=\"#8B8A54\" size=\"2\"><a
href=\"maindemoutputmap.php?prid=".$prid."&dtag=2\";\">Industrial</a></font></td></tr>";
echo "<tr><td align=\"center\" ><font face=\"Arial, Helvetica,
sans-serif\" color=\"#8B8A54\" size=\"2\"><a
href=\"maindemoutputmap.php?prid=".$prid."&dtag=3\";\">Agricultural</a></font></td></tr>";
echo "<tr><td align=\"center\" ><font face=\"Arial, Helvetica,
sans-serif\" color=\"#8B8A54\" size=\"2\"><a
href=\"maindemoutputmap.php?prid=".$prid."&dtag=4\";\">Transportation</a></font></td></tr>";
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-php@postgresql.org
Cc: ryanne.cruz@up.edu.ph
Subject: Re: delayed passing of values in form
In-Reply-To: <1047988803.3e770a438abf9@mail.up.edu.ph>
References: <1047988803.3e770a438abf9@mail.up.edu.ph>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox