Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

HTML Forum


You are currently viewing our HTML Forum as a guest. Please register to participate.
Login



Post a Project »

Find a Professional HTML Freelancer!

Find a Freelancer to help you with your HTML projects

FREE Outsourcing eBook!

Reply
Visiting Page from only ONE page first
Old 12-10-2006, 09:49 AM Visiting Page from only ONE page first
Junior Talker

Posts: 2
Name: JohnK
Trades: 0
I want to make sure that people who come to this page: www.mysite.com/test.html can only get there if they FIRST goto http://www.mysite.com/disclaimer.html

This way here I know they read the disclaimer and made the choice to continue.

Hard to explain, but I hope you understand.

Thanks for the assistance!

KLIMO
KLIMO is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 12-10-2006, 10:29 AM Re: Visiting Page from only ONE page first
blackhawkpowers's Avatar
Ultra Talker

Posts: 313
Name: Dustin
Location: GA
Trades: 0
it's going to have to be a serverside solution for this I've not actually written a script to do this so bare with me I'll whip out some code here but i'm not going to test it so work with it .. Make sure your server has php enabled and then instead of test.html make it test.php with the following code
PHP Code:
<?
if (!strstr($_SERVER['HTTP_REFERER'], "disclaimer.html")) {
header ("Location: http://" $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']). "/disclaimer.html");
}
?>
 
<html><body>put your test.html html here </body></html>
This will redirect anyone who did not come from your disclaimer page back to the disclaimer page until they arrive from that page.... Remember it will only work as long as the server has php and you change the estention of test.html to test.php
__________________
A patch is a piece of software which replaces old bugs with new bugs.

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
blackhawkpowers is offline
Reply With Quote
View Public Profile Visit blackhawkpowers's homepage!
 
Old 12-10-2006, 11:29 AM Re: Visiting Page from only ONE page first
Junior Talker

Posts: 2
Name: JohnK
Trades: 0
Instead of ("Location: http://" . $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']). "/disclaimer.html");
}



I used

("Location: http://www.mysite/disclaimer.html");
}


And it redirects the people to the right page. The code you gave me stated 404 Error when I came from a page other then the disclaimer..

Seems to work the way I modified the code with a direct link.

Do you think this will be fine or is this not going to be good?

Thanks for your assistance amd fast reply earlier as well.

KLIMO

Last edited by KLIMO; 12-10-2006 at 11:50 AM..
KLIMO is offline
Reply With Quote
View Public Profile
 
Old 12-10-2006, 01:43 PM Re: Visiting Page from only ONE page first
blackhawkpowers's Avatar
Ultra Talker

Posts: 313
Name: Dustin
Location: GA
Trades: 0
well the only real drawback to using that is going to be that they will have to view your disclaimer every single time... if that's what you want then it's good.. the only thing I can think of where that would really be acceptable is an adult site if that's what it is then yeah good thinking if it's not you may just have frustrated customers..... the first time I would be ok with it but every other time it would become annoying
__________________
A patch is a piece of software which replaces old bugs with new bugs.

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
blackhawkpowers is offline
Reply With Quote
View Public Profile Visit blackhawkpowers's homepage!
 
Reply     « Reply to Visiting Page from only ONE page first
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.66339 seconds with 12 queries