Getting started
Manual data entry
Menu
Getting started
Manual data entry
Hooks & filters Floor plan rentfetch_filter_floorplan_title

rentfetch_filter_floorplan_title

Last updated: December 12, 2025

The rentfetch_filter_floorplan_title filter allows you to modify the title of floorplan posts before they are displayed. This filter is applied in the rentfetch_get_floorplan_title() function and affects how floorplan titles appear throughout the Rent Fetch plugin.

Usage

add_filter( 'rentfetch_filter_floorplan_title', 'my_custom_floorplan_title', 10, 1 );

function my_custom_floorplan_title( $title ) {
    // Modify the $title as needed
    return $title;
}

Parameters

  • $title (string)
    The original floorplan title from get_the_title().

Return

(string) The modified floorplan title.

Examples

Add Property Name to Floorplan Title

For small multi-property websites, you may want to show a combined view of all of the floorplans, but you’d still like your users to be able to see at a glance which floorplans belong to which property. Here’s a snippet that can help:

// How to add the property title to each floorplan
function rf_add_property_title_to_floorplan_title( $title ) {
		
	$property_id = get_post_meta( get_the_ID(), 'property_id', true );
			
	// do a query for properties with this property_id
	$args = array(
		'post_type' => 'properties',
		'posts_per_page' => 1,
		'meta_query' => array(
			array(
				'key' => 'property_id',
				'value' => $property_id,
			)
		)
	);
	
	$propertylist = get_posts( $args );
	$property = $propertylist[0];
		
	if ( $property->post_title )
		$title = sprintf( '%s - %s', $property->post_title, $title );
		
	return $title;
}
add_filter( 'rentfetch_filter_floorplan_title', 'rf_add_property_title_to_floorplan_title', 10, 1 );

Customize Title Format

function customize_floorplan_title_format( $title ) {
    // Remove any existing prefixes and format consistently
    $title = 'Floor Plan: ' . $title;
    return $title;
}
add_filter( 'rentfetch_filter_floorplan_title', 'customize_floorplan_title_format', 10, 1 );

Where It’s Used

This filter affects floorplan titles in:

Notes

  • The filter receives the raw title from WordPress’s get_the_title() function
  • Changes made here will be reflected wherever rentfetch_get_floorplan_title() or rentfetch_floorplan_title() are called
  • The filter runs within the floorplan post context, so you can access floorplan metadata using get_the_ID() or get_post_meta()

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.