Slider Question

Home Forums Theme Support Slider Question

  • Question status -
  • Ali Öztürk
    Participant

    Hi, i set up 3 image for slider but that 3 image and text appears below the slider as a post. How can i remove post from main page except slider?

    #4852
    Support Staff
    Keymaster

    Hi Ali,

    the easiest way is to change the post date, or you can add this to theme setup function (functions.php):

    function remove_category( $query ) {
    if ( $query->is_home ) {
       $query->set('cat', '-1');
    }
    return $query;
    }
    add_filter('pre_get_posts', 'remove_category');
    #4856

You must be logged in to reply to this topic.

Viewing 2 posts - 1 through 2 (of 2 total)