Support » Plugins and Hacks » Promotion Slider » Promotion Slider Plugin Custom Template

  • Resolved InHouse

    (@inhouse)


    Hi, I’m wondering if it’s possible to use a custom template to customize what content is used in the slider. I’d like to insert a custom field in the slider. It looks like the plugin index.php file controls the content so I’m not sure the plugin even supports custom templates. Thanks in advance.

    http://wordpress.org/plugins/promotion-slider/

Viewing 2 replies - 1 through 2 (of 2 total)
  • I found the my_slider_content function but am not sure how to display a custom field. i thought echoing the field would work but it’s not drawing in the field. Does this need to use get_meta or get_meta_custom or something like that? My field name is “_author”. Thanks again.

    function my_slider_content($values){
    extract($values);
    add_action('promoslider_content', 'promoslider_display_title', 9);
    add_action('promoslider_content', 'promoslider_extra_content');
    }
    add_action('promoslider_content', 'my_slider_content');
    function promoslider_extra_content(){
    echo mcm_custom_field('_author');
    }
    Plugin Author Micah Wood

    (@woodent)


    @inhouse,

    If you are using post meta for storage, which would be the case when using WordPress’s built-in custom field functionality, then you would retrieve your data like this:

    function promoslider_extra_content() {
        global $post;
        echo get_post_meta( $post->ID,  '_author', true );
    }
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Promotion Slider Plugin Custom Template’ is closed to new replies.