Changeset 3180026
- Timestamp:
- 11/01/2024 02:33:55 PM (17 months ago)
- File:
-
- 1 edited
-
ac-custom-loop-shortcode/tags/1.5.1/readme.txt (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
ac-custom-loop-shortcode/tags/1.5.1/readme.txt
r3179993 r3180026 10 10 License URI: https://www.gnu.org/licenses/gpl-2.0.html 11 11 12 Shortcode to display posts in content areas.12 A simple WordPress plugin that creates a shortcode to loop through posts, pages, or custom post types and display them anywhere on your site. 13 13 14 14 == Description == 15 15 16 A simple Wordpress plugin that creates Wordpress shortcode that will loop through posts, pages, or custom post types and display them on your website or blog. A typical use would be to show your latest post on your homepage.16 Easily display posts, pages, or custom post types in content areas using a customizable shortcode. Display your latest posts, group by taxonomies, or use custom templates with Timber for Twig support. 17 17 18 18 == Installation == 19 19 20 Use WordPress' Add New Plugin feature, searching "AC custom loop", or download the archive and: 20 1. Install via WordPress Add New Plugin feature by searching "AC Custom Loop," or upload the plugin files to `/wp-content/plugins/ac-wp-custom-loop`. 21 2. Activate the plugin via the ‘Plugins’ screen in WordPress. 22 3. Use `[ac_custom_loop]` shortcode in any page, post, or widget supporting shortcodes. 23 4. The default setup displays your latest 4 posts. Customize with attributes like `type` and `show`, e.g., `[ac_custom_loop type="page" show="3"]` to display the latest three pages. 21 24 22 1. Upload the plugin files to the `/wp-content/plugins/ac-wp-custom-loop` directory, or install the plugin through the WordPress plugins screen directly. 23 2. Activate the plugin through the 'Plugins' screen in WordPress 24 3. Add the shortcode [ac_custom_loop] to the content area of any page, post or custom post type or to any widget that supports shortcode. 25 4. By default the shortcode will display your latest 4 post, you can use the 'type' and 'show' arguments to customise the type of post that are shown and how many eg. [ac_custom_loop type="page" show="3"] would show the last three published pages. 25 == Shortcode Options and Examples == 26 26 27 **Display a specific post type:** 28 `[ac_custom_loop type="foo"]` 29 This displays posts from the `foo` custom post type. 30 31 **Display posts with specific tags:** 32 `[ac_custom_loop type="post" tax="tag" term="foo"]` 33 This displays posts tagged with `foo`. 34 35 **Group posts by taxonomy (e.g., categories and tags):** 36 `[ac_custom_loop type="post" subtax="category,tag"]` 37 Groups posts by categories, then by tags within each category. 38 39 **Exclude posts by specific tags:** 40 `[ac_custom_loop type="post" tax="tag" term="foo,bar" exclude="baz"]` 41 This displays posts tagged with `foo` and `bar`, but excludes those tagged with `baz`. 42 43 **Use a custom template for loop display:** 44 To use a custom template, copy `loop-template.php` from the plugin folder to the root of your theme folder and modify as desired. You can also create templates for specific post types (e.g., `loop-template-post.php`). 27 45 28 46 == Frequently Asked Questions == 29 47 30 = How do I display a certain post type using the short code 48 = How do I show posts from a specific post type? = 49 Use `[ac_custom_loop type="your_post_type"]` to show posts from a specific custom post type. 31 50 32 [ac_custom_loop type="foo"] 33 this displays foo custom post types 51 = Can I display posts with a specific taxonomy term? = 52 Yes! Use `[ac_custom_loop type="post" tax="tag" term="your_term"]` to filter posts by taxonomy term. 34 53 35 = How do I display a post that have a certain tag = 54 = How can I group posts by taxonomies? = 55 Use `[ac_custom_loop subtax="category,tag"]` to group posts by taxonomies. 36 56 37 [ac_custom_loop type="post" tax="tag" term="foo" ] 38 this displays posts that have been tagged foo 57 = Can I exclude specific terms? = 58 Yes, add `exclude="term"` to exclude posts tagged with that term. 39 59 40 = How do I group post in to tags = 41 42 [ac_custom_loop type="post" subtax="category,tag"] 43 this displays posts grouped into category and sub-grouped in to tags 44 45 Cat Foo 46 Tag bar 47 post1, post2 48 tag baz 49 post3, post4 50 Cat Foo2 51 Tag bar2 52 post5, post6 53 54 = Can I use my own template to display the looped posts? = 55 56 Yes you can! Simply copy loop-template.php from the plugin folder to the root of your theme folder and edit as needed. 57 You can also create a template for each post type such as loop-template-post.php or loop-template-page.php or loop-template-my-custom-post.php 60 = Can I use custom templates? = 61 Absolutely! Copy `loop-template.php` to your theme directory or create post-type-specific templates, such as `loop-template-post.php`. 58 62 59 63 == Screenshots == 60 64 61 1. Add the code to any content area that accepts shortcode.62 2. Posts, Pages or Custom post types are shown on the front end of your website.65 1. Adding the shortcode to any content area that supports shortcodes. 66 2. Posts, pages, or custom post types appear styled in your chosen layout on the front end. 63 67 64 68 == Upgrade Notice == 65 69 66 70 = 1.5.1 = 67 Added support for grouping posts by taxonomies.71 Added support for grouping posts by multiple taxonomies and refactored core code for flexibility and clarity. 68 72 69 73 = 1.5 = 70 Updated Timber support.74 Improved Timber support. 71 75 72 76 = 1.4.3 = 73 Fix release issues. 74 75 = 1.4.2 = 76 Fix template arguments to allow .php to be optional. 77 78 = 1.4.0 = 79 Updates to templates plus timber support and show posts using ids. 80 81 = 1.1.0 = 82 Updates to default template and post order. 83 84 = 0.1.1 = 85 Added user template function 86 87 = 0.0.1 = 88 Initial version 77 Fixed release issues. 89 78 90 79 == Changelog == 91 80 92 81 = 1.5.1 (2024-11-01) = 93 * Added support for grouping posts by taxonomies.94 * Refactored all the code82 * Added support for grouping posts by multiple taxonomies. 83 * Refactored core code for improved maintainability. 95 84 96 85 = 1.5 (2021-04-04) = 97 * Fix release issues.86 * Enhanced Timber compatibility. 98 87 99 88 = 1.4.3 (2019-12-06) = 100 * Fixrelease issues.89 * Resolved release issues. 101 90 102 91 = 1.4.2 (2019-12-24) = 103 * Fix shortcode argument issues. 104 105 = 1.4.1 (2019-12-06) = 106 * Fix release issues. 92 * Fixed shortcode argument issues. 107 93 108 94 = 1.4.0 (2019-12-05) = 109 * Added ids param to shortcode. 110 * Added post type templates. 111 * Added Timber template integration 95 * Added support for specific post type templates and custom Timber integration. 112 96 113 97 = 1.1.0 (2018-10-16) = 114 * Added optional excerpt to the default template. 115 * Added default post order (post = date, everything else = menu_order). 116 117 = 0.1.1 (2018-10-13) = 118 * Added function to override template with the users own template 119 * Added GPLv2 licence 120 * Fixed some typos 98 * Added default post order and optional excerpt in the default template. 121 99 122 100 = 0.1.0 (2018-10-07) = 123 * Initial version on WP repository101 * Initial release.
Note: See TracChangeset
for help on using the changeset viewer.