This is a step-by-step howto based on "Flooble's Expandable Content script".
It is mainly a copy & past of the resulting script to show you how you are able to use such a code for your own moslate.
(This means that I did not create any of the used JavaScript)
However, this is the logic-version of the previous howto. The benefit of this approach is a cleaner code because no php is used. (you will need moslate & logic 0.5+)