I fail to see how the submit button would be stopping the script.  However,
you could use a 

        if ($REQUEST_METHOD=="POST") {
        // script //
                                                }

and then run the rest of the script.  Unless the rest of the script relies
upon the submit button.

Rick

-----Original Message-----
From: Ron Jamison [mailto:[EMAIL PROTECTED]]
Sent: Friday, December 14, 2001 8:00 AM
To: markus|lervik
Cc: [EMAIL PROTECTED]
Subject: RE: [PHP] Performance


When working with normal connections i.e. non-persistent months ago, using
what must've been PHP 4.0.1 or .2, I had some similar experiences.

In a number of my more lengthy scripts I was seeing MySQL connections
closing on me before the script was done executing.  Thus PHP would spit out
errors about not having a connection and to ensure it worked I was having to
repeatedly call mysql_connect().  I wouldn't doubt the same thing is what
Markus is seeing.  In these cases, using persistent connections solved the
problem for me.

-----Original Message-----
From: markus|lervik [mailto:[EMAIL PROTECTED]]
Sent: Thursday, December 13, 2001 2:16 PM
To: Fournier Jocelyn [Presence-PC]
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP] Performance


On Thu, 2001-12-13 at 23:56, Fournier Jocelyn [Presence-PC] wrote:
> Hi,
>
> You absolutely don't have to reconnect to the database each time a
PHP-block
> ends ! (it would be completely awfull !!).
> Don't you forget to specify the mysql link in you 'mysql_query' ??

Nope, I always specify the mysql link in my queries. But the problem
remains. As I'm at home for the moment, I can't try out all the
suggestions, but I have tried the p_connect, and it most certanly didn't
work. I'll have to try to pinpoint the problem more closely tomorrow at
work.

It just might be (came to think of it now), that php closes the
connection every time I use a submit-button and it reloads the page.
Technically speaking, that would be "ending a script", right?

-Markus

--
Markus Lervik
Linux administrator with a kungfoo grip
Vasa City Library - Public Library



---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail
<[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php



---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail
<[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to