Thursday, January 29, 2009

[jQuery] Re: complex selector question

$("select[name^='test']")

Straight from the docs:

http://docs.jquery.com/Selectors/attributeStartsWith#attributevalue


On Jan 29, 7:12 am, Trend-King <i...@trend-king.de> wrote:
> Hi there i want to get all select elements on a page with name=test
> [1],name=test[2]...
>
> is there a way to specify a placeholder in the selector?
>
> i think about
>
> $('select[name=id[*]]').each(function(){
> alert($(this).html())
>
> });
>
> is there any possibility for that?
>
> thanks for your replies

No comments: