Hi Deepak,

In order of simplify the things I tested another web page which does not
have dynamic form ID and URL. 

The web page update the content of the page. In browser I am able to update
the content but not through jMeter. 

I have attached the HTTPLiveHeaders Data and JMeter Result Tree data file
along with this post. I am not able to find why I am not able to update the
content using jmeter.

http://old.nabble.com/file/p26626554/HTTPLiveHeadersOutput
HTTPLiveHeadersOutput 

http://old.nabble.com/file/p26626554/JMeterResultTreeOutput
JMeterResultTreeOutput 


Can you please look into this files and point out what could be the reason
for jmeter not updating the content.


Thanks and Regards


Harry_ wrote:
> 
> Thanks for the reply Deepak.
> 
> I will try this in the morning and will let you know about the results.
> 
> Regards
> 
> 
> Deepak Shetty wrote:
>> 
>>>then user is taken to Accept Terms and Conditions page.
>> How is this implemented?
>>  If it is via a redirect then it's ok so long as you have follow
>> redirects.
>> if its via some javascript window.location.href, then you must test
>> whether
>> the page contains this (using say a regex extractor with an IF controller
>> which checks what value you got).
>> If your question is how do I know whether I got redirected or not you
>> could
>> either extract out the text and use an IF controller or you could disable
>> follow redirects and check the status code (again you can extract this
>> using
>> regex or beanshell post processors). Im assuming here that a user who has
>> successfully logged in and previously accepted gets a 200 status code. It
>> is
>> difficult however for anyone to know how your application behaves since
>> there are many ways in which your application could have implemented the
>> behavior you see. In all cases however the response(including the url) is
>> always available to JMeter to inspect in any post processor.
>> 
>>>and random form id in the page.
>> This will typically be of the form <input type="hidden" name="form-id"
>> value="some random value" />
>> You would write a regex extractor like
>> <input.*?name="form-id"\s*?value="([^"]*)" and you can have the value in
>> a
>> variable and post it into the next request with ${VAR_NAME}.
>> 
>> 
>> regards
>> deepak
>> 
>> On Wed, Dec 2, 2009 at 4:49 PM, Harry_ <harjitwo...@gmail.com> wrote:
>> 
>>>
>>> Hi Deepak,
>>>
>>> I can only read when I am having response of the page.
>>>
>>> Suppose I am on login page.
>>>
>>> I make corresponding Http Request Sampler for this.
>>>
>>> Now if the user has not accepted the conditions then user is taken to
>>> Accept
>>> Terms and Conditions page.
>>>
>>> The page address is something like:
>>> http://test/acceptterms/userid/[some<http://test/acceptterms/userid/%5Bsome>random
>>> combination of alphanumeric
>>> characters]  and random form id in the page.
>>>
>>> So how can I get to this page through jmeter when I do not know in
>>> advance
>>> what will be the random characters in url.
>>>
>>> If somehow, if jmeter can take me to the page which comes up after
>>> login,
>>> and tell me its URL and its source. Then I can use Regex Post processor
>>> to
>>> extract necessary information and hit this url with appropriate values.
>>>
>>> But I dont know whether jmeter can do this or not.
>>>
>>> Regards
>>>
>>>
>>> Deepak Shetty wrote:
>>> >
>>> > Hi
>>> >>And how do i extract form ID.
>>> > Regex Post processor (or xpath or any of the other post processors
>>> that
>>> > work)
>>> >>I have no information about this page during http request for login.
>>> > Yes you do , your application always behaves in the same way right.
>>> you
>>> > know
>>> > that there will be a form which has a dynamic value. You either know
>>> the
>>> > name or the location where this will be and you can extract and send
>>> it.
>>> > you
>>> > can also have conditionals that check either the url or content (if
>>> > controllers) and vary the next request accordingly.
>>> >
>>> > regards
>>> > deepak
>>> >
>>> > On Wed, Dec 2, 2009 at 4:21 PM, Harry_ <harjitwo...@gmail.com> wrote:
>>> >
>>> >>
>>> >> Yes I am using Cookie Manager.
>>> >>
>>> >> I am able to visit pages for logged on users (provided Accept Terms &
>>> >> Conditions is already accepted for user). If I dont use cookie
>>> manager,
>>> i
>>> >> get Forbidden errors.
>>> >>
>>> >> And how do i extract form ID.
>>> >>
>>> >> Suppose I enter User name and password and click Submit (JMeter HTTP
>>> Post
>>> >> request with params). Now I get another page which has form with
>>> dynamic
>>> >> form ID. I have no information about this page during http request
>>> for
>>> >> login. How can I know the ID of the page.
>>> >>
>>> >> Is there any way by which I can get this information. Like I click on
>>> on
>>> >> login by providing credentials and I get information about the
>>> resulting
>>> >> page source (Accept Terms and Conditions in our case.) So that I can
>>> pass
>>> >> necessary information to the resulting page.
>>> >>
>>> >> Regards
>>> >>
>>> >>
>>> >> Deepak Shetty wrote:
>>> >> >
>>> >> > Also have you added the CookieManager
>>> >> >
>>> >> > On Wed, Dec 2, 2009 at 1:46 PM, Deepak Shetty <shet...@gmail.com>
>>> >> wrote:
>>> >> >
>>> >> >> Hi
>>> >> >> not sure what you are referring to , but you need to check
>>> >> >> a. The request itself seems to be to a dynamically generated url.
>>> Are
>>> >> you
>>> >> >> extracting this out from the previous request correctly? the form
>>> >> build
>>> >> >> id
>>> >> >> parameter too seems to be dynamic, are you extracting this
>>> correctly
>>> >> (or
>>> >> >> are
>>> >> >> you just sending out recorded values )
>>> >> >> b. In your previous message you specified that it works for 1
>>> user.
>>> >> Does
>>> >> >> the test work only for the recorded user or does it work the first
>>> >> time?
>>> >> >> If
>>> >> >> the problem was in cookies you need to see the request after
>>> >> set-cookie,
>>> >> >> if
>>> >> >> jmeter does send the cookies then the problem isn't there.
>>> >> >> you need to check what your script is doing.
>>> >> >> regards
>>> >> >> deepak
>>> >> >>
>>> >> >>
>>> >> >>
>>> >> >> On Wed, Dec 2, 2009 at 12:59 PM, Harry_ <harjitwo...@gmail.com>
>>> wrote:
>>> >> >>
>>> >> >>>
>>> >> >>> I checked the headers using "Live HTTP Headers" and in "View
>>> Result
>>> >> >>> Tree".
>>> >> >>>
>>> >> >>> The difference is in setting Cookie. Is it something why my test
>>> is
>>> >> not
>>> >> >>> accepting the terms and conditions. If yes how do I set these
>>> cookies
>>> >> in
>>> >> >>> jMeter, if it is not doing by itself.
>>> >> >>>
>>> >> >>>
>>> >> >>> Live HTTP Headers Shows:
>>> >> >>>
>>> >> >>> http://test/legal_accept/56008/3e787bed9257fd643a45a0f2c25fe1aa
>>> >> >>>
>>> >> >>>
>>> >> >>>
>>> >> >>> POST /legal_accept/56008/3e787bed9257fd643a45a0f2c25fe1aa
>>> HTTP/1.1
>>> >> >>>
>>> >> >>> Host: test
>>> >> >>> User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-GB;
>>> rv:1.9.0.15)
>>> >> >>> Gecko/2009102815 Ubuntu/9.04 (jaunty) Firefox/3.0.15
>>> >> >>>
>>> >> >>> Accept:
>>> >> text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
>>> >> >>>
>>> >> >>> Accept-Language: en-gb,en;q=0.5
>>> >> >>>
>>> >> >>> Accept-Encoding: gzip,deflate
>>> >> >>>
>>> >> >>> Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
>>> >> >>>
>>> >> >>> Keep-Alive: 300
>>> >> >>>
>>> >> >>> Connection: keep-alive
>>> >> >>>
>>> >> >>> Referer:
>>> >> http://test/legal_accept/56008/3e787bed9257fd643a45a0f2c25fe1aa
>>> >> >>>
>>> >> >>> Cookie:
>>> >> __utma=236072452.573991268.1259585934.1259771130.1259784337.4;
>>> >> >>>
>>> >> >>>
>>> >>
>>> __utmz=236072452.1259585934.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none);
>>> >> >>> SESSdaebf48ce4666186eb29a7f5b9e90b00=3pfe3c5cfn5di2dbebivfs4at0;
>>> >> >>>
>>> __utmv=236072452.authenticated%20user%2Cadministrator%3A%3A%3A%3A%3A;
>>> >> >>> has_js=1; __utmc=236072452; _csoot=1259775258852;
>>> >> >>> _csuid=4ae6d3624bed3faf;
>>> >> >>> __utmb=236072452.53.10.1259784337; DRUPAL_LOGGED_IN=Y
>>> >> >>>
>>> >> >>> Content-Type: application/x-www-form-urlencoded
>>> >> >>>
>>> >> >>> Content-Length: 98
>>> >> >>>
>>> >> >>>
>>> >> >>>
>>> >>
>>> form_build_id=form-9565758b95b12d94f330804f32f13449&form_id=legal_login&legal_accept=on&op=Confirm
>>> >> >>>
>>> >> >>> HTTP/1.x 302 Found
>>> >> >>>
>>> >> >>> Date: Wed, 02 Dec 2009 20:47:31 GMT
>>> >> >>>
>>> >> >>> Server: Apache/2.2.9 (Unix) mod_ssl/2.2.9
>>> OpenSSL/0.9.8e-fips-rhel5
>>> >> >>> PHP/5.2.9
>>> >> >>>
>>> >> >>> X-Powered-By: PHP/5.2.9
>>> >> >>>
>>> >> >>> Cache-Control: no-store, no-cache, must-revalidate, post-check=0,
>>> >> >>> pre-check=0
>>> >> >>>
>>> >> >>> Pragma: no-cache
>>> >> >>>
>>> >> >>> Set-Cookie: DRUPAL_LOGGED_IN=Y; expires=Tue, 01-Dec-2009 20:47:31
>>> >> GMT;
>>> >> >>> path=/
>>> >> >>>
>>> >> >>> Set-Cookie: ns_remember=deleted; expires=Tue, 02-Dec-2008
>>> 20:47:31
>>> >> GMT;
>>> >> >>> path=/
>>> >> >>>
>>> >> >>> Set-Cookie: DRUPAL_LOGGED_IN=Y; expires=Sat, 26-Dec-2009 00:20:52
>>> >> GMT;
>>> >> >>> path=/
>>> >> >>>
>>> >> >>> Expires: Sun, 19 Nov 1978 05:00:00 GMT
>>> >> >>>
>>> >> >>> Last-Modified: Mon, 23 Apr 2010 02:00:32 GMT
>>> >> >>>
>>> >> >>> Etag: "d41d8cd98f00b204e9800998ecf8427e"
>>> >> >>>
>>> >> >>> X-Drupal: loggedin
>>> >> >>>
>>> >> >>> Location: http://test/
>>> >> >>>
>>> >> >>> Content-Length: 0
>>> >> >>>
>>> >> >>> Connection: close
>>> >> >>>
>>> >> >>> Content-Type: text/html; charset=utf-8
>>> >> >>>
>>> >> >>>
>>> >> >>> ----------
>>> >> >>>
>>> >> >>> View Result Tree Headers Shows:
>>> >> >>>
>>> >> >>> Sampler Result Tab
>>> >> >>>
>>> >> >>> Thread Name: Thread Group 1-1
>>> >> >>> Sample Start: 2009-12-02 20:25:31 GMT
>>> >> >>> Load time: 518
>>> >> >>> Latency: 518
>>> >> >>> Size in bytes: 0
>>> >> >>> Sample Count: 1
>>> >> >>> Error Count: 0
>>> >> >>> Response code: 302
>>> >> >>> Response message: Found
>>> >> >>>
>>> >> >>> Response headers:
>>> >> >>> HTTP/1.1 302 Found
>>> >> >>> Date: Wed, 02 Dec 2009 20:25:50 GMT
>>> >> >>> Server: Apache/2.2.9 (Unix) mod_ssl/2.2.9
>>> OpenSSL/0.9.8e-fips-rhel5
>>> >> >>> PHP/5.2.9
>>> >> >>> X-Powered-By: PHP/5.2.9
>>> >> >>> Set-Cookie:
>>> >> >>> SESSdaebf48ce4666186eb29a7f5b9e90b00=mpaspit0fcl9rmp5r2nv5agtg0;
>>> >> >>> expires=Fri, 25-Dec-2009 23:59:10 GMT; path=/; domain=.test
>>> >> >>> Expires: Sun, 19 Nov 1978 05:00:00 GMT
>>> >> >>> Last-Modified: Mon, 23 Apr 2010 02:00:32 GMT
>>> >> >>> Cache-Control: post-check=0, pre-check=0
>>> >> >>> ETag: "d41d8cd98f00b204e9800998ecf8427e"
>>> >> >>> Location: http://test/
>>> >> >>> Content-Length <http://test/%0AContent-Length>: 0
>>> >> >>> Connection: close
>>> >> >>> Content-Type: text/html; charset=utf-8
>>> >> >>>
>>> >> >>>
>>> >> >>> HTTPSampleResult fields:
>>> >> >>> ContentType: text/html; charset=utf-8
>>> >> >>> DataEncoding: utf-8
>>> >> >>> ---------------------------------
>>> >> >>> Request Tab
>>> >> >>>
>>> >> >>> POST
>>> http://test/legal_accept/56005/1c54c8bf3308d9138388b77d7b0911bf
>>> >> >>>
>>> >> >>> POST data:
>>> >> >>>
>>> >> >>>
>>> >>
>>> form_build_id=form-3b21145374b980b87ef4fd87e64f625a&form_id=legal_login&legal_accept=on&op=Confirm
>>> >> >>>
>>> >> >>> [no cookies]
>>> >> >>>
>>> >> >>> Request Headers:
>>> >> >>> Accept-Language: en-gb,en;q=0.5
>>> >> >>> Content-Length: 98
>>> >> >>> Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
>>> >> >>> Referer:
>>> >> http://test/legal_accept/56005/1c54c8bf3308d9138388b77d7b0911bf
>>> >> >>> Accept-Encoding<
>>> >>
>>> http://test/legal_accept/56005/1c54c8bf3308d9138388b77d7b0911bf%0AAccept-Encoding
>>> >> >:
>>> >> >>> gzip,deflate
>>> >> >>> Keep-Alive: 300
>>> >> >>> User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-GB;
>>> rv:1.9.0.15)
>>> >> >>> Gecko/2009102815 Ubuntu/9.04 (jaunty) Firefox/3.0.15
>>> >> >>> Connection: keep-alive
>>> >> >>> Content-Type: application/x-www-form-urlencoded
>>> >> >>> Accept:
>>> >> text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
>>> >> >>>
>>> >> >>>
>>> >> >>>
>>> >> >>>
>>> >> >>>
>>> >> >>>
>>> >> >>>
>>> >> >>> Deepak Shetty wrote:
>>> >> >>> >
>>> >> >>> > All of these class of problems are covered by 'Why does Jmeter
>>> not
>>> >> >>> behave
>>> >> >>> > like my browser' covered in
>>> >> >>> > http://wiki.apache.org/jakarta-jmeter/DifferentBehaviour. And
>>> all
>>> >> need
>>> >> >>> you
>>> >> >>> > to understand how your application behaves(any browser tool
>>> like
>>> >> >>> > fiddler/livehttpheaders) v/s what Jmeter is sending(view
>>> results
>>> >> >>> tree).
>>> >> >>> >
>>> >> >>> > If i have to guess, your application probably stores the
>>> acceptance
>>> >> as
>>> >> >>> a
>>> >> >>> > cookie, and the second iteration (for the different user)
>>> probably
>>> >> >>> does
>>> >> >>> > something wrong. perhaps you clear the cookies and dont set it,
>>> >> >>> perhaps
>>> >> >>> > you
>>> >> >>> > get the earlier cookie, you need to .This is a guess , we dont
>>> >> know,
>>> >> >>> check
>>> >> >>> > your application against what you have specified in jmeter
>>> >> >>> > regards
>>> >> >>> > deepak
>>> >> >>> >
>>> >> >>> > On Wed, Dec 2, 2009 at 9:07 AM, Harry_ <harjitwo...@gmail.com>
>>> >> wrote:
>>> >> >>> >
>>> >> >>> >>
>>> >> >>> >> Hi,
>>> >> >>> >>
>>> >> >>> >> I have created a test plan using HTTP Proxy Server recording
>>> the
>>> >> >>> >> following
>>> >> >>> >> sequence.
>>> >> >>> >>
>>> >> >>> >> 1. New User Login to System with valid user name and Password.
>>> >> >>> >> 2. Accepts the terms and conditions (This sends post
>>> information
>>> >> to
>>> >> >>> >> server
>>> >> >>> >> that user is accepting terms and conditions. This happens only
>>> >> once.)
>>> >> >>> >> 3. Now user can navigate various pages of the site which are
>>> >> >>> accessible
>>> >> >>> >> to
>>> >> >>> >> login user.
>>> >> >>> >>
>>> >> >>> >> Now when I re-run this test with different new user with
>>> different
>>> >> >>> >> username/password from csv file, i get the following error for
>>> >> pages
>>> >> >>> of
>>> >> >>> >> third step.
>>> >> >>> >>
>>> >> >>> >>  Response code: 403
>>> >> >>> >>  Response message: Forbidden
>>> >> >>> >>
>>> >> >>> >> First two steps shows success and I have checked that jMeter
>>> >> during
>>> >> >>> the
>>> >> >>> >> run
>>> >> >>> >> sends terms and condition accept params to the server of
>>> step2.
>>> >> >>> >>
>>> >> >>> >> But the terms and conditions are still not accepted that is
>>> why
>>> we
>>> >> >>> get
>>> >> >>> >> the
>>> >> >>> >> error on pages of step 3.
>>> >> >>> >>
>>> >> >>> >> Now can anyone point me where could be the problem. Why Post
>>> >> params
>>> >> >>> sent
>>> >> >>> >> through jMeter for checkboxes is not accepted by the server.
>>> >> >>> >>
>>> >> >>> >> The problem seems to be with check boxes only. Because if I
>>> had
>>> >> >>> already
>>> >> >>> >> accepted the terms and conditions, jmeter works fine for every
>>> >> >>> request.
>>> >> >>> >>
>>> >> >>> >> If this a defect can anyone suggest me a workaround. I have to
>>> >> work
>>> >> >>> with
>>> >> >>> >> checkboxes quite often, so I am facing this problem
>>> everywhere.
>>> >> >>> >>
>>> >> >>> >> Thanks and Regards
>>> >> >>> >> --
>>> >> >>> >> View this message in context:
>>> >> >>> >>
>>> >> >>>
>>> >>
>>> http://old.nabble.com/Accept-Terms-and-Conditions-checkbox-not-working-through-jMeter-tp26612532p26612532.html
>>> >> >>> >> Sent from the JMeter - User mailing list archive at
>>> Nabble.com.
>>> >> >>> >>
>>> >> >>> >>
>>> >> >>> >>
>>> >> ---------------------------------------------------------------------
>>> >> >>> >> To unsubscribe, e-mail:
>>> jmeter-user-unsubscr...@jakarta.apache.org
>>> >> >>> >> For additional commands, e-mail:
>>> >> jmeter-user-h...@jakarta.apache.org
>>> >> >>> >>
>>> >> >>> >>
>>> >> >>> >
>>> >> >>> >
>>> >> >>>
>>> >> >>> --
>>> >> >>> View this message in context:
>>> >> >>>
>>> >>
>>> http://old.nabble.com/Accept-Terms-and-Conditions-checkbox-not-working-through-jMeter-tp26612532p26616337.html
>>> >> >>> Sent from the JMeter - User mailing list archive at Nabble.com.
>>> >> >>>
>>> >> >>>
>>> >> >>>
>>> ---------------------------------------------------------------------
>>> >> >>> To unsubscribe, e-mail:
>>> jmeter-user-unsubscr...@jakarta.apache.org
>>> >> >>> For additional commands, e-mail:
>>> jmeter-user-h...@jakarta.apache.org
>>> >> >>>
>>> >> >>>
>>> >> >>
>>> >> >
>>> >> >
>>> >>
>>> >> --
>>> >> View this message in context:
>>> >>
>>> http://old.nabble.com/Accept-Terms-and-Conditions-checkbox-not-working-through-jMeter-tp26612532p26618806.html
>>> >> Sent from the JMeter - User mailing list archive at Nabble.com.
>>> >>
>>> >>
>>> >> ---------------------------------------------------------------------
>>> >> To unsubscribe, e-mail: jmeter-user-unsubscr...@jakarta.apache.org
>>> >> For additional commands, e-mail: jmeter-user-h...@jakarta.apache.org
>>> >>
>>> >>
>>> >
>>> >
>>>
>>> --
>>> View this message in context:
>>> http://old.nabble.com/Accept-Terms-and-Conditions-checkbox-not-working-through-jMeter-tp26612532p26619192.html
>>> Sent from the JMeter - User mailing list archive at Nabble.com.
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: jmeter-user-unsubscr...@jakarta.apache.org
>>> For additional commands, e-mail: jmeter-user-h...@jakarta.apache.org
>>>
>>>
>> 
>> 
> 
> 

-- 
View this message in context: 
http://old.nabble.com/Accept-Terms-and-Conditions-checkbox-not-working-through-jMeter-tp26612532p26626554.html
Sent from the JMeter - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-user-unsubscr...@jakarta.apache.org
For additional commands, e-mail: jmeter-user-h...@jakarta.apache.org

Reply via email to