Forum Discussion
Andrew_Abplanal
Nimbostratus
Jan 30, 2007Help with String map
I am having issues with the " string map " command when using variables in the map section of the command.
Notice how the command logs the correct string when there is just text in the mapping setion....
ex.
if {[HTTP::is_redirect]}{
set find ":25620/"
set replace "/"
set location [HTTP::header value Location]
HTTP::header replace Location [string map { $find $replace} $location]
log [string map {$find $replace} $location]
log [string map { ":25620/" "/"} $location]
}
}
Jan 30 09:58:43 tmm tmm[1385]: 01220002:6: Rule lng-ln-cert-certlexisgw.lexis.com-http : http://www.test.com:25620/hbeat/
Jan 30 09:58:43 tmm tmm[1385]: 01220002:6: Rule lng-ln-cert-certlexisgw.lexis.com-http : http://www.test.com/hbeat/
No RepliesBe the first to reply
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects