Created
April 13, 2016 12:31
-
-
Save bkozora/46d7fea55afd7dfb927f48eabfd2bc4f to your computer and use it in GitHub Desktop.
Magento -
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Bootstrap Magento | |
require_once("../www/app/Mage.php"); | |
$app = Mage::app('default'); | |
// Grab our database config info | |
$config = Mage::getConfig()->getResourceConnectionConfig("default_setup"); | |
// Connect to our RDS MySQL instance | |
$mysqli = new mysqli($config->host, $config->username, $config->password, $config->dbname); | |
// check RDS MySQL connection | |
if ($mysqli->connect_errno) { | |
printf("Connect failed: %s\n", $mysqli->connect_error); | |
exit(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment