[pmwiki-users] Web for mobiles -- Apple sold over 1 million iPhones last weekend...
Patrick R. Michaud
pmichaud at pobox.com
Mon Jul 14 17:38:32 CDT 2008
[resending reply to the mailing list]
On Mon, Jul 14, 2008 at 11:36:32PM +0200, kirpi at kirpi.it wrote:
> > require a separate command. Instead, the site (or skin or whatever)
> > can detect that the request is coming from a mobile device and alter
> > the display accordingly.
> But maybe you mean that there should be a way to just sniff the user
> agent and make the switch towards mobiles, while always retaining the
> ability to manually force ?action=mobile if desired?
Yes, that's what I was meaning.
> Yes, nice, but even too nice for a start. Too complicated for my skills, anyway.
> Would anything like this
> http://dev.mobi/article/lightweight-device-detection-php be of any
The article does a bit more than what I would do, but yes, it contains
the essential idea. Basically we examine the HTTP headers and select a
different skin based on the headers by default.
Even better than using ?action=mobile might be to use ?skin=mobile
or ?setskin=mobile, so that the setting is remembered from one page
link to the next.
More information about the pmwiki-users