Connect to other database (5.7)2 users found helpful
I have created a custom form. The result of the form needs to be written to another database. How is this achieved?
In Concrete 5.6 it was possible like this:
$db = Loader::db( 'newserver', 'newuser', 'newpassword', 'newdatabase', true);
Currently I am still writing to the site database
$db = Database::get(); //tried this $db = Loader::db('localhost', 'root', 'root', 'db_new', true); //error //db_original.db_new does not exist
Thanks for the help
Thank you for posting the solution on the forum.
This is useful information.