You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@jmeter.apache.org by Michael Sobczak <ms...@yahoo.com> on 2013/04/10 14:24:00 UTC
CSS/jQuery Extractor for radio button
Hi,
I need to get all of the values for a radio button field on a form, regardless of whether they are checked or not.
For example, I have a radio button field like this:
<input type="radio" value="HTML" title="Output Type" name="outputType" id="outputType1">
<input type="radio" value="PDF" title="Output Type" name="outputType" id="outputType2">
<input type="radio" value="XLS" title="Output Type" name="outputType" id="outputType3">
I need to get an array or list of all of the values: HTML, PDF and XLS. How can I do this?
Thanks,
- Mike.
Re: CSS/jQuery Extractor for radio button
Posted by Flavio Cysne <fl...@gmail.com>.
An equivalent way will work when using a RegEx Extractor Post-processor.
ref. name: outputType
regex: <input type="radio" value="([^"]+)" title="Output Type"
name="outputType"
group to match: $1$
match number: -1
JMeter will store variables as below
outputType_1=HTML
outputType_2=PDF
outputType_3=XLS
2013/4/10 Philippe Mouawad <p....@ubik-ingenierie.com>
> Hello,
> Configuration of CSS/JQuery Extractor:
> 1)Css/Jquery expression : input[name=outputType]
> 2) attribute : value
> 3)reference names : values
>
> JMeter will store variables:
>
> - values_1=HTML
> - values_2=PDF
> - values_3=XLS
> - values_matchNr=3
>
>
> --
> Regards.
> Philippe M..
>
> Follow me on Twitter <http://twitter.com/philmdot>
>
> UBIK LOAD PACK Web Site <http://www.ubikloadpack.com/>
>
> UBIK LOAD PACK on TWITTER <https://twitter.com/ubikloadpack>
>
>
> On Wed, Apr 10, 2013 at 2:24 PM, Michael Sobczak <ms...@yahoo.com>
> wrote:
>
> > Hi,
> >
> > I need to get all of the values for a radio button field on a form,
> > regardless of whether they are checked or not.
> >
> > For example, I have a radio button field like this:
> >
> > <input type="radio" value="HTML" title="Output Type" name="outputType"
> > id="outputType1">
> > <input type="radio" value="PDF" title="Output Type" name="outputType"
> > id="outputType2">
> > <input type="radio" value="XLS" title="Output Type" name="outputType"
> > id="outputType3">
> >
> > I need to get an array or list of all of the values: HTML, PDF and XLS.
> > How can I do this?
> >
> >
> > Thanks,
> >
> > - Mike.
>
Re: CSS/jQuery Extractor for radio button
Posted by Philippe Mouawad <p....@ubik-ingenierie.com>.
Hello,
Configuration of CSS/JQuery Extractor:
1)Css/Jquery expression : input[name=outputType]
2) attribute : value
3)reference names : values
JMeter will store variables:
- values_1=HTML
- values_2=PDF
- values_3=XLS
- values_matchNr=3
--
Regards.
Philippe M..
Follow me on Twitter <http://twitter.com/philmdot>
UBIK LOAD PACK Web Site <http://www.ubikloadpack.com/>
UBIK LOAD PACK on TWITTER <https://twitter.com/ubikloadpack>
On Wed, Apr 10, 2013 at 2:24 PM, Michael Sobczak <ms...@yahoo.com> wrote:
> Hi,
>
> I need to get all of the values for a radio button field on a form,
> regardless of whether they are checked or not.
>
> For example, I have a radio button field like this:
>
> <input type="radio" value="HTML" title="Output Type" name="outputType"
> id="outputType1">
> <input type="radio" value="PDF" title="Output Type" name="outputType"
> id="outputType2">
> <input type="radio" value="XLS" title="Output Type" name="outputType"
> id="outputType3">
>
> I need to get an array or list of all of the values: HTML, PDF and XLS.
> How can I do this?
>
>
> Thanks,
>
> - Mike.