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.

Post New Thread Reply

Register GFY Rules Calendar
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed.

 
Thread Tools
Old 06-02-2015, 02:16 AM   #1
getcontentnow
Registered User
 
Industry Role:
Join Date: Jun 2014
Posts: 61
Good htaccess mobile redirect code?

Can somebody help me with an "uptodate" mobile redirect code for .htaccess?

I did google it, but theres to much crap out there.
__________________
Mike Glass
Icq: 652387948
getcontentnow is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 06-02-2015, 03:18 AM   #2
gebu
Confirmed User
 
gebu's Avatar
 
Industry Role:
Join Date: Jun 2013
Posts: 244
RewriteEngine On
RewriteRule \.(jpg|png|gif|jpeg|bmp)$ - [L]
RewriteCond %{HTTP_USER_AGENT} (mobile|android|blackberry|brew|cldc|docomo|htc|j2 me|micromax|lg|midp|mot|motorola|netfront|nokia|ob igo|openweb|opera.mini|palm|psp|samsung|sanyo|sch| sonyericsson|symbian|symbos|teleca|up.browser|voda fone|wap|webos|windows.ce) [NC]
RewriteRule ^(.*)$
http:// yoururl. com [R=302,L]
gebu is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 06-02-2015, 08:24 AM   #3
Matyko
PsyHead
 
Matyko's Avatar
 
Industry Role:
Join Date: Aug 2005
Location: Hungary
Posts: 8,632
this is a good code gebu posted, but don't do this. Get your mobile traffic a proper landing page On Your Site. Otherwise Google will fuck your site's ass.
__________________
-=- Register with our ref link and we help you with the setup! -=-
AdSpyglass.com - Double your profit from brokers
Matyko is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 06-02-2015, 08:43 AM   #4
campartner
Registered User
 
campartner's Avatar
 
Industry Role:
Join Date: Aug 2011
Posts: 37
Quote:
Originally Posted by getcontentnow View Post
Can somebody help me with an "uptodate" mobile redirect code for .htaccess?
Hi mike

No Need to redirect.I got what you need.
Please ping me on skype.

skype id CPRenato
__________________
Best Dating and Cam Affiliate Program for your German traffic!
Campartner.com
campartner is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 06-02-2015, 11:12 AM   #5
Ferus
Bye - Left to do stuff
 
Industry Role:
Join Date: Feb 2013
Posts: 4,109
Quote:
Originally Posted by Matyko View Post
this is a good code gebu posted, but don't do this. Get your mobile traffic a proper landing page On Your Site. Otherwise Google will fuck your site's ass.
This +1.
As fast as possible
Ferus is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 06-02-2015, 03:09 PM   #6
AlexTmz
Confirmed User
 
Industry Role:
Join Date: Sep 2005
Posts: 2,362
Use mobile pop code, dont use mobile redirect
__________________
Best banners/native ads and POPUPS with no any shit - Exoclick
Selling quality hardlinks/menu tabs/contextual links: from good aged sites
contact email:mastermich {here} gmail In com
AlexTmz is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 06-02-2015, 03:13 PM   #7
Paul&John
Confirmed User
 
Paul&John's Avatar
 
Industry Role:
Join Date: Aug 2005
Location: YUROP
Posts: 8,541
Quote:
Originally Posted by matyko View Post
this is a good code gebu posted, but don't do this. Get your mobile traffic a proper landing page on your site. Otherwise google will fuck your site's ass.
+1
.
.
.
__________________
Use coupon 'pauljohn' for a $1 discount at already super cheap NameSilo!
Anal Webcams | Kinky Trans Cams Live | Hotwife XXX Tube | Get your Proxies here
Paul&John is online now   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 06-02-2015, 04:25 PM   #8
Jel
Confirmed User
 
Jel's Avatar
 
Industry Role:
Join Date: Feb 2007
Posts: 6,904
Quote:
Originally Posted by Matyko View Post
this is a good code gebu posted, but don't do this. Get your mobile traffic a proper landing page On Your Site. Otherwise Google will fuck your site's ass.
it depends what page(s) you are using it on... not all traffic is se traffic
Jel is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 06-02-2015, 11:29 PM   #9
getcontentnow
Registered User
 
Industry Role:
Join Date: Jun 2014
Posts: 61
Thanks for the code!
Its for redirecting the mobile traffic to the .m version of the same website.
__________________
Mike Glass
Icq: 652387948
getcontentnow is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 06-02-2015, 11:44 PM   #10
Matyko
PsyHead
 
Matyko's Avatar
 
Industry Role:
Join Date: Aug 2005
Location: Hungary
Posts: 8,632
Quote:
Originally Posted by getcontentnow View Post
Thanks for the code!
Its for redirecting the mobile traffic to the .m version of the same website.
There are better solutions to make this happen. For example we use this on a very simple site, Above <head> !! :

<?php
if(! empty($_SERVER['HTTP_USER_AGENT'])){
$useragent = $_SERVER['HTTP_USER_AGENT'];
if( preg_match('@(iPad|iPod|iPhone|Android|BlackBerry| SymbianOS|SCH-M\d+|Opera Mini|Windows CE|Nokia|SonyEricsson|webOS|PalmOS)@', $useragent) ){
header('Location: ./mobile/');
}
}
?>

This redirects users to domain.com/mobile

But you can also determine a screen width in css to show the mobile site if the width is smaller than xxx pixels... Not sure how this works, but others will help to finetune this method
__________________
-=- Register with our ref link and we help you with the setup! -=-
AdSpyglass.com - Double your profit from brokers
Matyko is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 06-03-2015, 08:15 AM   #11
HowlingWulf
Confirmed User
 
HowlingWulf's Avatar
 
Join Date: Nov 2001
Posts: 1,662
Can also make CSS changes by screen width:
Code:
@media only screen and (max-width: 1440px) { }  /* small desktop */

@media only screen and (max-width: 1280px) { }  /* laptop */

@media only screen and (max-width: 1024px) { }   /* tablet landscape */

@media only screen and (max-width: 768px) { }     /* tablet portrait */

@media only screen and (max-width: 480px) { }    /* mobile landscape */

@media only screen and (max-width: 320px) { }   /* mobile portrait */
__________________
WP Porn directory/review theme Maddos $35.

webmaster AT howling-wulf.com
HowlingWulf is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 06-03-2015, 08:25 AM   #12
hdbuilder
Confirmed User
 
hdbuilder's Avatar
 
Industry Role:
Join Date: Jun 2012
Location: Canada
Posts: 1,338
Just go there and grab the one you need:

Detect Mobile Browsers - Open source mobile phone detection
hdbuilder is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 06-03-2015, 10:13 AM   #13
Matyko
PsyHead
 
Matyko's Avatar
 
Industry Role:
Join Date: Aug 2005
Location: Hungary
Posts: 8,632
Listen to HowlingWulf
__________________
-=- Register with our ref link and we help you with the setup! -=-
AdSpyglass.com - Double your profit from brokers
Matyko is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Post New Thread Reply
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >

Bookmarks

Tags
code, crap, google, mobile, redirect, htaccess



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.