WordPress.org

Ready to get started?Download WordPress

Forums

Query Shortcode
Powerful indeed, with even bigger potential (1 post)

5 stars
  1. Eliot Akira
    Member
    Posted 10 months ago #

    This plugin gives you the power to do query loops with shortcodes. The built-in functions should be plenty for most people to display posts and pages just how they want.

    For an even more extensive control, I am using this plugin with the following combination: Custom Post Type UI, Advanced Custom Fields, and an additional shortcode called "custom" to display custom fields from any post of any type.

    I changed how the output of this plugin is returned, so it's possible to have shortcodes within the query loop - that really opens up possibilities. I also added a couple of additional keywords to this plugin: {ID}, {IMAGE}, {IMAGEURL}, {TAGS}.

    With all that together, it's possible to do query loops like this:

    [query post_type="apartment"]
    {TITLE}<br/>
    {THUMBNAIL}<br/>
    Description: [custom id="{ID}" field="description"]<br/>
    Monthly Rent: [custom id="{ID}" field="rent"]<br/>
    Availability: [custom id="{ID}" field="availability"]<br/>
    [/query]

    As you can see, the "custom" shortcode pulls out the custom fields from the posts during the loop.

    This allows me to have view templates for all kinds of content. The reason why I'm raving about this plugin is that it helps me to show content any way I want, without having to go into PHP. A step towards a more powerful and flexible CMS!

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.