Forum Discussion

N_67263's avatar
N_67263
Icon for Nimbostratus rankNimbostratus
Sep 15, 2014

need help with an iRule for redirection

Hi Folks, I need an iRule to work with the below logic:

 

We are hitting the below URL: http://nik.test.com/support/new.cgi?type=ccid&fixnos=BAO9070

 

Now this needs to redirect to http://newnik.test.com?type=ccid&fixnos=BAO9070

 

So the content after the ? will remain common, what will only need to be replaced is "http://nik.test.com/support/new.cgi" getting substituted with "http://newnik.test.com".

 

Thanks for the help.

 

Regards, Nik

 

4 Replies

    • MiLK_MaN's avatar
      MiLK_MaN
      Icon for Nimbostratus rankNimbostratus
      I'm pretty sure you're going to need a trailing / after the host, so it would become http://newnik.test.com/?[HTTP::query]
    • MiLK_MaN's avatar
      MiLK_MaN
      Icon for Nimbostratus rankNimbostratus
      I'm pretty sure you're going to need a trailing / after the host, so it would become http://newnik.test.com/?[HTTP::query]