Learn F5 Technologies, Get Answers & Share Community Solutions Join DevCentral

Filter by:
  • Solution
  • Technology
Clear all filters

Portal access redirect based on on device type.


I´ve some issues with doing a redirect based on device type.

My setup looks like this:

We are using a webtop to publish some Portal access resources for both desktop browsers and for mobile devices. My issue are that the mobile devices should be redirected to a different uri then the desktop users. If a desktop user clicks on a Portal access resource the base uri are /asdf but when mobile device user clicks it should be /qwerrtt

I´ve tried to do this with an irule but without success.

All help are appreciated.

  set wtType [ACCESS::session data get session.policy.result.webtop.type]
  if {[ info exists wtType ] && $wtType == "full" } {
    if { !([HTTP::uri] starts_with "/f5-w-*masked Value/") &&  [HTTP::header User-Agent] equals "*android*" && [HTTP::uri] contains "/asdf"  }  {  
       HTTP::redirect "/f5-w-70616c657474652e706561622e7365$$/qwerrtt"

  unset wtType
Rate this Question

Answers to this Question