Time for action – creating an animated content viewer

We'll start again by adding the underlying markup and styling.

  1. The underlying markup for the content viewer should be as follows:
    <div id="slider"> <div id="viewer"> <img id="image1" src="img/amstrad.jpg" alt="Amstrad CPC 472"> <img id="image2" src="img/atari.jpg" alt="Atari TT030"> <img id="image3" src="img/commodore16.jpg" alt="Commodore 64"> <img id="image4" src="img/commodore128.jpg" alt="Commodore 128"> <img id="image5" src="img/spectrum.jpg" alt="Sinclair ZX Spectrum +2"> </div> <ul id="ui"> <li class="hidden" id="prev"><a href="" title="Previous">&laquo;</a></li> <li><a href="#image1" title="Image 1" class="active">Image 1</a></li> <li><a href="#image2" title="Image 2">Image 2</a></li> ...

Get jQuery 1.4 Animation Techniques Beginner's Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.