Foros del Web » Programando para Internet » PHP »

se carga 2 veces la pagina al hacer login

Estas en el tema de se carga 2 veces la pagina al hacer login en el foro de PHP en Foros del Web. Hola, necesito ayuda referente al tema de los frames, ya se que están desfasados pero la apliacion que estoy "retocando" los lleva y necesito arreglar ...
  #1 (permalink)  
Antiguo 17/11/2008, 03:18
 
Fecha de Ingreso: junio-2007
Ubicación: Cádiz
Mensajes: 369
Antigüedad: 16 años, 10 meses
Puntos: 7
se carga 2 veces la pagina al hacer login

Hola, necesito ayuda referente al tema de los frames, ya se que están desfasados pero la apliacion que estoy "retocando" los lleva y necesito arreglar una anomalía que ocurre al iniciar sesión en ella. Está dividida en 3 frames, top, main y bottom. Entonces cuando entro como usuario, se cargan 2 veces tanto el topframe como el botttomframe y cuando actualizo se soluciona el problema, os paso el index.php y si quereis que os pase otro archivo me lo decis a ver si podeis ayudarme....gracias!!tambien os muestro una imagen de lo que ocurre para que tengais mas idea....




Código PHP:
<?php
include ("digitalimp_PCU.php");
session_start();

session_register("autentificado");
//COMPRUEBA QUE EL USUARIO ESTA AUTENTIFICADO
//if ($autentificado == "SI") {
//Configuracion
echo"
<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Frameset//EN' 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd'>
<html xmlns='http://www.w3.org/1999/xhtml'>
<head>
<meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1' />
<title>DIGITAL IMPRESION</title>
<style type='text/css'>
<!--
body {
    margin-left: 0px;
    margin-top: 0px;
    margin-right: 0px;
    margin-bottom: 0px;
}
-->
</style></head>

<frameset rows='105,*,44' frameborder='no' border='0' framespacing='0'>
  <frame src='topframe.php' name='topFrame' scrolling='No' noresize='noresize' id='topFrame' title='topFrame' />
  <frame src='inicio.php' name='mainFrame' id='mainFrame' title='mainFrame' />
  <frame src='bottomframe.html' name='bottomFrame' scrolling='No' noresize='noresize' id='bottomFrame' title='bottomFrame' />
</frameset>
<noframes><body>
</body>
</noframes></html>
"
;
//}
//else "NO OLVIDE INTRODUCIR LA CLAVE CORRECTA";
?>
  #2 (permalink)  
Antiguo 17/11/2008, 04:13
 
Fecha de Ingreso: junio-2007
Ubicación: Cádiz
Mensajes: 369
Antigüedad: 16 años, 10 meses
Puntos: 7
Respuesta: se carga 2 veces la pagina al hacer login

el codigo del top frame es este....


Código PHP:
<?php
include ("digitalimp_PCU.php");
// topFrame
echo"
<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">
<html xmlns=\"http://www.w3.org/1999/xhtml\">
<head>
<meta http-equiv=\"Content-Type\" content=\"text/html; charset=iso-8859-1\" />
<title>Documento sin t&iacute;tulo</title>
<style type=\"text/css\">
<!--
body {
    margin-left: 0px;
    margin-top: 0px;
    margin-right: 0px;
    margin-bottom: 0px;
}
-->
</style>
<script type=\"text/JavaScript\">
<!--
function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf(\"#\")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf(\"?\"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->
</script>
</head>

<body onload=\"MM_preloadImages('images/bot-clientes-over.gif','images/bot-ordenes-over.gif','images/bot-operaciones-over.gif','images/bot-trabext-over.gif','images/bot-provee-over.gif','images/bot-pedidos-over.gif','images/bot-disconf-over.gif','images/bot-historial-over.gif','images/bot-back-over.gif','images/bot-inicio-over.gif')\">
<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">
  <tr height=\"66\">
    <td align=\"left\" width=\"237\"><img src=\"images/img-cabecera.gif\" alt=\"DIGITAL IMPRESI&Oacute;N\" width=\"237\" height=\"66\" /></td>
    <td height=\"66\"><img src=\"images/fondo-cabecera.gif\" alt=\"DIGITAL IMPRESI&Oacute;N\" width=\"1043\" height=\"66\" /></td>
  </tr>
  <tr >
    <td colspan=2 height=\"34\" align=\"center\" valign=\"top\" background=\"images/fondo-botonera.gif\"><table width=\"590\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">
      <tr>
        <td width=\"2\" bgcolor=\"#FFFFFF\"><img src=\"images/spacer.gif\" width=\"2\" height=\"19\" /></td>
        <td><a href=\"inicio.php\" target=\"mainFrame\"><img src=\"images/bot-inicio.gif\" alt=\"INICIO\" width=\"34\" height=\"19\" border=\"0\" id=\"Image10\" onmouseover=\"MM_swapImage('Image10','','images/bot-inicio-over.gif',1)\" onmouseout=\"MM_swapImgRestore()\" /></a></td>
        <td width=\"2\" bgcolor=\"#FFFFFF\"><img src=\"images/spacer.gif\" width=\"2\" height=\"19\" /></td>
        <td><a href=\"clientes.php\" target=\"mainFrame\"><img src=\"images/bot-clientes.gif\" alt=\"CLIENTES\" name=\"Image1\" width=\"49\" height=\"19\" border=\"0\" id=\"Image1\" onmouseover=\"MM_swapImage('Image1','','images/bot-clientes-over.gif',1)\" onmouseout=\"MM_swapImgRestore()\" /></a></td>
        <td width=\"2\" bgcolor=\"#FFFFFF\"><img src=\"images/spacer.gif\" width=\"2\" height=\"19\" /></td>
        <td><a href=\"ordenes.php\" target=\"mainFrame\"><img src=\"images/bot-ordenes.gif\" alt=\"&Oacute;RDENES\" name=\"Image2\" width=\"52\" height=\"19\" border=\"0\" id=\"Image2\" onmouseover=\"MM_swapImage('Image2','','images/bot-ordenes-over.gif',1)\" onmouseout=\"MM_swapImgRestore()\" /></a></td>
        <td width=\"2\" bgcolor=\"#FFFFFF\"><img src=\"images/spacer.gif\" width=\"2\" height=\"19\" /></td>
        <td><a href=\"ordenes.php?Historial=fact\" target=\"mainFrame\"><img src=\"images/bot-operaciones.gif\" alt=\"PEND FACTURAR\" name=\"Image3\" width=\"72\" height=\"19\" border=\"0\" id=\"Image3\" onmouseover=\"MM_swapImage('Image3','','images/bot-operaciones-over.gif',1)\" onmouseout=\"MM_swapImgRestore()\" /></a></td>
        <td width=\"2\" bgcolor=\"#FFFFFF\"><img src=\"images/spacer.gif\" width=\"2\" height=\"19\" /></td>
        <td><a href=\"trabajos_externos.php\" target=\"mainFrame\"><img src=\"images/bot-trabext.gif\" alt=\"TRABAJOS EXTERNOS\" name=\"Image4\" width=\"97\" height=\"19\" border=\"0\" id=\"Image4\" onmouseover=\"MM_swapImage('Image4','','images/bot-trabext-over.gif',1)\" onmouseout=\"MM_swapImgRestore()\" /></a></td>
        <td width=\"2\" bgcolor=\"#FFFFFF\"><img src=\"images/spacer.gif\" width=\"2\" height=\"19\" /></td>
        <td><a href=\"proveedores.php\" target=\"mainFrame\"><img src=\"images/bot-provee.gif\" alt=\"PROVEEDORES\" name=\"Image5\" width=\"72\" height=\"19\" border=\"0\" id=\"Image5\" onmouseover=\"MM_swapImage('Image5','','images/bot-provee-over.gif',1)\" onmouseout=\"MM_swapImgRestore()\" /></a></td>
        <td width=\"2\" bgcolor=\"#FFFFFF\"><img src=\"images/spacer.gif\" width=\"2\" height=\"19\" /></td>
        <td><a href=\"pedidos.php\" target=\"mainFrame\"><img src=\"images/bot-pedidos.gif\" alt=\"PEDIDOS\" name=\"Image6\" width=\"48\" height=\"19\" border=\"0\" id=\"Image6\" onmouseover=\"MM_swapImage('Image6','','images/bot-pedidos-over.gif',1)\" onmouseout=\"MM_swapImgRestore()\" /></a></td>
        <td width=\"2\" bgcolor=\"#FFFFFF\"><img src=\"images/spacer.gif\" width=\"2\" height=\"19\" /></td>
        <td><a href=\"disconformidades.php\" target=\"mainFrame\"><img src=\"images/bot-disconf.gif\" alt=\"DISCONF.\" name=\"Image7\" width=\"50\" height=\"19\" border=\"0\" id=\"Image7\" onmouseover=\"MM_swapImage('Image7','','images/bot-disconf-over.gif',1)\" onmouseout=\"MM_swapImgRestore()\" /></a></td>
        <td width=\"2\" bgcolor=\"#FFFFFF\"><img src=\"images/spacer.gif\" width=\"2\" height=\"19\" /></td>
        <td><a href=\"ordenes.php?Historial=si\" target=\"mainFrame\"><img src=\"images/bot-historial.gif\" alt=\"HISTORIAL\" name=\"Image8\" width=\"49\" height=\"19\" border=\"0\" id=\"Image8\" onmouseover=\"MM_swapImage('Image8','','images/bot-historial-over.gif',1)\" onmouseout=\"MM_swapImgRestore()\" /></a></td>
        <td width=\"2\" bgcolor=\"#FFFFFF\"><img src=\"images/spacer.gif\" width=\"2\" height=\"19\" /></td>
        <td><a href=\"./BACKUP/backup.php\" target='_BLANCK'><img src=\"images/bot-back.gif\" alt=\"BACKUP\" name=\"Image9\" width=\"45\" height=\"19\" border=\"0\" id=\"Image9\" onmouseover=\"MM_swapImage('Image9','','images/bot-back-over.gif',1)\" onmouseout=\"MM_swapImgRestore()\" /></a></td>
        <td width=\"2\" bgcolor=\"#FFFFFF\"><img src=\"images/spacer.gif\" width=\"2\" height=\"19\" /></td>
      </tr>
    </table></td> "
;




    echo
"
  </tr>
</table>
</body>
</html>"
;
?>
  #3 (permalink)  
Antiguo 18/11/2008, 10:07
 
Fecha de Ingreso: junio-2007
Ubicación: Cádiz
Mensajes: 369
Antigüedad: 16 años, 10 meses
Puntos: 7
Respuesta: se carga 2 veces la pagina al hacer login

nadie puede decirme a que se debe??o parte de codigo que necesiteis ver para averiguarlo???

Saludos!!
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 17:35.