in_array()
is what I use
if (in_array($variable, array('one','two','three'))) {
More Related Contents:
- PHP session variable issue while using iframe
- How is this not passing PHP values to JS and vice-versa?
- How i can earn variable from string in PHP? [closed]
- What is more efficient for a PHP variable, $timelimit 10*60; or $limit 600;? [closed]
- How to store variable value after clicking “Submit”?
- How do you use variables within $_POST? [closed]
- How to include a PHP variable inside a MySQL statement
- PHP Pass variable to next page
- Send JavaScript variable to PHP variable [duplicate]
- Comparing String to Integer gives strange results
- PHP | define() vs. const
- Mixing a PHP variable with a string literal
- PHP variable variables
- Can’t access global variable inside function
- PHP Accessing Parent Class Variable
- Can PHP namespaces contain variables?
- What’s the best way to pass a PHP variable to Javascript? [duplicate]
- How to pass jQuery variables to PHP variable?
- How do I pass data between pages in PHP?
- PHP variable interpolation vs concatenation [duplicate]
- How to set $_GET variable
- Workaround for basic syntax not being parsed
- PHP pass variable to include
- implicit class variable declaration in php?
- Convert a String to Variable
- How to cast variable to array
- If you create a variable inside a if statement is it available outside the if statement?
- Public static variable value
- Changing a global variable from inside a function PHP
- Use Variable as Function Name in PHP [duplicate]