connection - php pgadmin remote db connect failure -
i want connect remote database php
postgres
not connect , says
warning: pg_connect() [function.pg-connect]: unable connect postgresql server: not connect server: no route host (0x00002751/10065) server running on host "xxxxxxxxx" , accepting tcp/ip connections on port 5432? in c:\xampp\htdocs\test.php on line 4 wrong conn_string <html> <body> <?php $db = pg_connect('host=xxx.xxx.xxx.xxx port=5432 dbname=postgres user=postgres password=') or die('wrong conn_string'); if (!$db) { echo 'error'; }else{ echo 'success'; } ?> </body>
the same database can access pgadmin
client running on same machine apache running, not understand pgadmin can access db apache webserver's php not access ? idea ?
"no route host" tells there kind of networking problem - fact different client able access same host indicate it's kind of security restriction or firewall preventing connection, it's hard more specific without detailed information environment.
Comments
Post a Comment