Need Code Converted Able Connect Online Domain Code Online Domain Also Shows Connection Li Q37018983

I need the code converted below to be able to connect to myonline domain

My code for my online domain. Also shows connection islive. Make the two php files connect to this!:

   $servername = “localhost”;
   $db_username = “jstedman”;
   $db_password = “password”;
   $dbname = “onlinejob”; //Database name

    
try  
{
    $conn = newPDO(“mysql:host=$servername;dbname=$dbname”, $db_username,$db_password);
    // set the PDO error mode to exception
    $conn->setAttribute(PDO::ATTR_ERRMODE,PDO::ERRMODE_EXCEPTION);
     
    echo “Connected successfully onlinejob”;
} catch (PDOException $e)  
{
    echo “Connection failed: ” .$e->getMessage();
}

login-exec.php

   //Start session
   session_start();
  
   //Include database connection details
   require_once(‘includes/config.php’);
  
   //Array to store validation errors
   $errmsg_arr = array();
       //Validation error flag
   $errflag = false;
  
   //Connect to mysql server
   $link = mysql_connect(‘localhost’,’root’,””);
  

OR
OR

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.