|
You can examine the HTTP "User-Agent" header that may carry information about the user's browser used. How to do depends on your server-side development platform (e.g. CGI/PHP/Java etc.) However, because that field can be easily forged, it is not necessarily accurate but that is mostly what you can do.
For redirects, there are mainly 2 ways: HTTP redirect and HTML-based (browser) redirect. With HTTP redirect the server-side generates a redirect (a "moved" HTTP response) that the browser responds to. The second way is to generate a meta tag in the HTML returned to browser, that the browser will do the redirect, but only after the original response is rendered completely. Again, how to do depends on your development platform.
The main difference is that HTML-based redirect will break the "back" button. If the user presses the back button after the redirect, the browser will run the redirect again and the end result is the user is not redirected.
You do not necessarily need to do this with programming. I think you can also implement some of these redirect schemes with certain Apache configuration directives. Dealing with this the Apache way is not my favourite, but that is up to you.
|