Reputation: 3486
Can I publish component presentation without adding it to a page? The answer seems to be yes. I have a component that is not on any pages. I published just that component and the component presentation ended up at my destination, but where is the component picking up the template? Is it picking it up via the LinkedSchema tab in the template? I did link the schema used for the component to a template.
Thanks
Upvotes: 6
Views: 858
Reputation: 3547
You guessed right. A component is published as a dynamic component presentation (so without a page) if there are one or more component templates that are:
a. linked to the schema the component is based on
b. marked as 'publish as a dynamic component'
Upvotes: 9
Reputation: 251
Yes, that's right. When you create a component template, you specify the linked schemas which can use this template. Publishing a component with out adding to a page is called dynamic component presentation. In component template general tab, you could specify this as "Published as dynamic component" for the field component presentations based on this template. If you have value as "Publish embedded on a page", your component presentation is static meaning you have to associate this component with page to get it published. Dynamic component presentations makes use of content broker database to query the data and to display it in website. However components embedded on a page would be static and would be served from file system (instead of database). Hope it helps!
Upvotes: 7