Forum Discussion
Oz_Ayd_69699
Nimbostratus
Mar 07, 2007regexp and xml
How do you extract the operation name from a SOAP request (body) using regexp?
In the following request, how do you extract CalcSalary from the XML using regexp?
----- Sample Request Body ------
123
Cheers
Oz
- Give this a shot:
when HTTP_REQUEST { set content " xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\">123" set matches [regexp -inline {[\r\n ]*<(\w+)} $content] if { [llength $matches] > 1 } { $fullMatch = [lindex $matches 0] $methodName = [lindex $matches 1] } }
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