vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=194)
-   -   Add-On Releases - Mobile Device Style Assignment (https://vborg.vbsupport.ru/showthread.php?t=130983)

edytwinky 12-03-2008 09:29 PM

how do you get this to redirect for iPhones?

My buddies iPhones go to the regular site and not the mobile version.

I've removed the word iPhone from Useragent Exceptions and it still pulls up the full version of the site.

dartho 12-04-2008 03:39 AM

You should be able configure which skin you wish to display to iPhone devices in teh options...

Bakushan 12-04-2008 02:16 PM

When I turn on the exceptions list, i get this error:

Warning: preg_match() [function.preg-match]: Unknown modifier '5' in /global.php(237) : eval()'d code on line 13

dartho 12-04-2008 04:16 PM

do you have any forward slashes in the exception string? If so, escape it with a back slash. ie: "mozilla/4.0" becomes "mozilla\/4.0" Let me know if that was the issue and I'll look at updating the add-on....
thanks

Bakushan 12-04-2008 07:12 PM

yes, there were three of them:

"Mozilla/5.0 (Linux; U; Android 0.5; en-us) AppleWebKit/522+ (KHTML, like Gecko) Safari/419.3"

it now looks like:

"Mozilla\/5.0 (Linux; U; Android 0.5; en-us) AppleWebKit\/522+ (KHTML, like Gecko) Safari\/419.3"

and the error is gone..

(this is the Android G1 useragent i believe... just waiting on a user to test it for me to verify)

Bakushan 12-04-2008 07:15 PM

FYI, i wonder if the comma in the useragent will make it not work since they are comma-separated?

MissKalunji 12-04-2008 07:35 PM

Quote:

Originally Posted by Bakushan (Post 1678636)
yes, there were three of them:

"Mozilla/5.0 (Linux; U; Android 0.5; en-us) AppleWebKit/522+ (KHTML, like Gecko) Safari/419.3"

it now looks like:

"Mozilla\/5.0 (Linux; U; Android 0.5; en-us) AppleWebKit\/522+ (KHTML, like Gecko) Safari\/419.3"

and the error is gone..

(this is the Android G1 useragent i believe... just waiting on a user to test it for me to verify)

how is it suppose to look? i have some android users

dartho 12-05-2008 02:34 AM

You don't have to have a complete useragent - you could simple have the word "Android" and that would catch it. Should probably change it to use carriage returns or '|' symbols ...

Deathweaver 01-06-2009 08:11 AM

We've just installed this Add-On at our board, but some users prefer to choose the original style. Using a simple cookie this could be a usefull extension.

Just change the beginning of the Plugin at style_fetch Hook like this to check for an cookie:
PHP Code:

$noMobile $_COOKIE['bbNoMobile'];
if (
$vbulletin->options['mob_detect_enabled'] == && $noMobile != 1) {
...


Then you have to provide a possibility to set the cookie:
PHP Code:

<?php
setcookie
('bbNoMobile''1'time()+3600*24*30'/''%your_bb_url%');
if (
strpos($HTTP['HTTP_REFERER'], '%your_bb_url%')) {
    
header("Location: ".$HTTP['HTTP_REFERER']);
} else {
    
header("Location: http://%your_bb_url%/");
}
?>

Save this to a file called e.g. switch.php and replace %your_bb_url% with your board hostname. Now you only have to provide a link to switch.php.

Perhaps it is possible to include this feature and integrate the switch.php code as plugin into vBulletin. Unfortunately I'm not very skilled in vB Plugin development.

stemmy 01-30-2009 07:17 AM

This is probably a veruy simple answer but I cant find it !!

I am running VBA and I did the mods you requested to removed VBA sections.

Now when I look at the forum the first page is all crammed to the left. The rest of the forum looks fine.

Please can you help me sort this. Thanks in advance.

www.photography-forum.org


All times are GMT. The time now is 10:31 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01347 seconds
  • Memory Usage 1,744KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete