Ver Mensaje Individual
  #10 (permalink)  
Antiguo 21/06/2011, 01:35
Avatar de livemusic
livemusic
 
Fecha de Ingreso: abril-2011
Ubicación: Lima - Chorrillos
Mensajes: 150
Antigüedad: 13 años
Puntos: 18
Respuesta: Enviar datos de un Jquery Tab a PHP

Mira no entiendo como lo estas trabajando pero te recomiendo q lo trabajes de la siguiente forma,, :) espero y te sea de mucha ayuda...

////////HTML

Código HTML:
Ver original
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml">
  3. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  4. <title>Documento sin título</title>
  5. <script src="http://www.google.com/jsapi"></script>
  6.     google.load("jquery", "1.6.1");
  7. <script type="text/JavaScript">
  8.  
  9. function fn_insert_user(){
  10.     var str = $("#insert_user").serialize();
  11.     $.ajax({
  12.         url: 'demo.php',
  13.         data: str,
  14.         type: 'post',
  15.         success: function(data){
  16.             $("#show").html(data);
  17.         }
  18.     });
  19. };
  20.  
  21. function wizard(integer){
  22.     $('#myslide .cover').animate({left:-350*(parseInt(integer)-1)})
  23.     $('#button a').each(function(){
  24.     $(this).removeClass('active');
  25.         if($(this).hasClass('button'+integer)){
  26.             $(this).addClass('active')
  27.         }
  28.     });
  29. }
  30.  
  31. $(function(){
  32.     $('#button a').click(function(){
  33.         var integer = $(this).attr('rel');
  34.         wizard(integer);
  35.         return false;
  36.     });
  37. })
  38.  
  39. <style type="text/css">
  40.     #myslide {width:350px;overflow:hidden;position: relative;height:330px;margin-bottom:20px}
  41.     #myslide .cover{width:1400px; position: absolute; height:350px;}
  42.     #myslide .mystuff {width:350px;float:left;margin:20px 0;}
  43.     .button1,.button2,.button3,.button4{background:#999;padding:6px;display:block;float:left;margin-right:5px;}
  44.     .active{background:#111;padding:6px;display:block;float:left;outline:none;}
  45.     .clear{clear:both;}
  46. </head>
  47.  
  48.     <div id="button">
  49.          <a class="button1 active" rel="1" href="#"></a>
  50.          <a class="button2" rel="2" href="#"></a>
  51.          <a class="button3" rel="3" href="#"></a>
  52.          <a class="button4" rel="4" href="#"></a>
  53.     </div>
  54.     <div class="clear"></div>
  55.     <div id="myslide">
  56.         <form action="javascript: fn_insert_user();" id="insert_user">
  57.         <div class="cover">
  58.             <div class="mystuff">
  59.               <label>Ingresar Nombre <input type="text" name="txtNombre" /></label>
  60.             </div>
  61.             <div class="mystuff">
  62.               <label>Ingresar Apellido <input type="text" name="txtApellido" /></label>
  63.             </div>
  64.             <div class="mystuff">
  65.               <label>Ingresar Telefono <input type="text" name="txtTelefono" /></label>
  66.             </div>
  67.             <div class="mystuff">
  68.               <label>Mostrar datos <input type="submit" value="Mostrar datos" /></label>
  69.             </div>
  70.         </div>
  71.         </form>
  72.     </div>
  73.     <div class="clear"></div>
  74.     <div id="show"></div>
  75. </body>
  76. </html>

//////// PHP

Código PHP:
Ver original
  1. <?php
  2.     $nombre   = $_POST['txtNombre'];
  3.     $apellido = $_POST['txtApellido'];
  4.     $telefono = $_POST['txtTelefono'];
  5.    
  6.     echo "$nombre $apellido $telefono\n";
  7.    
  8. ?>


Saludos suerte si ay algo q no te sale me avisas SALUDOS... suerte