Hola, me sale el siguiente mensaje:
Warning: Invalid argument supplied for foreach() in C:\wamp\www\views\tables\tabla.salud.colectivos.ph p on line 198
Este es el codigo:
Código PHP:
Ver originalconsulta_Tabla_Registro_Detalle_Soporte_Comercial($_SESSION["USER_MATRICULA"],$COD_ESTADO);
if (!$TOT_REGISTRO_SCOL_DETALLE){
?>
<!-- Tabla Listado de Casos Pendientes -->
<div class="container-fluid">
<h3 class="sub-header text-success"><em>Listado de Casos Pendientes</em></h3>
<div class="table-responsive">
<table class="table table-hover">
<thead>
<tr>
<th>ID</th>
<th>RAMO</th>
<th>N° DE CASO</th>
<th>CLIENTE</th>
<th>BROKER</th>
<th>ASIGNADO</th>
<th>FECHA DE ENVIO</th>
<th>OBSERVACION</th>
</tr>
</thead>
<?php
foreach ($TOT_REGISTRO_SCOL_DETALLE as $rgSdet) { //Aqui es la Linea 198
?>
<tbody>
<tr>
La función consulta_Tabla_Registro_Detalle_Soporte_Comercial( ) es:
Código PHP:
Ver originalfunction consulta_Tabla_Registro_Detalle_Soporte_Comercial($USER_MATRICULA,$COD_ESTADO) {
$conexion = db_connect();
$sql = 'SELECT *
FROM tb_registro_scol_detalle
WHERE USER_MATRICULA = :USER_MATRICULA
AND COD_ESTADO = :COD_ESTADO
ORDER BY FEC_SOLICITUD ASC';
$Q_TB_REGISTRO_SCOL_DETALLE = $conexion->prepare($sql);
$Q_TB_REGISTRO_SCOL_DETALLE->execute(array(':USER_MATRICULA' => $USER_MATRICULA, ':COD_ESTADO' => $COD_ESTADO)); $TOT_REGISTRO_SCOL_DETALLE = $Q_TB_REGISTRO_SCOL_DETALLE->fetchAll();
//print_r($TOT_REGISTRO_SCOL_DETALLE); //Aqui se imprimen en pantalla los Arrays para verificar que la consulta si funcione.
//$Q_TB_REGISTRO_SCOL_DETALLE->closeCursor();
}