GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   anyone know of a cookie script for... (https://gfy.com/showthread.php?t=88174)

Va2k 11-14-2002 12:38 PM

anyone know of a cookie script for...
 
setting cookies so if a surfer visited a page before and you dot want him to visit it a gain it will redirect him to the page you want him instead of the page you dont want him or her.


TOM

Rory 11-14-2002 12:45 PM

Quote:

Originally posted by va2k
setting cookies so if a surfer visited a page before and you dot want him to visit it a gain it will redirect him to the page you want him instead of the page you dont want him or her.


TOM

Well if you do this other thing.........

here is some quick php code that should work (test it first just writing in the little gfy box here) :

\<\?php
if (!$_COOKIE['iamahomo']) {
setcookie("iamahomo","Yes");
} else {
header("Location: http://www.iamnotahomo.com/pagetobeserverd.html");
}
?>

fuckin thing.... take out the 2 \'s on the first line ... doesnt wanna output it and if you do in PHP tag its fuckin tiny

Va2k 11-14-2002 12:54 PM

im getting this Warning: Cannot add header information - headers already sent by (output started at /home/sites/site14/web/ifriends.php:8) in /home/sites/site14/web/ifriends.php on line 16

Rory 11-14-2002 12:56 PM

Quote:

Originally posted by va2k
im getting this Warning: Cannot add header information - headers already sent by (output started at /home/sites/site14/web/ifriends.php:8) in /home/sites/site14/web/ifriends.php on line 16
You need to paste that code before any output ..... so paste that as the top thing (and obviopsuly replace the url..)

Rory

Va2k 11-14-2002 01:01 PM

great Fuck yea i t works thanks thanks thank :)

Rory 11-14-2002 01:03 PM

Quote:

Originally posted by va2k
great Fuck yea i t works thanks thanks thank :)
:)

Just keep in mind that some people have cookies completely disabled so its always nice to have a backup plan for people who dont have cookies enabled as well.

Rory
:helpme

Theo 10-06-2003 08:23 PM

nice,i was looking for this too :)


All times are GMT -7. The time now is 07:12 AM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123