Ver Mensaje Individual
  #6 (permalink)  
Antiguo 22/08/2010, 22:10
nimar2010
 
Fecha de Ingreso: agosto-2010
Mensajes: 4
Antigüedad: 13 años, 8 meses
Puntos: 0
Respuesta: Recargar SELECT en misma url en PHP

Bueno al parecer, la importación del jquery tiene que ir antes de la importación del tablesorter (parece ser que por el tema del shorcut $ por lo que estuve leyendo en la web del jquery)
Haciendolo así, funciona correctamente :D
Pero.., al querer ordenar la tabla mediante un link externo no me funciona. He hecho lo que dice aquí: http://tablesorter.com/docs/example-trigger-sort.html pero no funciona.
Código Javascript:
Ver original
  1. <script type="text/javascript">
  2. $(document).ready(function()
  3.     {
  4.         $("#tablita").tablesorter();
  5.         $("#link").click(function() {
  6.         // set sorting column and direction, this will sort on the first and third column the column index starts at zero
  7.         var sorting = [[0,0]];
  8.         // sort on the first column
  9.         $("tablita").trigger("sorton",[sorting]);
  10.         // return false to stop default link action
  11.         return false;
  12.     });
  13.            
  14.     });
  15. </script>
El link es:
Código HTML:
Ver original
  1. <a href="#" id="link">Ordenar!</a>
En que estoy fallando? Gracias, hasta luego! :)