Ver Mensaje Individual
  #3 (permalink)  
Antiguo 23/03/2010, 14:36
Avatar de netzky
netzky
 
Fecha de Ingreso: mayo-2007
Mensajes: 56
Antigüedad: 17 años
Puntos: 1
Respuesta: ¿Cómo optimizar ésta función?

Ahi te va una ayudadita...

Código Javascript:
Ver original
  1. $(function(){
  2.    $(".enlace_turismo").click(function(){
  3.          $(".clase_secundaria_de_las_divisiones").hide();
  4.          var id = $(this).attr("rel"); //Usar el Atributo REL del "Link" o "Enlace" para ahi especificar el ID del elemento a mostrar
  5.          $("#" + id).show();
  6.          return false;
  7.    });
  8.  
  9. });

Espero te sirva, algun problema o duda no dudes en avisar.. saludos
__________________
Mess With The Best and Die Like The Rest