httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kevin A. McGrail" <>
Subject Re: [users@httpd]
Date Thu, 01 Nov 2012 05:12:04 GMT
On 11/1/2012 12:59 AM, ABHISHEK GUPTA wrote:
> I want to configure apache in a way that all the request from mobile 
> browsers are redirected to a separate virtualhost and requests from 
> desktop browsers are served from another virtualhost. 


Because I recommend that the mobile site have a choice to choose to view 
the full site, this is likely best handled on the full site with a user 
agent check that then redirects to the mobile site coupled with a cookie 

However, mod_rewrite would be the likely answer based on user agent if 
you wanted to implement it that way. has an example 
access control with user agent but instead using the condition to redir 
with a rule such as (untested):

RewriteCond %{HTTP_USER_AGENT}   ^iPad
RewriteRule ^(.*)$1 [L,R=permanent]


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message