Master document types mean that within the document type tree you can associate your new doument type as a child of the master type.
What this gives you in practice is a means to declare your common page properties in one single document type and then have those display in the editor for all pages of that document type or the child document types. It basically provides you with a single point to update / add page properties for the most common elements of your site.
If you understand the master templates system there are some similiarties between the template markup inheritance and using this for document type property inheritance.
Some examples of master document type properties could be: Hide in navigation, hide from search results, url alias, url redirect, meta data, meta keywords, page title.
to build off of what dirk has mentioned above... i often start with a mater docType that has tabs for navigation parameters [like urlAlias umbracoRedirect, umbracoNaviHide, plus others], a SEO tab, and sometimes i even throw a base content tab on their with pageHeading and bodyText...
using this as a master keeps me from having to add docType tabs and properties to EVERY doctype...
so if i create a docType for newsItem for example... i have it inherit from the masterDoc and simply have a tab for newsData on the newsItem docType that contains newsDate[datePicker] || newsImage [upload or mediaPicker] || newsDocument [upload or mediaPicker] and maybe even a newsLink [text field]
this way i only have to create one tab and 4 properties... instead of 3-4 tabs... just speeds up dev and deploy phases...
While this is an awesome feature indeed, it does require a bit of care when used.
Once a document type has been created there are no easy way to have it inherit from a master type, a feature I'd like to see would be an inheritance field where you could insert/remove doctypes that the document shoud inherit from. That would make it much simpler to adjust the site as it was developed.
For what it's worth, I don't use master docTypes for exactly the reasons Jannik mentioned, plus a few other minor items like dififculty packaging up docTypes that use master docTypes. I'm also kind of picky about what fields appear in a docType and find that not every one needs meta data or even umbracoNaviHide settings. I like to make docTypes that are absolutely specific to its use and needs.
But I'm also insterested in making sites as quickly and consistently as possible. So...
I create a base docType with all the properties and tabs that everyone puts on their master docType. I also add a content tab with a bodyText property. Then I right-click > copy that base docType for all my new docTypes and simply delete any fields that aren't necessary. It's much faster to click the X a few times than to create new properties.
I can also export the base docType and import it to a new site with a few clicks.
In practice I've found this to be a better solution for me than using master docTypes, but everyone has their own workflow and opinion on these matters... isn't it great that umbraco supports each of us in the way that we work best!
Beginner Document Type Question - easy karma...
Hi,
I was just wondering what the uses/advantages/restrictions are for nesting document types.
I see that there is a 'Master Document Type' drop-down to select from when creating a new document type, but I'm a bit unsure of what it's useful for.
If a master is selected, does that place any restrictions on using that document type in any templates?
Thanks,
Sean
Master document types mean that within the document type tree you can associate your new doument type as a child of the master type.
What this gives you in practice is a means to declare your common page properties in one single document type and then have those display in the editor for all pages of that document type or the child document types. It basically provides you with a single point to update / add page properties for the most common elements of your site.
If you understand the master templates system there are some similiarties between the template markup inheritance and using this for document type property inheritance.
Sean,
Some examples of master document type properties could be: Hide in navigation, hide from search results, url alias, url redirect, meta data, meta keywords, page title.
Hope this helps.
Regards,
/Dirk
to build off of what dirk has mentioned above... i often start with a mater docType that has tabs for navigation parameters [like urlAlias umbracoRedirect, umbracoNaviHide, plus others], a SEO tab, and sometimes i even throw a base content tab on their with pageHeading and bodyText...
using this as a master keeps me from having to add docType tabs and properties to EVERY doctype...
so if i create a docType for newsItem for example... i have it inherit from the masterDoc and simply have a tab for newsData on the newsItem docType that contains newsDate[datePicker] || newsImage [upload or mediaPicker] || newsDocument [upload or mediaPicker] and maybe even a newsLink [text field]
this way i only have to create one tab and 4 properties... instead of 3-4 tabs... just speeds up dev and deploy phases...
hope this is helpful to you.
I love this place... Something so obvious, that I have been dumb enough to miss! Good question and good answers - Thanks
While this is an awesome feature indeed, it does require a bit of care when used.
Once a document type has been created there are no easy way to have it inherit from a master type, a feature I'd like to see would be an inheritance field where you could insert/remove doctypes that the document shoud inherit from. That would make it much simpler to adjust the site as it was developed.
For what it's worth, I don't use master docTypes for exactly the reasons Jannik mentioned, plus a few other minor items like dififculty packaging up docTypes that use master docTypes. I'm also kind of picky about what fields appear in a docType and find that not every one needs meta data or even umbracoNaviHide settings. I like to make docTypes that are absolutely specific to its use and needs.
But I'm also insterested in making sites as quickly and consistently as possible. So...
I create a base docType with all the properties and tabs that everyone puts on their master docType. I also add a content tab with a bodyText property. Then I right-click > copy that base docType for all my new docTypes and simply delete any fields that aren't necessary. It's much faster to click the X a few times than to create new properties.
I can also export the base docType and import it to a new site with a few clicks.
In practice I've found this to be a better solution for me than using master docTypes, but everyone has their own workflow and opinion on these matters... isn't it great that umbraco supports each of us in the way that we work best!
cheers,
doug.
is working on a reply...