i have this query in link 10_11&9_12&9_14
i need to create array for db to look like this
[0] => 'and value in (11)'
[1] => 'and value in (12,14)'
so i need for every value that is same until _ (in this example 10_ and 9_) to put values after _
this is my code so far:
$test = $_GET['value'];
foreach($test as $atr_val)
{
list($attribute, $value) = explode("_", $atr_val);
$selected_attributes[] = $attribute;
$selected_values[] = $value;
}
i have now values before _ and after, but i don't know what to do after that
$_GETis a function :) You probably want to change()->[]