O'Reilly logo

WordPress Plugin Development Cookbook by Yannick Lefebvre

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

Storing stylesheet data in user settings

While most common plugin options are typically presented to users as simple textboxes, checkboxes, or drop-down lists, there are instances where more text needs to be stored for user settings. A good example of this are plugin-specific stylesheets, which allow users to change the visual appearance of plugin output. While loading a separate stylesheet file worked well in the Loading a stylesheet to format plugin output recipe in Chapter 2, Plugin Framework Basics, this approach did not give users a lot of liberty in changing these styling rules to work better with their site design since any changes that users make to the stylesheet will get overwritten when the plugin is updated using the WordPress automatic ...

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