PDA

View Full Version : Redirecting mobile traffic with sponsor scripts


LD
2009-09-07, 07:05 AM
I've noticed some of my sponsors offer a script or code that redirects mobile visitors to their mobile tour. Anyone using something like this? I'm thinking of trying it out. What do you think?

Cleo
2009-09-07, 07:50 AM
This reminds me that I need to contact Topbucks to ask about their script to redirect mobile traffic to my Topbucks white label site that they did for me (http://mobile.cleos-porn-links.com/).

LD
2009-09-07, 07:52 AM
White label redirect, eh? Sounds interesting...

Cleo
2009-09-07, 07:56 AM
White label redirect, eh? Sounds interesting...
So far zero sales but I'm barely sending any traffic to it.

InfoGuy
2009-09-07, 12:56 PM
FYI, your 2257 notice appears as black text on black background.

Cleo
2009-09-07, 02:34 PM
FYI, your 2257 notice appears as black text on black background.
Who's, what url?

I'm looking at the three ways TopBucks is suggesting doing it (http://terrizamore.com/redirect.html).

Cleo
2009-09-07, 03:35 PM
OK, This is what I ended up doing and it seems to be working well.

In my htaccess,
DirectoryIndex index.php index.shtml index.html index.htm
This way index.php is looked for first.

Then in the index.php file I put this,
<?php
$REGULAR_URL = 'http://cleos-porn-links.com/index.shtml';
$MOBILE_URL = 'http://mobile.cleos-porn-links.com/';

// Do not edit below
$WORDS = array('mobile', 'blackberry', 'j2me', 'webos', 'windows ce', 'android', 'nokia', 'samsung', 'LG', 'palm', 'PSP');
$is_mobile = FALSE;
foreach ($WORDS as $w)
{
if (isset($_SERVER['HTTP_USER_AGENT'])
&& stripos($_SERVER['HTTP_USER_AGENT'], $w))
{
$is_mobile = TRUE;
break;
}
}
$url = ($is_mobile) ? $MOBILE_URL : $REGULAR_URL;
if (!empty($url))
{
header('Location: ' . $url);
}
?>
(The links on my mobile domain (http://mobile.cleos-porn-links.com/) are getting changed to http://cleos-porn-links.com/index.shtm sometime in the next day or so. Until then the "View Full Web Version" link does not go to my non mobile site)
This way mobile surfers can still reach my regular site but will get presented with a mobile option first. Non mobile surfers will not notice anything different at all and both mobile and non mobile users can still reach any non mobile page too.

On a side note... I modified the htaccess in my porntube by adding this,
RewriteCond %{HTTP_USER_AGENT} (mobile|blackberry|j2me|symbian|windows.ce) [NC]
RewriteRule ^(.*)$ http://mobile.cleos-porn-links.com/ [R=302,L]
Now the mobile traffic is going to my Topbucks white label site instead of Brazzers. :D

InfoGuy
2009-09-07, 09:52 PM
Who's, what url?

http://mobile.cleos-porn-links.com/ ==> Enter Mobile Site (maybe it only looks that way because I'm using a standard browser).

Gausche
2009-09-07, 09:52 PM
Good luck Cleo :)

Cleo
2009-09-07, 10:45 PM
http://mobile.cleos-porn-links.com/ ==> Enter Mobile Site (maybe it only looks that way because I'm using a standard browser).
This is what you should be seeing.
http://www.greenguysboard.com/board/attachment.php?attachmentid=1910&stc=1&d=1252377875
Good luck Cleo :)
Thanks. :)

LD
2009-09-08, 02:15 PM
I plugged in Pimproll's code and tried it out on my LD domain. Looks pretty good. They have a Java and a php version which is quick and easy, but I do like the white label.