Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
  • How to connect to your MySQL database from a PHP Script

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 321
    Comment on it

    Create simple Mysql connection with the help of PHP code

    <?php
    
    $hostname   =   'localhost';            //define the hostname here
    $username   =   'root';                //define the username here 
    $password    =   ' ';                  //define the password here
    $dbname      =   'database&#95;name'; //define the database name here
    
    mysql&#95;connect($hostname,$user,$password) or die('unsuccessful connection '); 
    
    //mysql&#95;connect() is function of php to establish the  connection from Mysql   
    
    ?>   
    

    In this tutorial we'll learn how to establish a connection to a MySQL database from within a PHP script. we are establish the connection simple and secure with the help of this PHP code script

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: