Provides flexible and advanced random posts. Display it via shortcode or widget with thumbnails, post excerpt, and much more!
This plugin is no longer supported, please use Recent posts widget Extended instead.
This plugin will enable a custom, flexible and advanced random posts. It allows you to display a list of random posts via shortcode or widget with thumbnail, excerpt and post date, also you can display it from all or specific or multiple taxonomy.
Explanation of shortcode options:
Basic shortcode
[arpw]
Display 10 random posts
[arpw limit="10"]
Display with thumbnail and set the size
[arpw thumbnail="true" thumbnail_size="arpw-thumbnail"]
Display posts based on category by id
[arpw thumbnail="true" cat="10"]
Display portfolio post type
[arpw post_type="portfolio"]
Here’s the full default shortcode arguments
title="" offset="" limit="5" post_type="post" post_status="publish" ignore_sticky="1" taxonomy="" cat="" tag="" thumbnail="false" thumbnail_size="arpw-thumbnail" thumbnail_align="left" excerpt="false" excerpt_length="10" date="false" date_modified="false" date_relative="false" css_class="" before="" after=""
Through Dashboard
Installing Via FTP
Your theme needs to support Post Thumbnail, please go to https://codex.wordpress.org/Post_Thumbnails to read more info and how to activate it in your theme.
By default it uses arpw-thumbnail which have 50×50 size. If you want to use custom image size, you can install https://wordpress.org/plugins/simple-image-sizes/ then create new image size, it will appear in the Thumbnail Size selectbox in the widget option.
I have mentioned it in the plugin description. If you use images that were uploaded to the media library before you installed this plugin and/or you have your own custom image sizes, please install Regenerate Thumbnails plugin to fix the image size.
The plugin comes with a very basic style, if you want to add custom style please do wp_dequeue_style
to remove the default stylesheet. Place the code below in your theme functions.php
.
function prefix_remove_arpw_style() { wp_dequeue_style( 'arpw-style' ); } add_action( 'wp_enqueue_scripts', 'prefix_remove_arpw_style', 10 );
Then you can add your custom style using Custom CSS plugin or in your theme style.css
. Here’s the plugin selector
/* ul */ .arpw-ul {} /* li */ .arpw-li {} /* title */ .arpw-title {} /* thumbnail */ .arpw-thumbnail {} /* date */ .arpw-time {} /* excerpt */ .arpw-summary {}
width
and height
attribute if using custom image size