I am getting this error saying "Undefined variable: stq" and the variable is there. I looked to see if I missed something but I don't see what I'm missing. What is the problem?
Here is my code
$stq=str_replace(", ", " ,", $userinputt);
$pro=User::Where('tags','Like','%'. $str .'%')->Where(function ($query) use($strrr,$strr,$strrrr) {
$query->Where('cityandstate', 'LIKE', '%'. $strr .'%')->orWhere('cityandstate', 'LIKE', '%'. $strrr .'%')->orWhere('cityandstate', 'LIKE', '%'. $strrrr .'%')->orWhere('cityandstate', 'LIKE', '%'. $stq .'%');
Thanks in advance