Support » Plugin: A-Z Listing » Perfect!

  • This is exactly what I was looking for! Thank you.

    On the other hand, if the featured image were displayed I’ll give you the 6th star 😉

    Regards.

Viewing 1 replies (of 1 total)
  • Plugin Author Daniel Llewellyn

    (@diddledan)

    Thankyou for your glowing review 🙂

    Featured images, you say…? I need to add-in an optional toggle switch somewhere that allows for this in an easier way, but until then the output is all customisable via the template mechanism the same way that you can customise your other pages.

    There is a file in the installed plugin folder called templates/a-z-listing.php which you can copy into your theme or child theme and customise as you desire 🙂 it needs to be in the top-level of your theme, not a subdirectory. If you are familiar with WordPress’ “The Loop” mechanism then it should be easily understandable. Otherwise the bit you want to change is around line 30. That line currently outputs a single <li> tag for each item with the item’s title. You probably want to amend it to something like below:

    <li>
        <a href="<?php $a_z_query->the_permalink(); ?>">
            <?php if ( has_post_thumbnail() ) : ?>
                <!-- add any code around this next line to customise -->
                <?php the_post_thumbnail( 'post-thumbnail' ); ?>
                <!-- the line above outputs the thumbnail at "post-thumbnail" size -->
            <?php endif; ?>
            <?php $a_z_query->the_title(); ?>
        </a>
    </li>

    References:

Viewing 1 replies (of 1 total)
  • The topic ‘Perfect!’ is closed to new replies.