Message # 1 | 5:18 AM
Hi my name is Adrian i'm from romania and I am wondering if it's posible to create a next page scrip from the page id's?
For example i have my main page and i want my sub pages from that page to have a next page button (ex. the range from page 0-91 to 0-103) and the script recognizes curent page id and when clicked redirect you to the next page id (from /0-91 to /0-92) so basically it ads +1 value to the current page id.
I think it can be done with a jQuery but i dont know how to program one.
someone can help me?

P.S. Sorry for my english! wacko

Added (2013-06-27, 11:18 PM)
---------------------------------------------
I resolved it paste this script in a informer template and it automaticaly ads +1 value to the page id

Code
<div id="pages"></div>  
  <script>  
  a=location.href;  
  b=a.split('-');  
  c=b.length;  
  d=eval(c-1);  
  e=b[d];  
  f=a.split('-'+e)[0];  
  $('#pages').html('<a id="b" href="'+f+'-'+eval(e-1)+'">Previous</a><span id="i"> | </span><a id="a" href="'+f+'-'+eval(e*1+1)+'">Next</a>');  
  $.ajax({  
  type: 'GET',  
  url: f+'-'+eval(e*1+1),  
  error: function(){$('#a, #i').hide();}  
  });  
  $.ajax({  
  type: 'GET',  
  url: f+'-'+eval(e-1),  
  error: function(){$('#b, #i').hide();}  
  });  
  </script>
Post edited by Levyatan - Thursday, 2013-06-27, 10:32 PM