Forum Discussion

Sonny's avatar
Sonny
Icon for Cirrus rankCirrus
Feb 16, 2017

irule syntax

I need someone to check my syntax. Thanks.

 

when HTTP_REQUEST { if { ( [string tolower [HTTP::path]] contains "spclaimproviderwebservice.https.svc" ) or ( [string tolower [HTTP::path]] contains "cellstorage.https.svc" { HTTP::path [string map {.https ""} [HTTP::path]] } } }

 

2 Replies

  • when HTTP_REQUEST { 
      if { [string tolower [HTTP::path]] contains "spclaimproviderwebservice.https.svc" or [string tolower [HTTP::path]] contains "cellstorage.https.svc" } { 
        HTTP::path [string map {.https ""} [HTTP::path]] 
      } 
    }
    
  • when HTTP_REQUEST { if { ( [string tolower [HTTP::path]] contains "spclaimproviderwebservice.https.svc" ) or ( [string tolower [HTTP::path]] contains "cellstorage.https.svc")} { HTTP::path [string map {.https ""} [HTTP::path]] }

     

    }

     

    You were missing a )} after cellstorage.https.svc" and you had an extra } at the end