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

  • Home
  • SEARCH
  • 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 8957407
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T14:59:01+00:00 2026-06-15T14:59:01+00:00

In Play! Framework v. 1.x there was such thing like a ‘tag’ where was

  • 0

In Play! Framework v. 1.x there was such thing like a ‘tag’ where was possible to reuse some thml/template code.

In Play! Framework v 2.x, for me it is not clear still how it’s going to be used (here).

For example, I want to use tag to define a header for my site (in order not to repeat myself, but just include the header every in the pages where I need it).

Could someone explain me / show how to use tags, or whatever I should use to include the header or any block of html/template code.

  • 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-06-15T14:59:02+00:00Added an answer on June 15, 2026 at 2:59 pm

    You showed us a sample and you are asking for sample 🙂

    That’s easy, create a common view in views.tags package (remember to leave first line empty if you’re not gonna to pass any params! also remember to add brackets after tags name):

    /app/views/tags/header.scala.html

    <div id="header">
        <h1>Hello World!</h1>
    </div>
    

    So you can ‘include’ it in any other view just with:

    <body>
        @tags.header()
        Some other content
    </body>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I wondering is there an equivalent of this feature from play framework http://www.playframework.org/documentation/2.0/JavaAsync Basicly
Is there a way to make the Play! Framework ignore slashes and ? in
hi there i am woring with java play framework and i want to implement
In play framework application.conf there are lines: %test.db.url=jdbc:h2:mem:play;MODE=MYSQL;LOCK_MODE=0 %test.jpa.ddl=create But I am using MongoDB
Is there a way to access Play framework's embedded H2 database ( db=fs in
I want to implement pagination in Play FrameWork , Is there any tutorial or
I'm using play framework version 1.2.5 and I would like to retrieve all the
I'm trying to create a plugin for Play Framework 2.0 (latest code in Github
Using scalaforms for the play framework, say that i have form such as: case
Play framework doesn't support the servlet specification, nevertheless among it's deployment options there's the

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.