SHARE
TWEET

Untitled

a guest May 19th, 2017 39 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. pg = 1;
  2. ProxAnt = function(act){
  3.    if(act == "ant" && pg > 1){
  4.       pg--;
  5.        if(pg < 10){
  6.          pg = "0"+pg;
  7.       }
  8.       location.href = pg+".htm";
  9.    }
  10.    else
  11.    {
  12.     if(act == "prox" && pg < 4 /*coloca o numero de paginas no lugar do 4*/){
  13.         pg++;
  14.          if(pg < 10){
  15.             pg = "0"+pg;
  16.          }
  17.         location.href = pg+".htm";
  18.     }
  19.    }
  20. }
RAW Paste Data
Want to get better at JavaScript?
Learn to code JavaScript in 2017
Top