Publishing to mySQL

Top  Previous  Next

 

When you publish your site using the deploy wizard, dbQwikSite will automatically create a _connection.php file containing your server settings that you entered in the deploy wizard.  You can also manually edit this file if you choose, should you change hosts or other connection information.

 

Example of a local connection file versus on that could represent your server.

 

Local

<? php

$host = "localhost:3306";

$db = "test";

$user = "root";

$passwd = "";

$link = mysql_connect($host,$user,$passwd)

       or die("Could not connect");

mysql_select_db("test") or die("Could not select database");

?>

 

Server

<? php

$host = "yourhost:3306";

$db = "test";

$user = "root";

$passwd = "";

$link = mysql_connect($host,$user,$passwd)

       or die("Could not connect");

mysql_select_db("test") or die("Could not select database");

?>