|
Current Topic: View Topic Tree |
Everything > Science & Technology > Computers > Programming > PHP |
|---|
|
|
{ ... } |
|
|
[ ... ] |
|
|
< ... > |
|
|
( ... ) |
In the PHP programming language, curly brackets { ... } are used to designate the start and end of a block of statements to be executed after an if, a for, or a while statement. This is exactly the same as is used in the programming languages C and C++.
For example, the following code will increment the variable $y four times if $x is a positive number (greater than zero):
if ($x > 0)