Jump to content

Opera & Nulls


lead2gold

Recommended Posts

why does every browser except opera treat <div class="classname"></div> as absolutly nothing (or dependant on the actual class attributes).

Where as Opera puts the keyword "null" on the page as place holder.

It's much cleaner and easier to code stuff like this:
[code]
<div class="dberror"><?=$error; ?></div>
[/code]

instead of
[code]
<?=($error)?"<div class=\"dberror\">$error</div>";
[/code]


The cleaner approach works in every browser except opera :( *sniffs*
How do you guys do it?

Link to comment
https://forums.phpfreaks.com/topic/14504-opera-nulls/
Share on other sites

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.