I have information being passed to a script through a form. It is a query for a search engine.
So, let's say the user wants to search for the words 'yellow' AND 'string' and inputs these individual words in the text field. Using a script to convert the boolean options properly, this data would be passed to search.php as:
search.php?q=yellow+string
It would search for both the words yellow and string.
What I need to do is take this information and put it into an array. So, I need to strip out all of the boolean language (+ - , AND OR) and put the left over data into an array:
$querydata = array('yellow', 'string');
How can I convert $q = "yellow+string"; into this array?