久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

如何使用可選擇的 Jquery UI 查找選定的元素

how to find selected elements with Jquery UI selectable(如何使用可選擇的 Jquery UI 查找選定的元素)
本文介紹了如何使用可選擇的 Jquery UI 查找選定的元素的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學(xué)習(xí)吧!

問題描述

我正在尋找有關(guān) jQuery 可選事件的事件和 ui 對象的信息:選擇"和開始"作為參數(shù).我在文檔中找不到這個,循環(huán)遍歷屬性也無濟(jì)于事.

I am looking for info on the event and ui objects the jQuery selectable events: "selecting", and "start" take as parameters. I cannot find this in the documentation and looping through the properties is no help.

$('#content_td_account').selectable({
    filter: 'li:not(".non_draggable")',
    selecting: function(event, ui) { 
    }
});

具體來說,我想找出正在選擇的元素并檢查它們以查看它們的父元素是否相同.我認(rèn)為這將在 ui 對象中的某個位置.

Specifically I want to find what elements are being selected and check them to see if their parent elements are the same or not. I assumed this would be in the ui object some where.

推薦答案

當(dāng)一個元素被選中時,它會添加 ui-selected 類.

When an element is selected it gets the ui-selected class added.

所以你可以使用 $(".ui-selected")

這可能不完全有效,但我認(rèn)為這個想法是這樣的:

This might not work exactly but I think the idea would be something like this:

$('#content_td_account').selectable({
  filter: 'li:not(".non_draggable")',
  selecting: function(event, ui) { 
    var p = $(this).parent();
    $(".ui-selected").each(obj, function() {
      if(obj.parent() == p) {
        // get rad
      }
    });
  }
});

這篇關(guān)于如何使用可選擇的 Jquery UI 查找選定的元素的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

【網(wǎng)站聲明】本站部分內(nèi)容來源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問題,如果有圖片或者內(nèi)容侵犯了您的權(quán)益,請聯(lián)系我們刪除處理,感謝您的支持!

相關(guān)文檔推薦

jQuery/JavaScript Library for avatar creation?(用于創(chuàng)建頭像的 jQuery/JavaScript 庫?)
How to do following mask input problem?(如何做以下掩碼輸入問題?)
Issues Setting Value/Label Using DropKick Javascript(使用 DropKick Javascript 設(shè)置值/標(biāo)簽的問題)
how to unit-test private methods in jquery plugins?(如何對 jquery 插件中的私有方法進(jìn)行單元測試?)
stellar.js - configuring offsets / aligning elements for a vertical scrolling website?(stellar.js - 為垂直滾動網(wǎng)站配置偏移量/對齊元素?)
jQuery masked input plugin. select all content when textbox receives focus(jQuery 屏蔽輸入插件.當(dāng)文本框獲得焦點時選擇所有內(nèi)容)
主站蜘蛛池模板: 日韩国产精品一区二区三区 | 午夜a√| 免费黄色大片 | 欧美亚洲一区二区三区 | 午夜精品一区二区三区在线 | 国产丝袜人妖cd露出 | 成人在线观看免费 | 午夜免费精品视频 | 99久久免费精品 | 国产精品a一区二区三区网址 | 一区二区三区四区在线 | 久久欧美精品 | 亚洲第1页 | 天天躁日日躁狠狠很躁 | se婷婷| 亚洲成人福利 | 午夜一区二区三区在线观看 | 国产精品欧美一区二区三区 | 欧美bondage紧缚视频 | 精品综合视频 | 欧美视频三区 | 久久午夜电影 | 成人h片在线观看 | 成在线人视频免费视频 | 成人乱人乱一区二区三区软件 | 宅女噜噜66国产精品观看免费 | 日韩精品av一区二区三区 | 亚洲精品18 | 黄色片在线免费看 | 日本人做爰大片免费观看一老师 | 精品一区二区三区免费毛片 | 99久久精品免费看国产小宝寻花 | 欧美精品欧美精品系列 | 日本aa毛片a级毛片免费观看 | 美女福利网站 | 亚洲区一区二区 | 免费观看av网站 | 日本高清中文字幕 | 亚洲精品粉嫩美女一区 | 欧美成人a∨高清免费观看 色999日韩 | 久久av一区二区三区 |