I used following code for hiding .php extension but mail() function stopped working. What is the problem?
RewriteCond %{THE_REQUEST} ^[A-Z]{3,}\s([^.]+)\.php [NC]
RewriteRule ^ %1 [R,L,NC]
RewriteCond %{REQUEST_FILENAME}.php -f
RewriteRule ^ %{REQUEST_URI}.php [L]
Mail function & redirect
mail($to,$subject,$message,$headers);
header('Location: http://xyz.com/');