Foros del Web » Creando para Internet » HTML »

Aparecen solos varios <br> solos

Estas en el tema de Aparecen solos varios <br> solos en el foro de HTML en Foros del Web. hola, tengo una pagina generada con php. cuando le hago click derecho con firefox y le doy en ver codigo fuente, veo lo siguiente: Código ...
  #1 (permalink)  
Antiguo 01/05/2010, 00:13
Avatar de ASCENDEDMASTERS  
Fecha de Ingreso: julio-2005
Ubicación: Pergamino, Buenos Aires
Mensajes: 302
Antigüedad: 18 años, 9 meses
Puntos: 1
Aparecen solos varios <br> solos

hola, tengo una pagina generada con php. cuando le hago click derecho con firefox y le doy en ver codigo fuente, veo lo siguiente:

Código HTML:
....<td>&nbsp;</td>
    <td valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0">....


cuando hago lo mismo con IE se ve asi:

Código HTML:
<td>&nbsp;</td>
    <td valign="top"><br> <br> <br> <br> <br> <table width="100%" border="0" cellpadding="0" cellspacing="0"> 

El tema es que me tira la tabla para abajo bastante separandomela de la botonera principal. El codigo que imprime mi php es el que figura al principio, lo misterioso es que si yo escribo asi en el archivo:

Código HTML:
@1@<table width="100%" border="0" cellpadding="0" cellspacing="0"> 

cuando me genera la pagina resultado es así:

Código HTML:
<td>&nbsp;</td>
    <td valign="top">@1@<br> <br> <br> <br> <br> <table width="100%" border="0" cellpadding="0" cellspacing="0"> 

!!!! que pasa acá? me aparecen varios br por arte de magia??? por favor alguien me de una mano porque esto si que me llevo al limite.

Gracias.
__________________
Dios es la unica fuente de todo bien.
  #2 (permalink)  
Antiguo 01/05/2010, 01:09
Avatar de ipraetoriux  
Fecha de Ingreso: abril-2010
Ubicación: ipraetoriux.com
Mensajes: 1.125
Antigüedad: 14 años
Puntos: 155
Respuesta: Aparecen solos varios <br> solos

Estimado, imagino que por magia no aparece nada, sino seriamos todos ilusionistas (jeje..mal chiste!!!)...

Lo que se me ocurre es lo siguiente, que tengas dentro del php algun script o clase o algo que este generando los <br>...revisa el codigo detalladamente, o pon el codigo aca para que lo miremos

saludos
  #3 (permalink)  
Antiguo 01/05/2010, 06:29
Avatar de desteco  
Fecha de Ingreso: abril-2008
Ubicación: BOLIVIA
Mensajes: 16
Antigüedad: 16 años
Puntos: 0
Respuesta: Aparecen solos varios <br> solos

Por que no muestras el codigo fuente de tu PHP
  #4 (permalink)  
Antiguo 01/05/2010, 17:48
Avatar de ASCENDEDMASTERS  
Fecha de Ingreso: julio-2005
Ubicación: Pergamino, Buenos Aires
Mensajes: 302
Antigüedad: 18 años, 9 meses
Puntos: 1
Respuesta: Aparecen solos varios <br> solos

Mira, ahora les pongo el codigo php de ese sector, pero vean este simple hecho:

1º Le haces click derecho y miras el codigo fuente en firefox y no aparecen los <br>
2º en IE si
3º guardas la pagina con cualquier navegador y cuando miras el codigo fuente estan los <br>
4º ahora entenderan lo que digo:

Si tenes este codigo

Código PHP:
$var='HOLA CHICOS';

echo 
$var
y al imprimirlo te muestra

Código HTML:
<br> <br> <br> <br> <br>    HOLA CHICOS
entonces vos decis, bueno, hagamos una cosa. Le pondre una marca al inicio de la cadena y por lógica si los br aparecen antes de la marca entonces hay algo que interfiere el valor de la variable mientras se imprime en el navegador, caso contrario ...

entonces, hago lo siguiente:

Código PHP:
$var='@1@HOLA CHICOS';

echo 
$var
Imprime (Sorpresa!):
Código HTML:
@1@<br> <br> <br> <br> <br>    HOLA CHICOS

la logica sería que los <br> aparezcan al inicio de $var o al final, pero no entre medio de su contenido!

este es el codigo real:

Código PHP:
$mostrar_entrevista_famosa='<table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td><table width="100%" border="0" cellpadding="0" cellspacing="0" background="images/fondo_entrevistas_bandas.jpg">
          <tr>
            <td><img src="images/punto.gif" width="1" height="44" /></td>
            <td><div align="center"><b>'
.sale($tt).'</b> ('.$vf.' visitas - '.$vr.' lecturas)</div></td>
            <td><img src="images/punto.gif" width="1" height="44" /></td>
          </tr>
          <tr>
            <td><img src="images/punto.gif" width="1" height="273" /></td>
            <td><table width="15%" border="0" align="center" cellpadding="0" cellspacing="0">
              <tr>
                <td><div align="center">
                    <table width="100%" border="0" cellspacing="0" cellpadding="0">
                      <tr>
                        <td width="3%"><img src="images/contorno_foto_entrevistas_1.gif" width="10" height="10" /></td>
                        <td width="93%" background="images/contorno_foto_entrevistas_2.gif"><img src="images/contorno_foto_entrevistas_2.gif" width="10" height="10" /></td>
                        <td width="4%"><img src="images/contorno_foto_entrevistas_3.gif" width="10" height="10" /></td>
                      </tr>
                      <tr>
                        <td background="images/contorno_foto_entrevistas_8.gif"><img src="images/contorno_foto_entrevistas_8.gif" width="10" height="10" /></td>
                        <td><img src="'
.$dire_fotos_articulos.$sql2_['img'].'_.jpg" border=0></td>
                        <td background="images/contorno_foto_entrevistas_4.gif"><img src="images/contorno_foto_entrevistas_4.gif" width="10" height="10" /></td>
                      </tr>
                      <tr>
                        <td><img src="images/contorno_foto_entrevistas_7.gif" width="10" height="10" /></td>
                        <td background="images/contorno_foto_entrevistas_6.gif"><img src="images/contorno_foto_entrevistas_6.gif" width="10" height="10" /></td>
                        <td><img src="images/contorno_foto_entrevistas_5.gif" width="10" height="10" /></td>
                      </tr>
                    </table>
                </div></td>
              </tr>
              <tr>
                <td><table width="100%" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td width="7%" background="images/contorno_foto_entrevistas_8.gif"><img src="images/contorno_foto_entrevistas_8.gif" width="10" height="10" /></td>
                      <td width="86%"><div align="center"></div></td>
                      <td width="7%" background="images/contorno_foto_entrevistas_4.gif"><img src="images/contorno_foto_entrevistas_4.gif" width="10" height="10" /></td>
                    </tr>
                    <tr>
                      <td background="images/contorno_foto_entrevistas_8.gif">&nbsp;</td>
                      <td width="86%"><div align="center"><i>'
.$artista.'</i></div></td>
                      <td width="7%" background="images/contorno_foto_entrevistas_4.gif">&nbsp;</td>
                    </tr>
                    <tr>
                      <td><img src="images/contorno_foto_entrevistas_7.gif" width="10" height="10" /></td>
                      <td background="images/contorno_foto_entrevistas_6.gif"><img src="images/contorno_foto_entrevistas_6.gif" width="10" height="10" /></td>
                      <td><img src="images/contorno_foto_entrevistas_5.gif" width="10" height="10" /></td>
                    </tr>
                </table></td>
              </tr>
            </table></td>
            <td><img src="images/punto.gif" width="1" height="273" /></td>
          </tr>
          <tr>
            <td><img src="images/punto.gif" width="1" height="1" /></td>
            <td><img src="images/punto.gif" width="600" height="1" /></td>
            <td><img src="images/punto.gif" width="1" height="1" /></td>
          </tr>
        </table></td>
      </tr>
      <tr>
        <td>'
.showent($show).'</td>
      </tr>
    </table>'

__________________
Dios es la unica fuente de todo bien.

Etiquetas: Ninguno
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 16:59.