Strange behaviour with self written class - Mailing list pgsql-php

From Markus Fischer
Subject Strange behaviour with self written class
Date
Msg-id 20010305105420.A27544@josefine.ben.tuwien.ac.at
Whole thread Raw
Responses Re: Strange behaviour with self written class  (Michael Fork <mfork@toledolink.com>)
Re: Strange behaviour with self written class  (Michael Fork <mfork@toledolink.com>)
List pgsql-php
Hello,

    I've written a class for the pgsql_* function ( just a
wrapper to speed up things and have a cleaner interface, I've
attached it). While working with it, I've made some interesting
observation :

When create my first instance of the class all works ok; then,
later in a function in my new php file I create another instance
of the same class; this time the connection can be established,
but its somehow corrupted and subsequent queries fail because of
this:

called dbpg->connect()
connectstring -> host=XXXXXXXXXXXXXX user=XXXXXX password=XXXXXXX dbname=XXXXXX
connect() succeeded
connectLink = resource
resource(1) of type (pgsql link)

called        <- function called
called dbpg->connect()
connectstring -> host=XXXXXXXXXXXXXX user=XXXXXX password=XXXXXXX dbname=XXXXXX
connect() succeeded
connectLink = resource
resource(1) of type (Unknown)

its still of type resource, but its resource type is NOT pgsql
link like above but 'Unknown'.

Anyone know whats wrong or why this happening ?

thanks
    Markus

--
Markus Fischer,  http://josefine.ben.tuwien.ac.at/~mfischer/
EMail:         mfischer@josefine.ben.tuwien.ac.at
PGP Public  Key: http://josefine.ben.tuwien.ac.at/~mfischer/C2272BD0.asc
PGP Fingerprint: D3B0 DD4F E12B F911 3CE1  C2B5 D674 B445 C227 2BD0

Attachment

pgsql-php by date:

Previous
From: "Andy Arledge"
Date:
Subject: novice question
Next
From: Michael Fork
Date:
Subject: Re: Strange behaviour with self written class