Home Forums General Issues Loop issue with checkbox Reply To: Loop issue with checkbox

  • That way of putting it in the query from the start is the first thing i tried to tackle this problem when it arose.

    $args = array (
        'post_type' => 'nieuws',
        'posts_per_page' => -1,
        'orderby' => 'date',
        'order' => 'DESC',
        'meta_key' => 'featured',
        'meta_compare' => '=',
        'meta_value' => 'featured'    

    I tried changing the meta_value to 1 like in your example, I tried to change the values for the checkbox itself in the admin panel, but some how it just doesn’t want to show any post, even if i set the posts_per_page to -1 just for testing purposes. And this got me looking to other solutions like in my first post. I know there is something wrong with the meta_value bit of the query, I tested if the meta_key on its own works and it does. The solution may well be in a small corner, but I just can’t figure it out hehe…