Forum Discussion

Jay_Sawyer_1110's avatar
Jay_Sawyer_1110
Icon for Nimbostratus rankNimbostratus
May 08, 2009

Breaking a page out of a frame when using HTTP::redirect

Under normal circumstances, the a request to http://www.mysite.com/firstlevel/secondlevel/e/web/MySitePortal/en_US/special-offers.workflow:ShowPromo?LandingPage=/All/US/Portals/Products lands you on a page with multiple frames. Customer is using an iRule that attempts a redirect to an apology page - here's part of the iRule:

 
 if { ([HTTP::method] equals "POST") }{ 
      if { ([HTTP::request] contains "systemconfig.runtime.workflow") or ([HTTP::request] contains "config.workflow") } { 
             HTTP::redirect http://www.mysite.com/firstlevel/secondlevel/e/web/MySitePortal/en_US/special-offers.workflow:ShowPromo?LandingPage=/All/US/Portals/Products 
 } else { 
          HTTP::redirect [HTTP::header "Referer"] 
        }             
 } 
 

The iRule and redirect works great, but the problem is, the apology page appears in one of the frames (main frame). Is there a way to break the apology page out of the frame and displaying just the apology page using the HTTP::redirect command or is there a different command I can use?

Thanks,

Jay
  • I think you can use HTTP::respond that returns javascript to rewrite href of your main frame (I assume it is top frame)...

     

     

    something like this..

     

     

    set newurl "http://devcentral.f5.com"

     

    HTTP::respond 200 content ""