Animation FAQ

Frequently asked questions about the Animation CGI script.

Q1: How do I set up the animation script?

To set up the Animation script, follow these steps:

  1. Upload animation.pl to your cgi-bin directory
  2. Set permissions: chmod 755 animation.pl
  3. Create an images directory for your animation frames
  4. Configure the script variables:
    • $image_dir - path to your images
    • $delay - time between frames
  5. Add the animation to your page using SSI or direct call

Q2: Why isn't my animation displaying?

If your animation is not displaying, check the following:

  • File permissions: Ensure the script has execute permissions (755)
  • Image path: Verify the $image_dir path is correct
  • Image files: Check that image files exist and are readable
  • Server support: Confirm your server supports CGI scripts
  • Error logs: Check your server error logs for specific messages
Tip: Test the script directly by navigating to its URL to see any error messages.

Q3: How do I change the animation speed?

To change the animation speed, modify the $delay variable in the script:

$delay = 100;  # Time in milliseconds between frames

Common values:

  • 50 - Very fast animation
  • 100 - Normal speed
  • 250 - Slower animation
  • 500 - Half-second between frames
Note: Very fast animations may not work consistently across all browsers.

Q4: Can I use different image formats?

Yes, the Animation script supports multiple image formats:

FormatExtensionBest For
GIF.gifSimple graphics, transparency
JPEG.jpg, .jpegPhotographs, complex images
PNG.pngHigh quality, transparency
Recommendation: Use GIF or PNG for animations with solid colors, and JPEG for photographic content.

Q5: How do I add more frames to my animation?

To add more frames to your animation:

  1. Create your new frame images with consistent dimensions
  2. Name them sequentially (e.g., frame1.gif, frame2.gif, frame3.gif)
  3. Upload them to your image directory
  4. Update the @images array in the script:
    @images = ("frame1.gif", "frame2.gif", "frame3.gif", "frame4.gif");
Tip: Keep all frames the same size to prevent flickering or layout shifts during animation.
Back to FAQ