-
Notifications
You must be signed in to change notification settings - Fork 16
Cache management
Victor Jonsson edited this page Apr 27, 2014
·
6 revisions
Saving an Arlima list will invoke a wordpress action named "arlima_save_list" with the Arlima_List object sent as argument to the callback function. Your cache expiring code might look something like:
<?php
add_action('arlima_save_list', function($list) {
$home_url = home_url();
foreach( explode(',', $list->getOption('pages_to_purge')) as $page_url ) {
some_slick_cache_purger( sprintf('%s/%s/', $home_url, trim($page_url, '/')) );
}
});
This Wordpress plugin was created by Swedish newspaper Västerbottens-Kuriren to give its editorial staff an easy to use tool for customizing the front pages of their online magazines.
- Download the latest release from github and unzip the folder in your plugin directory.
- Open up wp-admin and activate the plugin.
- Go to "Article lists" -> "Edit lists" in wp-admin and create your first article list.
- Open up a page (or create it) in wp-admin. Down to the right you will see a meta box labeled "Arlima" where you choose the list that you created on step 2.
- Go to "Article lists" -> "Manage lists" and start stuffing your article list with interesting content.