title: pg_connect not working with PHP 5
body: <p>I'm working on an application that runs fine with PHP 4 in a windows 8 server. I'm setting a local server with postgres to work locally but with PHP 5 to migrate a few things. I'm having some compatibility issues but nothing big except that the pg_connect function in a class is not working and is not throwing me any error</p>
  
  <pre><code>class basededatos{
      var $link_;
  
      function basededatos(){
          $this-&gt;link_=pg_connect("host=localhost port=5432 dbname=... user=postgres password=...") or die('Falla en la conexión a la Base de Datos. Por favor, Revise la Configuración.');
      }
  
      function cerrarconexion(){
          pg_close($this-&gt;link_);
      }
  
      function Abreconexionconretorno($consulta){
          $resultado=pg_query($consulta)or die("La consulta falló con error: ".pg_last_error());
          return $resultado;
      }
  
      function Abreconexionsinretorno($consulta){
          pg_query($consulta)or die("La consulta falló con error: ".pg_last_error());
      }
  }
  </code></pre>
  
  <p>After this </p>
  
  <pre><code>$this-&gt;link_=pg_connect(...)
  </code></pre>
  
  <p>It just dies, any idea why is this happenning? Thanks</p>