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 08-16-2012, 09:37 PM   #1
versa
Confirmed User
 
Industry Role:
Join Date: Jun 2011
Posts: 266
Mobile redirect code

How would you go about having a mobile visitor go to a page linked from a referring site and display page as normal . If the surfer clicks on any of the site navigation bars/pages etc after this would get redirected if mobile?

Thanks for any thoughts on this!
versa is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook
Old 08-19-2012, 05:29 AM   #2
AdultPayout
Confirmed User
 
Industry Role:
Join Date: Aug 2012
Location: Europe
Posts: 115
do you need a code?
Code:
<script type="text/javascript">
if (navigator.userAgent.match(/(opera mini|samsung|ipod|ipad|iphone|up.browser|up.link|mmp|symbian|smartphone|midp|wap|vodafone|o2|pocket|kindle|mobile|psp|treo|nokia|blackberry|pre\/0.1|android)/i)) {
    location.replace("URL for redirect HERE"); 
} 
</script>
AdultPayout is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook
Old 09-04-2012, 04:19 PM   #3
Dating Port
Useless As Ever
 
Dating Port's Avatar
 
Industry Role:
Join Date: Jan 2009
Location: Planet Earth
Posts: 731
Oops, wrong answer....edited

You want them to land on your normal page first. Then when they click anything, they get redirected to mobile?
Why not redirect them coming in?
__________________
Email: admin[at]datingport.co.uk - ICQ: 456416181
It's amazing what you (L)earn when you put some effort into it!

Last edited by Dating Port; 09-04-2012 at 04:22 PM..
Dating Port is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook
Old 09-07-2012, 12:50 AM   #4
versa
Confirmed User
 
Industry Role:
Join Date: Jun 2011
Posts: 266
One of those image hosting sites. Want them to see the gallery image when they come in through a external link but redirect if they do any actions
versa is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook
Old 09-07-2012, 01:47 AM   #5
Dating Port
Useless As Ever
 
Dating Port's Avatar
 
Industry Role:
Join Date: Jan 2009
Location: Planet Earth
Posts: 731
Put this between your <head> </head> tags

Quote:
<script type="text/javascript">
window.onclick = function() {
setTimeout("window.location.href= 'http://the.redirect.site/'",0);
}
</script>
The "redirect site" being where you want to send them

I just tested it on a page that had an image but no links or urls.
__________________
Email: admin[at]datingport.co.uk - ICQ: 456416181
It's amazing what you (L)earn when you put some effort into it!

Last edited by Dating Port; 09-07-2012 at 01:52 AM..
Dating Port is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook
Old 09-07-2012, 03:14 PM   #6
Bonken
Registered User
 
Join Date: Apr 2008
Posts: 35
If you want an alternative, you could use PHP on all the other pages, like this:

Edit: I can't post links, but if you google 'php if mobile device' the google codes reuslt seems optimal.
Bonken 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



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.