[FX.php List] Tired of making special solutions for every browser?

Gjermund Gusland Thorsen ggt667 at gmail.com
Thu May 7 07:34:57 MDT 2009


This is OK
---
<?php echo "Elo word!";?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
Strict//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
<head>
---

This is not
---
<?php echo "Elo word!";?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
Strict//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
<head>
---
ggt

2009/5/7 Anders Monsen <andersm at alamark.com>:
> Do you know if matters that you any have <?php stuff ?> above this DOCTYPE?
>
> Thanks,
> Anders
>
> On May 7, 2009, at 7:41 AM, Gjermund Gusland Thorsen wrote:
>
>> Tired of making special solutions for every browser?
>>
>> IE 6, 7 and 8 do not interpret the page in the same manner
>>
>> Nor does FF and Safari, however Safari FF and IE 8 are more similar
>> than the others at the moment.
>>
>> One of the problems is that the different browsers have different
>> default DOCTYPEs, if you use this
>> ---
>> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
>> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
>> <html lang="en" xmlns="http://www.w3.org/1999/xhtml">
>> <head>
>> ---
>> On the top of each of your solutions, you will have less problems. Why?
>> Because this is the DOCTYPE that most browsers renders in almost the same
>> way.
>>
>> ggt667
>> _______________________________________________
>> FX.php_List mailing list
>> FX.php_List at mail.iviking.org
>> http://www.iviking.org/mailman/listinfo/fx.php_list
>>
>>
>
> _______________________________________________
> FX.php_List mailing list
> FX.php_List at mail.iviking.org
> http://www.iviking.org/mailman/listinfo/fx.php_list
>


More information about the FX.php_List mailing list