The order of operations. The word "or" has a much lower priority than the corresponding "||". Lower, even than assignment operator. Thus, the assignment occurs first, and the assignment value is the first operand to "or".
"or" means more for flow control than for logical operations. It lets you say something like
$x = get_something() or die("Couldn't do it!");
if get_something is encoded to return false or 0 on error.
cHao
source share