AnsweredAssumed Answered

How to replace a string with another in response

Question asked by SuhalkaPankaj on Sep 16, 2015
Latest reply on Sep 16, 2015 by SuhalkaPankaj

I have a request argument that hold ip address(10.123.12.345)

I want to send back above ip address in my response by replacing '.' with '%2e'

 

I have tried {{=request_input_ip_address.replace('.','%2e'}} but it isnt working.Instead getting below error:

ERROR com.itko.lisa.test.ScriptExecHandler - Failed to evaluate expression '=request_input_ip_address.r

eplace('.','%2e'': Sourced file: inline evaluation of: ``request_input_ip_address.replace('.','%2e';'' Token Parsing Error: Lexical error at line 1, column 40.  Encountered: "2" (50), after :

"\'%": <at unknown location>

 

Can someone tell me how above can be achieved?

Outcomes