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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T20:44:30+00:00 2026-05-25T20:44:30+00:00

How to create div with id=test with 100% height? <div data-role=page id=device1> <div data-role=header>

  • 0

How to create div with id=test with 100% height?

<div data-role="page" id="device1">
    <div data-role="header">
        <h1>Title</h1>
    </div><!-- /header -->
    <div data-role="content">
      <div data-role="fieldcontain">
        <input type="range" name="slider1" id="slider1" value="0" min="0" max="255"  />
      </div>
      <div id=test height=100%>
      </div>    
    </div><!-- /content -->
<div data-role="footer" data-position="fixed">
    </div><!-- /footer -->
</div><!-- /page -->
  • 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-25T20:44:30+00:00Added an answer on May 25, 2026 at 8:44 pm

    OK, here is what I have for you. Keep in mind though, if the content of the page is tall at all this might not be very usable. The swipe area is everything below the content. So as the content area gets bigger the swipe area gets smaller.

    <!DOCTYPE html> 
    <html>
    <head>
        <meta charset="UTF-8">
        <title>jQuery Swipe</title>
    
        <link href="jquery-mobile/jquery.mobile-1.0b3.min.css" rel="stylesheet" type="text/css"/>
        <script src="jquery-mobile/jquery.min.js" type="text/javascript"></script>
        <script src="jquery-mobile/jquery.mobile-1.0b3.min.js" type="text/javascript"></script>
    
        <script src="phonegap.js" type="text/javascript"></script>
    
        <script>
            $(document).ready(function() {
    
                // Set the initial window (assuming it will always be #1
                window.now = 1;
    
                //get an Array of all of the pages and count
                windowMax = $('div[data-role="page"]').length; 
    
               $('.swipeArea').bind('swipeleft', turnPage);
               $('.swipeArea').bind('swiperight', turnPageBack);
            });
    
            // Named handlers for binding page turn controls
            function turnPage(){
                // Check to see if we are already at the highest numbers page            
                if (window.now < windowMax) {
                    window.now++
                    $.mobile.changePage("#device"+window.now, "slide", false, true);
                }
            }
    
            function turnPageBack(){
                // Check to see if we are already at the lowest numbered page
                if (window.now != 1) {
                    window.now--;
                    $.mobile.changePage("#device"+window.now, "slide", true, true);
                }
            }
            </script> 
    
            <style>
                body, div[data-role="page"], div[data-role="content"], .swipeArea {
                    height: 100%;
                    width: 100%;
                }
        </style>
    </head> 
    <body> 
    
    <div data-role="page" id="device1"">
        <div data-role="header">
            <h1>Page One</h1>
        </div>
        <div data-role="content">   
            Content 
            <div class=swipeArea></div>
        </div>
    
        <div data-role="footer" data-position="fixed">
            <h4>Page Footer</h4>
        </div>
    </div>
    
    <div data-role="page" id="device2" style="height: 100%">
        <div data-role="header">
            <h1>Content 2</h1>
        </div>
        <div data-role="content" style="height: 100%">  
            Content     
            <div data-role="fieldcontain">
                <label for="slider">Input slider:</label>
                <input type="range" name="slider" id="slider" value="0" min="0" max="100"  />
            </div>
            <div class=swipeArea></div>
        </div>
        <div data-role="footer"  data-position="fixed">
            <h4>Page Footer</h4>
        </div>
    </div>
    
    <div data-role="page" id="device3" style="height: 100%">
        <div data-role="header">
            <h1>Content 3</h1>
        </div>
        <div data-role="content" style="height: 100%">  
            Content     
            <div class=swipeArea></div>
        </div>
        <div data-role="footer"  data-position="fixed">
            <h4>Page Footer</h4>
        </div>
    </div>
    
    <div data-role="page" id="device4" style="height: 100%">
        <div data-role="header">
            <h1>Content 4</h1>
        </div>
        <div data-role="content" style="height: 100%">  
            Content     
            <div class=swipeArea></div>
        </div>
        <div data-role="footer"  data-position="fixed">
            <h4>Page Footer</h4>
        </div>
    </div>
    
    </body>
    </html>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to create a page that takes 100% of the height of the
I'm gonna create two div tags with CSS that appear in the page like
I am trying to create a grid like system with div's with content floated
I have following HTML code: <div id=wrapper> <div class=page id=first> Test<br/> Test<br/> Test<br/> Test<br/>
I have a menu bar and I want to create a div for each
I have code to create another row (div with inputs) on a button click.
Is it possible to create a footer div that sits at the bottom of
I'm trying to create a new div each time a text field contained in
I have a script that create a new div element. Then, I want to
i want to create a new '.b' div appendTo document.body, and it can dragable

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.