title: How To Disable Ajax In jQuery Mobile Before Page Load?
body: <p>On my mobile website. I've been trying to load Adsense Mobile ads, but they continue to take up the entire page after the page loads itself.</p>
  
  <p>I did figure out that if I disable ajax the page would load fine with the ad together. This only works on the second page I load because I click a link with the tag...</p>
  
  <pre><code>data-ajax="false"
  </code></pre>
  
  <p>Which makes the next page load perfectly.</p>
  
  <p><strong>Problem</strong>: The first page loaded will be overwritten by the adsense ad because ajax is enabled (I think).</p>
  
  <p>Basically the first part of my page looks like this...</p>
  
  <pre><code>&lt;html&gt;
  &lt;head&gt;
  
  &lt;link rel="stylesheet" href="http://code.jquery.com/mobile/1.0rc3/jquery.mobile-1.0rc3.min.css" /&gt;
  &lt;script src="http://code.jquery.com/jquery-1.6.4.min.js"&gt;&lt;/script&gt;
  &lt;script src="http://code.jquery.com/mobile/1.0rc3/jquery.mobile-1.0rc3.min.js"&gt;&lt;/script&gt;
  &lt;script language="text/javascript"&gt;
  
        $(document).bind("mobileinit", function () {
  
              $.mobile.ajaxEnabled = false;
  
        });
  
  &lt;/script&gt;
  &lt;/head&gt;
  &lt;body&gt;
  
      &lt;div data-role="header"&gt;
          &lt;h1&gt;Angry Birds Cheats&lt;/h1&gt;
      &lt;/div&gt;
  
  
  
      &lt;div data-role="content"&gt;
  
  &lt;div&gt;
      &lt;script type="text/javascript"&gt;&lt;!--
    // XHTML should not attempt to parse these strings, declare them CDATA.
    /* &lt;![CDATA[ */
    window.googleAfmcRequest = {
      client: '',
      format: '',
      output: '',
      slotname: '',
    };
    /* ]]&gt; */
  //--&gt;&lt;/script&gt;
  &lt;script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_afmc_ads.js"&gt;&lt;/script&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>I did try to disable ajax in the code, but I don't think it is because the ad still takes up the entire page...</p>
  
  <p>I was thinking that maybe I could start the visitor at a certain page and redirect them to a page that is non-ajax.</p>