Jump to content
Great article Sarah – really gives an insight into the iPhone specific features that you can access.
There seems to be some concerns here about the redirection.
As far as how whether to redirect to a single page or do a complete redirect, this depends entirely on what you want to achieve. I agree completely that if you wanted an iPhone version of a blog then you would probably want to do a full redirect, but Sarah’s code can easily be modified with:
header(‘Location: http://mobile.yoursitehere.com’ . $_SERVER[‘REQUEST_URI’] . $_SERVER[‘QUERY_STRING’]);
However it is equally possible that for other uses your iPhone specific version will be different to your web version, especially in the example Sarah gives as replicating an iPhone app – in this case it may be appropriate to redirect only to the homepage to provide a different user experience.
.htaccess can obviously achieve the same thing, but will not help if you have a windows server.