$uri = '/index.php/';
$this->finalRegex = '/^' . preg_quote($uri, '/') . '$/';
if(preg_match($this->finalRegex, '/index.php')
{
echo "works!";
}
It returns
string(18) "/^\/index\.php\/$/"As you can see it adds a \ before .php which would be inconsistent with the string i'm trying to match ( offered an example). can you help me understand how to fix i tried everything it came in my mind.













