Archives

rem_attachments_title_length

This filter returns the number of characters for the attachment’s title to display.

Arguments

  1. Number of Characters [Integer]
  2. Property ID [Integer]
  3. Field’s Data [Array]

Example

Now if you want to increase the title’s length, you can use the following code.

You have to paste the following code inside the functions.php file of your active theme.

add_filter( 'rem_attachments_title_length', 'rem_change_attachment_title_length', 10, 1 );

function rem_change_attachment_title_length($length){
	return '30';
}

rem_property_field_value_separator

This filter can be used to change the field value separators used in Single Property Pages. By default, it displays colons.

Arguments

  1. Colons : [String]
  2. Field Data Name [String]
  3. Field’s All Data [Array]
  4. Property ID [Integer]

Example

The following code will display an equal sign instead of colons between field name and value. Please paste the following code in your theme’s functions.php file.

add_filter( 'rem_property_field_value_separator', 'rem_property_change_value_separator', 10, 1 );

function rem_property_change_value_separator($sep){
	return '=';
}

 

rem_single_property_grid_attrs

This filter is responsible for all the settings related to the Gallery Grid, on the Single Property Page.

Arguments

  1. Grid Settings [Array]

Default settings that we’re using are defined below

  • cells => 5
  • align => true

Example

Now if you want to change the cell numbers and don’t want to cut off the images, use the below example code.

You have to paste the following code inside the functions.php file of your active theme

add_filter( 'rem_single_property_grid_attrs', 'rem_custom_single_listing_grid', 10, 1 );

function rem_custom_single_listing_grid($settings){
	$settings['cells'] = 4;
	$settings['align'] = false;
	return $settings;
}

rem_single_property_slick_attrs

This filter is responsible for all the settings related to the Simple Gallery Slider, on the Single Property Page. We’re using the Slick library here.

Arguments

  1. Slick Settings [Array]

Default settings that we’re using are defined below

  • arrows => true
  • adaptiveHeight => true

Example

Now if you want to make this slider more interactive or enable more options, you can play with this filter. The following example code will make the single property page slider 3 images in a row and will also enable the bottom navigation dots.

You have to paste the following code inside the functions.php file of your theme to achieve this

add_filter( 'rem_single_property_slick_attrs', 'rem_custom_single_listing_slider', 10, 1 );

function rem_custom_single_listing_slider($settings){
	$settings['dots'] = true;
	$settings['slidesToShow'] = 3;
	return $settings;
}

rem_featured_image_size

This filter can be used to change the size of featured images of listings used in the listing archives.

Arguments

  1. Image size or array of width height [String|Integer[]]
  2. Image ID [Integer]

Example

The following code will set the featured image size to 200px by 200px. Please paste the following code in your theme’s functions.php file.

add_filter( 'rem_featured_image_size', 'rem_change_f_image_size', 10, 2 );

function rem_change_f_image_size($image_size, $id){
	return array( 200, 200);
}

 

rem_email_sender_email

This filter can be used to change the sender email address used in Emails. By default, REM uses WordPress admin’s email address for sending emails.

Arguments

  1. Admin Email Address [String]

Example

The following code will set the “from email address” in emails as rem@webcodingplace.com. Please paste the following code in your theme’s functions.php file.

add_filter( 'rem_email_sender_email', 'rem_change_sender_email', 10, 1 );

function rem_change_sender_email($email){
	return 'rem@webcodingplace.com';
}

 

rem_email_sender_title

This filter can be used to change the site title used in From Emails. By default, REM uses WordPress’s site title for sending emails.

Arguments

  1. Site Title [String]

Example

The following code will set the “from email” text as REM Notification. Please paste the following code in your theme’s functions.php file.

add_filter( 'rem_email_sender_title', 'rem_change_title_email', 10, 1 );

function rem_change_title_email($title){
	return 'REM Notification';
}

 

rem_change_admin_email

This filter can be used to change the admin email. By default, REM uses WordPress’s admin email for sending emails.

Arguments

  1. Admin Email [String]

Example

The following code will set the admin email to someone@gmail.com. Please paste the following code in your theme’s functions.php file.

add_filter( 'rem_change_admin_email', 'rem_change_admin_email', 10, 1 );

function rem_change_admin_email($email){
	return 'someone@gmail.com';
}

 

rem_energy_efficiency_fields

This filter can be used to alter any data in the Energy Efficiency fields.

Arguments

  1. EE Fields [Array]

Example

The following code will replace the Energy Efficiency scale values  (A+, A, B, C, …)  with new ones (Efficient, Average, etc), paste the following code in your theme’s functions.php file.

add_filter( 'rem_energy_efficiency_fields', 'rem_new_energy_efficiency_scales', 10, 1 );

function rem_new_energy_efficiency_scales($ee_fields){
	$ee_fields[0]['options'] = array(
		'Very Efficient',
		'Efficient',
		'Better',
		'Good',
		'Average',
		'Inefficient',
		'Very inefficient',
	);
	return $ee_fields;
}