#Man kann nicht mit andereen benutzern db oder tabbles ein verbindung (mysql) eingehen

2 messages · Page 1 of 1 (latest)

stark crane
#

conn:
<?php
error_reporting(E_ALL);
ini_set('display_errors','On');
session_start();

try{
$pdo = new PDO('mysql:host=localhost;dbname=LiveChat','LiveChat','');
$pdo->setAttribute(PDO::ATTR_ERRMODE,PDO::ERRMODE_EXCEPTION);
return $pdo;
}catch (Exception $e){

header('Content-Type:application/json;charset=utf-8');

http_response_code(500);
$output = ['status'=>'failed','message' => $e->getMessage()];
echo json_encode($output);
exit();

}
$pdo = createPdoConnection();

thorn flume
#

Thanks for your question :clap:, if someone gives you an answer it would be great if you thanked them with a :white_check_mark: in response. This response will earn you both points for special roles on this server.