WildcardSearch / Advanced-Sidebox

A plugin for MyBB forums that displays custom boxes on various forum pages.
GNU General Public License v3.0
20 stars 10 forks source link

Module Development: Radio Setting Doesn't Display #149

Closed Tanweth closed 10 years ago

Tanweth commented 10 years ago

I'm developing another ASB module. I wanted to make one of the settings use radio buttons. However, I could not get a setting with optionscode "radio" to display on the module's settings page. If I kept everything the same, except used an optionscode of "select," the setting displayed as expected. I may ultimately go with a select box, but either way I figure it is worth reporting. :tongue:

Here is the setting array in question:

        "steam_displayname" => array
        (
            "sid" => "NULL",
            "name" => "steam_displayname",
            "title" => $lang->steam_displayname_title,
            "description" => $lang->steam_displayname_desc,
            "optionscode" => "radio
            steam=".$lang->steam_displayname_steam."
            forum=".$lang->steam_displayname_forum."
            both=".$lang->steam_displayname_both,
            "value" => 'steam'
        ),
WildcardSearch commented 10 years ago

Hi @Tanweth

Thanks for the report.

I've used code from admin/modules/settings.php to reproduce settings and perhaps I made some mistake. I'll give it a look today or tomorrow and let you know.

Frankly, I have only ever used yesno, text, onoff and select in testing.

WildcardSearch commented 10 years ago

@Tanweth this should be good. Can you test and close/report?

Tanweth commented 10 years ago

Yes, it now works. Thanks for working on it. :)

WildcardSearch commented 10 years ago

:+1: