dyelton Posted November 22, 2010 Report Share Posted November 22, 2010 It used to work this way, but with the last couple of releases, IP.Content is loading on the mobile skin instead of it going straight to the forums. It looks horrible since I'm using a pretty heavily customized template for IP.Content on my board. I'd rather anyone that gets the mobile skin loaded be redirected to the forums instead of having IP.Content display.Any way around this to make it work like it used to in previous versions?Thanks! Link to comment
Timan Posted November 24, 2010 Report Share Posted November 24, 2010 Ah I've not had the chance to mess with ip.content. I'll have to look into skinning that (if its logical) after I finish blogs. Link to comment
dyelton Posted November 25, 2010 Author Report Share Posted November 25, 2010 I'm not wanting IP.Content being skinned necessarily, I just want the mobile version to go to the forums automatically if IP.Content is enabled. Link to comment
Timan Posted November 26, 2010 Report Share Posted November 26, 2010 Only thing I can suggest, is if there is a mobile template for it.Add a simple redirect/refresh thingy to go to your forums.<meta http-equiv="refresh" content="0;url=http://website.com/forums/" /> Link to comment
dyelton Posted November 26, 2010 Author Report Share Posted November 26, 2010 Only thing I can suggest, is if there is a mobile template for it.Add a simple redirect/refresh thingy to go to your forums.<meta http-equiv="refresh" content="0;url=http://website.com/forums/" />Unfortunately I do not see a mobile template for it in your mobile skin. I'm curious why it used to redirect to the forums automatically, but that functionality changed somewhere in the last 2-3 versions of your mobile skin? Link to comment
Timan Posted November 26, 2010 Report Share Posted November 26, 2010 Unfortunately I do not see a mobile template for it in your mobile skin. I'm curious why it used to redirect to the forums automatically, but that functionality changed somewhere in the last 2-3 versions of your mobile skin?Nope, my skin has no control over how the site works. Just how it looks. Link to comment
miguelmayo Posted December 15, 2010 Report Share Posted December 15, 2010 (edited) I racked my brains on this subject, I use upportal for my homepage on the desktop and it renders horribly on the aquaskin, but I used the ipb-portal and built in some content tailered for the aquaskin and it looks great but getting it to switch when a mobile phone user was a problem. I found a solution with a script offered by this guy - you must pay for it if its a commercial site, I am not but I made a donation for the script anyway./>http://detectmobilebrowsers.mobi/download and put the php file in your forum root, mobile_device_detect.php in the same folder as the ipb file initdata.php, then edit that file with thischange if ( ! defined( 'IPS_DEFAULT_PUBLIC_APP' ) ){ define( 'IPS_DEFAULT_PUBLIC_APP', 'ipcontent' );}to this substituting the ap of your choice for desktop and mobile my aps are uportal and portal, they can be switched to index or whatever you use.line 19 addrequire_once('mobile_device_detect.php');$mobile = mobile_device_detect();line 46 change to/** * Default app name * You can set this in your own scripts before 'initdata.php' is required. */if ( ! defined( 'IPS_DEFAULT_PUBLIC_APP' ) ){ if($mobile =='0') { define( 'IPS_DEFAULT_PUBLIC_APP', 'uportal' ); }else { define( 'IPS_DEFAULT_PUBLIC_APP', 'portal' ); }}my forum/>http://www.vfrd.com Edited December 15, 2010 by miguelmayo Link to comment
dyelton Posted December 15, 2010 Author Report Share Posted December 15, 2010 Here is my workaround. A simple PHP script that I use as my index.php file in my site's root directory:<?php//setting the variables$ipod = stripos($_SERVER['HTTP_USER_AGENT'],"iPod");$iphone = stripos($_SERVER['HTTP_USER_AGENT'],"iPhone");//detecting deviceif ($ipod == true || $iphone == true){header( 'Location: http://www.urbanplanet.org/forums/index.php/' ) ;} else {header( 'Location: http://www.urbanplanet.org/forums/index.php?app=ccs&module=pages§ion=pages&folder=&id=4' ) ;//header( 'Location: http://www.urbanplanet.org/forums/index.php' ) ;}?> Link to comment
Recommended Posts