I need help with this (maybe a hint) – the question might be naive but I have to resolve it:
An PHP page when located in the root is properly displayed – https://reverd.com/why-use-reverd-com but not visible when placed in the "about" directory – https://reverd.com/about/why-use-reverd-com while other pages in the "about" dir are properly displayed – https://reverd.com/about/ssl-security – What is wrong? What should I correct?
Thanks,
I do have the following statements in my .htaccess file in the root:
# Enable output compression
<FilesMatch ".(php|html|txt|css|js|gz|xml)$">
SetOutputFilter DEFLATE
</FilesMatch>
# Remove (.php)
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}.php -f
RewriteRule ^(.*)$ $1.php
2
Answers
Sorry folks, my bad: At the beginning of the PHP page file I have requests like this // We must require the xxxxxx file. require_once '/nnnnnn/xxxxxxx.php';
and the path must be like this instead (because it's in a folder, not in the root require_once '../nnnnnn/xxxxxxx.php.php';
It's all good now and working. [https://reverd.com/about/why-use-reverd-com][1] [1]: https://reverd.com/about/why-use-reverd-com
Make sure you turn
RewriteEngine
on in your.htaccess
file:Try that and let us know if that changes anything.