In the sound of Doors music: "The End".
Let's make a resume of all this:
OBJECTIVE OF THIS "BIG" POST:
Make a show/hide details button inside a repeat region, so
when user click on that button the details of that specific record
inside the repeat region appear and disapear. (toggle).
WHAT WAS NOT WORKING?
1)
PROBLEM:
The effect (in the effects menu of dreamweaver) despite the
fact that we click on toggle option, he DON'T toggle at all.
SOLUTION:
There is know bug in Spry effects.js file. We need to update
the .js file so the .js can toggle.
Get it here:
http://www.cristic.ro/samples/SpryEffects.js
Thanks Marin.
2)
PROBLEM:
The effect only happens on the first record, nothing happens
on the other!
SOLUTION:
Sugestion from Joris:
Apply a php counter.
3)PROBLEM:
The initial state of the "details div" is SHOW but we need
them to be HIDE. (so the details show, only when user whats to see
them).
SOLUTION MISSED:
Apply a CSS like this:
<style type="text/css">
<!--
#div_name<?php echo $counter; ?> { display: none; }
-->
</style>
Why? (don't know, maybe because we can't apply a dynamic div
name inside a CSS or maybe because I don't know how to do it)
SOLUTION THAT WORK:
Suggested by Joris again:
Apply to eatch particular div that you want to hide (since we
have a repeat region it will be only one)
and apply at that div the style="display:none" property.
THANKS A LOT!!!!! JORIS!!! REALLY!!!!
Thanks for your time, your patience and, your lessons.
:)