Jump to content

Download: [mm31] Hide Language Dropdown


Mod-Mall.com

Recommended Posts

File Name: [mm31] Hide Language Dropdown
File Submitter: Mod-Mall.com
File Submitted: 09 Oct 2010
File Updated: 29 Jul 2011
File Category: Hooks and Plugins

This hook will hide the language chooser in the IP.Board footer. I know it can be done with a simple template edit, but what can I say, I'm lazy %7Boption%7D

A few things you should be aware of before installing this hook:

1) The hook will immediately hide the language dropdown once it is installed, to re-enable the language dropdown you need to go to ACP -> System Settings -> General Configuration and at the bottom you will find an option to display/hide the language dropdown (or just disable / uninstall this hook).

2) This hook is a bit of a cludge in that it just uses class='hide' to hide the language dropdown. That means that the W3C validation tool will complain about an unclosed tag.

Any questions / suggestions / issues / etc, feel free to ask %7Boption%7D

Click here to download this file

Link to comment

nice, one suggestion...


I never got why the language drop down is there on sites that only have one language installed.


Maybe in your next version you can add a feature so if a site has more then one language installed it will show up.




I would imagine that if the site has more than 1 language installed, they won't install this hook :)

Also, as you cannot edit phrases in the default language anymore, I tend to rename the default language to "Master language", then copy it as "English", then make that the default and edit the phrases in that. that's the main reason I wrote this mod, to hide the language drop down so it doesn't show the "Master" language option :)
Link to comment
  • 3 weeks later...
  • 3 weeks later...
  • 4 months later...

This may be unique to our board, but I thought I'd mention it anyway. We use a non-standard skin (this one) which displays a pop-up quick log-in box for members to sign in, rather than take them to the main sign-in page.

With this hook installed/enabled, that feature does not function in IE8 (fine in Chrome, FF). No idea why, but disabling the hook restores functionality.

As I say, might be unique to us, but thought it worth mentioning.

Link to comment

Hi Jon,

Unfortunately, this hook uses a bit of a cludge to hide the language dropdown so it doesn't play well with some custom skins :)

The hook adds a "<h2 class='hide'>" in front of the language dropdown and relies on there being an </h2> just after the language dropdown as there is in the default skin (as part of "<h2 class="hide">Execution Stats</h2>", it'll just wrap everything that follows in the <h2> tag until it finds a closing one.

Thankfully though, this feature will be standard in IP.Board 3.2 so this cludge will soon be a thing of the past :D

Link to comment
  • 3 weeks later...

Hey, if you really want to fix this hook just use a simple css insert to fix it.

In place of: (line 48 of the hook)

return "<h2 class='hide'>";

use:

return "<style>#newLang{display:none;}</style>";

which will fix the W3C validation tool complaint about an unclosed tag and will Hide the Language Dropdown on any skin.

If you have installed this hook, then uninstall it and make the change and then re-install it.
Hopefully Alan (the author of this hook) will make this correction and upload the new version so it's publicly available.

Thank you for this very useful hook Alan! %7Boption%7D

Link to comment

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...