← Javascript

[AJAX] Paginação em AJAX, como?

Lida 8651 vezes

Offline

bfms 
Equipa
Mensagens 1769 Gostos 40
Feedback +1

Troféus totais: 35
Trófeus: (Ver todos)
Search Level 6 Apple User Super Combination Combination Topic Starter 50 Poll Votes 10 Poll Votes Poll Voter Poll Starter

Olá mais uma vez,

Tenho o seguinte código para mostrar as páginas de notícias (em números)

Código: [Seleccione]
<?
   for ($i = 1; $i <= $IntTotalPages; $i++)
   {
      if ($i == $IntPage)
   {
      echo "<strong>$i</strong> |";
   } else
   {
      if (!empty($HTTP_GET_VARS['categoria']))
   {
?>
    <a href="index.php?categoria=<? echo $IntCategory; ?>&page=<? echo $i; ?>&id=<? echo $IntMaxID; ?>"><? echo $i; ?></a> |
    <?
        } else
{
    ?>
   <a href="index.php?page=<? echo $i; ?>&id=<? echo $IntMaxID; ?>"><? echo $i; ?></a> |
   <?
        }
        }
$IntMaxID = $IntMaxID - 12;
        }
    ?>

Gostaria agora de incorporar isto com a paginação em AJAX, limitando o número de páginas a mostrar.
Estive a ver este script: http://www.dynamicdrive.com/dynamicindex17/ajaxpaginate/index.htm

Fico a aguardar opiniões :)

UPDATE: Este código mostra-me 470 páginas! tudo seguido...
Offline

bfms 
Equipa
Mensagens 1769 Gostos 40
Feedback +1

Troféus totais: 35
Trófeus: (Ver todos)
Search Level 6 Apple User Super Combination Combination Topic Starter 50 Poll Votes 10 Poll Votes Poll Voter Poll Starter

Será que alguém me podia ajudar? (BUMP)
Offline

Diogo Pinto 
Administrador
Mensagens 4400 Gostos 371
Feedback +4

Troféus totais: 37
Trófeus: (Ver todos)
Avatar Search Level 6 Linux User Mobile User Super Combination Combination Topic Starter 50 Poll Votes 10 Poll Votes

Será que alguém me podia ajudar? (BUMP)

Acho que devias tentar foruns específicos de programação, onde a ajuda é excelente: www.portugal-a-programar.org

Boa sorte ;)
Offline

bfms 
Equipa
Mensagens 1769 Gostos 40
Feedback +1

Troféus totais: 35
Trófeus: (Ver todos)
Search Level 6 Apple User Super Combination Combination Topic Starter 50 Poll Votes 10 Poll Votes Poll Voter Poll Starter

Volto aqui a dar um pequeno bumpzito neste tópico...
ehhe
Offline

Nuno 
Administrador
Mensagens 7780 Gostos 216
Feedback +2

Troféus totais: 42
Trófeus: (Ver todos)
100 Poll Votes Level 7 Search Mobile User Level 6 Super Combination Combination Topic Starter 50 Poll Votes 10 Poll Votes