TheDragon wrote:
> You ever tried viewing a web page on a mobile phone, very difficult.
>
> What I am trying to achieve is a mini version of my site just for mobiles.
> There thay can download games ringtones etc.
> They could view a mini copy of the main site, but will much smaller
> graphics, and less of them.
Search Google for "content negotiation".
Basically what you need to do is check the "Accept" header in the HTTP
request provided by the user agent. if it claims to prefer
"text/vnd.wap.wml" over "text/html" then serve up the .wml content. Apache
servers can do this automatically for you. YMMV on other systems.
Checking for specific HTML user agents (e.g. Palm) isn't going to be quite
as straightforward, and to be honest you might be better off producing a
flexible design that works at all sizes, as others have suggested.
Alternatively you could apply string matching to the "User-Agent" request
header (which is probably what Google are doing). But bear in mind your algo
will have to be updated regularly as new handheld HTML browsers come out.
--
phil [dot] ronan @ virgin [dot] net
http://vzone.virgin.net/phil.ronan/