How to connect this script with database (MySQL)

You are missing the SQL file. If you have it, edit the file configClass.php under the folder functions. Put the info in the PDO initiation line.
 
Any news ? has it worked ? You must edit constants.php for site links
I need sql files can you upload please.
 
use @ before your connectn and Db select in new wamp extensin despreted
 
A simple way to to do this is simply using mysqli

PHP:
<?PHP
 $mysqli = mysqli_connect("example.com", "user", "password", "database");
 $res = mysqli_query($mysqli, "SELECT * FROM `example`");
 $row = mysqli_fetch_assoc($res);
 echo $row['_msg'];

More information can be found here: http://php.net/manual/en/mysqli.quickstart.dual-interface.php

I recommend using MySQL OOP Though.
 
Last edited:
I recommend using PDO

PHP:
<?php
try {
    $dbh = new PDO('mysql:host=localhost;dbname=test', $user, $pass);
    foreach($dbh->query('SELECT * from FOO') as $row) {
        print_r($row);
    }
    $dbh = null;
} catch (PDOException $e) {
    print "Error!: " . $e->getMessage() . "<br/>";
    die();
}
?>
 
Back
Top