Overslaan naar inhoud
Menu
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Deze vraag is gerapporteerd
1 Beantwoorden
2942 Weergaven

I've got a problem in the widget when I defined the selector so the events are only called by children from selector element.

How can I search for elements (children) in the selector (parent element)? The selector is the ID of a form. Now I want to find all elements with specific class or all input elements.

    selector: '#ec_energy_input_form',

$(this).find('.form_control') gives me only undefined. 

 

Avatar
Annuleer
Beste antwoord

Hi,

To get the child element of the selector you can try 

this.$el.find('child_selector')

Example: 

this.$el.find('.form_control')

Regards

Avatar
Annuleer
Gerelateerde posts Antwoorden Weergaven Activiteit
1
mei 23
5853
0
jul. 21
4053
0
jun. 21
4170
0
mei 23
3082
1
jan. 23
7886