可捕获的致命错误:mysqli_stmt类的对象无法转换为字符串3

时间:2019-01-11 17:17:21

标签: mysqli

我无法终生了解为什么这会引发可捕获的致命错误...

$rs_contacts = mysqli_prepare($conn, "SELECT CONTACTID, COMPANY, FORENAME, SURNAME, DEAR, POSITION, LASTCHECK, EDITDATE, ACCMAN, LOGO, ADDRESS1, ADDRESS2, ADDRESS3, CITY, COUNTY, POSTCODE, COUNTRY, SWITCHBOARD, EMAIL, WEBSITE, COMPTYPE, PRE, OPTOUT, TPS, OPTIN FROM CONTACTS WHERE ? LIKE CONCAT('%',?,'%') ORDER BY ?");

// bind parameters
mysqli_stmt_bind_param($rs_contacts, "sss", $_GET['search'], $_GET['column'], $_GET['order']);

// execute query
mysqli_stmt_execute($rs_contacts);

mysqli_stmt_store_result($rs_contacts);// store result - needed for longtext fields
mysqli_stmt_bind_result($rs_contacts, $CONTACTID, $COMPANY, $FORENAME, $SURNAME, $DEAR, $POSITION, $LASTCHECK, $EDITDATE, $ACCMAN, $LOGO, $ADDRESS1, $ADDRESS2, $ADDRESS3, $CITY, $COUNTY, $POSTCODE, $COUNTRY, $SWITCHBOARD, $EMAIL, $WEBSITE, $COMPTYPE, $PRE, $OPTOUT, $TPS, $OPTIN);// bind result variables
$rowcount_contacts = mysqli_stmt_num_rows($rs_contacts);

有什么想法吗?

0 个答案:

没有答案