At Pressable we take site security very seriously, and part of that is limiting access to the Database. We have phpMyAdmin setup in your Site settings dashboard for easy access. Click here to learn more about phpMyAdmin at Pressable.
Direct Access to the Database
If you need to access the Database from a PHP file in your site folder you can use this script:
$this->db = new mysqli(DB_HOST, DB_USER, DB_PASS, DB_NAME);
But only from Pressable servers. We don’t allow remote connection to the Database for security reasons.
Accessing Database Credentials
If you need the specific credentials for your sites database you can use this to print them out:
// Display WP database credentials
echo "DB NAME :".DB_NAME ."<br>";
echo "DB USER :".DB_USER ."<br>";
echo "DB HOST :".DB_HOST ."<br>";
echo "DB PASSWORD :".DB_PASSWORD;
If you have any questions please contact support.