/wp-date-pagination

A WordPress plugin to paginate your posts by year, month or day.

Primary LanguagePHPGNU General Public License v2.0GPL-2.0

Date Pagination

Paginate your posts by year, month or day.

Build Status

Version: 2.1.1
Requires at least: 4.5
Tested up to: 5.5

This is the development repository for the WordPress plugin Date Pagination.

This plugin provides an easy way to paginate posts by year, month or day in your theme’s template files. Use the native WordPress pagination functions to display the pagination links.

It’s likely your theme is already using these functions for normal pagination. If not, see if it works with your theme’s pagination or add them yourself.

To tell WordPress a page should be paginated by dates set the date_pagination_type query argument to yearly, monthly or daily in the pre_get_posts action.

See the plugin documentation for examples and more information on how to use this plugin in your theme.

Note: This plugin intentionally doesn't do pagination for date archives. See this plugin to do just that.

Development

The master branch is where you'll find the most recent, stable release. The develop branch is the current working branch for development. Both branches are required to pass all unit tests. Any pull requests are first merged with the develop branch before being merged into the master branch. See Pull Requests

Installation

Add the plugin to the plugins folder and activate it.

Pull Requests

When starting work on a new feature, branch off from the develop branch.

# clone the repository
git clone https://github.com/keesiemeijer/date-pagination.git

# cd into the date-pagination directory
cd date-pagination

# switch to the develop branch
git checkout develop

# create new branch newfeature and switch to it
git checkout -b newfeature develop

Creating a new build

To compile the plugin without all the development files (as in the WP repository) use the following commands:

# Go to the master branch
git checkout master

# Install Grunt tasks
npm install

# Build the production plugin
grunt build

The plugin will be compiled in the build directory.

Bugs

If you find an issue, let us know here!

Support

This is a developer's portal for Date Pagination and should not be used for support. Please visit the support forums.

Contributions

There are various ways you can contribute:

  1. Raise an Issue on GitHub
  2. Send us a Pull Request with your bug fixes and/or new features
  3. Provide feedback and suggestions on enhancements