Basic Use of the if Statement : If statement « Statement « PHP
- PHP
- Statement
- If statement
Basic Use of the if Statement
<?php
if (true) echo "This will always display!<BR>";
if (false) {
echo "This will never, ever be displayed.<BR>";
} else {
echo "This too will always display!<BR>";
}
?>
Related examples in the same category