Can you add support for subtexts?
Re: Settings page integration
« Reply #15, on March 12th, 2012, 07:45 AM »
Strikes me that there's two ways to do it, either by checking for $txt[$current_setting . '_subtext'] and just setting subtext to that if found, or manually specifying it as a parameter. The former would be quicker and likely easier to use but the latter would be clearer how the answer is derived.
Which would you prefer to use? (Remember that you can have help text if you so desire, though it's not immediately obvious how... if you declare $helptxt[$current_setting] and then have it so your language file is also loaded by the lang_help hook, it should work (though I haven't tested to be sure)
The way it's meant to be |
That seems a big drastic seeing how there's absolutely no need to do anything extra in core for help popup strings.
Strikes me that there's two ways to do it, either by checking for $txt[$current_setting . '_subtext'] and just setting subtext to that if found, or manually specifying it as a parameter. The former would be quicker and likely easier to use but the latter would be clearer how the answer is derived.
Which would you prefer to use? (Remember that you can have help text if you so desire, though it's not immediately obvious how... if you declare $helptxt[$current_setting] and then have it so your language file is also loaded by the lang_help hook, it should work (though I haven't tested to be sure)
<settings>
<setting name="contact_verification" default="guests" />
</settings>
<settings>
<setting name="contact_verification" default="guests" subtext="contact_verification_somestring" />
</settings>