Easy one: Can I use a ternary in a PHP class method return statement?

Can I do this? (I can't test it at the moment to see for myself)\[code\]public function overSimplifiedTernaryTest($condition = false) { return ($condition) ? 'someString' : 'someOtherString';}\[/code\]
 
Back
Top