web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id : tZsNuyNKNnkGyZZeVHH6tU
Power Pages - Power Apps Portals
Unanswered

Add Multiple Content Snippets to HTML Body

Like (0) ShareShare
ReportReport
Posted on 21 Jan 2022 15:47:50 by

 

Can you please tell me what is wrong with this setup? I am trying to render content snippets

 

I have created a website, a web template for the website, a page template for the website, a webpage for the website and 4 content snippets.

Web Template

My web template shows

 

{% include 'snippet' snippet_name:'snippet1' %}

{% include 'snippet' snippet_name:'snippet2' %}

{% include 'snippet' snippet_name:'snippet3' %}

{% include 'snippet' snippet_name:'snippet4' %}
 

Content Snippets

snippet 1 - <p> I am snippet 1 </p>

snippet 2 - <p> I am snippet 2 </p>

snippet 3 - <p> I am snippet 3 </p>

snippet 4 - <p> I am snippet 4 </p>

 

Page Template

My page template

 

Website

My website

 

Webpage

My webpage

 

 

I have seen this documentation but it seems to be for one website and one content snippet.

 

Customize content by using content snippets - Power Apps | Microsoft Docs

After you create a snippet with text, HTML, or liquid objects shown in the example above, you can use it in a portal page.

To do add snippet on a portal page:

  1. Create a web template and use snippets liquid object to call the snippet you created.

  2. Create a page template using the web template created earlier.

  3. Use the portals Studio to create a new page using the page template created earlier.

 

I have the same question (0)
  • Christian Leverenz Profile Picture
    1,214 on 25 Jan 2022 at 15:27:25
    Re: Add Multiple Content Snippets to HTML Body

    Hi @Anonymous ,

    There are two ways to use snippets:

     

    {{ snippets["snippet1"] }} or {% assign myname = "snippet1"%} {{ snippets[myname] }}

     

    or

     

    {% editable snippets "snippet1" type:html %} as documented here: https://docs.microsoft.com/en-

    us/powerapps/maker/portals/liquid/portals-entity-tags#editable ( i am never sure, whether you have to quote the name here or not )

     

    the former just reads them, the latter lets you edit them in the frontend if you are allowed to.

     

    Keep in mind, that {{ }} usually renders something on the page and {% %} is usually a statement.

     

    May be, that is the problem.

     

    Does this help?

    Have fun,

      Christian

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Telen Wang – Community Spotlight

We are honored to recognize Telen Wang as our August 2025 Community…

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Pages

#1
Fubar Profile Picture

Fubar 62 Super User 2025 Season 2

#2
Lucas001 Profile Picture

Lucas001 48 Super User 2025 Season 2

#3
KevinGador Profile Picture

KevinGador 44 Super User 2025 Season 2

Loading started
Loading complete