• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer
WPArena

WPArena

WPArena is a premium online resource site of WordPress and is focused on providing excellent WordPress Tutorials, Guides, Tips, and Collections.

  • News
    • Opinion
  • Tutorials
  • Reviews
    • Themes
    • Plugins
  • Comparisons
  • Collections
    • Education Themes
    • Genesis Child Themes
    • Best Responsive Themes
    • Medical WordPress Themes
    • Finance & Business Themes
    • Crowdfunding Themes
  • Resources
    • Inspiration
  • Services
WPArena » Tutorials
Tutorials

How to Customize WordPress Post Order?

Avatar of Noor Mustafa Raza Noor Mustafa Raza Updated: June 29, 2023

FacebookTweetPinLinkedInEmailPrint

WordPress is the most popular blogging platform for bloggers. This post will show you how to change the order of posts and pages in WordPress themes. Here are a few ways you can customize the sorting order of your posts in WordPress.

Customize WordPress Post Order Manually

Open your theme and enter the following code to customize the post order manually:

// display posts organized by title in ascending order

This code will display a specified number of posts, in ascending order according to the post title. This code can be customized in many ways to suit your needs.

Another useful trick is to customize the order of categories, such as in an archive directory or service directory. Replace the first line in the loop example above with the following:

<?php if (is_category()) { $posts = query_posts( $query_string . '&orderby=title&order=asc' ); } ?>

You can also add another endif to the loop as follows:

<?php endif; ?>
<?php endif; ?>

You can also replace is_category() with the is_whatever() statements of your choice.

  • is_home()
  • is_single()
  • is_author()
  • is_search()
  • is_archive()

For more information, visit the WordPress Codex.

Plugins to customize post order automatically

We’ll look at some simpler custom sorting methods using WordPress plugins.

1. Custom Query string Reloaded for WordPress

Custom Query Reloaded is a popular WordPress plugin. CQS (Custom Query String) offers an Admin Options Panel where users can specify as many custom post queries as they wish. CQS allows for custom sorting.

2. Smart Sort WordPress Plugin: Sort posts by Custom Field

This plugin lets you place a sorting bar with the option to sort posts based on any custom field. The sort bar can be placed above or below the list of posts within a category, archive or anywhere else in your template.

3. aStickyPostOrderER – Plugin to Change the WordPress Post Order

This plugin can help you reorder the posts that WordPress displays.
aStickyPostOrderER allows you to customize the order in which posts appear on a WordPress blog, based on categories or tags. This is useful for WordPress to be used as a Content Management System. ).

4. WP-Snap! WordPress Plugin

WP-SNAP! WordPress Plugin that creates alphabetical listing ABCDEF etc. Links on a template file. Clicking “A”, “D”, and “Z” will display all post titles beginning with the letter you selected.

5. Sort category posts by title

This plugin appears to be a simple and quick way to sort category posts alphabetically in ascending order based on the post title. The plugin’s home page states that “WordPress sort category posts by title” was created for WordPress 2.0.2. It only changes the order of the posts in category view. This will not affect the ordering of the posts on other pages (e.g. the homepage) of the site. This plugin’s code is clean and simple. It just begs to be explored and adapted.

This post was orginally published on: December 14, 2010 and was updated on: June 29, 2023.
FacebookTweetPinLinkedInEmailPrint

Related Stories

  • How To Fix The Email Deliverability Issue In WordPress?

    How To Fix The Email Deliverability Issue In WordPress?

  • Make your own social blog network By using WordPress Multisite Network

  • How To Setup Flash Slideshow On WordPress Theme Header

    How To Setup Flash Slideshow On WordPress Theme Header

Avatar of Noor Mustafa Raza

Noor Mustafa Raza

Ex-Editor in chief

I am a WordPress Developer and Designer, author @WPArena. I am providing Free WordPress consultation and can help you to install WordPress in a secure way to small businesses and bloggers.

Reader Interactions

Share Your Thoughts Cancel reply

Before submitting your comment, we kindly ask that you read our comment policy. Your email address will remain confidential and will not be published or shared anywhere. If you subscribe, you will receive notifications regarding new comments.

Primary Sidebar

How to Troubleshoot Slow loading Site and WordPress blog

A person navigating through sales on his laptop

3 Conversion Optimization Tips To Boost Your eLearning Product’s Sales

Recent Topics

  • 27 Top SEO Companies in the World
  • 12 Ways To Monetize Your WordPress Blog
  • Comparing the Best Employee Engagement Software in the Market
  • Stellar Converter for OST Review: Best Tool for OST to PST Conversion
  • How To Use WordPress as an eCommerce Store

Footer

Top

  • Services
  • Our Themes
  • Facebook
  • Twitter
  • Linkedin

Reviews

  • Beaver Builder Review
  • Beaver Themer Review
  • WP User Frontend Pro
  • Ninja Forms Review
  • MemberPress Review

More Reviews »

Resources

  • Best WordPress Plugins
  • WordPress Permalinks Structure
  • Email Management System
  • Envato Free Files
  • Advertise
  • Write for us
  • Disclosure
  • Terms
  • Privacy
  • Contact

Copyright © 2023 · All Rights Reserved · WPArena is a Project of TechAbout LLC.
We are not affiliated with Automattic or WordPress.

  • Advertise
  • Write for us
  • Disclosure
  • Terms
  • Privacy
  • Contact
Share this ArticleLike this article? Email it to a friend!

Email sent!