Please note that the forum isn't realy used anymore.

If you have questions, want support or just simply want to talk to us you can find us on slack.

 

Parameter driven widgets

Is it possible to build widgets which can be configured by back-end UI parameters? For example, if I have a recent comments widgets I would like to set the amount of recent comments to display when adding the widget.

Thanks, Andre

You can't set a variable when you insert a widget if that's what you mean... You can set the amount of comments in the settings > module > blog settings but then all the recent comments widgets will use that setting.

If that's not what you want, then try to modify the module and add a few extra widgets...

I think Andre means the same as there happens in the blog module. Normally the amount of comment you want to show is set with a ModuleSetting. That's the easiest way for doing this.

Indeed. You can change the items per page, but also the total number of items in the blog widgets. But maybe he wants to insert multiple widgets into his website, each with a different amount of items?

Oh I just figured out that you weren't explicitly talking about the blog module. Other modules with recent comments widgets probably also have a setting for the number of items...

Comment

The forum is deprecated in favor of our Slack channel, which provides real-time support for your issues.

Join us on Slack here: https://fork-cms.herokuapp.com/