pg.ddx.io  pgsql-php@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Timothy_Maguire@hartehanks.com
To: pgsql-php@postgresql.org
Subject: using includes
Date: Tue, 23 Jan 2001 10:42:57 -0500
Message-ID: <852569DD.005655D6.00@linmail.hartehanks.com> (raw)

I have a few questions on connections to the db and using the pgsql.php module.

First, I have been using pg_connect for all my connections but have run into
some problems when I include and require files that also use pg_connect.  I have
2 db servers that i use all the time and one web server.  (The first db, on my
web server called A and the other db server called B)  I noticed that if I use
pg_pconnect for Server A, (webserver) the entire server crashes and none of the
pages will load.  The server just freezes.  And if I use pg_connect on server B,
I get errors saying it doesn't recognize the connection.  So, I now use just
pg_connect to server A and pg_pconnect on server B.  I was wondering what is the
difference in this or is there another way of solving this problem?

Also, I just picked up the book "PHP - Developer's Cookbook" by Sterling Hughes.
(It is a decent book)  I was reading about the pgsql.php module where if you
include it, you can use db_connect for all your connections.  Basically what it
does is make php act more of an object oriented language and creates functions
for smaller php scripts.  Has anyone used these?  Does anyone kow what I am
talking about?  I include the file fine but i keep on getting errors saying
db_connect is not a supported function when it is in the file.  In order to use
these includes, do we have to install or config php a certain way.  I can send
my code if you need that.

thanks,
Tim.





Message-ID: <852569DD.005655D6.00@linmail.hartehanks.com>
Permalink:  ../852569DD.005655D6.00@linmail.hartehanks.com/
Also on:    postgresql.org/message-id/852569DD.005655D6.00@linmail.hartehanks.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-php@postgresql.org
  Cc: Timothy_Maguire@hartehanks.com
  Subject: Re: using includes
  In-Reply-To: <852569DD.005655D6.00@linmail.hartehanks.com>
  References: <852569DD.005655D6.00@linmail.hartehanks.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox