Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6914317
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T09:19:55+00:00 2026-05-27T09:19:55+00:00

How can I include a page from magnolia into a magnolia template script? In

  • 0

How can I include a page from magnolia into a magnolia template script?

In the template script with I can access data from a specific page, but how can I load that page into the template?

Let’s say I have 2 pages each with its own template. Page 1 contains in its tree page 2. I want to include in the template script of page 1, page 2, but doesn’t work.

Thank you very much 🙂

UPDATED

What I actually want to do is include my header in all of my project’s pages. But I don’t want to put it as a paragraph, because if I ever want to change my header, I’ll have to edit all the project’s pages.

So what I try to do and I don’t know if this is the correct approach is to create a page template for the header. This template won’t include any , or css, it’s just the code for the header.
The next thing I want to do is create a page in magnolia with that model to be the header.
Next I’d like to include the page I’ve just created in my main template model for the project, but I can’t figure how to do that.

I am new to Magnolia cms and initially I tried creating my demo site using stk. The only problem was that I couldn’t use jsp as a scripting language, or at least I couldn’t find any solution on the internet. I don’t really know freemarker, but that’s not really a big problem. I’m really reluctant in using freemarker because maybe in the future in a more complex project I might need some features that freemarker doesn’t support, but jsp does. I’d like to build my site using jsp if that’s possible with magnolia.

I’m sorry for this long update, but if anyone has any suggestions on what a best practice could be and if I could implement what I want in jsp I would be really grateful.

Thanks again for you time 🙂

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T09:19:56+00:00Added an answer on May 27, 2026 at 9:19 am

    If you’re using the STK then see this guide on content-reuse.

    If not have a look at the cms tag-lib, especially the tags cms:loadPage and cms:setNode with which you can get a piece of content and set it as a JSP/JSTL variable and then render it using cms:includeTemplate.

    A common scenario is to ‘inherit’ content from the parent page, the header is an excellent example of this. What you do is for an area you walk up the content hierarchy and render everything from the parent pages in their area with the same name. This way the header which you’ve only added to the top page is included in all its children.

    Another option is to a have special page which simply holds things to be included in other pages. Like header, footer and banners that should go in the side pane of some pages.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm creating a mobile website that will include a page from which people can
How can I include Javascript onto my page from a webcontrol that is loading,
I'm looking for a key/value pair object that I can include in a web
I have a loooooooooooong SELECT ending with a ORDER BY that can include the
I am looking for a syntax highlighting component that I can include in a
I have several textboxes where users can enter information into them. This can include
How can include CodeIgniter content in a regular PHP page on the same server
Can anybody explain me how I can include .inc file from VB classic ASP
I'm trying to include a jsp page from a servlet: RequestDispatcher rd = ctx.getRequestDispatcher(
I have to show a page from my php script based on certain conditions.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.