MyBB Community Forums

Full Version: How to construct plugin settings like this
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi.

The setting for "Board Online / Offline" has this nice function that only shows the message text field, when the offline message has been enabled.
How can I set this up for plugin settings?

Please see attachment for example images of this.
This is done with javascript in the settings module. These are called "peekers" within MyBB. See this line for the list of them within MyBB core.

Not entirely sure of the process of constructing new peekers, but there is a hook in there to allow them to be easily added into the array.
(2021-02-08, 01:31 PM)Darth Apple Wrote: [ -> ]This is done with javascript in the settings module. These are called "peekers" within MyBB. See this line for the list of them within MyBB core.

Not entirely sure of the process of constructing new peekers, but there is a hook in there to allow them to be easily added into the array.

Thank you, I will use the hook to trigger these new peekers. Thanks man!