vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=252)
-   -   Sorting out mobile (https://vborg.vbsupport.ru/showthread.php?t=313228)

pjkcards 07-25-2014 02:17 PM

Sorting out mobile
 
I was browsing http://forums.androidcentral.com/ today on my mobile phone and was very impressed by how well it worked on mobile. When I go to it, it looks very nice, and formats well with mobile. However, at the bottom of the site, I can click "View Full Site" and the desktop version shows up.

How can I setup like this (I'm running vB 4.2.1, but androidcentral is running vB 5 I think)? How does it force the mobile phone useragent to go to the mobile site, yet still lets a mobile device view the full desktop site upon clicking "View Full Site"?

Many thanks.

Dave 07-25-2014 02:42 PM

It looks like this theme. View full site is just a normal link and it's just a matter of checking the useragent to identify a mobile user.

pjkcards 07-27-2014 06:54 AM

Quote:

Originally Posted by Dave (Post 2508244)
It looks like this theme. View full site is just a normal link and it's just a matter of checking the useragent to identify a mobile user.

If you're using useragent though, when a mobile user clicks "View Full Site", wouldn't it recognize your useragent and just forward you to the mobile site again? How do you overcome this?

Thanks.

Dave 07-27-2014 08:12 AM

That's a matter of setting a cookie or session variable. If your custom variable is set, do not redirect, else redirect unless the user changed styles.

pjkcards 07-27-2014 12:14 PM

How do I do that?

pjkcards 09-28-2014 06:15 AM

Can anyone help me with this? Thanks.

Azum 09-28-2014 08:02 PM

AdminCP -> Settings -> Options -> Style & Language Options

Default Style for Old Mobile Browsers
Select the default mobile style for old mobile browsers. This style will be used if user is browsing your forum with an older mobile browser. Set to 'None' to use desktop browser style.

Default Style for Modern Mobile Browsers
Select the default mobile style for modern mobile browsers. This style will be used if user is browsing your forum with a modern mobile browser. Set to 'None' to use desktop browser style.


All times are GMT. The time now is 02:56 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.01034 seconds
  • Memory Usage 1,720KB
  • 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
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (7)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete