vbulletin how to select site language in mobile style

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Farid Helal
    Senior Member
    • Mar 2013
    • 102
    • 4.1.x

    vbulletin how to select site language in mobile style

    I have 2 languages for my site id=1 and id=2
    the default is id=1

    for users need to change language , there no such option in the mobile style

    Help please ? Click image for larger version

Name:	mobile-home.JPG
Views:	111
Size:	37.9 KB
ID:	4325718
  • Zachery
    Former vBulletin Support
    • Jul 2002
    • 59097

    #2
    There isn't an option to select a language by default. You could fix that with some hard coded links in the footer of the mobile template.

    Comment

    • Farid Helal
      Senior Member
      • Mar 2013
      • 102
      • 4.1.x

      #3
      Originally posted by Zachery
      There isn't an option to select a language by default. You could fix that with some hard coded links in the footer of the mobile template.
      Any help or guide on how to do that ?

      Thank you

      Comment

      • kh99
        Senior Member
        • Aug 2009
        • 533

        #4
        Well, the "Full Site" link is basically a style switching link, so you could make a language switching link in a similar way:
        Code:
        <vb:if condition="LANGUAGEID == 1">
        <a href="{vb:raw vboptions.forumhome}/?langid=2" class="fullsitelink" rel="external">English</a>
        <vb:else />
        <a href="{vb:raw vboptions.forumhome}/?langid=1" class="fullsitelink" rel="external">Other Language</a>
        </vb:if>
        But that link will bring you back to the forum home page. The drop-down language chooser on the non-mobile style uses a javascript function to build a url that switches languages but keeps you at the same place on the same page. But it expects the languages to be in a 'select' tag so if you wanted to do that you'd have to either write your own or come up with some clever way to re-use the existing javascript. I thought it might be possible to do by including a hidden select tag in the template, but for some reason it becomes visible when the mobile style is done messing with it.
        Last edited by kh99; Sat 25 Jul '15, 4:02am.

        Comment

        widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
        Working...