O'Reilly logo

CMS Made Simple Development Cookbook by Samuel Goldstein

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Creating a module-specific preference and admin panel to set it

Modules often need a way to have multiple options available for customization. That way, a single module can be used in different ways on different websites, and a site administrator can configure the module to suit their needs without having to modify the module's code.

To have such options, it would be an advantage if there were a standard approach to setting and retrieving persistent preference settings. Not surprisingly, the CMS Made Simple module API provides just that standard. This recipe gives an example of using that API, and wraps it into a form that allows the site administrator to update the preference.

How to do it...

  1. Using any of the methods described in Chapter 4, Getting ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required