Skip to content
Advertisement

Failure to connect to mySQL DB via PHP (msqli object-oriented issue)

I’m trying to connect from my Heroku app to a mysql db (Xeround) in an object-oriented way:

$this->db = new mysqli(
    Credentials::databaseHost(), 
    Credentials::databaseUsername(), 
    Credentials::databasePassword(), 
    Credentials::databaseName()); 

(for clarity–> this line is located within the constrcutor of a central dispatcher I use. The sql connection is injected by this dispatcher if needed)

In my locally running production environment everything is working fine, however once I test it on Heroku the app hangs at the above point. No error msgs.

Any suggestions?

Advertisement

Answer

Dunno if this is still an issue for you guys but no, heroku does not support mysqli.

User contributions licensed under: CC BY-SA
2 People found this is helpful
Advertisement