Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Conditioning the generation of an html table

Status
Not open for further replies.

Kharas

Programmer
Jan 30, 2007
39
0
0
MX
I was wondering if you could condition the generation of an html table with php.

So far I know this works:

<?php do { ?>
<table>
</table>
<?php } while (); ?>

But what about this for example?

<?php if ($rows_query <= 0) {echo "Query rows are empty";} else { do { ?>
<table>
</table>
<?php } while (); } ?>

Thanks in advance
 
oohhh and congratulations. boy or girl?

----------------------------------
Ignorance is not necessarily Bliss, case in point:
Unknown has caused an Unknown Error on Unknown and must be shutdown to prevent damage to Unknown.
 
hehe, not meant to swing this too far off topic, but thank you. Boy, first child, 9 lbs. 1 oz., 21.5 inches.
 
9lbs Wowsers!!!. Congratulations again.

----------------------------------
Ignorance is not necessarily Bliss, case in point:
Unknown has caused an Unknown Error on Unknown and must be shutdown to prevent damage to Unknown.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top