課程
/后端開發
/PHP
/PHP進階篇
setcookie('test','',time()-1);
這句中test為什么不能用雙引號?一用就不過………………
2016-07-12
源自:PHP進階篇 4-3
正在回答
單引號內部的變量不會執行雙引號會執行如$name = 'hello';echo "the $name";會輸出 the hello而如果是單引號$name = 'hello';echo 'the $name';會輸出 the $name
猿教授 提問者
跟單雙引號沒關系的。
舉報
輕松學習PHP中級課程,進行全面了解,用PHP快速開發網站程序
3 回答為什么orange是單引號,橘子用雙引號?
2 回答此處為什么要用()?
1 回答這里蘋果用雙引號和單引號有什么區別?
4 回答單引號和雙引號
3 回答$fruit = array('orange'=>"橘子");為什么前面用單引號,后面用雙引號呢?
Copyright ? 2025 imooc.com All Rights Reserved | 京ICP備12003892號-11 京公網安備11010802030151號
購課補貼聯系客服咨詢優惠詳情
慕課網APP您的移動學習伙伴
掃描二維碼關注慕課網微信公眾號
2016-07-12
單引號內部的變量不會執行
雙引號會執行
如
$name = 'hello';
echo "the $name";
會輸出 the hello
而如果是單引號
$name = 'hello';
echo 'the $name';
會輸出 the $name
2017-04-22
跟單雙引號沒關系的。