It always helps to have a different point of view to look at code sometimes.
Else you'll go bonkers looking for that stupid semi-colon! :)
On 2/6/06 2:18 AM, "Paul Goepfert" <[EMAIL PROTECTED]> wrote:
> Thanks everyone for your help. I should have seen the semi-colon at
> the end of the while
Thanks everyone for your help. I should have seen the semi-colon at
the end of the while loop. I must have looked at the code 20 times
and I can't believe I missed it.
Paul
On 2/6/06, Brady Mitchell <[EMAIL PROTECTED]> wrote:
> > > echo '\n';
> > $month_query = mysql_query("SELE
> echo '\n';
> $month_query = mysql_query("SELECT m_id, months FROM Month");
> while ($r = mysql_fetch_array($month_query));
Remove the semi-colon at the end of the above line and it works like a charm.
> {
> $v = $r["m_id"];
> $
Paul Goepfert wrote:
This is the full code for the code that doesn't work.
\n';
$month_query = mysql_query("SELECT m_id, months FROM Month");
while ($r = mysql_fetch_array($month_query));
{
$v = $r["m_id"];
$out = $r["months"];
This is the full code for the code that doesn't work.
\n';
$month_query = mysql_query("SELECT m_id, months FROM Month");
while ($r = mysql_fetch_array($month_query));
{
$v = $r["m_id"];
$out = $r["months"];
echo "$out\n";
> Doesn't work
> -
> $month_query = mysql_query("SELECT m_id, months FROM Month");
> while ($row = mysql_fetch_array($month_query))
> {
> $val = $row["m_id"];
> $out = $row["months"];
> echo "$out";
> }
> ?>
You're missing the tags.
Hi Paul,
If "equip" contains a space it will probably break the dropdown.
Change it to:
echo "$val\n";
in case it has quotes, spaces, < or > in it.
Paul Goepfert wrote:
Hi all,
I have a mysql database setup to use with my php web page. I have
been able to access the database and get values
Hi all,
I have a mysql database setup to use with my php web page. I have
been able to access the database and get values into my drop down
menus. However when I tried to output the contents into two two
diferent variables the code does not work. To be more specific I will
show you the code bot
8 matches
Mail list logo