Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save vanpariyar/3a2f560abfbf223f7d9e063b66d60609 to your computer and use it in GitHub Desktop.
Save vanpariyar/3a2f560abfbf223f7d9e063b66d60609 to your computer and use it in GitHub Desktop.
Connecting Wordpress to Database using Unix Domain Socket #wordpress #php

Connecting Wordpress to Database using Unix Domain Socket

Do this inside your wp-config.php.

It must be the absolute path to the socket.

define('DB_HOST', 'localhost:' . __DIR__ . '/.mysql/mysql.sock');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment