This plugin is able to read datafiles used by the popular Unix tool fortune and to display a random one. It then replaces the displayed one every few seconds with a new one using an AJAX request.
- Version upped (2017-04-20 23:51)
- major refactoring (2017-04-20 17:01)
- Version upped (2016-02-03 18:22)
- Merge pull request #4 from splitbrain-forks/php7-signature (2016-02-03 12:54)
- Adjust method signatures to match parent (2016-02-03 12:52)
- Version upped (2016-01-24 14:18)
- Version upped (2014-05-21 19:45)
- Merge pull request #3 from franckbrignoli/jquery_update (2013-01-09 20:28)
Just reference a textfile with the correct format with the following syntax:
You may specify the interval for changing the cookie in seconds:
The default is 30 seconds.
Here is an example:
% My first cookie % Another cookie with multiple lines % Third cookie %
- If your input files are not in UTF-8 this plugin will assume they are in latin1 and tries to convert them to UTF-8. If you get any charset problems, make sure the file is valid UTF-8.
- Using compiled fortune cookies would probably be more effective
- It is implied above, but I think it is better to state it explicitly: at least for DW Lemming and the latest version of the plugin, the fortune file must have UNIX line endings (
LF). Windows line endings won't do. — ryan.chappelle 2011/02/07 02:48