title: Scrolling problems on a web page with fixed header and footer in iOS7
body: <p>This will be difficult for me to explain, but I'll try:
  As a start, my web page is working on mobilebrowser in iOS6.x, Android, W7 and desktop browser IE9, Safari and Chrome. The problem happens in Apple's mobile Safari browser in iOS7. I had a problem with a sticky footer and the virtual keyboard, but that got solved <a href="https://stackoverflow.com/questions/18977540/div-element-wont-stay-at-the-bottom-when-ios-7-virtual-keyboard-is-present">here</a></p>
  
  <p>Now I've a problem when scrolling on the page. When scrolling down, normally the navigation bar will hide and the address bar will shrink on iOS7. This doesn't happens. The content between the fixed header and footer is scrolling, but the bottom of the content is overlapped by the footer and navigation bar. I've to wait for the scrolling to stop before I can scroll down again. Then the address bar will shrink, the nav bar will hide and the bottom content will show. When I'm at the bottom of my page and want to scroll back up, the same thing happens, just upwards: Scrolling to the top, the header and the tiny address bar overlaps the upper content, wait for the scrolling to stop, then scroll again to have the address bar expand, the nav bar to show and the upper content to show.
  Hope this image can help:</p>
  
  <p><img src="https://i.stack.imgur.com/RoGuX.png" alt="Scenario"></p>
  
  <p>Here are some of the css code:</p>
  
  <pre><code>* 
  {
      margin: 0; padding: 0;
      -webkit-tap-highlight-color: rgba(0,0,0,0);
  }
  
  html, body {
     height: 100%;
     margin: 0;
  }
  body{
      font-family: Helvetica, Segoe UI, Arial, Sans-Serif; 
      font-size: 130%;
  
      background-image: url('../images/background.png');
      background-repeat:repeat;
  
      overflow:hidden;    
  }
  
  #header
  {
      text-align: center;
      color:#FFF;
  
      height: 45px;               
      position:fixed;
      z-index:5;
      top:0px;
      width:100%;
  
      top:0; left:0;
      padding:0;
  
      background-color:#2785c7; /* Old browsers */    
      background:    -moz-linear-gradient(top, #206493, #2375ae, #2785c7 85%); /* FF3.6+ */    
      background: -webkit-linear-gradient(top, #206493, #2375ae, #2785c7 85%); /* Chrome10+,Safari5.1+ */
      background:      -o-linear-gradient(top, #206493, #2375ae, #2785c7 85%); /* Opera 11.10+ */
      background:     -ms-linear-gradient(top, #206493, #2375ae, #2785c7 85%); /* IE10+ */
      background:         linear-gradient(top, #206493, #2375ae, #2785c7 85%); /* W3C */
      background: -webkit-gradient(linear, left top, left bottom, from(#206493), to(#2375ae), color-stop(85%, #2785c7)); /* Chrome,Safari4+ */
      filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#206493', endColorstr='#2785c7',GradientType=0 ); /* IE6-9 */
  }
  
  #footer{
      color:#CCC;
      height: 48px;
  
      position:fixed;
      z-index:5;
      bottom:0px;
      width:100%;
      padding-left:2px;
      padding-right:2px;
      padding:0;
  
      border-top:1px solid #444;
  
      background:#222; /* Old browsers */
      background:-webkit-gradient(linear, 0 0, 0 100%, color-stop(0, #999), color-stop(0.02, #666), color-stop(1, #222));  
      background:    -moz-linear-gradient(top, #999, #666 2%, #222); /* FF3.6+ */    
      background: -webkit-linear-gradient(top, #999, #666 2%, #222); /* Chrome10+,Safari5.1+ */
      background:      -o-linear-gradient(top, #999, #666 2%, #222); /* Opera 11.10+ */
      background:     -ms-linear-gradient(top, #999, #666 2%, #222); /* IE10+ */
      background:         linear-gradient(top, #999, #666 2%, #222); /* W3C */
  }
  
  #footer &gt; div
  {
      height:48px; width:52px;
      color:#AAACAF;
      text-align:center;
      font-size:0.55em;
  
      display:inline-block;
      cursor:pointer;
  }
  @media screen and (max-width: 350px)    /* Mindre skift på mobil enheder  */
  {
      #footer &gt; div
      {
          width:48px;
          font-size:0.40em;
      }
  }
  
  #scroller
  {
  /*    min-height: 360px;*/
      padding-top:45px;
      padding-bottom:48px;
      overflow:hidden;
  
      width:100%;
  }
  </code></pre>
  
  <p>And here are some of the HTML:</p>
  
  <pre><code>&lt;html&gt;
      &lt;head&gt;
          &lt;title&gt;Title&lt;/title&gt;
  
          &lt;meta http-equiv="Content-Type" content="text/html; charset=utf-8" /&gt;
          &lt;meta name="viewport" content="initial-scale=1.0, user-scalable=0, width=device-width, height=device-height"/&gt;
          &lt;meta name="apple-mobile-web-app-capable" content="yes" /&gt;
          &lt;meta name="apple-mobile-web-app-status-bar-style" content="black" /&gt;
          &lt;link rel="apple-touch-icon" href="images/name.png" /&gt;
          &lt;link rel="apple-touch-startup-image" href="images/startup.png" /&gt;
          &lt;link rel="shortcut icon" href="/images/name.ico" /&gt;
  
          &lt;link href="css/style.css?square=#VERSION" rel="stylesheet" type="text/css" /&gt;
          &lt;script src="js/jquery-1.6.4.min.js?square=#VERSION" type="text/javascript"&gt;&lt;/script&gt;
          &lt;script src="js/jquery.placeholder.js?square=#VERSION" type="text/javascript"&gt;&lt;/script&gt;
          &lt;script src="js/javascript.js?square=#VERSION" type="text/javascript"&gt;&lt;/script&gt;
          &lt;script src="js/divScroll.js?square=#VERSION" type="text/javascript"&gt;&lt;/script&gt;
  
          &lt;script&gt;
              $(function() {
                  $('input[placeholder], textarea[placeholder]').placeholder();
              });
          &lt;/script&gt;        
      &lt;/head&gt;
      &lt;body&gt;    
          &lt;form id="Form1" runat="server"&gt;
              &lt;div id="header" style="line-height:45px;" runat="server"&gt;
                  Name
              &lt;/div&gt;
              &lt;div id="scroller" &gt;
                  &lt;div id="content"&gt;
                  ...
                  ...
                  ...
              &lt;/div&gt;
              &lt;div id="footer" style="text-align:center"&gt;
                  &lt;div id="LoginNameLogoDiv"&gt;&lt;img alt="Company" src="images/company_logo.png" /&gt;&lt;/div&gt;
              &lt;/div&gt;
          &lt;/form&gt;
      &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>