What is the correct syntax for using OR in an if statement in PHP?

When using the OR operator in an if statement in PHP, you need to use either "||" or "or" between the conditions you want to check. This allows you to evaluate multiple conditions and execute the code block if any of the conditions are true. Make sure to use parentheses to group the conditions properly to avoid any confusion with operator precedence.

// Example of using OR in an if statement
if ($condition1 || $condition2) {
    // Code to execute if either $condition1 or $condition2 is true
}