You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jmeter-dev@jakarta.apache.org by Modha Khammammettu <MK...@calcas.com> on 2007/11/22 15:32:38 UTC

HTTPSampler name attribute Question

Hi

I am looking at HTTPSampler elementProp 

<elementProp name="" elementType="HTTPArgument">
                <boolProp
name="HTTPArgument.always_encode">false</boolProp>
                <stringProp name="Argument.name">password</stringProp>
                <stringProp name="Argument.value">pass</stringProp>
                <stringProp name="Argument.metadata">=</stringProp>
                <boolProp name="HTTPArgument.use_equals">true</boolProp>
              </elementProp>

And specifically the lines:

<stringProp name="Argument.name">password</stringProp>
<stringProp name="Argument.value">pass</stringProp>

Looks like Jmeter uses name attribute of a html element to identify a
particular element on a page and then sends the name value pairs when
submitted..

Can it identify element based on my custom attribute, and then send name
value pairs.

I am looking at something like:
<stringProp name="Argument.customattrib">mycustomattrib</stringProp>
----Figure out argument value for name
<stringProp name="Argument.value">pass</stringProp>
Then pass name value pairs.

My html element looks like   <input id="dynamically_changing_value"
name="dynamically_changing_value" customeattrib="fixed".....>
I want to be able to identify element based on customattrib, figure out
what is in the name and then send that name value pair.

Please let me know if we can do this.

Thanks
Modha/-



Re: HTTPSampler name attribute Question

Posted by sebb <se...@gmail.com>.
On 22/11/2007, Modha Khammammettu <MK...@calcas.com> wrote:
> Hi
>
> I am looking at HTTPSampler elementProp
>
> <elementProp name="" elementType="HTTPArgument">
>                <boolProp
> name="HTTPArgument.always_encode">false</boolProp>
>                <stringProp name="Argument.name">password</stringProp>
>                <stringProp name="Argument.value">pass</stringProp>
>                <stringProp name="Argument.metadata">=</stringProp>
>                <boolProp name="HTTPArgument.use_equals">true</boolProp>
>              </elementProp>
>
> And specifically the lines:
>
> <stringProp name="Argument.name">password</stringProp>
> <stringProp name="Argument.value">pass</stringProp>
>
> Looks like Jmeter uses name attribute of a html element to identify a
> particular element on a page and then sends the name value pairs when
> submitted..

No, that's not the case. They are internal names used by JMeter to
identify the parts of the parameter list.

> Can it identify element based on my custom attribute, and then send name
> value pairs.
>
> I am looking at something like:
> <stringProp name="Argument.customattrib">mycustomattrib</stringProp>
> ----Figure out argument value for name
> <stringProp name="Argument.value">pass</stringProp>
> Then pass name value pairs.
>
> My html element looks like   <input id="dynamically_changing_value"
> name="dynamically_changing_value" customeattrib="fixed".....>
> I want to be able to identify element based on customattrib, figure out
> what is in the name and then send that name value pair.

You'll need to use the RE Post-Processor to extract the values from
the response, and then use them in the parameter list:

Name: id
Value: ${IDVALUE}

etc

> Please let me know if we can do this.
>
> Thanks
> Modha/-
>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-dev-help@jakarta.apache.org