Skip navigation
Currently Being Moderated

CollapsiblePanel inside DataSet

Jun 17, 2008 3:09 AM

It looks not so difficult, but I'm trying many times but can't work.
My code is like...

<div spry:region="dsItems1 dsToppings">
<div spry:repeat="dsItems1">
<div spry:repeat="dsToppings">
<div id="CollapsiblePanel1" class="CollapsiblePanel">
<div class="CollapsiblePanelTab" tabindex="0">MoreInfo</div>
<div class="CollapsiblePanelContent">{dsToppings::moreinfo}</div>

<script type="text/javascript">
var CollapsiblePanel1 = new Spry.Widget.CollapsiblePanel("CollapsiblePanel1");

Please teach me how should I do.
Thanks in advance,
  • Currently Being Moderated
    Jun 17, 2008 8:45 AM   in reply to sakizo
    I could be wrong but what it looks like to me is that you are repeating the CollapsiblePanel1 over and over again if you changed the name to be unique I think that should solve your problem. So maybe do

    <div id="CollapsiblePanel{ID}" class="CollapsiblePanel">

    or something like that.
    Mark as:
  • Currently Being Moderated
    Jun 18, 2008 9:35 AM   in reply to sakizo
    Hi sakizo,

    Take a look at this accordion (from data) sample. The principles are the same for all our widgets that folks try to create with regions and data sets.

    Basically, you need to choose a way to fire off your widget constructor *AFTER* Spry has processed the region. ple2.html

    --== Kin ==--
    Mark as:
  • Currently Being Moderated
    Aug 4, 2012 9:01 PM   in reply to sakizo

    For everybody reference:



    <div spry:region="GetGroupNews">

      <div spry:repeat="GetGroupNews">

        <div id="{GroupNews_ID}" class="CollapsiblePanel">

          <div class="CollapsiblePanelTab" tabindex="0">Tab:{GroupNews_Title}</div>

          <div class="CollapsiblePanelContent">{GroupNews_Content}</div>


        <script type="text/javascript">

    var GroupNews_ID = new Spry.Widget.CollapsiblePanel("{GroupNews_ID}");








    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points