Matt Wangsness

Forum Replies Created

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts

  • Matt Wangsness
    Expired Member
    Post count: 2

    Oops! Forgot, this new WP_Query line is actually part of the code… I’ve added it here for clarification:

    $clinic_loop = new WP_Query ( $clinic_args ); // A loop through the Clinic (Places) posts…


    Matt Wangsness
    Expired Member
    Post count: 2

    Thanks, but “echo $post->post_address;” was the very first code I tried, when first trying to display a Geodirectory Place post’s address. This line of code returns nothing… not null, not an empty string…

    Here is the full code I’m testing:

    // Get the Physical Clinic (Geodirectory Places) Post Type
    $clinic_args = array (
    ‘post_type’ => ‘gd_place’, // These will be Geodirectory Places post types (gd_place).
    ‘orderby’ => ‘menu_order’,
    ‘order’ => ‘DESC’,
    ‘posts_per_page’ => ‘100’
    );

    $clinic_arr = Array ();

    if ($clinic_loop->have_posts ()) : // gd_place post type!

    while ( $clinic_loop->have_posts () ) :
    // looping throug all Geodirectory’s gd_place posts…
    $clinic_loop->the_post ();

    global $post;

    echo get_the_title (); // Works!
    echo ‘<br />’;
    echo the_content (); // Works!
    echo $post->post_address; // Does NOT work… This is the line that needs a solution.
    endwhile;

    endif;

    Do you have any other suggestions? I’m trying to display the STRING of characters that are entered into a Geodirectory Place post field named “Address” and “Zip/Postal Code”. I haven’t found any property or funcition yet that will output just the Address and the zip code strings…

    Any ideas? Thanks.

Viewing 2 posts - 1 through 2 (of 2 total)
20% Discount Offer
Hurry! Get your 20% discount before it expires. Get 20% Discount