Sunday, March 13, 2011

CrazyEngineers Forum - Computer Science & IT Engineering

CrazyEngineers Forum - Computer Science & IT Engineering


How to connect to postgre database using php in xampp?

Posted: 12 Mar 2011 02:46 AM PST

I am facing problem in connecting to postgre database in xampp

when try to execute the following script

It is showing me an unexpected error ie undefined function pg_connect()

Here is the script

<?php
$conexion = pg_connect("host=localhost port=5432 password=*** user=postgres dbname=***") or die('Can't connect!!!: ' . pg_last_error());
?>

No comments:

Post a Comment