Tema: Funcion PHP
Ver Mensaje Individual
  #1 (permalink)  
Antiguo 04/12/2012, 15:38
Avatar de danramglez
danramglez
 
Fecha de Ingreso: septiembre-2012
Mensajes: 70
Antigüedad: 11 años, 7 meses
Puntos: 2
Funcion PHP

Hola chicos quisiera su ayuda, necesito crear una funcion que me atrape los valores de una tabla que se llama hesk_refacciones, y quiero guardarlos en una tabla que se llama hesk_refacciones_usuario

Código HTML:
Ver original
  1. <form name="refaccion" action="ticket.php" method="post">
  2.         <table border="0" cellspacing="1" cellpadding="1">
  3.        
  4.             <?php
  5.            
  6.             if (isset($_REQUEST['check']))
  7.             {
  8.              $varifica = $_REQUEST['check'];
  9.             }  
  10.             else
  11.             {
  12.              $varifica = 0;
  13.             }
  14.  
  15.             $sql = 'SELECT nombre,id FROM `'.hesk_dbEscape($hesk_settings['db_pfix']).'refacciones`';
  16.             $res = hesk_dbQuery($sql);
  17.  
  18.             while ($row = hesk_dbFetchAssoc($res))
  19.             {
  20.             ?>   
  21.             <tr>
  22.             <td><b><input type="checkbox" name="check" value=<?php $row['nombre']; ?>/><b></td>
  23.             <td><b><?php echo $row['nombre']; ?></b></td>
  24.             </tr>
  25.  
  26.  
  27.             <?php
  28.             }
  29.             ?>
  30.            
  31.             <input type="submit" value="<?php echo $hesklang['submit_reply']; ?>" class="orangebutton" onmouseover="hesk_btn(this,'orangebuttonover');" onmouseout="hesk_btn(this,'orangebutton');"\" /></p>



Muchas gracias amigos
__________________
"La funcion de un buen software es hacerlo parecer simple"