Ver Mensaje Individual
  #5 (permalink)  
Antiguo 21/09/2012, 09:47
Avatar de satjaen
satjaen
 
Fecha de Ingreso: septiembre-2012
Ubicación: Jaén (Andalucía)
Mensajes: 893
Antigüedad: 11 años, 8 meses
Puntos: 10
Respuesta: Funcion pulsar

Dadri7, gracias por contestar.Le he puesto window.location y sigue sin funcionar y el evento onclick me parece que esta en users porque ademas cuando lo pulso se pone la celda de color naranja y está en la pestaña de users.


Código Javascript:
Ver original
  1. function pulsar(obj) {
  2.   obj.style.background = 'orange';
  3.   if (fila != null && fila != obj)
  4.     fila.style.background = 'white';
  5.   fila = obj;
  6.   window.location="menu2.php?id="+num_usuario;
  7. }
  8. function filtrar()
  9. {  
  10.     $.ajax({
  11.         data: $("#frm_filtro").serialize()+ordenar,
  12.         type: "POST",
  13.         dataType: "json",
  14.         url: "ajax.php?action=listar",
  15.             success: function(data){
  16.     var html_user ='' ;
  17.     var html_aparato = '';
  18.     var html_avisos = '';
  19.     if(data.length > 0){
  20.         $.each(data, function(i,item){
  21.        
  22.        
  23.          
  24.             html_user += '<tr onclick="pulsar(this)" >';
  25.             html_user += '<td >'+item.num_usuario+'</td>';
  26.             html_user += '<td>'+item.telefono+'</td>';
  27.             html_user += '<td>'+item.nombre+' '+item.apellidos+'</td>';
  28.             html_user += '<td>'+item.poblacion+'</td>';
  29.             html_user += '</tr>';