Feature Pages (not posts) in the Slider?

  • ggci

    #292

    Hi,

    first of all: great theme, but I guess you’ve heard that before.

    Secondly: my feature request: As far as I see, I can only feature posts (either by category or by date) in the slider. However I’d like to feture pages instead. Is there any chance to:

    a) Add Categories to pages

    b) Use “custom field” (hope it’s translated correctly, I’m using the German version) property to select content for the slider.

    c) Some magic you do.

    Best,

    Erik

    Admin

    Syahir Hakim

    #12000

    Hi Erik,

    There’s a plugin that allows you to assign categories to pages, such as this Map Categories to Pages plugin.

    As for the custom field, what are the options of the content to be selected for the slider?

    cb-rcw

    #12001

    Hello boys~

    I’ve installed the plugin mentioned above, assigned a category, and told that category to show up in the slider – but nothing shows up in the slider.

    Any ideas?

    Thanks!

    Admin

    Syahir Hakim

    #12002

    Try adding this code in your child theme’s functions.php file:

    function graphene_custom_slider_post_type(){
    $post_type = array('post', 'page');
    return $post_type;
    }
    add_filter('graphene_slider_post_type', 'graphene_custom_slider_post_type');

    cb-rcw

    #12003

    Alright… where exactly would I put that in the functions.php file?

    Admin

    Syahir Hakim

    #12004

    If you’re using a child theme, just put that anywhere in the child theme’s functions.php file. If you’re not using child theme, put it anywhere in the theme’s functions.php file. The positioning doesn’t matter.

    erne0815

    #12005

    Brilliant, works for me. Thanks!

    cb-rcw

    #12006

    I got it to work also, thank you!

    However, for some reason, the image won’t display floating left to the text like it would before. See here (http://www.cleansingfyi.com/uhtsite).

    Any ideas for this? I appreciate your help!

    Regards,

    ~RCW

    Admin

    Syahir Hakim

    #12007

    Your CSS is missing this rule declaration:

    .sliderpost_featured_image {
    float: left;
    margin: 4px 1em 12px 0;
    }

    Just add it back to either your child theme or the theme’s style.css file.

    cb-rcw

    #12008

    Oh – stupid me! Thank you for your reply and help.

    I applied the css code and it fixed it. Much appreciated!

    Thank you,

    ~RCW

Viewing 10 posts - 1 through 10 (of 16 total)

You must be logged in to reply to this topic.