SORU
29 ŞUBAT 2012, ÇARŞAMBA


Jquery $jquery tüm öğeleri seçin.()veri

Daha önce jquery.data(); ayarlanmış olan öğeleri seçin

yani .data('myAttr') Tüm elemanları zaten ayarlanmış Seçin

ÇÖZÜM
Gösteri için bir jsfiddle http://jsfiddle.net/argiropoulostauros/xynZA/3/

CEVAP
29 ŞUBAT 2012, ÇARŞAMBA


Yapabilirsin

$('[data-myAttr!=""]'); 

bu eşit değil, bölgelere sahip olan tüm elemanları data-myAttr seçer " set olmalı ();

ayrıca filter() kullanabilirsiniz

$('*').filter(function() {
    return $(this).data('myAttr') !== undefined;
});

Bunu Paylaş:
  • Google+
  • E-Posta
Etiketler:

YORUMLAR

SPONSOR VİDEO

Rastgele Yazarlar

  • Official Android Tips

    Official And

    23 EYLÜL 2009
  • Alexey - servant of Christ

    Alexey - ser

    15 EYLÜL 2007
  • maxman.tv

    maxman.tv

    29 EKİM 2013