Your address will show here +12 34 56 78

Home Forums WP ESTATE – Real Estate WordPress Theme FORUM Property Template customizing Reply To: Property Template customizing

#101197

Roxana
Keymaster

Hi Massive Ant

Front end page is single-estate_property.php

If I want to remove or move “Property Features” section…
What chunk of code would I comment out or move?

–> look for Property Features and delete all code related. Use this as example for your next question please.

$property_features_text = icl_translate('wpestate','wp_estate_property_features_text', esc_html( get_option('wp_estate_property_features_text') ) );

$property_features_text = esc_html( get_option('wp_estate_property_features_text') );

       <?php 
                        // features and ammenties
                        $counter            =   0;                          
                        $feature_list_array =   array();
                        $feature_list       =   esc_html( get_option('wp_estate_feature_list') );
                        $feature_list_array =   explode( ',',$feature_list);
                        $total_features     =   round( count( $feature_list_array )/2 );
                       
                        if ( !count( $feature_list_array )==0 ){ //  if are features and ammenties
                        ?>
                        <h4 id="prop_ame">
                        <?php 
                        if($property_features_text ==''){
                            _e('Amenities and Features', 'wpestate'); 
                        }else{
                            print $property_features_text ;
                        }
                        ?>
                        </h4>
                    
                            <?php 
                            $show_no_features= esc_html ( get_option('wp_estate_show_no_features','') );
                            if($show_no_features!='no'){
                                 print'    <div class="prop_details"><ul>';
                                 foreach($feature_list_array as $checker => $value){
                                      
                                        if (function_exists('icl_translate') ){
                                            $value     =   icl_translate('wpestate','wp_estate_property_custom_amm_'.$value, $value ) ;                                      
                                        }
                                
                                
                                        $counter++;
                                        if ($counter == ($total_features+1) ) {
                                            print'</ul></div><div class="prop_details"><ul>';
                                        }
                                        $post_var_name=  str_replace(' ','_', trim($value) );

                                        if (esc_html( get_post_meta($post->ID, $post_var_name, true) ) == 1) {
                                            print '<li><img src="' . get_template_directory_uri() . '/images/yes_prop.png" alt="yes"/>' . trim($value) . '</li>';
                                        }else{
                                            print '<li><img src="' . get_template_directory_uri() . '/images/no_prop.png" alt="no"/>' . trim($value). '</li>';
                                        }
                                  }
                                 print'</ul>     </div>';
                            }else{
                                 foreach($feature_list_array as $checker => $value){
                                    $post_var_name=  str_replace(' ','_', trim($value) );
                                     
                                    if (function_exists('icl_translate') ){
                                        $value     =   icl_translate('wpestate','wp_estate_property_custom_amm_'.$value, $value ) ;                                      
                                    }
                                
                                        
                                    if (esc_html( get_post_meta($post->ID, $post_var_name, true) ) == 1) {
                                        print '<div class="features_listing_div"><img src="' . get_template_directory_uri() . '/images/yes_prop.png" alt="yes"/>' . trim($value) . '</div>';
                                    }
                                }
                           }
                        ?>
                        
                        
                        <?php 
                        } // end if are features and ammenties
                        ?>
                        

Make backup before in case it doesn’t work. These codes need to be tested.

If I want to remove or move “Agent Notes” section…
What chunk of code would I comment out or move?

` < ?php $message = esc_html( get_post_meta($post->ID, ‘property_sale_pitch’, true) );
if ($message != ”) {
print ‘

‘;
_e(‘Agent Notes’, ‘wpestate’);
print ‘

‘ . $message.’

‘;
}
?>
`
Thank You