2013-10-08 2 views
1

atooltip을 클릭 해 툴팁을 클릭 할 수 있으며 내용물로 jQuery UI Multiselector을 설정할 수있었습니다.jQuery 클릭 가능한 도구 설명 내의 다중 선택 위젯

 jQuery1_9('.fixedHeader tr').first().find('th').first().aToolTip({ 
      clickIt: true, 
      tipContent: '<select class="test" multiple="multiple">' + 
         '<option>Test1</option>' + 
         '<option>Hello</option>' + 
         '<option>1F</option>' + 
         '</select>', 
      onShow: function() { 
      jQuery1_9(".test").multiselect(); 
      } 
     }); 

그러나 툴팁은 항상 내용을 생성하고 파기하므로 다중 선택기 상태는 저장되지 않습니다.

나는 지속적이고 상호 작용적인 HTML 콘텐츠가 포함 된 툴팁과 같은 기능을 갖춘 솔루션을 찾고 있습니다.

팝업 대화 상자는 옵션이 아닙니다.

답변

0

qTip2을 사용하여 문제를 해결했습니다.

<select class="test" multiple="multiple"> 
    <option>Test1</option> 
    <option>Hello</option> 
    <option>1F</option> 
</select> 

내가 다음 다중 선택 작업을 호출하고 모든 것을 숨길 : 나는 다음을 사용 multiselector 위젯을 포함 qTip를 들어

$(".test").multiselect() 
    $('.ui-multiselect').hide(); 
    $('.ui-multiselect-close').hide(); // the default close-button is not wanted 

나는이 숨겨진 선택기를 만드는거야 다음 옵션 :

$('.selector').qtip({ 
     content: { 
      text: $(".test").multiselect("widget"), // display the widget 
      button: 'Close' 
     }, 
     position: { 
      my: 'top center', 
      at: 'bottom center' 
     }, 
     hide: { 
      event: false 
     }, 
     show: { 
      event: 'click' 
     } 
    }); 

결과는 대화 형, 소형, d jQuery UI Multiselector가 들어있는 툴팁 형 윈도우. 죄송합니다. 아직 이미지를 게시 할 수 없습니다.