Re: Connection problem - Mailing list pgsql-php

From Ewald Geschwinde
Subject Re: Connection problem
Date
Msg-id 3C0CE388.40306@cybertec.at
Whole thread Raw
In response to Connection problem  (Laukó Péter <plauko@freemail.hu>)
List pgsql-php
>
>
>
>The code is:
><?
>
>class DBConnection
>{
>    var $con_string;
>
>    function DBConnection()
>    {
>        $con_string = "dbname=hajnalcsillag user=lao password=abc123 host=localhost port=5432";
>        $ret = pg_connect( $this->con_string );
>    }
>}
>
>?>
>

it's better to do it so
$this>con_string="dbname.....";
otherwise you run into big trouble
cause
$this->con_string =>GLOBAL
$con_string=>local

PHP is nto so stble with such declarations
(real-tie experience)
Ewald




pgsql-php by date:

Previous
From: "Dan Wilson"
Date:
Subject: Re: Connection problem
Next
From: Marius Andreiana
Date:
Subject: How to manage search results?