Category: 

What Is a JavaScript® Slideshow?

JavaScript slideshows allow two or more images to show up as a slideshow.
JavaScript is commonly used to make slideshows that use both photos and text.
Article Details
  • Written By: Alex Newth
  • Edited By: Angela B.
  • Last Modified Date: 15 September 2014
  • Copyright Protected:
    2003-2014
    Conjecture Corporation
  • Print this Article
Free Widgets for your Site/Blog
The seahorse is among the only animals on Earth which has males bear the young.  more...

September 30 ,  1949 :  The Berlin Air Lift ended.  more...

A JavaScript® slideshow, also known as a carousel or slider, is a script made from JavaScript® that allows two or more images to show up as a slideshow. Different implementation types allow the programmer to make a different JavaScript® slideshow based on his or her preferences. The main reason to use a JavaScript® slider is because it adds to the website and allows the user to see and scroll through many images without taking up much website space.

The JavaScript® slideshow begins, typically, as a list of image arrays. This tells JavaScript® to display an image; a few basic functions are added to the script that tells JavaScript® to move its focus from one image to the next. The programmer either can set the images in a linear list or can tell JavaScript® to display the images randomly. Along with this list, another common function added to the slideshow is a time function, so the images will move after a certain amount of time.

Some JavaScript® slideshow presentations may also include functions for the user, but this is not always the case. Such functions allow the user to control the slideshow. Common functions are a stop and play button, a next button, and the ability to move to the last image. Some slideshows may also display thumbnails of the other images along the edge or under the main displayed image, so the user can click the thumbnail and expand that specific image.

Ad

Aside from just showing images, a JavaScript® slideshow can also have special effects added to it. This allows the programmer to make fading images, sliding images, or a variety of other effects. The JavaScript® carousel typically will only include images, because this is easier to code and takes much less memory. The programmer can choose to include other files, such as movies or audio files. Links can also be added to the files in the slideshow, so if someone clicks the file, he or she will be directed to a website.

While JavaScript® slideshows are impressive to look at and require a relatively small amount of code, they serve another important function. If a website gallery is made just to display images right next to each other, this takes up a lot of the website’s space and makes it hard to look at the images individually. A slideshow uses much less space and, because it is made to focus on one image at a time, makes it easier for the user to mentally digest the images.

Ad

More from Wisegeek

You might also Like

Discuss this Article

Post your comments

Post Anonymously

Login

username
password
forgot password?

Register

username
password
confirm
email