Forum Moderators: coopster
As an example I allow a page named:
THE_PAGE_TO_BE_MONITORED.asp to load ONLY IF Set WITHIN AN IFRAME.
OK to load:
<IFRAME SRC="http://www.mysite.com/THE_PAGE_TO_BE_MONITORED.asp"
Name="this page may load" ID=OK>
</iframe>
Disallow/Stop Loading/Send an Alert Message with Warning if
(same page)loaded this way:
<a href="http://www.mysite.com/THE_PAGE_TO_BE_MONITORED.asp">DO SOMETHING TO SUPRESS THIS PAGE LOAD</a>
I am trying this in order to disallow a visitor coming to my website
bypassing the index.htm page.
Thank you very very much and please respond a.s.a.p
then on other pages
check if does_it_match isset !empty
etc...
if OK then the user went through the index
If not... redirect..
[webmasterworld.com...]
Although it generally relies on the referer you could look into the solutions for avoiding hotlinking to images for .htaccess. Although as it has been pointed out above the referer can be faked.
Some form of $_SESSION variable would probably be your best bet, as mentioned above by henry0 and surrealillusions. As this would stop people viewing the page directly irrespective of javascript being active or not and there is no referer check involved.