daily pastebin goal
74%
SHARE
TWEET

Untitled

a guest Jan 19th, 2018 54 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. add_action( 'propertyhive_property_imported_blm', 'set_ph_custom_fields', 10, 2 );
  2. function set_ph_custom_fields($post_id, $property)
  3. {
  4.     if ( isset($property['INVESTOR_LIST_DISPLAY']) )
  5.     {
  6.         update_post_meta( $post_id, '_investor_list_display', $property['INVESTOR_LIST_DISPLAY'] );
  7.     }
  8.     if ( isset($property['INVESTOR_RENT_AMOUNT']) )
  9.     {
  10.         update_post_meta( $post_id, '_investor_rent_amount', $property['INVESTOR_RENT_AMOUNT'] );
  11.     }
  12.     if ( isset($property['INVESTOR_YIELD']) )
  13.     {
  14.         update_post_meta( $post_id, '_investor_yield', $property['INVESTOR_YIELD'] );
  15.     }
  16. }
RAW Paste Data
Top