Getting started
Manual data entry
Menu
Getting started
Manual data entry
Templating Single-properties.php

Single-properties.php

Last updated: December 12, 2025

Rent Fetch provides a flexible templating system for single property pages that allows extensive customization while maintaining default functionality.

Template Hierarchy

Rent Fetch follows WordPress template hierarchy with custom overrides:

  1. Theme Override: single-properties.php in your theme root
  2. Plugin Default: single-properties.php

The plugin automatically detects and loads the appropriate template.

Main Template Structure

The default single properties template is minimal:

<?php
get_header();

echo '<div class="single-properties-wrap">';
    do_action( 'rentfetch_do_single_properties_parts' );
echo '</div>';

get_footer();

Template Parts

The template is composed of modular parts that are added via the rentfetch_do_single_properties_parts action hook. Each part can be customized or removed independently.

Default Parts (in order)

  1. Images (rentfetch_single_properties_parts_images)
    • Displays property image gallery
    • Location: single-properties-section with ID images
    • Admin option: property_images
  2. Subnav (rentfetch_single_properties_parts_subnav)
    • Navigation menu for page sections
    • Location: single-properties-section no-padding with ID subnav
    • Admin option: section_navigation
  3. Details (rentfetch_single_properties_parts_details)
    • Property title, address, and basic information
    • Location: single-properties-section with ID details
    • Admin option: property_details
  4. Floorplans (rentfetch_single_properties_parts_floorplans)
    • Floor plan listings with pricing and availability
    • Location: single-properties-section with ID floorplans
    • Admin option: floorplans_display
  5. Fees Embed (rentfetch_single_properties_parts_fees_embed)
    • Property fees and charges display
    • Location: single-properties-section with ID fees
    • Admin option: fees_embed_display
  6. Amenities (rentfetch_single_properties_parts_amenities)
    • Property amenities list
    • Location: single-properties-section with ID amenities
    • Admin option: amenities_display
  7. More Information (rentfetch_single_properties_parts_more_information)
    • Additional property content from the editor
    • Location: single-properties-section with ID more-information
    • Always enabled (displays only if content exists)
  8. Map (rentfetch_single_properties_parts_map)
    • Google Maps display
    • Location: single-properties-section no-padding full-width with ID googlemaps
    • Admin option: property_map
  9. More Properties (rentfetch_single_properties_parts_more_properties)
    • Related properties section
    • Location: single-properties-section with ID more-properties
    • Admin option: nearby_properties

Customization Methods

Method 1: Override Main Template

Create single-properties.php in your theme:

<?php
get_header();

// Custom wrapper with your classes/structure
echo '<div class="my-custom-property-wrapper">';

    // Include only specific parts
    do_action( 'rentfetch_single_properties_parts_images' );
    do_action( 'rentfetch_single_properties_parts_details' );
    
    // Add custom content
    echo '<div class="my-custom-section">';
        // Your custom content here
    echo '</div>';
    
    do_action( 'rentfetch_single_properties_parts_floorplans' );

echo '</div>';

get_footer();

Method 2: Modify Individual Parts

Each part function can be filtered. For example, to modify the details section:

<?php
function my_custom_property_details() {
    // Custom details markup
    echo '<div id="details" class="single-properties-section my-custom-details">';
        // Your custom details content
    echo '</div>';
}
remove_action( 'rentfetch_do_single_properties_parts', 'rentfetch_single_properties_parts_details' );
add_action( 'rentfetch_do_single_properties_parts', 'my_custom_property_details' );

Method 3: Remove/Add Parts

<?php
// Remove unwanted sections
remove_action( 'rentfetch_do_single_properties_parts', 'rentfetch_single_properties_parts_more_properties' );
remove_action( 'rentfetch_do_single_properties_parts', 'rentfetch_single_properties_parts_fees_embed' );

// Add custom sections
function my_custom_section() {
    echo '<div class="single-properties-section">';
        echo '<h2>My Custom Section</h2>';
        // Custom content
    echo '</div>';
}
add_action( 'rentfetch_do_single_properties_parts', 'my_custom_section', 15 ); // Position after details

Method 4: Reorder Parts

Since parts are added with default priority 10, you can reorder by removing and re-adding with different priorities:

<?php
// Move amenities before floorplans
remove_action( 'rentfetch_do_single_properties_parts', 'rentfetch_single_properties_parts_amenities' );
add_action( 'rentfetch_do_single_properties_parts', 'rentfetch_single_properties_parts_amenities', 5 ); // Lower priority = earlier

Method 5: Filter Content Within Parts

Many parts have filters for specific content. For example:

<?php
// Modify property title display
add_filter( 'rentfetch_single_properties_title', function( $title ) {
    return '<h1 class="my-custom-title">' . $title . '</h1>';
} );

// Modify amenities display
add_filter( 'rentfetch_single_properties_amenities_output', function( $output ) {
    return '<div class="my-amenities">' . $output . '</div>';
} );

Admin Options

Most sections can be enabled/disabled via Rent Fetch > Settings > Properties > Single Property Components:

  • Property images
  • Section navigation
  • Property details
  • Floorplan display
  • Property fees display
  • Amenities display
  • Property map
  • Nearby properties

Note: “More Information” cannot be disabled via admin options – it displays automatically when content exists.

CSS Classes and Structure

Each section uses consistent CSS classes:

  • Container.single-properties-wrap
  • Sections.single-properties-section
  • Modifiers:
    • .no-padding – Removes default padding
    • .full-width – Makes section full width

Available Hooks

Main Structure Hooks

  • rentfetch_do_single_properties_parts – Main content assembly

Section-Specific Hooks

  • rentfetch_single_properties_parts_images
  • rentfetch_single_properties_parts_subnav
  • rentfetch_single_properties_parts_details
  • rentfetch_single_properties_parts_floorplans
  • rentfetch_single_properties_parts_fees_embed
  • rentfetch_single_properties_parts_amenities
  • rentfetch_single_properties_parts_more_information
  • rentfetch_single_properties_parts_map
  • rentfetch_single_properties_parts_more_properties

Content Filters

  • rentfetch_single_properties_title
  • rentfetch_single_properties_address
  • rentfetch_single_properties_amenities_output
  • rentfetch_single_properties_floorplans_output

Best Practices

  1. Preserve IDs: Keep section IDs for navigation and styling
  2. Maintain Structure: Use the .single-properties-section class for consistency
  3. Test Responsiveness: Ensure custom layouts work on mobile devices
  4. Use Filters First: Prefer filters over complete overrides when possible
  5. Document Changes: Comment your customizations for future maintenance

Example: Complete Custom Template

<?php
/**
 * Custom Single Properties Template
 * Place in your theme as single-properties.php
 */

get_header();

$property_id = get_the_ID();
$property_title = get_the_title();
?>

<div class="my-property-page">
    <header class="property-hero">
        <?php 
        // Custom hero section
        if ( has_post_thumbnail() ) {
            the_post_thumbnail( 'large' );
        }
        ?>
        <div class="hero-content">
            <h1><?php echo esc_html( $property_title ); ?></h1>
            <?php echo esc_html( get_post_meta( $property_id, 'address', true ) ); ?>
        </div>
    </header>
    
    <nav class="property-nav">
        <?php do_action( 'rentfetch_single_properties_parts_subnav' ); ?>
    </nav>
    
    <main class="property-content">
        <div class="property-details">
            <?php do_action( 'rentfetch_single_properties_parts_details' ); ?>
            <?php do_action( 'rentfetch_single_properties_parts_amenities' ); ?>
        </div>
        
        <div class="property-floorplans">
            <?php do_action( 'rentfetch_single_properties_parts_floorplans' ); ?>
        </div>
        
        <div class="property-fees">
            <?php do_action( 'rentfetch_single_properties_parts_fees_embed' ); ?>
        </div>
    </main>
    
    <aside class="property-sidebar">
        <?php do_action( 'rentfetch_single_properties_parts_map' ); ?>
        <?php do_action( 'rentfetch_single_properties_parts_more_properties' ); ?>
    </aside>
</div>

<?php get_footer(); ?>

This approach gives you complete control over the layout while still leveraging Rent Fetch’s functionality for individual sections.

Take Your Apartment Website to the Next Level

Whether for an entire portfolio or a single property, get completely setup and sync new property info & floor plan data in 10 minutes or less.

Trusted By

Cowboy Partners

Brickstone

Four Star

StreetLights

Richmark

Gates Hudson

Try Rent Fetch Today

We offer a 30-day, money-back guarantee.