A very lightweight presentation plugin for jQuery
Include script after the jQuery library (unless you are packaging scripts somehow else):
<script src="/path/to/jquery.clickthrough.js"></script>
Create a clickthrough presentation from a collection of HTML elements:
$('div.slide').clickthrough();
Be sure to include this after your HTML has rendered or inside a $(document).ready(){ ... } wrapper
Clicking on any slide will progress the slide show by either revealing the next list item or next slide depending on where you are in the presentation and whether or not you have set the option to control list items.
Options can be fed into the intitialisation of the plugin, this example shows all options being set:
$('div.slide').clickthrough(
'control_lis': true,
'slide_width': '600px',
'slide_height': '550px',
'back_button': true
);
control_lis : true
Define whether or not list items are to be revealed with each click,
slide_width: '600px'
Simple setting which defines in pixels, ems or percent how wide the wrapper element created by the plugin will be
slide_height: '550px'
Again, use pixels, ems or percent to define the height of the wrapper
back_button: true
Defines whether or not a back button will be present on screen to step back a whole slide, it will not step back through list items, just whole slides
- Source hosted at GitHub
- Report issues, questions, feature requests on GitHub Issues