Forum Discussion
reldar_76465
Jul 13, 2011Nimbostratus
redirect mobile devices
Hi,
I'm looking for a script that will enable us to redirect all traffic coming from mobile devices to a mobile site.
Many thanks for the help.
Roy
reldar_76465
Jul 19, 2011Nimbostratus
Many thanks for your reply.
now I created the below iRule to redirect all mobile traffic coming to my site to another site.
the thing is that on that 'other site', i want to have the reversed iRule that would redirect back to the original site all traffic that is NOT a mobile.
I would appreciate some guidance as how to 'reverse' the below script by using 'not'. something like 'if any of the below does not exist - redirect to www....'
thanks
when HTTP_REQUEST {
switch -glob [string tolower [HTTP::header User-Agent]] {
"*blackberry*" -
"*ipad*" - {
HTTP::redirect "http://m.mysite.com/[HTTP::uri]"
return
}
}
}
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects