{"id":11609,"date":"2022-07-24T16:03:13","date_gmt":"2022-07-24T16:03:13","guid":{"rendered":"https:\/\/fhug.org.uk\/kb\/?post_type=kb_article&#038;p=11609"},"modified":"2025-03-24T15:42:28","modified_gmt":"2025-03-24T15:42:28","slug":"adding-and-customising-source-templates-in-version-7","status":"publish","type":"kb_article","link":"https:\/\/www.fhug.org.uk\/kb\/kb-article\/adding-and-customising-source-templates-in-version-7\/","title":{"rendered":"Adding, Customising and Sharing Source Templates in Version 7"},"content":{"rendered":"<h2>Introduction<\/h2>\n<p>Many users will never need\/choose to customise Source Templates but everyone who uses them will need to add some to their project. This article introduces some key terminology, describes how to add Templates to a project, and (for those users who wish to do so) how to create new Templates or customise existing ones.<\/p>\n<p>If you have not already done so, we recommend you read <a href=\"https:\/\/fhug.org.uk\/kb\/kb-article\/working-with-sources-and-citations-in-version-7\/\">Sources and Citations in FH7 (for Upgraders)<\/a> or <a href=\"https:\/\/fhug.org.uk\/kb\/kb-article\/sources-and-citations-in-version-7-for-new-users\/\">Sources and Citations in FH7 (for New Users)<\/a>\u00a0before continuing here.<\/p>\n<div class=\"lightweight-accordion\"><details><summary class=\"lightweight-accordion-title\"><h3>Terminology:  Source Template Definitions, Source Template Records and Collections<\/h3><\/summary><div class=\"lightweight-accordion-body\"><p><glwrap>A Source Template Definition includes information needed to identify the Template (the Template name, a Category and possible a Subcategory which are useful when determining which Template to use), and a description of the Template. It also includes all the information needed to determine how a particular Template behaves: what fields are included and the type of data each holds, and how the Title, Footnote, Short Footnote and Bibliography entry is constructed from those fields.<\/p>\n<p>Source\u00a0Template Definitions do <strong>not <\/strong>form part of any project, but sit outside them, available to be added to one or more projects of your choice. When you add a Source\u00a0Template Definition to a project, it creates a Source\u00a0Template Record, which does sit inside a project and appears in the Source\u00a0Template record list.\u00a0 The distinction becomes important when Customising Templates, as changes you make to a Source\u00a0Template Record are not automatically applied to a Source\u00a0Template Definition (more on this later, for advanced users).<\/p>\n<p>A Collection is a group of Source\u00a0Template Definitions. The standard collections supplied with <span class=\"fh\" style=\"font-size: 17px !important; line-height: 21.4286px !important;\">\u0192<span style=\"color:#73B262; font-weight: bold;\">h<\/span><\/span> are the Essentials Collection and the Advanced Collection, but you can create additional custom Collections for your own use or to share with others.<\/p>\n<p><\/glwrap><\/p>\n<\/div><\/details><\/div>\n<div class=\"lightweight-accordion\"><details><summary class=\"lightweight-accordion-title\"><h3>How to Make Templates Available in a Project<\/h3><\/summary><div class=\"lightweight-accordion-body\"><p><img decoding=\"async\" class=\"wp-image-11661 alignleft lazyload\" data-src=\"https:\/\/fhug.org.uk\/kb\/wp-content\/uploads\/2020\/09\/Screenshot-2020-10-16-124243.png\" alt=\"\" width=\"400\" height=\"174\" data-wp-editing=\"1\" data-srcset=\"https:\/\/www.fhug.org.uk\/kb\/wp-content\/uploads\/2020\/09\/Screenshot-2020-10-16-124243.png 557w, https:\/\/www.fhug.org.uk\/kb\/wp-content\/uploads\/2020\/09\/Screenshot-2020-10-16-124243-300x130.png 300w, https:\/\/www.fhug.org.uk\/kb\/wp-content\/uploads\/2020\/09\/Screenshot-2020-10-16-124243-150x65.png 150w\" data-sizes=\"(max-width: 400px) 100vw, 400px\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 400px; --smush-placeholder-aspect-ratio: 400\/174;\" \/>When you create a new Project or import a Project from <span class=\"fh\" style=\"font-size: 17px !important; line-height: 21.4286px !important;\">\u0192<span style=\"color:#73B262; font-weight: bold;\">h<\/span><\/span>6, no Source Template Records are included. The first time you attempt to Create a Source from a Template, you will be asked if you wish to add the Templates from the Essentials collection, or whether you wish to add Templates as needed.<\/p>\n<p>If you accept the offer, the Essentials collection of Source Template Definitions will be used to create Source Template Records within your project.<\/p>\n<p>If you choose not to accept the offer, you can add Templates at any point using <a href=\"#!\" class=\"cs_tooltip\" fhugtt=\"This is the menu across the top of the main Family Historian windows. The &gt; denotes a submenu\">Tools&nbsp&gt;&nbspSource&nbspTemplate&nbspDefinitions&#8230;<\/a>, or by clicking the <em>Find More&#8230;<\/em>button wherever you&#8217;re prompted to select a Source Template Record (for example when Creating a Source from a Template). Both routes will open the <em>Source Template Definitions Dialog<\/em>, which allows you to select the Templates you want to add, and is described at <a href=\"https:\/\/www.family-historian.co.uk\/help\/fh7\/hh_start.htm#sourcetemplatedefinitiondialog.html\" target=\"_blank\" rel=\"noopener noreferrer\">Source Template Definitions Dialog<\/a><\/p>\n<\/div><\/details><\/div>\n<div class=\"lightweight-accordion\"><details><summary class=\"lightweight-accordion-title\"><h3>Creating and Customising Templates<\/h3><\/summary><div class=\"lightweight-accordion-body\"><p>The Source Template Definitions Dialog is the starting point for creating\/editing your own Source Templates Definitions; open it via <a href=\"#!\" class=\"cs_tooltip\" fhugtt=\"This is the menu across the top of the main Family Historian windows. The &gt; denotes a submenu\">Tools&nbsp&gt;&nbspSource&nbspTemplate&nbspDefinitions&#8230;<\/a>, or by clicking the <em>Find More&#8230;<\/em>button wherever you&#8217;re prompted to select a Source Template Record (for example when Creating a Source from a Template). It is possible to edit a project&#8217;s Source Template Records directly but we don&#8217;t recommend it as the editing and template management facilities are better in the Source Templates Definition Dialog, including facilities for keeping everything in synch.<\/p>\n<p>You cannot edit the standard Source Template Definitions (or add to the standard Collections), but you can <em>Clone&#8230;<\/em> an existing Template Definition or create a <em>New&#8230;<\/em> Template Definition. Both Cloned and New Definitions can be put in a Collection of your own. By default, this Collection is called Custom; however, you can call your Collection anything you like, and have as many of your own Collections as you wish. You might want to create a Collection of Templates suitable for Sources\u00a0generated in a particular country, or one for the various sorts of Military Service Records created in the UK. Or you might be content with the Essentials Collection of Templates, except for some changes to the Record Title Formats to ensure all the source-identifying data is included in the Title when you <a href=\"https:\/\/fhug.org.uk\/kb\/kb-article\/exporting-templated-sources\/\">export a Gedcom file<\/a>.<\/p>\n<p>The <a href=\"https:\/\/www.family-historian.co.uk\/help\/fh7\/hh_start.htm#sourcetemplatedefinitiondialog.html\" target=\"_blank\" rel=\"noopener noreferrer\">Help file<\/a> covers creating and customising Templates, but there are some key things to bear in mind:<\/p>\n<ul>\n<li>Changes you make to a Source Template Definition will <strong>not<\/strong> be applied to the corresponding Source Template Record and associated Source records in your Project until you use the <em>Compare\/Synch with Source Template Record..<\/em>. button within the Source Template Definitions dialog and use its <em>Perform Task<\/em> options.<\/li>\n<li>Changes you make to a Source Template Record within your Project by editing it directly will <strong>not<\/strong> affect any Source record already created from that Template, so is <strong>not<\/strong> normally recommended.<\/li>\n<li>If you want to delete a custom Template completely, you must not only delete the relevant Source Template Definition using <a href=\"#!\" class=\"cs_tooltip\" fhugtt=\"This is the menu across the top of the main Family Historian windows. The &gt; denotes a submenu\">Tools&nbsp&gt;&nbspSource&nbspTemplate&nbspDefinitions&#8230;<\/a> and then selecting the relevant Template and clicking Delete; you must also delete the corresponding Source Template Record in any projects where it is present, by using <a href=\"#!\" class=\"cs_tooltip\" fhugtt=\"This is the menu across the top of the main Family Historian windows. The &gt; denotes a submenu\">View&nbsp&gt;&nbspOther&nbspRecord&nbspLists&nbsp&gt;&nbspSource&nbspTemplates<\/a> (if the Source Templates are not already visible in the Records Window), and selecting the relevant Source Template Record and using the DEL key to delete it.<\/li>\n<\/ul>\n<p>Special care is needed when deleting or changing an existing Field definition:<\/p>\n<ul>\n<li>Before deleting a Field definition from the Source Template Definition perform the following steps:\n<ul>\n<li>Create a Query or Records Window column to display the Source record Field and delete all instances of its value.<\/li>\n<li>In the Source Template record Property Box, delete the Field Definition via the All tab.<\/li>\n<li>Finally, in the Source Template Definition, delete the Field, then Save and Close and ensure <em>Compare\/Synch with Source Template Record..<\/em>. is OK.<\/li>\n<\/ul>\n<\/li>\n<li>Changing a Field definition via the Source Template Definition Editor is usually successful as long as the new Type definition is compatible with the old Type. When using the <em>Compare\/Synch with Source Template Record..<\/em>. button ensure the old Field from Source Template Record is chosen from the droplist before using its <em>Perform Task<\/em> option. Then both the Source Template record and any existing associated Source records will be updated accordingly, but take note of the Caution message.<\/li>\n<\/ul>\n<p><img decoding=\"async\" class=\"wp-image-11661 aligncenter lazyload\" data-src=\"https:\/\/www.fhug.org.uk\/kb\/wp-content\/uploads\/2025\/03\/Compare-Fields-Dialogue-and-Caution.png\" alt=\"\" width=\"950\" height=\"320\" data-wp-editing=\"1\" src=\"data:image\/svg+xml;base64,PHN2ZyB3aWR0aD0iMSIgaGVpZ2h0PSIxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjwvc3ZnPg==\" style=\"--smush-placeholder-width: 950px; --smush-placeholder-aspect-ratio: 950\/320;\" \/><\/p>\n<\/div><\/details><\/div>\n<div class=\"lightweight-accordion\"><details><summary class=\"lightweight-accordion-title\"><h3>Sharing User-Defined and Imported Templates<\/h3><\/summary><div class=\"lightweight-accordion-body\"><p><span class=\"fh\" style=\"font-size: 17px !important; line-height: 21.4286px !important;\">\u0192<span style=\"color:#73B262; font-weight: bold;\">h<\/span><\/span> is written assuming a workflow from the Source Template Definition to Source Template Record to Source Record, so if a new template is required this is normally implemented by creating the definition first.\u00a0 While this is usually the preferred route, there will be occasions where the template is created without a definition.\u00a0 In particular, when Source Template Records are imported from another application, <span class=\"fh\" style=\"font-size: 17px !important; line-height: 21.4286px !important;\">\u0192<span style=\"color:#73B262; font-weight: bold;\">h<\/span><\/span> does not automatically create the corresponding definition.\u00a0 If there is no definition file, the Source Template Record cannot be shared with other projects.\u00a0 Another common scenario is where a user who is familiar with Source Templates from another application but unfamiliar with <span class=\"fh\" style=\"font-size: 17px !important; line-height: 21.4286px !important;\">\u0192<span style=\"color:#73B262; font-weight: bold;\">h<\/span><\/span> Source Template Definitions will create new Source Template Records directly.<\/p>\n<p>It is not possible to create Source Template Definitions from existing Source Template Records in <span class=\"fh\" style=\"font-size: 17px !important; line-height: 21.4286px !important;\">\u0192<span style=\"color:#73B262; font-weight: bold;\">h<\/span><\/span> &#8220;out of the box&#8221;, but this gap is filled by the <a href=\"https:\/\/pluginstore.family-historian.co.uk\/page\/plugin\/create-source-template-definitions\">Create Source Template Definitions<\/a>\u00a0plugin.\u00a0 Download and run this plugin to automatically create all missing Source Template Definitions and add them to the corresponding Collection file.<\/p>\n<p>Once the missing Source Template Definitions have been created, any user-defined or imported templates can be added to other <span class=\"fh\" style=\"font-size: 17px !important; line-height: 21.4286px !important;\">\u0192<span style=\"color:#73B262; font-weight: bold;\">h<\/span><\/span> projects as described above.<\/p>\n<\/div><\/details><\/div>\n<div class=\"lightweight-accordion\"><details><summary class=\"lightweight-accordion-title\"><h3>Importing and Exporting Collections<\/h3><\/summary><div class=\"lightweight-accordion-body\"><p><a href=\"#!\" class=\"cs_tooltip\" fhugtt=\"This is the menu across the top of the main Family Historian windows. The &gt; denotes a submenu\">File&nbsp&gt;&nbspImport\/Export<\/a> or the Source Template Definitions Dialog <em>Import&#8230;<\/em> and buttons allow you to use Template Collection files (.fhst extension) created by other people, or to make a Collection that you&#8217;ve created available for other people to use.<\/p>\n<p>Collections which FHUG users have made available for other are found at <a href=\"https:\/\/fhug.org.uk\/kb\/download-type\/source-templates\/\">Download Type: Source Templates<\/a>. If you want to contribute a Collection of your own, please go to <a href=\"https:\/\/fhug.org.uk\/kb\/add-download\/\">Add\/Update a Download<\/a>.<\/p>\n<\/div><\/details><\/div>\n<p>&nbsp;<\/p>\n","protected":false},"template":"","fh_version":[739],"skill_level":[18,17,16],"topic":[83],"class_list":["post-11609","kb_article","type-kb_article","status-publish","hentry","fh_version-v7","skill_level-advanced","skill_level-intermediate","skill_level-newcomer","topic-sources-and-citations"],"_links":{"self":[{"href":"https:\/\/www.fhug.org.uk\/kb\/wp-json\/wp\/v2\/kb_article\/11609","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.fhug.org.uk\/kb\/wp-json\/wp\/v2\/kb_article"}],"about":[{"href":"https:\/\/www.fhug.org.uk\/kb\/wp-json\/wp\/v2\/types\/kb_article"}],"wp:attachment":[{"href":"https:\/\/www.fhug.org.uk\/kb\/wp-json\/wp\/v2\/media?parent=11609"}],"wp:term":[{"taxonomy":"fh_version","embeddable":true,"href":"https:\/\/www.fhug.org.uk\/kb\/wp-json\/wp\/v2\/fh_version?post=11609"},{"taxonomy":"skill_level","embeddable":true,"href":"https:\/\/www.fhug.org.uk\/kb\/wp-json\/wp\/v2\/skill_level?post=11609"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.fhug.org.uk\/kb\/wp-json\/wp\/v2\/topic?post=11609"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}