The Ani(mation)S applet

Page 5 - The toggle buttons, bottom controls, frame labels, and number of frames choicebox

5. You may also want to add toggle controls so that the user can remove frames if they want. This is done by adding the name toggle to the list of controls. But that's too easy! Let's we also want to put the toggle controls below the image and add a label for each frame. So, we'll need to specify the controls like this:

<PARAM name="controls" value="startstop, overlay, framelabel"> <PARAM name="bottom_controls" value="toggle"> and then a PARAM for the frame_labels themselves: <PARAM name="frame_label" value=" Aug 3 12:15pm CDT, Aug 3 1:15pm, Aug 3 2:15pm, Aug 3 3:15pm">

You can also give your users the option to only initially load a subset of the total frames you have. First, let's add the numframeschoide control:

<PARAM name="controls" value="startstop, overlay, ,numframeschoice, framelabel"> And then let's add these parameters: <PARAM name="num_frames_choice" value="-2, -3, -*2, all"> <PARAM name="default_num_frames_choice" value="1">

Finally, so you can more easily see the effect of the frame choices, we'll modify the toggle control to the special value toggle/showall, although this is not required nor really recommended.

This initially shows the user the last two frames, and then gives them a choice of either the last 3 frames, 2 equally-spaced frames, or all four. Here's the modified example:


Go to next page

AniS Home Page

If you would like more information, or have questions or suggestions, please contact Tom Whittaker