2013-11-28 2 views
0

검색 및 끈적한 표 머리글 정렬 테이블이 있습니다. 내가 직면 한 첫 번째 문제는 헤더를 테이블에 붙일 수 없다는 것입니다. 스크롤하면 창이 고정됩니다. 두 번째로 테이블 너비와 높이의 크기를 조정할 수 없습니다. div 태그 안에 보관하면 끈적한 헤더가 작동하지 않습니다.끈적 헤더가 있고 정렬 및 검색하는 테이블 크기를 수정하는 방법은 무엇입니까?

달성 방법을 알려주세요.

<script id="js">$(function(){ 
    $("table").tablesorter({ 
     widthFixed : true, 
     showProcessing: true, 
     headerTemplate : '{content} {icon}', 
     // Add icon for jui theme; new in v2.7! 
     widgets: [ 'uitheme', 'zebra', 'stickyHeaders', 'filter' ], 
     widgetOptions: { 
      // extra css class name applied to the sticky header row (tr) - changed in v2.11 
      stickyHeaders : '', 
      // adding zebra striping, using content and default styles - the ui css removes the background from default 
      // even and odd class names included for this demo to allow switching themes 
      zebra : ["ui-widget-content even", "ui-state-default odd"], 
      // use uitheme widget to apply defauly jquery ui (jui) class names 
      // see the uitheme demo for more details on how to change the class names 
      uitheme : 'jui' 
     } 
    }); 

});</script> 

는 CSS를위한 JS 파일 내가 jsfiddle에서했던 한 것과 동일 할

<script src="js/jquery.tablesorter.widgets.js"></script> 
+0

stickyHeaders 위젯은 현재 상위 요소에 "고정"할 수 없습니다. 브라우저 창에만 붙어 있습니다. 이미 공개 된 [미해결 문제] (https://github.com/Mottie/tablesorter/issues/295)가 있습니다. 아직 익숙하지 않았습니다. – Mottie

+0

답변을위한 Thnaks ... 솔루션이 나오면 공유하십시오 .. – SUDARSHAN

답변

0

시도입니다 :

[http://jsfiddle.net/Ziad/2EZjJ/][1] 
+0

이 링크는 작동하지 않습니다 .. – SUDARSHAN

0

가 지금 css sticky header widget이지만,이 아직 베타 테스트 중입니다.

위에서 공유 한 버전은 끈적한 헤더를 부모에게 부착 할 수 없지만이 기능이있는 demo in the works입니다 (업데이트는 this issue 참조). 극복해야 할 마지막 문제는 Firefox에서 캡션이 제대로 고정되도록하는 것입니다 (cssStickyHeaders_addCaption 옵션).

$(function() { 

    $("table").tablesorter({ 
     widgets: ['cssStickyHeaders'], 
     widgetOptions: { 
      cssStickyHeaders_offset: 0, 
      cssStickyHeaders_addCaption: true, 
      cssStickyHeaders_attachTo: null 
     } 
    }); 

}); 

나는 국경이 끈적 세포와 함께 머물하지 외에, 해결해야 할 다른 문제를 찾는 데 도움을 주셔서 감사합니다 것입니다 (LOL, 그 문제를 해결하는 방법을 몰라).