Store and display random/rotated text by category in sidebar widget or templates.
RandomText is a handy WordPress plugin that allows you to save, edit and delete categorized text, and inject random/rotated text by category into the sidebar (via widget) or page body (via template tags). The sidebar widget allows you to set an optional Title, and text header and footer. You could say RandomText picks up where the Text widget left off. Whether you want to display random/rotated trivia, quotes, helpful hints, featured articles, or snippets of html, you can do it all easily with RandomText.
|Tags||plugin, quotes, random, sidebar, text, widget|
IMPORTANT: This plugin uses the WP_Widget class introduced in WordPress v2.8 and will not work with earlier versions of WordPress.
/wp-content/plugins/directory of your WordPress installation
- Activate the plugin through the 'Plugins' menu in WordPress
- The Random Text widget can now be configured and used from the Appearance -> Widgets menu
- Text entries can be managed via from the Settings -> Random Text menu
Note: During installation, Random Text creates a new database table to store the entries by category - you should see two test records after installation by clicking on the Settings -> Random Text menu.
- Fixed issues highlighted by WP_DEBUG.
- Added Settings link to Plugins page.
- Added cleanup on Uninstall.
- Tested up to WP v3.5.1.
- Fixed pagination issues on admin page (again).
- Fixed pagination issues on admin page.
- Fixed numerous issues highlighted by debugging mode.
- Fixed shortcode recursion
- Added support for shortcodes in text field
- Fixed Admin unicode truncation issue
- Added shortcode support
- Added Bulk Insert option
- Improved handling of "No Category" items
- Added record id check before timestamp update
- Added database table check/error to admin page
- Added random/rotation option
- Added screenshots
- Fixed admin path bug
- Fixed Pre-text/Post-text bug
- Fixed editing issues
- Minor correction to readme.txt
- Minor corrections to readme.txt
- Initial release
Can I use shortcodes?
Yes, you can use [randomtext] or [randomtext category="funny"] or even [randomtext category="funny" random="1"].
What about template tags?
You can use something like this, where 'category' is the group you wish to select items from. < ?php randomtext('category'); ?>