Not sure if [] is valid in a css class.  Why not use two classes?

<div class="MyClass Param">

$$('.MyClass.Param')

or

$$('.MyClass.' + someParam)

-Fred

On Fri, Jun 13, 2008 at 11:31 AM, AlannY <[EMAIL PROTECTED]> wrote:

>
> I have a DIV in the following format: <div class="MyClass[Param]">
>
> I want to parse it. Which approach is better? I can found all divs
> with $$('.MyClass'), but how to find [Param] string?
>
> Or, for me, it's better to use <div class="MyClass" id="Param"> and
> then found all $$('.MyClass').each(function(el) { el.id })?
>
> I think, the first method is better, than second one. But I don't know
> how to implement it with Prototype.
>
> Thank you.
>
> >
>


-- 
Science answers questions; philosophy questions answers.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Spinoffs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to