lista.php 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <meta http-equiv="X-UA-Compatible" content="ie=edge">
  7. <title>Lista de personal</title>
  8. </head>
  9. <body>
  10. <h1>Listado de personal para generar firmas de correo electrónico</h1>
  11. <a href=<?=base_url('FirmaController/generarTodas')?>><button> Generar Todas las firmas</button></a>
  12. <br>
  13. <br>
  14. <table border ="1" style="border: 1px solid black; border-collapse:collapse;">
  15. <tbody>
  16. <?php
  17. foreach ($headers as $header){
  18. echo "<th>";
  19. print($header);
  20. echo "</th>";
  21. }
  22. echo "<th>Vista Previa</th>";
  23. foreach($personal as $persona){
  24. echo "<tr>";
  25. foreach($headers as $header){
  26. echo "
  27. <td>{$persona[$header]}</td>
  28. ";
  29. }
  30. $url = base_url('FirmaController/generarVistaPrevia');
  31. $id_user=$persona['N'];
  32. echo "<td><a href=$url/$id_user target='_blank'><button>Generar Previa</button></a></td>";
  33. echo "</tr>";
  34. }?>
  35. </tbody>
  36. </table>
  37. </body>
  38. </html>