The power of any programming language is all about making decisions based on user selection. Conditional operators (conditional statements) execute code only when certain condition is met. If the expressions inside the parentheses () evaluate to true, the code between braces {} is executed. If it is false, then the code between braces is skipped. It’s worth mentioning that the code which follows the closing brace } is executed in any case, ‘coz it’s not part of the conditional statement. Since the same principle is used throughout all programming languages, you can learn it in the PHP context and the apply the same skils, say, in JavaScript. Ain’t it cool? (more…)
Tag: conditional operators
-
Conditional Operators – Learning PHP for absolute beginners