Content behind header, after create dinamically a page (.trigger('create').)

Content behind header, after create dinamically a page (.trigger('create').)

Hi guys,

I have problems when i create a page using .trigger("create").

well,

When i change the page, i do a loading data, and i do a refresh in page.

But the problem is, sometimes the content stay behind the fixed header.

What is the correct way to use page.trigger("create")?

look my code:

  1. app.pages.to("#info_establishment");
  2. $("#info_establishment").html(EstablishmentView.info_template({establishment: establishment, backParams: backParams})); // using handlebars to render the things
  3. app.renderPanels(); // how i do full a refresh in page, i need reconstruct the panel.
  4. $("#info_establishment").trigger('create');
I need do anymore than use only .trigger("create")?

EDIT: Annexed a screenshot

EDIT: Sample page:

  1. <script id="lst_segments_tpl" type="text/x-handlebars-template">
  2.       <div data-role="header" class="put-panel" data-position="fixed" data-tap-toggle="false">
  3.         <h1>Segmentos</h1>
  4.         <a href="#nav-panel" class="btn-panel" data-icon="bars">Menu</a>
  5.         <a data-icon="back" class="cz-back ui-btn-right">Voltar</a>
  6.       </div>
  7.       <div role="main" class="ui-content jqm-content jqm-fullwidth">
  8.         <div id="list-wrap">
  9.           <ul id="ul-segments" data-inset="true" data-role="listview" class="ui-listview"></ul>
  10.         </div>
  11.       </div>
  12.     </script>
  13.     
  14.     <script id="li_segments_tpl" type="text/x-handlebars-template">
  15.       {{#.}}
  16.       <li data-id="{{_id}}">
  17.         <a class="vclick" href="#list_establishment/{{_id}}">
  18.           {{public_name}}
  19.         </a>
  20.       </li>
  21.       {{/.}}
  22.     </script>
OBS: I create the markup page via javascript because i need a wrap to render tpl handlebars, and append to body.

Refresh functions only rewrite html in id of page.

All my pages is in index.html. There is any problem?

EDIT: Using: jQuery mobile 1.4.2 jQuery v2.0.3 

sorry my english.

Thanks!