hmt.js 408 B

123456789101112131415
  1. // JavaScript Document
  2. $(function(){
  3. //计算内容上下padding
  4. reContPadding({main:"#main",header:"#header",footer:"#footer"});
  5. function reContPadding(o){
  6. var main = o.main || "#main",
  7. header = o.header || null,
  8. footer = o.footer || null;
  9. var cont_pt = $(header).outerHeight(true),
  10. cont_pb = $(footer).outerHeight(true);
  11. $(main).css({paddingTop:cont_pt,paddingBottom:cont_pb});
  12. }
  13. });