connect to mysql from php

Web hosting discussion, programming, and shared and dedicated servers.
3 posts Page 1 of 1
by jond » Mon Feb 11, 2013 10:05 am
Sorry, this is not a question directly related to my sonic account right now, but I'd like to know the host name used here to connect to mysql from php - need to try the same idea on my server for testing - not sure if php or mysql are configured properly to access each other from regular linux accounts or the general syntax is wrong.

This does not appear to work:

$dsn = 'mysql:host=localhost;dbname=database_name';

Thanks, jon
by joemuller » Mon Feb 11, 2013 10:19 am
Jon,

The databases are located on a different server from your web page. You can look up the information on how to connect by exploring the options in our Member Tools:
https://members.sonic.net/databases/manage/

I hope this is helpful to you.

-- Joe
I'm a proud employee of Sonic.net! :-)
by jond » Mon Feb 11, 2013 10:24 am
Never mind, sorry folks, the localhost name works just fine on my system - I had the database wrong - so very sorry :shock:
3 posts Page 1 of 1

Who is online

In total there are 18 users online :: 0 registered, 0 hidden and 18 guests (based on users active over the past 5 minutes)
Most users ever online was 999 on Mon May 10, 2021 1:02 am

Users browsing this forum: No registered users and 18 guests