note 102404 added to control-structures.if
[email protected] Fri, 11 Feb 2011 20:30:25 -0800
| Newsgroups | php.notes |
|---|---|
| Message-ID | <[email protected]> |
In addition to the traditional syntax for if (condition) action; I am fond of the ternary operator that does the same thing, but with fewer words and code to type: (condition ? action_if_true: action_if_false;) example (x > y? 'Passed the test' : 'Failed the test') ---- Server IP: 208.69.120.55 Probable Submitter: 108.7.177.13 ---- Manual Page -- http://www.php.net/manual/en/control-structures.if.php Edit -- https://master.php.net/note/edit/102404 Del: integrated -- https://master.php.net/note/delete/102404/integrated Del: useless -- https://master.php.net/note/delete/102404/useless Del: bad code -- https://master.php.net/note/delete/102404/bad+code Del: spam -- https://master.php.net/note/delete/102404/spam Del: non-english -- https://master.php.net/note/delete/102404/non-english Del: in docs -- https://master.php.net/note/delete/102404/in+docs Del: other reasons-- https://master.php.net/note/delete/102404 Reject -- https://master.php.net/note/reject/102404 Search -- https://master.php.net/manage/user-notes.php