Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $(document).ready(function () {
- var index = 0
- $("div").not("#0, div:last-of-type").hide()
- $("#prev").click(function () {
- if(index>0){
- index--
- $("div").show().not("#"+index+", div:last-of-type").hide()
- }
- })
- $("#next").click(function () {
- if(index<3){
- index++
- $("div").hide()
- $("#"+index+", div:last-of-type").show()
- }
- })
- })
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement