1. Home
  2. Docs
  3. Developer Guide
  4. Miscellaneous and Snippet...
  5. Changing an Action Button Label on Property Details

Changing an Action Button Label on Property Details

add_filter( 'propertyhive_single_property_actions', 'change_floorplan_button_label' );
function change_floorplan_button_label( $actions )
{
    $new_actions = array();
    foreach ( $actions as $action )
    {
        if ( $action['class'] == 'action-floorplans'  )
        {
            $action['label'] = __( 'Floorplan', 'propertyhive' );
        }

        $new_actions[] = $action;
    }

    return $new_actions;
}
Was this article helpful to you? No Yes

How can we help?