search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o

Change from sqllite to MS SQL

Related article: HTML5 Scheduler
Asked by Anonymous
5 years ago.

Can I adapt this for MY SQL backend?

Answer posted by Dan Letecky [DayPilot]
5 years ago.

Yes, you just need to adjust the $db variable initialization in _db.php:

$db = new PDO('sqlite:daypilot.sqlite');

For MySQL you'll need to use something like this:

$host = "";
$port = 3306;
$username = "username";
$password = "password";
$database = "daypilot";

$db = new PDO("mysql:host=$host;port=$port",
$db->exec("CREATE DATABASE IF NOT EXISTS `$database`");
$db->exec("use `$database`");
Comment posted by Anonymous
5 years ago.

Thank you so much for such a swift reply.

This question is more than 3 months old and has been closed. Please create a new question if you have anything to add.