Home >Backend Development >PHP Tutorial > 问一个Js的语法,在PHP该怎样表示?解决方法
问一个Js的语法,在PHP该怎样表示?
Javascript:
<!-- Code highlighting produced by Actipro CodeHighlighter (freeware) http://www.CodeHighlighter.com/ --> var a = 'a'; var b = null; alert(a||b); //这会输出a的变量值,,想问一下php应该怎么表示?
<!-- Code highlighting produced by Actipro CodeHighlighter (freeware) http://www.CodeHighlighter.com/ --> $a = 'A'; $b = null; echo $a || $b; //这样只会输出1或0,, //我以前记得在哪个Oauth的开发文档上看过...但我现在忘记了... //不知道有能人能告诉一下本人..Thanks