What are the best practices for combining multiple conditions in a regex pattern in PHP?

When combining multiple conditions in a regex pattern in PHP, it is important to use the '|' (pipe) operator to separate the conditions. This allows you to match any of the conditions within the pattern. Additionally, using parentheses to group related conditions can help clarify the logic of the pattern. Finally, using the '/i' modifier at the end of the pattern makes the matching case-insensitive.

$pattern = '/(condition1|condition2|condition3)/i';
$string = "Your input string here";
if (preg_match($pattern, $string)) {
    echo "Match found!";
} else {
    echo "No match found.";
}