SyntaxFix
Write A Post
Hire A Developer
Questions
I found this method worked for me:
$thisproduct = "my_product_id"; $array=array("$product1", "$product2", "$product3", "$product4"); if (in_array($thisproduct,$array)) { echo "Product found"; }