ArmandPhilippot / post-types-list-widget

WordPress Plugin: display a list of posts by post types as widget.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Post Types List Widget

License Version

A WordPress Widget to display a list of posts by post types with custom options.

Presentation

This widget can be place in your sidebar to display a list of posts by post types. It allows you to choose:

  • between the default post types and your custom post types
  • if all posts must be displayed or if you prefer to set a number of posts
  • a sorting method (publication date, title, random...) and a sorting order
  • an additional sorting method (optional)
  • which data to display (dates, excerpt...)

If you have sticky posts, you may want checked "Ignore sticky post" to prevent them to appear at the top of the list.

Although the name of the widget is not very explicit, it allows you to build custom queries through WP_Query but all arguments are not available. At first, the idea was to list all posts for custom post types a little like the Categories widget. Then, I decide to add more options to make the widget more reusable.

Installation

Composer installation

You can use Composer to install this plugin as a dependency if you use custom installers:

{
"require": {
    "armandphilippot/post-types-list-widget": "dev-main"
}
"repositories": [{
    "type": "git",
    "url": "git@github.com:ArmandPhilippot/post-types-list-widget.git"
}]

It is also possible to specify a version by replacing dev-main with dev-main#v1.0.0 (an existent tag).

Manual installation

You can download this plugin on Github, then extract it in /wp-content/plugins/ directory.

Usage

  1. Navigate to the "Plugins" dashboard page and click on "Activate".
  2. Add "Post Types" to a widget area through the "Widgets" menu in WordPress.
  3. Configure settings.

Screenshots

Admin view Public view
Admin view Public view

License

This project is open source and available under the GPL v2 or later License.

About

WordPress Plugin: display a list of posts by post types as widget.

License:GNU General Public License v2.0


Languages

Language:PHP 53.6%Language:JavaScript 37.2%Language:CSS 5.3%Language:SCSS 4.0%