[rt-users] Re: [users at httpd] CGI script executing twice

Richard Gration richard at zync.co.uk
Mon Dec 15 14:16:49 EST 2003


On Sunday 14 December 2003 22:42, Chris W wrote:
> I have been having problems with my scripts executing twice so I looked
> at the log file and saw this.
>
>  "POST /cgi-bin/addToCart.pl HTTP/1.1" 200 6473
>  "GET /cgi-bin/addToCart.pl? HTTP/1.1" 200 6417
>
> The first time this script gets values from a form post and works
> correctly, the second time it gets no values and executes a second time,
> is there a way to stop this?  And why is this happening?  BTW it doesn't
> happen if the user is using an old version of Netscape. 4.7.

I'm assuming that you are testing your site from a windows box? Have you tried 
from a box running a different OS?

I had a problem on my site where some windows clients would make odd requests 
which weren't in response to user actions, they were made by Winders for some 
reasons of its own[1], and the pattern of bogosity resembles what you're 
saying here eg valid URLs with '?' tacked on the end, GET requests to pages 
which would only ever be called with a POST request from the site, etc, etc.

Another thing to remember is that many browsers will try and open the most 
recently viewed page when they are re-started, often without any of the 
context which was there when the browser was closed. Just a thought.

Rich

[1] I know this doesn't sound likely, I refused to believe it at first, but I 
would put money on the fact that this is the explanation.



More information about the rt-users mailing list