Aver bueno esto es lo que hice:
v_consulta.php
Código PHP:
<?php
if ($cod_postor==26) {
header ("Location: v_consulta2.php");
}
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>:: Venser S.A.C. :::</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link href="estilo.css" rel="stylesheet" type="text/css">
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<table width="760" border="0" align="center" cellpadding="0" cellspacing="0">
<tr valign="top" bgcolor="#FFFFFF">
<td colspan="3"><font color="#FFFFFF">
<?php include("superior.htm")?>
</font></td>
</tr>
<tr valign="top" bgcolor="#FFFFFF">
<td width="160"> <font color="#FFFFFF">
<?php include("izquierda.htm")?>
</font></td>
<td width="440"><font color="#FFFFFF">
<table width="420" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td colspan="2"><table border="0" cellpadding="0" cellspacing="0" width="420">
<!-- fwtable fwsrc="titulo.png" fwbase="titulo.jpg" fwstyle="Dreamweaver" fwdocid = "742308039" fwnested="0" -->
<tr>
<td><img src="http://www.forosdelweb.com/images/spacer.gif" width="115" height="1" border="0" alt="" /></td>
<td><img src="http://www.forosdelweb.com/images/spacer.gif" width="305" height="1" border="0" alt="" /></td>
<td><img src="http://www.forosdelweb.com/images/spacer.gif" width="1" height="1" border="0" alt="" /></td>
</tr>
<tr>
<td rowspan="3"><img src="http://www.forosdelweb.com/images/titulo_r1_c1.jpg" alt="" name="titulo_r1_c1" width="115" height="30" border="0" id="titulo_r1_c1" /></td>
<td><img src="http://www.forosdelweb.com/images/titulo_r1_c2.jpg" alt="" name="titulo_r1_c2" width="305" height="2" border="0" id="titulo_r1_c2" /></td>
<td><img src="http://www.forosdelweb.com/images/spacer.gif" width="1" height="2" border="0" alt="" /></td>
</tr>
<tr>
<td background="http://www.forosdelweb.com/images/titulo_r2_c2.jpg" class="titulo">Preliquidaciones</td>
<td><img src="http://www.forosdelweb.com/images/spacer.gif" width="1" height="25" border="0" alt="" /></td>
</tr>
<tr>
<td><img src="http://www.forosdelweb.com/images/titulo_r3_c2.jpg" alt="" name="titulo_r3_c2" width="305" height="3" border="0" id="titulo_r3_c2" /></td>
<td><img src="http://www.forosdelweb.com/images/spacer.gif" width="1" height="3" border="0" alt="" /></td>
</tr>
</table></td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td colspan="2" align="center" valign="middle" class="texto">RESULTADO DE LA CONSULTA</td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td colspan="2"><?php
require_once("autenticar_usr_fns.php");
$postor=$_POST[cod_postor];//
$contra=$_POST[contra];//'101'; //
$consulta_array=busca_empresa($postor,$contra);
?>
<table width="100%" border="0" cellpadding="0" cellspacing="0" class="texto_nota">
<tr>
<td align="center" valign="middle" class="rojo">EL SALDO QUE FIGURA DEBERA DEPOSITARLO EN LA CTA/CTE ME</td>
</tr>
<tr>
<td align="center" valign="middle" class="rojo">DEL BANCO DE CREDITO DEL PERU Nº 193-1194690-1-84</td>
</tr>
<tr>
<td align="center" valign="middle" class="rojo">DE "LOS ANDES SERVICIOS CORPORATIVOS SAC"</td>
</tr>
</table>
<table class="alt1" width="100%" cellpadding=4 border=0 cellspacing=1>
<?php
if (!is_array($consulta_array)){
echo 'No Se Puede mostrar ningun dato(s) para esta Empresa o el código y contraseña no es correcto.<br>';
}
else{
$color = "#dfebf8";
$alinea="center";
$alinea1="left";
$enca="class=thead";
echo "<tr $enca> <td><strong>Nº</strong></td>";
echo "<td align=$alinea><strong>Postor</strong></td>";
echo "<td align=$alinea><strong>Lote</strong></td>";
echo "<td align=$alinea><strong>Base N°</strong></td>";
echo "<td align=$alinea><strong>SALDO A CANCELAR US$</strong></td>";
echo "</tr>";
$aa=1;
$datofi=0;
foreach ($consulta_array as $cu)
{
foreach ($cu as $dato)
if ($color == '#dfebf8')
$color = '#f5f5f5';
else
$color = '#dfebf8';
echo "<tr bgcolor='$color'>";
echo "<td align='$alinea'>".$aa."\n</td>";
echo "<td align='$alinea'>".$cu[codigo]."\n</td>";
echo "<td align='$alinea'>".$cu[lote]."</td>";
echo "<td align='$alinea'>".$cu[codigo]."\n</td>";
echo "<td align='$alinea'>".$cu[saldo]."\n</td>";
echo "</tr>";
$aa++;
$datofi=$datofi+$cu[saldo];
}
}
?>
<tr class="alt5">
<td colspan="4" align="center">Saldo Total $ </td>
<td align="center"> <?php echo $datofi; ?> </td>
</tr>
</table>
</td>
</tr>
<tr>
<td><a href="v_preliquidaciones.php">Regresar a consultar nuevamente</a></td>
</tr>
</table>
</td>
<td width="160"> <font color="#FFFFFF">
<?php include("derecha.htm")?>
</font></td>
</tr>
<tr valign="top" bgcolor="#FFFFFF">
<td colspan="3"><font color="#FFFFFF">
<?php include("base.htm")?>
</font></td>
</tr>
</table>
</body>
</html>
pero no me redirecciono salio este mensaje:
Notice: Undefined variable: cod_postor in c:\archivos de programa\easyphp1-8\www\venser\v_consulta.php on line 2
cual es mi error ??