diff --git a/templates/CRM/Contact/Form/Edit/Address/CustomData.tpl b/templates/CRM/Contact/Form/Edit/Address/CustomData.tpl
index 1115cfa486fd..feaa7c09882c 100644
--- a/templates/CRM/Contact/Form/Edit/Address/CustomData.tpl
+++ b/templates/CRM/Contact/Form/Edit/Address/CustomData.tpl
@@ -31,17 +31,7 @@
{$cd_edit.title}
- {if $cd_edit.help_pre}
-
{$cd_edit.help_pre}
- {/if}
-
-
- {if $cd_edit.help_post}
{$cd_edit.help_post}
{/if}
+ {include file="CRM/Custom/Form/Edit/CustomData.tpl" customDataEntity='address'}
diff --git a/templates/CRM/Contact/Form/Edit/CustomData.tpl b/templates/CRM/Contact/Form/Edit/CustomData.tpl
index 73d994396bdc..8b5606a8ab33 100644
--- a/templates/CRM/Contact/Form/Edit/CustomData.tpl
+++ b/templates/CRM/Contact/Form/Edit/CustomData.tpl
@@ -38,21 +38,7 @@
-
- {if $cd_edit.is_multiple eq 1}
- {if $cd_edit.table_id}
-
- {/if}
- {/if}
{include file="CRM/Custom/Form/CustomData.tpl" formEdit=true}
diff --git a/templates/CRM/Custom/Form/CustomData.tpl b/templates/CRM/Custom/Form/CustomData.tpl
index 4403208135ad..c0de8e0b75da 100644
--- a/templates/CRM/Custom/Form/CustomData.tpl
+++ b/templates/CRM/Custom/Form/CustomData.tpl
@@ -25,44 +25,18 @@
*}
{* Custom Data form*}
{if $formEdit}
- {if $cd_edit.help_pre}
-
- {if $cd_edit.help_pre}
-
{$cd_edit.help_pre}
- {/if}
-
- {foreach from=$cd_edit.fields item=element key=field_id}
- {assign var="element_name" value=$element.element_name}
- {include file="CRM/Custom/Form/Edit/CustomField.tpl" formElement=$form.$element_name}
- {/foreach}
-
-
- {if $cd_edit.help_post}
-
{$cd_edit.help_post}
- {/if}
+ {include file="CRM/Custom/Form/Edit/CustomData.tpl" customDataEntity=''}
{else}
- {if $cd_edit.is_multiple eq 1 and $cd_edit.table_id and $contactId and !$skipTitle and $cd_edit.style eq 'Inline'}
- {assign var=tableID value=$cd_edit.table_id}
-
- {ts}Delete{/ts}
-
- {/if}
- {if $cd_edit.help_pre}
-
{$cd_edit.help_pre}
- {/if}
-
-
- {if $cd_edit.help_post}
-
{$cd_edit.help_post}
- {/if}
+ {include file="CRM/Custom/Form/Edit/CustomData.tpl" customDataEntity=''}
- {if $cd_edit.is_multiple and ( ( $cd_edit.max_multiple eq '' ) or ( $cd_edit.max_multiple > 0 and $cd_edit.max_multiple > $cgCount ) ) }
- {if $skipTitle}
- {* We don't yet support adding new records in inline-edit forms *}
-