DSN-less ODBC Connection to a MS Access Database using PHP Print

  • 12


This code sets up a DSN-less ODBC connection to a MS Access Database in PHP 5 on your server platform.


if (!isset($con))

{ $dbfilename = "D:/HostingSpaces/yourspacename/yourwebsite.com/wwwroot/DBfilename.mdb";

$dbuser = "";

$dbpassword = ""

$con = odbc_connect("Driver={Microsoft Access Driver (*.mdb)};

Dbq=$dbfilename", $dbuser, $dbpassword);




SEE ALSO: Database Knowledge base Articles | "Important IP Addresses" knowledge base article

Contact Support

If you are still having issues, please contact us for further help.
1-877-EPHOST1 | support@ephost.com



Was this answer helpful?

« Back