Support » Plugins and Hacks » Media Category Library » [Resolved] [Plugin: Media Category Library] Long code

[Resolved] [Plugin: Media Category Library] Long code

Viewing 9 replies - 1 through 9 (of 9 total)
  • Plugin Author timmcdaniels



    You can add this to your template:

    <?php if ( method_exists( $media_cat_lib, 'get_mediacategory_shortcode' ) ): ?>
    <?php echo $media_cat_lib->get_mediacategory_shortcode( array( 'cats' => "Documents", 'orderby' => "date", 'order' => "DESC" ) ); ?>
    <?php endif; ?>

    That’s great – thanks to much for the quick response.

    I need to be more granular.

    What I really want is to output a bulleted list of titles with the link behind it.

    Is this possible w/ your plugin?

    Plugin Author timmcdaniels


    I will be releasing version 0.8 which will allow you to do the following:

    <?php if ( method_exists( $media_cat_lib, 'get_mediacategory_shortcode' ) ): ?>
    <?php $posts = $media_cat_lib->get_mediacategory_shortcode( array( 'returnposts' => 1, 'cats' => "PDF", 'orderby' => "date", 'order' => "DESC" ) ); ?>
    <?php foreach ( $posts as $rpost ): ?>
            <li><a target="_BLANK" href="<?php echo wp_get_attachment_url( $rpost->ID ); ?>"><?php echo get_the_title( $rpost->ID ); ?></a></li>
    <?php endforeach; ?>
    <?php endif; ?>

    Does that help with what you are trying to do?

    Yes – it’s exactly what I’d like to do.

    When do expect to release it?

    Thanks so much!

    Plugin Author timmcdaniels


    It was already released this morning.

    It’s up and running and perfect. Thanks you, thank you, thank you!

    Plugin Author timmcdaniels


    You are welcome! Thanks for using the plugin.

    In your next round it would be fantastic to give the user an “order” field so they could choose the sort order.

    Really loving this! Thanks so much!

    How do I display the category and subcategory and not repeat the files? If I can only display subcategories is enough. Tank you!

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘[Resolved] [Plugin: Media Category Library] Long code’ is closed to new replies.
Skip to toolbar