Okay, it seems I've found a solution. Can I do it this way?
$res = DB::connection('mysql')->statement("CREATE DATABASE IF NOT EXISTS `{$mysqlDatabaseName}`");
$res2 = DB::connection('mysql')->statement("CREATE USER '{$mysqlDatabaseName}'@'%' IDENTIFIED BY '{$mysqlPassword}');
Or would I have SQL-injection problems?
Thanks again, Alessio Periloso
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community