Random Child

by Mike Branski

This jQuery plugin shows a random child of the selector. To use this plugin, include jquery.randomchild.js and call the randomChild() method.

Usage

<script type="text/javascript">
  $(document).ready(function(){
    $('.random').randomChild();
  });
</script>

Example

The follow list contains 10 items, but only one item is visible at a time. Try refreshing the page to see them change.

Note: The selector does not have to be a list! This should work on any element with children.

Suggestions

The follow is a list of features I plan to add.