pg.ddx.io  pgsql-php@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Having tough time getting php working for postgresql.. Pleeese help
9+ messages / 8 participants
[nested] [flat]

* Having tough time getting php working for postgresql.. Pleeese help
@ 2006-01-09 22:23  Jagan Reddy <jaganreddy98@yahoo.com>
  0 siblings, 2 replies; 9+ messages in thread

From: Jagan Reddy @ 2006-01-09 22:23 UTC (permalink / raw)
  To: pgsql-php

Hello,
  I have successfully compiled and installed postgresql 8.1.1. I have created some databases as well.
  But I want to get php working with pgsql so that I can do some web develoement.
   
  Whatever rpms I get and insall, it is still complaining for another.  I believe I have PHP 4.3.9 and I tried here to insall php-pgsql4.3.9.  No luck.  
   
  I am still running the default PHP installed by RedHat linux installaion process.  I have not removed and installed source code based PHP though.
   
  Thanks
  Jagan Reddy
   
  [root@gireesh tmp]# rpm -Uvh php-pgsql-4.3.9-3.i386.rpm
warning: php-pgsql-4.3.9-3.i386.rpm: V3 DSA signature: NOKEY, key ID 4f2a6fd2
error: Failed dependencies:
        php = 4.3.9-3 is needed by php-pgsql-4.3.9-3.i386
[root@gireesh tmp]# php --version
PHP 4.3.9 (cgi) (built: Nov  4 2005 11:49:35)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies
[root@gireesh tmp]#

^ permalink  raw  reply  [nested|flat] 9+ messages in thread

* Re: Having tough time getting php working for postgresql..
@ 2006-01-09 23:00  Jeff MacDonald <jam@zoidtechnologies.com>
  parent: Jagan Reddy <jaganreddy98@yahoo.com>
  1 sibling, 1 reply; 9+ messages in thread

From: Jeff MacDonald @ 2006-01-09 23:00 UTC (permalink / raw)
  To: Jagan Reddy <jaganreddy98@yahoo.com>; +Cc: pgsql-php

greetings,

On Mon, 2006-01-09 at 14:23 -0800, Jagan Reddy wrote:
> Hello,
> I have successfully compiled and installed postgresql 8.1.1. I have
> created some databases as well.
> But I want to get php working with pgsql so that I can do some web
> develoement.
>  
> Whatever rpms I get and insall, it is still complaining for another.
> I believe I have PHP 4.3.9 and I tried here to insall php-pgsql4.3.9.
> No luck.  
>  
> I am still running the default PHP installed by RedHat linux
> installaion process.  I have not removed and installed source code
> based PHP though.
>  
> Thanks
> Jagan Reddy
>  

what version of redhat are you using?

what version of the php rpm to do you have installed? (use 'rpm -q php'
to check)

regards,
J
-- 
Jeff MacDonald
Zoid Technologies, http://zoidtechnologies.com/




^ permalink  raw  reply  [nested|flat] 9+ messages in thread

* Re: Having tough time getting php working for postgresql..
@ 2006-01-10 07:16  brew@theMode.com
  parent: Jagan Reddy <jaganreddy98@yahoo.com>
  1 sibling, 0 replies; 9+ messages in thread

From: brew@theMode.com @ 2006-01-10 07:16 UTC (permalink / raw)
  To: pgsql-php


Jagan......

> But I want to get php working with pgsql so that I can do some web develoement.

Check that you have php working using the php_info function.  Place a file
in your web area containing this:

<?php
phpinfo();
?>

If php is working it should show a bunch of info.  Read about the
phpinfo() function at:

http://php.net/manual/en/function.phpinfo.php

You further need postgreSQL support.  This is for the postgreSQL php
functions.  It should report this on the page, under the heading pgsql.

If you don't have it, you'll have to figure out how to add it.

If postgreSQL support shows on the phpinfo output the next step is to make
a connection to the database.

At which point are you having problems?  I can't help you with Red Hat as
I use Debian, but it must be similar.

brew

 ==========================================================================
                  Strange Brew   (brew@theMode.com)
  Check out my Stock Option Covered Call website  http://www.callpix.com
     and my Musician's Online Database Exchange http://www.TheMode.com
 ==========================================================================




^ permalink  raw  reply  [nested|flat] 9+ messages in thread

* Re: Having tough time getting php working for postgresql..
@ 2006-01-10 14:04  manjusri schuit <manjusri.schuit@gmail.com>
  parent: Jeff MacDonald <jam@zoidtechnologies.com>
  0 siblings, 0 replies; 9+ messages in thread

From: manjusri schuit @ 2006-01-10 14:04 UTC (permalink / raw)
  To: Jeff MacDonald <jam@zoidtechnologies.com>; +Cc: Jagan Reddy <jaganreddy98@yahoo.com>; pgsql-php

Hello
form the php site--

In order to enable PostgreSQL support, --with-pgsql[=DIR] is required when
you compile PHP. DIR is the PostgreSQL base install directory, defaults to
/usr/local/pgsql. If shared object module is available, PostgreSQL module
may be loaded using
extension<http://nl3.php.net/manual/nl/ini.sect.path-directory.php#ini.extension>directive
in
php.ini or *dl()* <http://nl3.php.net/manual/nl/function.dl.php; function.

The default php instalations on most linux distro's don't come with
postgresql enabled !
So you need to unistall the default php version first.


On 1/10/06, Jeff MacDonald <jam@zoidtechnologies.com> wrote:
>
> greetings,
>
> On Mon, 2006-01-09 at 14:23 -0800, Jagan Reddy wrote:
> > Hello,
> > I have successfully compiled and installed postgresql 8.1.1. I have
> > created some databases as well.
> > But I want to get php working with pgsql so that I can do some web
> > develoement.
> >
> > Whatever rpms I get and insall, it is still complaining for another.
> > I believe I have PHP 4.3.9 and I tried here to insall php-pgsql4.3.9.
> > No luck.
> >
> > I am still running the default PHP installed by RedHat linux
> > installaion process.  I have not removed and installed source code
> > based PHP though.
> >
> > Thanks
> > Jagan Reddy
> >
>
> what version of redhat are you using?
>
> what version of the php rpm to do you have installed? (use 'rpm -q php'
> to check)
>
> regards,
> J
> --
> Jeff MacDonald
> Zoid Technologies, http://zoidtechnologies.com/
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: if posting/reading through Usenet, please send an appropriate
>        subscribe-nomail command to majordomo@postgresql.org so that your
>        message can get through to the mailing list cleanly
>



--
Met vriendelijke groet
Manjusri Schuit

^ permalink  raw  reply  [nested|flat] 9+ messages in thread

* Re: Having tough time getting php working for postgresql..
@ 2006-01-10 16:20  Sherwin M. Harris <Sherwin_Harris@byu.edu>
  0 siblings, 1 reply; 9+ messages in thread

From: Sherwin M. Harris @ 2006-01-10 16:20 UTC (permalink / raw)
  To: pgsql-php

Do NOT uninstall. The package you need to install is called php-pgsql.
You should be able to do a (as root of course or sudo if that is set up)

Yum install php-pgsql

Restart apache and you are good to go.

Sherwin Harris

 

________________________________

From: pgsql-php-owner@postgresql.org
[mailto:pgsql-php-owner@postgresql.org] On Behalf Of manjusri schuit
Sent: Tuesday, January 10, 2006 7:05 AM
To: Jeff MacDonald
Cc: Jagan Reddy; pgsql-php@postgresql.org
Subject: Re: [PHP] Having tough time getting php working for
postgresql..

 

Hello
form the php site--

In order to enable PostgreSQL support, --with-pgsql[=DIR] is required
when you compile PHP. DIR is the PostgreSQL base install directory,
defaults to /usr/local/pgsql. If shared object module is available,
PostgreSQL module may be loaded using extension
<http://nl3.php.net/manual/nl/ini.sect.path-directory.php#ini.extension;
directive in php.ini or dl()
<http://nl3.php.net/manual/nl/function.dl.php;  function.

The default php instalations on most linux distro's don't come with
postgresql enabled !
So you need to unistall the default php version first.



On 1/10/06, Jeff MacDonald <jam@zoidtechnologies.com> wrote:

greetings,

On Mon, 2006-01-09 at 14:23 -0800, Jagan Reddy wrote:
> Hello,
> I have successfully compiled and installed postgresql 8.1.1. I have
> created some databases as well.
> But I want to get php working with pgsql so that I can do some web 
> develoement.
>
> Whatever rpms I get and insall, it is still complaining for another.
> I believe I have PHP 4.3.9 and I tried here to insall php-pgsql4.3.9.
> No luck.
>
> I am still running the default PHP installed by RedHat linux 
> installaion process.  I have not removed and installed source code
> based PHP though.
>
> Thanks
> Jagan Reddy
>

what version of redhat are you using?

what version of the php rpm to do you have installed? (use 'rpm -q php' 
to check)

regards,
J
--
Jeff MacDonald
Zoid Technologies, http://zoidtechnologies.com/


---------------------------(end of broadcast)---------------------------

TIP 1: if posting/reading through Usenet, please send an appropriate
       subscribe-nomail command to majordomo@postgresql.org so that your
       message can get through to the mailing list cleanly 




-- 
Met vriendelijke groet
Manjusri Schuit

^ permalink  raw  reply  [nested|flat] 9+ messages in thread

* Re: Having tough time getting php working for postgresql..
@ 2006-01-11 17:35  Patrick White <ptothew@gmail.com>
  parent: Sherwin M. Harris <Sherwin_Harris@byu.edu>
  0 siblings, 2 replies; 9+ messages in thread

From: Patrick White @ 2006-01-11 17:35 UTC (permalink / raw)
  To: pgsql-php

Hello,

I was having trouble with setting up php-pgsql, but I think I have it
up and running. Before I attempt to move forward with attempting to
code without knowing if the environment is setup correctly, does
anybody know what exactly I am looking for in the phpinfo() tables. I
did a find for pgsql, postgre, etc. and didn't find anything.

I am running Windows XP Pro, Apache 2, PHP 5.1.1, PostgreSQL 8.0.

Thank you in advance.

Patrick

On 1/10/06, Sherwin M. Harris <Sherwin_Harris@byu.edu> wrote:
>
>
>
> Do NOT uninstall. The package you need to install is called php-pgsql. You
> should be able to do a (as root of course or sudo if that is set up)
>
> Yum install php-pgsql
>
> Restart apache and you are good to go.
>
> Sherwin Harris
>
>
>
>  ________________________________
>
>
> From: pgsql-php-owner@postgresql.org [mailto:pgsql-php-owner@postgresql.org]
> On Behalf Of manjusri schuit
>  Sent: Tuesday, January 10, 2006 7:05 AM
>  To: Jeff MacDonald
>  Cc: Jagan Reddy; pgsql-php@postgresql.org
>  Subject: Re: [PHP] Having tough time getting php working for postgresql..
>
>
>
>
> Hello
>  form the php site--
>
>  In order to enable PostgreSQL support, --with-pgsql[=DIR] is required when
> you compile PHP. DIR is the PostgreSQL base install directory, defaults to
> /usr/local/pgsql. If shared object module is available, PostgreSQL module
> may be loaded using extension directive in php.ini or dl() function.
>
>  The default php instalations on most linux distro's don't come with
> postgresql enabled !
>  So you need to unistall the default php version first.
>
>
>
>
> On 1/10/06, Jeff MacDonald <jam@zoidtechnologies.com> wrote:
>
> greetings,
>
>  On Mon, 2006-01-09 at 14:23 -0800, Jagan Reddy wrote:
>  > Hello,
>  > I have successfully compiled and installed postgresql 8.1.1. I have
>  > created some databases as well.
>  > But I want to get php working with pgsql so that I can do some web
>  > develoement.
>  >
>  > Whatever rpms I get and insall, it is still complaining for another.
>  > I believe I have PHP 4.3.9 and I tried here to insall php-pgsql4.3.9.
>  > No luck.
>  >
>  > I am still running the default PHP installed by RedHat linux
>  > installaion process.  I have not removed and installed source code
>  > based PHP though.
>  >
>  > Thanks
>  > Jagan Reddy
>  >
>
>  what version of redhat are you using?
>
>  what version of the php rpm to do you have installed? (use 'rpm -q php'
>  to check)
>
>  regards,
>  J
>  --
>  Jeff MacDonald
>  Zoid Technologies, http://zoidtechnologies.com/
>
>
>  ---------------------------(end of
> broadcast)---------------------------
>  TIP 1: if posting/reading through Usenet, please send an appropriate
>         subscribe-nomail command to majordomo@postgresql.org so that your
>         message can get through to the mailing list cleanly
>
>
>
>
>  --
>  Met vriendelijke groet
>  Manjusri Schuit



^ permalink  raw  reply  [nested|flat] 9+ messages in thread

* Re: Having tough time getting php working for postgresql..
@ 2006-01-11 18:00  Janning Vygen <vygen@gmx.de>
  parent: Patrick White <ptothew@gmail.com>
  1 sibling, 1 reply; 9+ messages in thread

From: Janning Vygen @ 2006-01-11 18:00 UTC (permalink / raw)
  To: pgsql-php; +Cc: Patrick White <ptothew@gmail.com>

Am Mittwoch, 11. Januar 2006 18:35 schrieb Patrick White:
> Hello,
>
> I was having trouble with setting up php-pgsql, but I think I have it
> up and running. Before I attempt to move forward with attempting to
> code without knowing if the environment is setup correctly, does
> anybody know what exactly I am looking for in the phpinfo() tables. I
> did a find for pgsql, postgre, etc. and didn't find anything.

you should find "pgsql" (look at the configuration parameters in 
http://www.php.net/manual/en/ref.pgsql.php ; they should be listed)

> I am running Windows XP Pro, Apache 2, PHP 5.1.1, PostgreSQL 8.0.

Consult http://www.php.net/manual/en/ref.pgsql.php
Maybe you have to add the libary in your php.ini file

kind regards
janning



^ permalink  raw  reply  [nested|flat] 9+ messages in thread

* Fwd: Having tough time getting php working for postgresql..
@ 2006-01-11 18:08  Patrick White <ptothew@gmail.com>
  parent: Janning Vygen <vygen@gmx.de>
  0 siblings, 0 replies; 9+ messages in thread

From: Patrick White @ 2006-01-11 18:08 UTC (permalink / raw)
  To: pgsql-php

Thank you for the quick reply. I was actually able to get it up and
running. It is always as soon as you hit the send button when the
light bulb goes off. The issue I was having was that I didn't realise
the order of which the server will look for the php.ini file (I
thought it was simply looking in the PATH directories), such as the
list I will provide for future reference:

     1.PHPIniDir directive (Apache 2 module only)
     2.HKEY_LOCAL_MACHINE\SOFTWARE\PHP\IniFilePath
     3. The PHPRC environment variable
     4. Directory of PHP (for CLI), or the web server's directory (for
       SAPI modules)
     5. Windows directory (C:\windows or C:\winnt)

My problem was that Apache was set to look in a directory that
contained a completly default php.ini file.

Thanks again, and I apologize for the premature post.

Patrick

---------- Forwarded message ----------
From: Janning Vygen <vygen@gmx.de>
Date: Jan 11, 2006 1:00 PM
Subject: Re: [PHP] Having tough time getting php working for postgresql..
To: pgsql-php@postgresql.org
Cc: Patrick White <ptothew@gmail.com>


Am Mittwoch, 11. Januar 2006 18:35 schrieb Patrick White:
> Hello,
>
> I was having trouble with setting up php-pgsql, but I think I have it
> up and running. Before I attempt to move forward with attempting to
> code without knowing if the environment is setup correctly, does
> anybody know what exactly I am looking for in the phpinfo() tables. I
> did a find for pgsql, postgre, etc. and didn't find anything.

you should find "pgsql" (look at the configuration parameters in
http://www.php.net/manual/en/ref.pgsql.php ; they should be listed)

> I am running Windows XP Pro, Apache 2, PHP 5.1.1, PostgreSQL 8.0.

Consult http://www.php.net/manual/en/ref.pgsql.php
Maybe you have to add the libary in your php.ini file

kind regards
janning



^ permalink  raw  reply  [nested|flat] 9+ messages in thread

* Re: Having tough time getting php working for postgresql..
@ 2006-01-11 22:17  operationsengineer1@yahoo.com
  parent: Patrick White <ptothew@gmail.com>
  1 sibling, 0 replies; 9+ messages in thread

From: operationsengineer1@yahoo.com @ 2006-01-11 22:17 UTC (permalink / raw)
  To: Patrick White <ptothew@gmail.com>; pgsql-php

> Hello,
> 
> I was having trouble with setting up php-pgsql, but
> I think I have it
> up and running. Before I attempt to move forward
> with attempting to
> code without knowing if the environment is setup
> correctly, does
> anybody know what exactly I am looking for in the
> phpinfo() tables. I
> did a find for pgsql, postgre, etc. and didn't find
> anything.
> 
> I am running Windows XP Pro, Apache 2, PHP 5.1.1,
> PostgreSQL 8.0.
>
> Thank you in advance.
> 
> Patrick

1. test for the apache test page (prior to php
install).  
2. test that phpinfo() displays (after php install).
3. edit->find to search for "sql" until you find the
reference to postgresql.  it should tell you what
version you are using.  of course, this is after pgsql
has been installed.

i also discuss how to use pgadminIII to test that
pgsql is working in the link to the install
instructions i posted earlier today.

once you get everything set up, you may want to
consider a db abstraction layer (i use adodb and find
it quite robust) and a forms generation and validation
class (i use manuel lemos' from phpclasses.org).  it
is also very nice.


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 



^ permalink  raw  reply  [nested|flat] 9+ messages in thread


end of thread, other threads:[~2006-01-11 22:17 UTC | newest]

Thread overview: 9+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2006-01-09 22:23 Having tough time getting php working for postgresql.. Pleeese help Jagan Reddy <jaganreddy98@yahoo.com>
2006-01-09 23:00 ` Re: Having tough time getting php working for postgresql.. Jeff MacDonald <jam@zoidtechnologies.com>
2006-01-10 14:04   ` Re: Having tough time getting php working for postgresql.. manjusri schuit <manjusri.schuit@gmail.com>
2006-01-10 07:16 ` Re: Having tough time getting php working for postgresql.. brew@theMode.com
2006-01-10 16:20 Re: Having tough time getting php working for postgresql.. Sherwin M. Harris <Sherwin_Harris@byu.edu>
2006-01-11 17:35 ` Re: Having tough time getting php working for postgresql.. Patrick White <ptothew@gmail.com>
2006-01-11 18:00   ` Re: Having tough time getting php working for postgresql.. Janning Vygen <vygen@gmx.de>
2006-01-11 18:08     ` Fwd: Having tough time getting php working for postgresql.. Patrick White <ptothew@gmail.com>
2006-01-11 22:17   ` Re: Having tough time getting php working for postgresql.. operationsengineer1@yahoo.com

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