2010-11-28 120 views
0

http://jqueryui.com/demos/autocomplete/#combobox这是什么JQuery脚本?

在右手边,有选择的选项卡(带有指向左边的箭头选择)

什么CSS菜单这是什么?为什么我无法在JQuery UI网站上找到它?

+0

这只是普通的HTML + CSS。不需要JavaScript/jquery。查看源代码,和/或使用浏览器的dom检查器。左指箭头只是一个背景图片,由css`a:hover`规则应用。 – Lee 2010-11-28 04:30:25

回答

0

这不是一个插件,它是一个简单的html/css/javascript位在页面上。

控制菜单的javascript在http://jqueryui.com/js/demos.js

的特定部分:

//Rewrite and prepare links of right-hand sub navigation 
    $('#demo-config-menu a').each(function() { 
     $(this).attr('target', 'demo-frame'); 
     $(this).click(function(e) { 

      resetDemos(); 
      $(this).parents('ul').find('li').removeClass('demo-config-on'); 
      $(this).parent().addClass('demo-config-on'); 

      //Set the hash to the actual page without ".html" 
      window.location.hash = this.getAttribute('href').match((/\/([^\/\\]+)\.html/))[1]; 

      loadDemo(this.getAttribute('href')); 
      e.preventDefault(); 

     }); 
    });