-3
如何在最後一行設置mysqli_result?如何編寫mysqli_result
if(isset($_POST['thename']) === true && empty($_POST['thename']) === false) {
$getVal = mysqli_real_escape_string($cutConn_db, trim($_POST['thename']));
require '../db/cb_bz.php';
$query = mysql_query("
SELECT 'photos'.'theurl' FROM 'names' WHERE 'names'.'thename'".$getVal."'");
$resultA = mysqli_query($cutConn_db, $query);
$rowz = mysqli_fetch_row($resultA);
$tota_rowz = $rowz[0];
echo($tota_rowz !== 0) ? mysqli_result($query, 0, 'theurl') : 'Not found.';
}
你爲什麼要混合mysql和mysqli函數? – deceze
我知道在mysql中這樣做。但是我在使用mysqli的時候問你如何寫? – NathaliaZeed
一些好的舊RTFM怎麼樣? http://www.php.net/manual/en/mysqli.quickstart.statements.php – deceze