Re: Applying a function to multiple ids

Amiri
Thu, 03 Jul 2008 21:51:21 -0000

On Jul 3, 3:27 pm, kangax <kan...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:
> 1) Simply get all tables (if those that you need are the only ones on
> the page):
>     $$(''table'');
>
> 2) Assign a unique class to all of the tables, then do:
>     $$(''table.myUniqueClassName'');
>
> 3) Specify id''s directly in selector expression (if the amount of
> tables is not too high):
>     $$(''table#foo, table#bar, table#baz'');
>
> 4) Get all tables with id attribute:
>     $$(''table[id]'');
>


I think 3 is what I need. That will most directly enable me to control
explicitly which tables the function gets applied to. I don''t like the
"grab em all and winnow them" approaches. Thank you, kangax!

Amiri