Update 'phpInterface/shoppingList.php'
Added Mysql SSL
This commit is contained in:
parent
f7c470f5a1
commit
78b35b84f2
@ -47,7 +47,14 @@
|
|||||||
{
|
{
|
||||||
if(DBLink::$sqlLink == null)
|
if(DBLink::$sqlLink == null)
|
||||||
{
|
{
|
||||||
DBLink::$sqlLink = new mysqli(Configuration::$mysqlserver, Configuration::$mysqluser, Configuration::$mysqlpw, Configuration::$mysqldb, Configuration::$mysqlPort);
|
DBLink::$sqlLink = mysqli_init();
|
||||||
|
|
||||||
|
if(Configuration::$mysqlSSL)
|
||||||
|
{
|
||||||
|
DBLink::$sqlLink->options(MYSQLI_OPT_SSL_VERIFY_SERVER_CERT, true);
|
||||||
|
DBLink::$sqlLink->ssl_set(NULL, NULL, Configuration::$mysqlSslCertificatePath, NULL, NULL);
|
||||||
|
}
|
||||||
|
DBLink::$sqlLink->real_connect(Configuration::$mysqlserver, Configuration::$mysqluser, Configuration::$mysqlpw, Configuration::$mysqldb, Configuration::$mysqlPort);
|
||||||
|
|
||||||
// Verbindung überprüfen
|
// Verbindung überprüfen
|
||||||
if (mysqli_connect_errno())
|
if (mysqli_connect_errno())
|
||||||
|
Loading…
Reference in New Issue
Block a user