MySQLi result is duplicating columns

ساخت وبلاگ

Vote count: 0

MySQLi result seems to be duplicating columns as you can see below in the screenshots. The data for each column seems to be duplicated.

enter image description here

Any thoughts one what I am doing wrong?

The DB Call

function getDBConnection() { // Connect to the database mysqli_report(MYSQLI_REPORT_ERROR | MYSQLI_REPORT_STRICT); $conn = new mysqli( DBHOST, DBUSER, DBPWD, DBNAME ); if ( $conn->connect_error ) { die( "Failed to connect with MySQL: " . $conn->connect_error ); } else { return $conn; }
}
function getAllCustomers() { $conn = getDBConnection(); $sql = "SELECT * FROM tblCustomers" ; return $conn->query( $sql );
}

Outputting in PHP

$records = getAllCustomers();
if (mysqli_num_rows($records) > 0) { while ($row = mysqli_fetch_array($records)) { echo '
asked 26 secs ago

back soft...
ما را در سایت back soft دنبال می کنید

برچسب : نویسنده : استخدام کار backsoft بازدید : 241 تاريخ : چهارشنبه 6 ارديبهشت 1396 ساعت: 22:15

خبرنامه