• I’ve got an if/else condition on my theme’s header:

    <div id="custom-header">
                    <?php
                    if ( has_post_thumbnail()) {
                        the_post_thumbnail();
                        // This is the standard WP hook for the Featured Image
    				} else {
                        wpf_custom_header();
                        // This is the default header image set in the theme options.
                    }
                    ?>

    I want to use the Taxonomy Images plugin as another condition, so that if the page is a category, and that category has an image thumbnail associated, it will show that image, or else it will show the post image.

    What would the php function be to call the associated Taxonomy Image in the conditional statement?

    Thanks
    Len

    http://wordpress.org/extend/plugins/taxonomy-images/

Viewing 1 replies (of 1 total)
  • Len, did you solve this?

    I’ve got the same problem now. I want to apply a conditional that basically says:

    IF this outputs an image,
    <?php print apply_filters( 'taxonomy-images-queried-term-image', '', array('image_size' => 'topbanner') ); ?>
    
    THEN
    <?php print apply_filters( 'taxonomy-images-queried-term-image', '', array('image_size' => 'topbanner') ); ?>
    
    ELSE
    Show something else.

    How would we make such a check in the IF clause?

    Excuse my ignorance.

    Thanks
    Trevor

Viewing 1 replies (of 1 total)
  • The topic ‘[Plugin: Taxonomy Images] Using in Header with conditional If-else php’ is closed to new replies.