Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

keeping a connection string open

Status
Not open for further replies.

Garabaldi

Technical User
Jan 16, 2002
61
0
0
CA
Hi...

I have a php include files which connects to numerous databases.

When I include this file into my php pages however the connection doesn't stay open.

How can I keep these connections open until I close them without using pconnect.

Thanks
Angelo.
 
are you using php as a cgi or a sapi? is the script being run across a web-browser or locally as a command-line?

typically connections do stay open within the execution life of a script. however the scope of variables is not so global. depending how you are addressing your db connections, you might have to make the resource handles global. the php manual is excellent on variable scope.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top