PHP variables from mysql table

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View


I have a PHP script which parces a mySQL table and shows which
sections meet on which day by using an array containing (mon,...Fri)
and another lisitng sections. I then have the PHP do to selecrt
statements on to list those sections that are mixed and those that are

I have a title "Open to Boys and Girls" then it cycles through the
applicable groups. I want to hide this title if there are no group
from the mysql search but can't figure out how as the actual varaible
$result is set once the search is done even if it pulls nothing back

Code is below, does anyone have any ideas?

$result = @mysql_query("SELECT Group_Name FROM `groups` where
".$section."_comment like '%".$day."%' and ".$section."_comment like
echo "<u>Open to Boys & Girls</u></br>";
        while($row = mysql_fetch_array( $result )) {
        $Group_Name = $row['Group_Name'];
        echo "&bull; ".$Group_Name."</br>";
        }// end Group Name loop mixed



Re: PHP variables from mysql table

I noticed that Message-ID:
the following:

Quoted text here. Click to load it

Check if mysql_numrows($result) is greater than zero

Geoff Berrow (put thecat out to email)
It's only Usenet, no one dies.
My opinions, not the committee's, mine.
Simple RFDs /

Site Timeline