本文介紹了致命錯誤:無法通過引用傳遞參數 1的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!
問題描述
我有這條線:
$stmt->bind_result('d', $keyarray['payment_gross']);
我收到此錯誤:
致命錯誤:無法在第 35 行的/home/star1231/public_html/pdt.php 中通過引用傳遞參數 1
Fatal error: Cannot pass parameter 1 by reference in /home/star1231/public_html/pdt.php on line 35
這里有什么問題?
推薦答案
關于你的代碼我能說的不多,但是如果參數 1 在函數定義中通過引用傳遞,那么你需要這樣做.
Not much I can tell about your code, but if parameter 1 is passed by reference in function definition then you need to do this.
$char = 'd';
$stmt->bind_result($char, $keyarray['payment_gross']);
只能通過引用傳遞變量,因為您傳遞的是變量的地址而不是實際值.讓我知道它是否解決了
Only variables can be passed by reference since you are passing the address of the variable and not an actual value. Let me know if it solves it
這篇關于致命錯誤:無法通過引用傳遞參數 1的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!
【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!