Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

connexion sql php/html

<!DOCTYPE html>
<?php
header( 'content-type: text/html; charset=utf-8' );
// SQL CREER BASE : CREATE DATABASE `ma_base` DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;
$conn = mysqli_connect('localhost', 'root', 'mdp', 'ma_base');
$conn->set_charset("utf8");
?>
<html>
    <head>
        <meta http-equiv="content-type" content="text/html; charset=utf-8" />
    </head>
 
    <body>
 
 
    </body>
</html>
<?php
mysqli_close($conn);
?>
Source by www.linuxtricks.fr #
 
PREVIOUS NEXT
Tagged: #connexion #sql
ADD COMMENT
Topic
Name
5+7 =