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.

 

Register GFY Rules Calendar
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >
New Webmasters ask "How-To" questions here. This is where other fucking Webmasters help.

 
Thread Tools
Old 01-17-2015, 11:20 AM   #1
Smart Fred
Confirmed User
 
Smart Fred's Avatar
 
Industry Role:
Join Date: Mar 2008
Location: France
Posts: 308
Google analytics and PHP redirection pages

Hi guys,

From a few months I started using redirection pages to manage from one place my affiliation code I use on many galleries.

So I use such a code
Quote:
<?php
$agent = $_SERVER['HTTP_USER_AGENT'];
if (preg_match('/(iPod|iPhone|android|blackBerry|symbianOS|opera mini|windows CE|nokia|sonyericsson|webOS|palmOS)/i', $agent)) {
header("location: http://my-affiliation-link-to-mobile-tour");
} else {
header("location: http://my-affiliation-link-to-classic-tour");
}
?>
in an index.php file in such a directory http://my-domain.com/go/program/

But I feel completely unable to get Google analytics stats for such a page.
So I'm unable to compare the amount I sent with the amount received on the affiliation program, and I'm also unable to define this page as a goal in Google Analytics.

Is there anyway to use Google Analytics stats and goals for such redirection pages ?

Thanks for your help.
__________________
Stop doing what you like and start doing what brings you money!
Smart Fred is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook
Old 01-19-2015, 04:42 PM   #2
robber
Web Developer
 
Industry Role:
Join Date: Jan 2011
Location: UK
Posts: 264
Hi,

You need to go about tracking the link in a different way, it needs to be on the page of your site it's being clicked on instead, as the php redirect will not trigger the code as it executes pretty much instantaneously.

Take a look at the google article on how to work with analytics to track the outbound links

https://support.google.com/analytics...36920?hl=en-GB

Hope this helps

Rob
robber is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook
Old 01-20-2015, 05:38 AM   #3
Smart Fred
Confirmed User
 
Smart Fred's Avatar
 
Industry Role:
Join Date: Mar 2008
Location: France
Posts: 308
Thanks Rob,
That should be what I need. I will try implement the outbound links on my site asap.
__________________
Stop doing what you like and start doing what brings you money!
Smart Fred is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook
Old 02-01-2015, 06:15 AM   #4
fappingJack
So Fucking Banned
 
Industry Role:
Join Date: Dec 2014
Location: somewhere down the road
Posts: 2,172
fappingJack is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook
 
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >

Bookmarks

Tags
google, analytics, redirection, unable, pages



Advertising inquiries - marketing at gfy dot com

Contact Admin - Advertise - GFY Rules - Top

©2000-, AI Media Network Inc



Powered by vBulletin
Copyright © 2000- Jelsoft Enterprises Limited.