Headers! When making a mobile site!

///Headers! When making a mobile site!

Headers! When making a mobile site!

Hi there,

Spend some time the last two days trying to figure out why my mobil xhtml site did’t showed on various non smartphones.

I’ve created a simple page, with content type application/xhtml+xml in my meta tags, and the DTD to mobile 1.0 xhtml and futhermore the page validated fine on W3C.

BUT the site failed on Sony Ericsson W810i and Nokia 6300 and for sure many others.
The users got: “Couldn’t reach the indicated web server”.

After hours of debugging i finally found out that Apache was bypassing the meta and sending a text/html content type – and that its unacceptable for the Symbian series browsers. (Opera mini worked fine).

SO remember to send a header!

This did’t the trick for me, just before your html write:

Header("Content-Type: application/xhtml+xml; charset=utf-8");

/Renzo

By |2018-01-06T01:52:20+00:00February 5th, 2009|Apache, Linux|2 Comments

2 Comments

  1. My May 19, 2009 at 12:30:03

    Super-Duper site! I am loving it!! Will come back again – taking you feeds also, Thanks. 🙂

  2. Mike May 28, 2009 at 04:42:14

    Thank you for sharing this. I had exactly the same issue with a mobile site I built for a client.

Leave A Comment