Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
1 Odpowiedz
2903 Widoki

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. 

 

Awatar
Odrzuć
Najlepsza odpowiedź

Hi,

To get the child element of the selector you can try 

this.$el.find('child_selector')

Example: 

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

Regards

Awatar
Odrzuć
Powiązane posty Odpowiedzi Widoki Czynność
1
maj 23
5802
0
lip 21
4019
0
cze 21
4124
0
maj 23
3022
1
sty 23
7832