|   |   |   | ||||
| Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. | 
|    | 
| 
 | |||||||
| Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. | 
|  | Thread Tools | 
|  12-07-2017, 08:01 AM | #1 | 
| Pay It Forward Industry Role:  Join Date: Sep 2005 Location: Yo Mama House 
					Posts: 77,250
				 | 
				
				[Tech] Redirections in PHP file
			 this is copied. i modified some of it. I'm using this php jump script for my affiliate links. Simply copy and paste following code to a text editor on your PC. I use Pspad Code: <?php
$v = $_GET['v'];
// In case someone calls naked php file
if ($v == '') {$link = 'http://pornstuffarooni.com/';}
// Add as many as links in below format. Each in a new line.
if ($v == 'fish') {$link = 'http://sexoidfsh.com/';}
if ($v == 'oils') {$link = 'http://fundepwe.com/';}
if ($v == 'grapes') {$link = 'http://grapeapewatreu.com/';}
// Don't change anything below this line.
header("Location: $link") ;
exit();
?>ads.php and uploaded to /go/ directory, linking to following URL will redirect user to example1.com. Code: http://pornstuffarooni.com/go/ads.php?v=fish We don't want Google to crawl these redirections. We can easily prevent it and other bots from crawling these files by blocking access to the directory. So open your robots.txt file and add following code to it. Code: User-agent: * disallow: /go/* 
				__________________ TRUMP 2025 KEKAW!!! - The Laken Riley Act Is Law! DACA ENDED - SUPPORT AZ HCR 2060 52R - email: brassballz-at-techie.com | 
|   |           | 
|  12-07-2017, 08:50 AM | #2 | 
| Too lazy to set a custom title Join Date: Mar 2002 Location: Australia 
					Posts: 17,393
				 | I would also add a header that explicitly changes the HTTP response code to 302: header("HTTP/1.0 302 redirect"); header("Location: $link"); | 
|   |           | 
|  12-07-2017, 08:51 AM | #3 | 
| Too lazy to set a custom title Join Date: Mar 2002 Location: Australia 
					Posts: 17,393
				 | You also have no default case. If $v isn't fish/oil/grapes then your server will tell the browser to redirect to a blank URL. | 
|   |           | 
|  12-07-2017, 08:56 AM | #4 | 
| Pay It Forward Industry Role:  Join Date: Sep 2005 Location: Yo Mama House 
					Posts: 77,250
				 | i actually use this. i have not had any issues. have sent over a million clicks this year through it 
				__________________ TRUMP 2025 KEKAW!!! - The Laken Riley Act Is Law! DACA ENDED - SUPPORT AZ HCR 2060 52R - email: brassballz-at-techie.com | 
|   |           | 
|  12-08-2017, 11:13 AM | #5 | 
| Pay It Forward Industry Role:  Join Date: Sep 2005 Location: Yo Mama House 
					Posts: 77,250
				 | bump for friday 
				__________________ TRUMP 2025 KEKAW!!! - The Laken Riley Act Is Law! DACA ENDED - SUPPORT AZ HCR 2060 52R - email: brassballz-at-techie.com | 
|   |           | 
|  12-09-2017, 03:43 PM | #6 | |
| Pay It Forward Industry Role:  Join Date: Sep 2005 Location: Yo Mama House 
					Posts: 77,250
				 | Quote: 
  
				__________________ TRUMP 2025 KEKAW!!! - The Laken Riley Act Is Law! DACA ENDED - SUPPORT AZ HCR 2060 52R - email: brassballz-at-techie.com | |
|   |           |