Forum Replies Created

Viewing 15 replies - 556 through 570 (of 927 total)
  • Plugin Author Dani Llewellyn

    (@diddledani)

    oh, damn, I missed a step in releasing the new version (the missing 2.0.6). There’s two places that need the version number changed for every release and I missed one of them so WordPress.org didn’t know that the new version was ok to make available..

    *facepalm*

    Thanks for alerting me, it’s updated now 🙂

    Plugin Author Dani Llewellyn

    (@diddledani)

    You need to be sure that the term and taxonomy values are correct.

    Go to the admin screen and select the taxonomy containing the term you want to display in the A-Z Listing (e.g. the taxonomy containing the term a-partir-de-02-ans). Check the address bar of your browser, and note the taxonomy name:

    https://example.com/wp-admin/edit-tags.php?taxonomy=category
    

    In the above address the taxonomy is called category and that needs to be inserted into the taxonomy="" bit of the short-code. If your address does not include /edit-tags.php?taxonomy= at all then you’re not viewing a taxonomy. (This plugin can only filter posts by taxonomy terms or by excluding specific post IDs.)

    Now click on the term you want to display in the A-Z Listing and copy the contents of the slug field. This needs to go into the terms="" part of the short-code.

    This should work with any term, multiple terms separated by commas (,), and any taxonomy.

    Plugin Author Dani Llewellyn

    (@diddledani)

    What is the behaviour of the failure?

    e.g. Does the page show an error? Is the page completely loaded, or is the html cut-off? Is the listing complete, just missing the thumbnails? Do any thumbnails load or are they all missing?

    Could you try some debugging steps such as inserting an else clause on the has_thumbnail() check – the example below will print the post ID to make sure that the $post object is loaded properly:

    if ( has_thumbnail( $post->ID ) ) :
        ...
    else :
        echo "<br />The thumbnail cannot be found. The post ID is '{$post->ID}'.<br />";
    endif;
    Plugin Author Dani Llewellyn

    (@diddledani)

    The latest update, 2.0.6 should fix this for you. You will need to re-save your widget configuration to be sure that it has saved to the correct place. Probably best to delete the target page name on the widget admin, save the widget, add the target page back again and then save a final time to be sure.

    Plugin Author Dani Llewellyn

    (@diddledani)

    Thumbnails are not a default output for this plugin. You need to customise the template and acknowledge that slowness might result.

    To do so, find the file at wp-content/plugins/a-z-listing/templates/a-z-listing.php and copy it into your theme. This is the template that will drive your listing. You need to edit the template to include an appropriate the_post_thumbnail() call.

    That will not work by itself, however, as the post object is not loaded into memory in an effort to improve performance. In addition to adding a call to the_post_thumbnail(), you also need to add a call to $a_z_listing->get_the_item_object() directly after the line that calls $a_z_listing->the_item(). This call must pass as the first parameter a value of I understand the issues! to confirm that you understand that on a large site this might slow down the page load or cause memory limit issues.

    • This reply was modified 7 years, 8 months ago by Dani Llewellyn. Reason: fix link
    Plugin Author Dani Llewellyn

    (@diddledani)

    Looks like I’ve made a mistake. Thanks for spotting it 🙂

    I used an incorrect name – There will be a new release shortly to fix it.

    Plugin Author Dani Llewellyn

    (@diddledani)

    You will need to copy the template from wp-content/plugins/a-z-listing/templates/a-z-listing.php into your theme and modify it to support the subtitles plugin.

    The modification required is on line 45. Replace that line with the following:

    $a_z_query->the_item(); // this was here already
    $a_z_query->get_the_item_object( 'I understand the issues!' ); // this is new

    Please note that on large listings this will slow your site down, and might cause it to hit the memory limits imposed by your server. The parameter supplied to get_the_item_object() must read exactly I understand the issues! to confirm that you understand this point. If your listing is smallish then this won’t be a problem.

    Plugin Author Dani Llewellyn

    (@diddledani)

    The fixed max-width is to force a minimum number of posts in each column before breaking to the next column. With a column-width set so that three columns can be fitted into the available space then when you have three posts each column will only have one post. With the fixed max-width we get roughly 10 posts in each column before breaking to the next column, should another column exist.

    This method also ensures that columns are all the same width, no matter how many are in the space.

    Plugin Author Dani Llewellyn

    (@diddledani)

    Yes, exactly like that.

    Plugin Author Dani Llewellyn

    (@diddledani)

    I think I’ve fixed it in 2.0.5 🙂

    Plugin Author Dani Llewellyn

    (@diddledani)

    This should be fixed in 2.0.5.

    Plugin Author Dani Llewellyn

    (@diddledani)

    This should now be fixed 🙂

    Plugin Author Dani Llewellyn

    (@diddledani)

    You’ve hit a problem that someone else just reported, too. It looks like there’s a bug, but I’m not sure what’s causing it – I’m investigating right now 🙂

    Plugin Author Dani Llewellyn

    (@diddledani)

    You’ve hit a problem that someone else just reported, too. It looks like there’s a bug, but I’m not sure what’s causing it – I’m investigating right now 🙂

    Plugin Author Dani Llewellyn

    (@diddledani)

    You’ll need to add a custom function to your theme’s functions.php file. Something like this should work:

    add_filter( 'a_z_listing_item_indices', 'custom_index_by_slug', 10, 3 );
    function custom_index_by_slug( $indices, $item, $type ) {
        $slug = $item->post_name;
        $index = mb_substr( $slug, 0, 1, 'UTF-8' );
        return array( $index => array( array(
            'title' => get_the_title( $item ),
            'item' => "post:{$item->ID}",
            'link' => get_the_permalink( $item ),
        ) ) );
    }
    • This reply was modified 7 years, 8 months ago by Dani Llewellyn. Reason: fix add_filter() to pass all the parameters
Viewing 15 replies - 556 through 570 (of 927 total)