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 8651967
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T14:11:50+00:00 2026-06-12T14:11:50+00:00

Does i realy have to repeat the Navbar on every page DIV? Or is

  • 0

Does i realy have to repeat the “Navbar” on every page DIV? Or is there an solution to use only one footer for all pages inside an multi-page html?

 <div data-role="page" id="page11">
        <div data-role="header"> <h1>Home</h1> </div>

        <div data-role="content"> <h3>TEST</h3>
            <p> <a href="#dialog" data-rel="dialog" data-transition="pop" data-role="button">Dialogbox </a> </p>
        </div>

        <div data-role="footer" data-id="foo1" data-position="fixed"> 
            <div data-role="navbar">
                <ul>
                    <li> <a href="#page1" data-iconpos="top" data-icon="home">Start </a> </li>
                    <li> <a href="#page2" data-iconpos="top" data-icon="help">Hilfe </a> </li>
                </ul>
            </div> 
        </div>
    </div>

    <div data-role="page" id="page2">
        <div data-role="header"> <h1>Hilfe </h1> </div>
        <div data-role="content"> <h3>TEST </h3> </div>

         <div data-role="footer" data-id="foo1" data-position="fixed"> 
            <div data-role="navbar">
                <ul>
                    <li> <a href="#page1" data-iconpos="top" data-icon="home">Start </a> </li>
                    <li> <a href="#page2" data-iconpos="top" data-icon="help">Hilfe </a> </li>
                </ul>
            </div> 
        </div>
    </div>

Thx for any ideas!

  • 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-12T14:11:51+00:00Added an answer on June 12, 2026 at 2:11 pm

    Yes, your navbar/footer/header must be present in all of your page-DOM-elements.
    But to avoid repeating yourself you have many options on the client and/or server side.
    I always recommend to use some kind of templating in such situations.

    On the client side you could place your navbar into a <script> tag beneath the <body> tag. Assign an unique id attribute to this script tag and add some JavaScript like this:

    Template Snippet:

    <script type="text/template" id="myFooterTemplateID">
        <div data-role="footer" data-id="foo1" data-position="fixed"> 
            <div data-role="navbar">
                <ul>
                    <li> <a href="#page1" data-iconpos="top" data-icon="home">Start </a> </li>
                    <li> <a href="#page2" data-iconpos="top" data-icon="help">Hilfe </a> </li>
                </ul>
            </div> 
        </div>
    </script>
    

    JavaScript:

    jQuery('*[data-role="page"]').on("pagebeforecreate", function(e) {
        var page = jQuery(this);
        // please replace this part with a template engine ...
        var header = jQuery(jQuery("#myFooterTemplateID").html()); 
    
        // bind some events to the header's content here - if any
        // for example: 
        // header.find('.myButtonClass').bind('tap', onButtonClicked);
    
        // append to page
        page.append(header);
    });
    

    Check out Handlebars.js or Underscore-Templates for production ready JS-templating instead of writing your own library.

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

Sidebar

Related Questions

I have a HTML page containing some hardcoded/static text. The text string does not
I have a div on my page with the following css: .modal { display:
Ok, question does not really make sense. Here is the situation. I have legacy
Does JQueryMobile have good support for entering credit card information. Users have a really
Does making the below class final (adding public final class) have any real impact
Does it have any major effect on performance/ memory if my web.config is really
Input textfield in AIR for iOS looks really ugly when it does not have
In a .f file there is code that does this: real Bob, avar ...
iPhone Safari seems to have some sort of problem whereby a page with css
I have a shopping cart flow like this: Page 1 . Choose Products Page

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.