Selecting Elements

From rbachwiki
Revision as of 23:40, 24 December 2016 by Bacchas (talk | contribs) (Created page with "=Selecting DOM Elements= $('#idname') $('.className') '''Find any a tags contained within the selected tag''' $('#idname').find('a') '''Find Children of tag''' $('#idnam...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Selecting DOM Elements

$('#idname')
$('.className')

Find any a tags contained within the selected tag

$('#idname').find('a')

Find Children of tag

$('#idname').children()
$('#idname').children('h2')

Select Parents

$('#idname').parents()

Siblings

$('#idname').siblings()