Search Rentals

ID ) ) { $image_url = get_the_post_thumbnail_url( $post->ID, 'full' ); } // 2. Fallback to first inline image else { preg_match_all( '//i', $post->post_content, $matches ); if ( ! empty( $matches[1][0] ) ) { $image_url = $matches[1][0]; } } if ( $image_url ) { return '' . esc_attr( get_the_title() ) . ''; } return ''; } add_shortcode( 'first_post_image', 'get_first_post_image_shortcode' ); ?>