Toggle on Div in repeater

I have a toggleon/off div tag insode a repeater.

It works...but ONLY toggles the top "repeated" div.

Activater and action div both inside repeater

Toggle action.....
<a class="select" onclick="$('#toggleOn_details').hide(); $('#toggleOff_details').show(); $('#search_Details').slideToggle('slow');"
                                                                                                                    href="javascript:void(null);"><span style="font-size: 9pt;">Click Here to Show Rates</span>
Div being toggled
 <div class='toggleoff' id="toggleOff_details">
                                                                                        <a class="toggle_sign" onclick="$('#toggleOff_details').hide(); $('#toggleOn_details').show(); $('#search_Details').slideToggle('slow');"
                                                                                            href="javascript:void(null);">&nbsp;</a><a class="toggle" onclick="$('#toggleOff_details').hide(); $('#toggleOn_details').show(); $('#search_Details').slideToggle('slow');"
more code...

Open in new window

Who is Participating?
GuitarRichConnect With a Mentor Commented:
it looks to be because of the id of the DIV - if you have that in a repeater your going to have multiple DIV elements with the same ID - you will need to give each div element a unique ID and also make sure that the links to toggle on/off have the corresponding ID in the onclick events.
lrbristerAuthor Commented:
  Excellent...I assigned the containerid to it and worlks great.

Asking new question now...
lrbristerAuthor Commented:
Excellent...I assigned the containerid to it and worlks great.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.