When creating dynamic templates or blocks, you must always select a source. The source determines which records you’ll use to fill in the content of your template or block. For example, when “Contacts” is the source, you can access your contacts’ first names or email addresses when you make elements dynamic. When “Blogs” is the source, you have access to fields such as blog title and blog content. You will find different sources depending on the objects in your account and the relationships you have set up between them.
This article will show you how to determine what information you can pull into your dynamic content based on the type of asset you create and the relationships you have set up in your account.
Table of contents
Dynamic content you can add to page
Dynamic content you can add to dynamic templates
• Make individual page elements dynamic
• Add dynamic blocks to your dynamic template
Dynamic content you can add to pages
Dynamic blocks are the only type of dynamic content you can add to regular (non-dynamic) Ontraport pages.
Once you’ve converted a regular block into a dynamic block by clicking , you can choose from the following sources:
Dynamic block source | Description |
---|---|
The objects in your account | The objects in your account include default objects such as Contacts, Users, Products, and Tasks. The data sources section also contains all your custom objects or objects added by Ontraport Apps. You’ll find these objects in the “Data sources” section. For example, use the Blogs source to add three blog posts to the bottom of your website’s home page. |
The subcollections related to your visiting contact | This includes default subcollections in your contact records, such as Notes, Transactions, Subscriptions, and Payment Plans and Transactions. It also includes subcollections created by custom relationships. These objects have a one-to-many relationship with contacts where contacts are the parent. You’ll also see any many-to-many relationships set up between contacts. These subcollections are in the “Related to Visiting Contact” section. For example, use the “Subscriptions and Payment Plans” source to display your visiting contact’s open orders on their profile. |
Dynamic content you can add to dynamic templates
There are two ways to make your content dynamic on templates:
1. Make individual page elements dynamic
Every published template pulls from a record in your account. For example, you’ll use a contact template to post information about a specific contact. This option allows you to change the content of your elements based on the data saved in your records.
You’ll always see at least two options when you make elements dynamic:
- Visiting contact fields
- You can use visiting contact fields and fields from your source’s records.
- [Object] fields (Dynamic page)
- You can access all of the fields from your source object’s records.
- You can also “drill in” to the fields in your parent records for one-to-many and one-to-one relationships.
- For example, if your page’s source is Contacts, you can “drill in” to company fields to add the name and industry of your contact’s company.
Add dynamic blocks to your dynamic template
When you add dynamic blocks to dynamic templates, you can choose from any sources you can add to pages, plus one that lets you add subcollections of your dynamic template’s source.
The subcollections of your dynamic template’s source are highly helpful for adding related records. For example, you can display only the comments left on a specific blog post, or show all of the deals you have in your pipeline for a particular company.
Dynamic block source | Description |
---|---|
The subcollections of your dynamic template’s source | This includes any object in your account with a one-to-many relationship with your template’s source, where the source is the parent. Or any object that has a many-to-many relationship with your template’s source. For example, if your template’s source is “Companies,” you can add a dynamic block that lists the employees of that company. You’ll find these subcollections in the “Related to the [Object name] record this dynamic page is based on” section. |