Hiding multiple id's [element.hide]

I’m looking at this changeset http://dev.rubyonrails.org/changeset/5057
and I’m running edge revision 5196 so I’m assuming multiple id’s on
element.hide would work.
I’m getting parse errors though

(“Toggle Info”, :after => “Element.hide(“basic”,“intermediate”)”)

Multiple ids do not work with the latest prototype anymore.

On 11/22/06, krunk- [email protected] wrote:

Multiple ids do not work with the latest prototype anymore.

So what is on the Scriptaculous site about multiple id’s is no longer
valid
?
Weird.

Stuart

Also, right now I’ve created 5 divs , each one with STYLE=“display:
none;”
Then I have 5 seperate link_to_remotes with :after => Element.show
(‘somediv’)
However , what I can’t seem to figure out is what one element is showing
and
another is clicked
then 2 divs are showing.
I would like 1 div at a time, where the first one goes away when the
second
is clicked ?
Is there a way to do this ?

Stuart
On 11/22/06, Dark A. [email protected] wrote:

So what is on the Scriptaculous site about multiple id’s is no longer
valid ?
Weird.

Stuart

On 11/22/06, Maxim K. [email protected] wrote:

then 2 divs are showing.
I would like 1 div at a time, where the first one goes away when the
second
is clicked ?
Is there a way to do this ?
You can Element.hide each of 5 divs before Element.show’ing the next one.

Okay, that encouraging, and how would I do this ?

Stuart

On 11/22/06, Dark A. [email protected] wrote:

Also, right now I’ve created 5 divs , each one with STYLE=“display: none;”
Then I have 5 seperate link_to_remotes with :after =>
Element.show(‘somediv’)
However , what I can’t seem to figure out is what one element is showing and
another is clicked
then 2 divs are showing.
I would like 1 div at a time, where the first one goes away when the second
is clicked ?
Is there a way to do this ?
You can Element.hide each of 5 divs before Element.show’ing the next
one.

On 23 November 2006 05:46, Dark A. wrote:

You can Element.hide each of 5 divs before Element.show’ing the next one.
Okay, that encouraging, and how would I do this ?
Element.hide(‘div1’);
Element.hide(‘div2’);
Element.hide(‘div3’);
Element.hide(‘div4’);
Element.hide(‘div5’);
Element.show(‘div3’);

or equal in RJS:

[‘div1’, ‘div2’, ‘div3’, ‘div4’, ‘div5’].each do |element_id
page.hide element_id
end
page.show @next_element_id

On 11/23/06, Maxim K. [email protected] wrote:

Element.hide(‘div5’);
Element.show(‘div3’);

Using the above -
<%= link_to_remote (“Basic Info”,
Element.hide
(‘canbckground’);
Element.hide
(‘canposition’);
Element.hide(‘canskill’);

Element.show(‘basicinfo’);%>

Getting this error:

SyntaxError in Candidates#show

Showing app/views/candidates/show.rhtml where line #3 raised:

compile error
./script/…/config/…/app/views/candidates/show.rhtml:3: parse error,
unexpected ‘;’, expecting ‘)’

I tried a few different ways of writing it.
Any right way ?

TIA
Stuart