jb489 Posted August 6, 2009 Share Posted August 6, 2009 Hi guys, I have a problem which I just cant seem to solve. I am trying to connect to a postgreSQL database using php over ssl: Now the postgreSQL database is not on the same machine. I know that the database has ssl built in because i am using pgAdminIII and connecting with ssl option as required. When I set this to disable, it doesnt connect at all. So therefore must have ssl built in. Now for the code. I am using the pg_connect as follows: pg_connect($ConnectionString); where $ConnectionString = "host=data.gf.com user=radedd password=pa55w0rd dbname=data sslmode=require port=5432" and I am getting this error: pg_connect(): Unable to connect to PostgreSQL server: sslmode value "require" invalid when SSL support is not compiled in Can someone please help me on this as I am losing my mind trying to figure it out. I have tried googling in vain, every site says, configure your postgreSQL server, restart it(which I couldnt even if i wanted to as its a live system, and i clearly dont need to as pgadmin3 is connecting fine with ssl) Please help guys... Thanks to all.. Link to comment https://forums.phpfreaks.com/topic/169121-cant-connect-to-postgressql-database-with-ssl/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.