Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author LDD Web Design

    (@lddwebdesign)

    Yes, sorry about this. We will be pushing out an update to address this issue and more here shortly.

    Untill we push out the next update that resolves this issue you can edit the file located here: \ldd-directory-lite\includes\template-functions.php

    On line 408 edit the ldl_get_address() function so that it is:

    function ldl_get_address() {
    
        $post_id = get_the_ID();
    
        if (!is_int($post_id))
            return false;
    
        $address_one = get_post_meta($post_id, ldl_pfx('address_one'), true);
        $address_two = get_post_meta($post_id, ldl_pfx('address_two'), true);
        $postal_code = get_post_meta($post_id, ldl_pfx('postal_code'), true);
        $country 	 = get_post_meta($post_id, ldl_pfx('country'), true);
        	$city 		= get_post_meta($post_id, ldl_pfx('city'), true);
       	 $state 	 	= get_post_meta($post_id, ldl_pfx('state'), true);
    
        $output = '';
        $output .= empty($address_one) ? '' : $address_one;
        $output .= empty($address_two) ? '' : ', ' . $address_two;
        $output .= empty($postal_code) ? '' : ', ' . $postal_code;
    	$output .= empty($city) ? '' : ', ' . $city;
    	$output .= empty($state) ? '' : ', ' . $state;
        $output .= empty($country) ? '' : ', ' . $country;
    
        $output = apply_filters('lddlite_presentation_get_address', $output, $post_id, compact('address_one', 'address_two', 'postal_code', 'country'));
    
        return $output ? $output : false;
    }
    Plugin Author LDD Web Design

    (@lddwebdesign)

    Please let us know if this fix has resolved your issue. The new update with this fix should be coming soon.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘City is missing’ is closed to new replies.