Jump to content

Xhtml integration with Conditionals...


bluegray

Recommended Posts

So my question is simple, but for brevity's sake I need to show you what's confusing me before I can articulate it.

 

while ($row = mysql_fetch_array ($result)) { ?>
	<div class="blah"><?php ; 
	include ("vars.inc.php") ;  ?>
                </div> 
                <span>blah blah</span><?php ; 
               } ?>

 

In regards to the ; after the div and span tags, are they needed/proper?  The display result is the same either way.  So nothing "breaks", but is it standards compliant to leave them out?  Or should I put them in?

 

Any help in the regards of adequately articulating what's going on there will also be much appreciated.  Thanks!

Link to comment
https://forums.phpfreaks.com/topic/194732-xhtml-integration-with-conditionals/
Share on other sites

I'm not sure what exactly you're asking, but if I were to have coded that, this is how I prefer to do it.  Then again your code didn't make much sense to me so anyways. :confused:

 

include("vars.inc.php");
while ( $row = mysql_fetch_array($result) )
{
echo '	<div class="blah">
		<span>blah blah</span>
	</div>';
}

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.