Is it possible to use .htaccess to prevent a page from being served unless it is by a rewrite rule?
for example I have clean URLS so a call to xyz.com/hi
serves xyz.com/hi.php
.
I would like to achieve if the called url = xyz.com/hi.php
that the page opps.html
gets served, but the normal xyz.com/hi
still works.
thx Art
DirectoryIndex h1.php
Options +FollowSymLinks
RewriteEngine on
RewriteBase /
# stop calling page by ext
RewriteRule .*\.(php)$ opps.html [L]
# main start page
RewriteRule ^hi$ hi.php [L]