У меня есть ретранслятор, который имеет UserControl внутри него, который показывает мне 3 вопрос безопасности, как это:Получения ребенка ввода от сНа JQuery
<asp:Repeater runat="server" ID="rptSecurityQuestions">
<ItemTemplate>
<it:TextBoxControl_v2
ID="txtQuestion"
runat="server"
ShowLabel="true"
MinLength="1"
MaxLength="64"
Label='<%# DataBinder.Eval (Container.DataItem, "question") %>'
RegexExpression=""
TextMode="SingleLine"
CssClass="field field-padding-r metro col-centered securityQuestions"
IsRequired="true" />
</ItemTemplate>
</asp:Repeater>
И это показывает, как это 3 раза:
<div class="securityQuestions">
<span>Question 1</span>
<input></input>
</div>
все, что я хочу, это получить входные данные, которые являются дочерними элементами моего div.
Я пробовал что-то вроде этого, но это не сработало.
$(this).children('securityQuestions').addClass('hover_triangle');
Что такое 'this'? – Rayon
Вы можете попробовать: '$ ('. SecurityQuestions'). Find ('input'). AddClass ('hover_triangle');' – Rayon