Support Forum ยป User Profile

Forum Replies Created

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • in reply to: โœ…rwmb_meta function not working #33201
    Travis SlonekerTravis Sloneker
    Participant

    I was able to figure out a solution using get_post_meta. You can mark this as solved.

    in reply to: โœ…rwmb_meta function not working #33200
    Travis SlonekerTravis Sloneker
    Participant

    I think I know the issue but still would love some advice if you can help.

    <?php
    // WP_Query arguments
    $args = array(
    'post_type' => array( 'listing' ),
    'posts_per_page' => 9,
    'order' => 'RAND'
    );

    // The Query
    $query_listing = new WP_Query( $args );

    // The Loop
    if ( $query_listing->have_posts() && $listing_status != "Sold" ) { ...

    Above is a snippet of code. I basically want to check the listing_status field to decide if a post should be shown or not but I believe what the issue is, is that I am not trying to get the values within the while loop. I am attempting to do it outside of it which probably explains why I am getting no value.

    I'm not sure if you can get the value within the arguments.

    in reply to: โœ…Shortcode for SELECT fields not working #32467
    Travis SlonekerTravis Sloneker
    Participant

    Disregard; I figured out my mistake.

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