Dani Llewellyn
Forum Replies Created
-
Forum: Plugins
In reply to: [A-Z Listing] Alphabetical sorting of categoriesYou have two options.
First, you could use the
a_z_listing_item_index_letterfilter provided by the plugin to customise the letter for each item. Your function should access$item->post_titleor$item->term_namedepending on whether it is aWP_PostorWP_Termobject. The function should return an array of index letters in lower-case for the item. If you return more than one index letter then the item will be listed multiple times allowing you to create aliases.The second way is to use the pre-packaged proper nouns extension that I sell in an attempt to help cover the costs of developing the main plugin. The documentation for the extension is available (the docs are broken at time of writing, but a fix is being deployed as I type) at https://a-z-listing.com/proper-nouns-extension-for-a-z-listing/a-z-listing-proper-nouns-usage-instructions/
Forum: Plugins
In reply to: [A-Z Listing] Problem with link a-z listing by attributes woocommerceHi,
I’m not sure what’s going on there. You might find that flushing your rewrite rules will fix it. To do that, navigate to wp-admin -> settings -> permalinks and click the “save changes” button without changing anything on the page.
I’m hoping that flushing the rewrite rules will fix it, because other than permalinks being confused I can’t think what would be causing the issue.
Hi,
To show posts (from the post-type called “posts”) you need to add
post-type="post"because it defaults to pages.The plugin doesn’t directly support showing one letter per page, but you can use the “tabify” javascript to do this client-side (in the browser) where the whole listing is loaded and hides all-but-one letter. You can load the javascript with the following line inserted into your theme’s
functions.phpfile:add_filter( 'a_z_listing_tabify', '__return_true' );Forum: Plugins
In reply to: [A-Z Listing] Plugin updated and now custom template not workingIt depends which version you updated from, but versions after 2.0.0 do not load the whole post into the server’s RAM when building the listing. You need to load the post object into memory to be able to use
the_contentorthe_excerptbecause this is not included in the data that the plugin normally loads. You can force the loading of post objects into memory by adding the following line to your template after$a_z_query->the_item();, which in the current template is on line 54:$a_z_query->get_the_item_object( 'I understand the issues!' );Note the text passed as the parameter
I understand the issues!must read exactly that to tell the plugin that you understand that doing this may result in the page loading slowly or failing to load at all if you have a large number of posts to show. This problem is because it takes a lot of database queries to load all the posts and also memory will be incrementally allocated as each post is loaded without being freed until the request is complete or fails.Forum: Plugins
In reply to: [A-Z Listing] Show only letters in a top header widgetSorry, The plugin does not currently support separate pages per letter. It’s all letters or nothing for now 🙁
Forum: Plugins
In reply to: [A-Z Listing] Show only letters in a top header widgetHi,
1) You can show the letters alone by either using the widget (which is a bit neglected and doesn’t support the full spectrum of configuration) or using the shortcode with the super secret option added that reads
return="letters"(this is actually what the widget uses underneath).2) From the screenshot it looks like you’ve added the shortcode into a “preformatted text” area in the post or a page builder. The shortcode needs to be in either a special “shortcode” block via a page builder or in normal post content with no styling applied (i.e. not wrapped in
<pre>and</pre>).Forum: Plugins
In reply to: [A-Z Listing] Show posts from non-english category nameI’ll make sure to update the description in the next release to correctly include
post-type="post"so that it is clearer. I’m sorry I forgot to include it, causing you issues…Forum: Plugins
In reply to: [A-Z Listing] Can the description be shown in lightbox or accordion?Anything is possible 🙂 The plugin doesn’t include this functionality so you’ll need to write some javascript and possibly override the template used to output the listing.
The template is at
wp-content/plugins/a-z-listing/templates/a-z-listing.php. To override the template, copy it into your theme so that it is atwp-content/themes/your-theme/a-z-listing.php, and edit to suit.Forum: Plugins
In reply to: [A-Z Listing] Show posts from non-english category nameCan you share the error that you receive when you attempt to set the term slug? It would also be helpful to see the exact short-code you’re entering into the post. The term slug should be sufficient when entered into the example short-code you put in your question above in the
terms=""bit.One thing to note is that you stated
display="posts"but haven’t specified a post-type so the listing will default to showing pages which in an unmodified WordPress does not have the category taxonomy applied. If this is not what you intended then you can addpost-type="post"or similar for other post-types to get the correct post-type in the listing. For example:[a-z-listing display="posts" post-type="post" taxonomy="category" terms="your-term-slug"]Forum: Plugins
In reply to: [A-Z Listing] How to display portfolio projectsAre you using the portfolio post-type from the Jetpack plugin?
If you are then the post-type is named
jetpack-portfolio, notportfolio.Otherwise you need to navigate to your WordPress admin page and then on the left hand menu click the Portfolio item to get a list of all your portfolio posts. Once you’ve found the list of all your portfolio items you should see in the address bar an address similar to:
https://example.com/wp-admin/edit.php?post_type=portfolio-posttypeThe post type for use in the short-code should be after
post_type=, up to either the end of the address or any&characters (which are used to separate key and value pairs from each other, where the key is before the=and the value is after)Forum: Plugins
In reply to: [A-Z Listing] Theming with multiple custom post-typesHi,
The section name is the top-most page in a page hierarchy. It will only work when the short-code is on a page rather than a post or any other post-type. An alternative that is available is to name the template after the slug of the page/post that holds the short-code. For your specific example, try:
a-z-listing-personer.phpThis is using the slug (
personer) of the post/page located at/mountains/personer.I’ll try to get post-type names added as an alternative template name in the next update.
- This reply was modified 6 years, 7 months ago by Dani Llewellyn.
Forum: Plugins
In reply to: [A-Z Listing] Number of posts per taxonomyYes, this is possible by overriding the template with one that uses
the_item_post_count().The process is:
- Copy the file from
wp-content/plugins/a-z-listing/templates/a-z-listing.phpinto your theme or child theme’s top-level folder, e.g.wp-content/themes/your-theme-name/a-z-listing.php - Edit the new copy and find on line 58 the code:
<?php $a_z_query->the_title(); ?> - Replace that line with:
<?php $a_z_query->the_title(); ?> (<?php $a_z_query->the_item_post_count(); ?>)
Forum: Plugins
In reply to: [A-Z Listing] Update 3.1.0 not working with WP 5.2.2hmm, that’s really freaky. I’m at a loss to explain what the problem might be…
I’m glad it’s working again for you, and fingers are crossed that it doesn’t break again 🙂
Forum: Plugins
In reply to: [A-Z Listing] Problems with display and strange # signHi,
The
#symbol is used to group all items that the plugin could not assign to a specific alphabet character. This usually means that items whose title begins with a symbol or a number are grouped into the#entry. You can separate the numbers into their own section by addingnumbers="before"ornumbers="after"which will place the numbers either before or after the main alphabet letters – the#symbol will then group all items whose titles don’t begin with either an alphabetic character or a number.Your use of
grouping="3"means that the alphabet will be grouped with three letters from the alphabet in each group, i.e.A-C,D-Fetc. When you add thenumbers="after"to a shortcode withgrouping=the numbers will be listed as a single0-9group.Forum: Plugins
In reply to: [A-Z Listing] Only 2 questions and No response in 1.5 Months Very SadHi,
I’m really sorry I missed your messages 🙁 I’ve now posted a reply to two of your threads, which I hope are all of the ones you mention here. Please continue to hold me to account when I fail, and I will endeavour to improve my response time. Again, I’m sorry I failed to help you in a timely manner.