On 1 December 2010 18:38, Rob Schroder <[email protected]> wrote:
> HI Steve,
>
> I was originally using: (?<=("csrf-token" content=")).*(?=("))
>
> But, ORO does not support look behinds.
>
> I just tried using Milamber's suggestion:  csrf-token" content="([^"]+)
> This returns: csrf-token" 
> content="6yuQXuFV5rx2tE5/QL0V9jclw0HnWK+4madV9uAwOsg=
>
> But, as Sebb pointed out, I had not configured the template properly to 
> return the correct pair.  It works now.
>
> Thank you all for your support as I cut my teeth on regular expressions, and 
> jmeter!
>

Thanks for letting us know that your issue has been solved - always
good to know that!


And if you have any suggestions for improving the RE and JMeter doc,
please let us know - best via Bugzilla if it may take a while to fix.

BTW, I already added a section about the Perl extended REs supported
(or not) by ORO to the RE section of the manual; this will be in the
next release, whenever that is.


> Regards,
> Rob
>
>
> On 12/1/10 9:00 AM, "Steve Eckhart" <[email protected]> wrote:
>
> Rob,
>
> Check for the placement of parentheses () in the regex. JMeter grabs the text 
> between the parentheses.
>
> Can you send the exact regex you're using now?
>
> Steve Eckhart
> Lead Quality Assurance Analyst
>
> WAUSAU Financial Systems
> 14010 FNB PKWY STE500
> Omaha, NE 68154-5206
> Main: (402) 431-8810
> Direct line: (402) 715-9382
> Email: [email protected]
>
> Enterprise Payment Solutions.
> CONFIDENTIALITY NOTICE:  This electronic transmission (including files 
> attached hereto) is intended only for the use of the individual or entity 
> named above.  If the reader of this message is not the intended recipient, 
> you are hereby notified that any disclosure, dissemination, copying, 
> distribution or taking of any action in reliance on the contents of this 
> confidential information is strictly prohibited.  If you have received this 
> communication in error, please destroy it and immediately notify us by return 
> email.  Thank you.
>
>
>
> -----Original Message-----
> From: Rob Schroder [mailto:[email protected]]
> Sent: Wednesday, December 01, 2010 10:38 AM
> To: JMeter Users List
> Subject: Re: Problem with Regular Expression Extractor
>
> Thanks for the tip about the combo box!
>
> The problem with the regular expression that you suggest, csrf-token" 
> content="([^"]+), is that it leaves <csrf-token" content="> in the result.
>
> What I need is to be able to just grab the dynamic string, in this case: 
> 6yuQXuFV5rx2tE5/QL0V9jclw0HnWK+4madV9uAwOsg=
>
> From this line:
> <meta name="csrf-token" 
> content="6yuQXuFV5rx2tE5/QL0V9jclw0HnWK+4madV9uAwOsg="/>
>
> Like I said, the string is a dynamic value.  For example:
> <meta name="csrf-token" 
> content="sXpW2DRUpZHgE3lIWjkTmlQYGrY7Gyi6pOhW14pfWvw="/>
>
>
> I guess since look behind isn't supported, I'll have to use a subexpression.  
> It's just not immediately clear how to do it :')
>
> Regards,
> Rob
>
>
> On 11/30/10 11:13 PM, "Milamber" <[email protected]> wrote:
>
> Hello,
>
> Regexp can be testing directly on JMeter in View Results Tree with
> Regexp tester view (combo list). JMeter use ORO as regexp engine.
>
> Try this :
>
> csrf-token" content="([^"]+)
>
> Milamber
>
> Le 01/12/2010 01:51, Rob Schroder a ecrit :
>> Hi,
>>
>> I'm trying to use the Regular Expression Extractor.  I've verified that I 
>> can use it to parse out simple text.  But, when I try to parse the following 
>> string:
>>
>> 6yuQXuFV5rx2tE5/QL0V9jclw0HnWK+4madV9uAwOsg=
>>
>> Form this HTML snippet:
>>
>> <meta name="csrf-param" content="authenticity_token"/>
>> <meta name="csrf-token" 
>> content="6yuQXuFV5rx2tE5/QL0V9jclw0HnWK+4madV9uAwOsg="/>
>>
>> The Regular Expression Extractor doesn't find the string.
>>
>> I've verified that the following regular expression works using a regular 
>> expression editor:
>>
>> (?<="csrf-token" content=").*(?=")
>>
>> Any ideas on why this isn't working, or how to debug this?
>>
>> Thanks...Rob
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to