![]() |
|
| |||||||
| Notices |
| mySQL & PHP Discussions, information and help with mySQL and PHP. |
![]() |
| | Thread Tools |
|
#1
| ||||
| ||||
|
Hi Folks, I have managed to get a page to populate reflecting data from a table in mysql. I have also managed to find this phph that will help me to exclude rows that do not have data. I understand that my phph file has 2 equalities [WHERE//AND], and i have several fields. I need to insert the Code below, after the while() statement, and that is part of my difficulty - where does the while() statement end in my php file? PHP Code: if($row['d32'] != '' && $row['d41'] != '' && $row['d42'] != '' && $row['d51'] != '' && $row['d52'] != '' && $row['d61'] != '' && $row['d62'] != '' && $row['d71'] != '' && $row['d72'] != '' && $row['d81'] != '' && $row['d82'] != '' && $row['d91'] != '' && $row['d92'] != '' && $row['d101'] != '' && $row['d111'] != '' && $row['d112'] != '' && $row['d121'] != '' && $row['d122'] != '' && $row['d131'] != '' && $row['d132']) { PHP Code: echo '</td></tr>'; I have several if statements but am not sure which if statement I should be using? to paste the following: PHP Code: } |
|
#2
| ||||
| ||||
|
Your while statement isn't listed in the code you pasted here but with multiple lines the while statement is enclosed in curly braces like so: Code: while(some condition here){
Stuff to execute of display here
more stuff...
} //End of While |
|
#3
| ||||
| ||||
|
Hi , Thanks for the help. It helps to understand these things no matter how simple they may be |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| |