Skip to content

Instantly share code, notes, and snippets.

@rafaelbernard
Created March 1, 2016 20:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rafaelbernard/67264a4d5b04714f82a1 to your computer and use it in GitHub Desktop.
Save rafaelbernard/67264a4d5b04714f82a1 to your computer and use it in GitHub Desktop.
Fix at wp-db.php - PG4WP - PG9.5
<?php
public function set_sql_mode( $modes = array() ) {
if ( empty( $modes ) ) {
/*
if ( $this->use_mysqli ) {
$res = mysqli_query( $this->dbh, 'SELECT @@SESSION.sql_mode' );
} else {
$res = mysql_query( 'SELECT @@SESSION.sql_mode', $this->dbh );
}*/
$res = '';
@errakeshpd
Copy link

HI i am checking the comment on plugin page, thanks for that,

i am also trying to install wordpress along with the postgresql

I dont the below checklists

1.g4wp directory in your /wp-content
2.Copy the db.php from the pg4wp directory to wp-content
3.in wp-setting added username and pass and dbname of postgresql
but it not worked for

in nginx i can see

tail -f /var/log/nginx/error.log
#2 /var/www/html/wp-includes/option.php(184): wpdb2->get_results('SELECT option_n...')
#3 /var/www/html/wp-includes/functions.php(1372): wp_load_alloptions()
#4 /var/www/html/wp-includes/load.php(532): is_blog_installed()
#5 /var/www/html/wp-settings.php(133): wp_not_installed()
#6 /var/www/html/wp-config.php(89): require_once('/var/www/html/w...')
#7 /var/www/html/wp-load.php(39): require_once('/var/www/html/w...')
#8 /var/www/html/wp-blog-header.php(13): require_once('/var/www/html/w...')
#9 /var/www/html/index.php(17): require('/var/www/html/w...')
#10 {main}

thrown in /var/www/html/wp-content/pg4wp/core.php(32) : eval()'d code on line 1637" while reading response header from upstream, client: 111.92.88.37, server: rakesh.com, request: "GET / HTTP/1.1", upstream: "fastcgi://unix:/run/php/php7.0-fpm.sock:", host: "rakesh.com"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment