Foros del Web » Creando para Internet » HTML »

Firefox 4 me descoloca una tabla...

Estas en el tema de Firefox 4 me descoloca una tabla... en el foro de HTML en Foros del Web. Hola buenas! Estaba trabajando en una web para guardar mis películas, y estaba a punto de acabar cuando instalé el firefox 4 y de repente ...
  #1 (permalink)  
Antiguo 22/03/2011, 05:47
 
Fecha de Ingreso: noviembre-2008
Mensajes: 52
Antigüedad: 15 años, 5 meses
Puntos: 0
Firefox 4 me descoloca una tabla...

Hola buenas! Estaba trabajando en una web para guardar mis películas, y estaba a punto de acabar cuando instalé el firefox 4 y de repente mis tablas escritas en php dejaron de estar colocadas. Lo pongo en html porque aunque hay código php mi problema está en la tabla a priori. Este es mi código:

Código:
echo '<center<table border="0">';
echo '<tr align="center"> <th>TITULO</th>
						  <th>AÑO</th>
						  <th>PAIS</th>
						  <th>DURACION</th>
						  <th>CALIDAD</th>
						  <th>FORMATO</th>
						  <th>CRITICA</th>
						  <th>ESPECTADOR</th>
						  <th>VISTA</th>
						  <th>GENERO</th>
						  <th>OSCARS</th></tr>
						  <tr><td align="center" colspan="11"><hr class="linea" /></td></tr>';


for ($i=0; $i<$num_resultados; $i++)
{
$fila =mysql_fetch_array($resultados);

if ($i%2==0){
echo '<tr class="tabla1"><td align="center" width="150">';
echo stripslashes($fila['titulo']);
echo '</td>';
echo '<td align="center" width="100">';
echo stripslashes($fila['ano']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['pais']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['duracion']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['calidad']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['formato']);
echo '</td>';
echo '<td align="center" width="100">';
echo stripslashes($fila['critica']);
echo '</td>';
echo '<td align="center" width="100">';
echo stripslashes($fila['espectador']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['vista']);
echo '</td>';
echo '<td align="center" width="200">';
echo stripslashes($fila['genero']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['oscars']);
echo '</td></tr>';
echo '<tr><td align="center" colspan="11"><hr class="linea" /></td>';
}
else{
echo '<tr class="tabla2"><td align="center" width="150">';
echo stripslashes($fila['titulo']);
echo '</td>';
echo '<td align="center" width="100">';
echo stripslashes($fila['ano']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['pais']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['duracion']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['calidad']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['formato']);
echo '</td>';
echo '<td align="center" width="100">';
echo stripslashes($fila['critica']);
echo '</td>';
echo '<td align="center" width="100">';
echo stripslashes($fila['espectador']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['vista']);
echo '</td>';
echo '<td align="center" width="200">';
echo stripslashes($fila['genero']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['oscars']);
echo '</td></tr>';
echo '<tr><td align="center" colspan="11"><hr class="linea" /></td></tr>';
}
}
echo '</table></center><br>';
Por desgracia no tengo una captura de como estaba la tabla antes, pero ahora he hecho una captura para que veáis.

El estilo de los <tr> es simplemente un color de fondo diferente.

Gracias de antemano.
  #2 (permalink)  
Antiguo 22/03/2011, 05:49
 
Fecha de Ingreso: noviembre-2008
Mensajes: 52
Antigüedad: 15 años, 5 meses
Puntos: 0
Respuesta: Firefox 4 me descoloca una tabla...

Cita:
Iniciado por ridgeback Ver Mensaje
Hola buenas! Estaba trabajando en una web para guardar mis películas, y estaba a punto de acabar cuando instalé el firefox 4 y de repente mis tablas escritas en php dejaron de estar colocadas. Lo pongo en html porque aunque hay código php mi problema está en la tabla a priori. Este es mi código:

Código:
echo '<center<table border="0">';
echo '<tr align="center"> <th>TITULO</th>
						  <th>AÑO</th>
						  <th>PAIS</th>
						  <th>DURACION</th>
						  <th>CALIDAD</th>
						  <th>FORMATO</th>
						  <th>CRITICA</th>
						  <th>ESPECTADOR</th>
						  <th>VISTA</th>
						  <th>GENERO</th>
						  <th>OSCARS</th></tr>
						  <tr><td align="center" colspan="11"><hr class="linea" /></td></tr>';


for ($i=0; $i<$num_resultados; $i++)
{
$fila =mysql_fetch_array($resultados);

if ($i%2==0){
echo '<tr class="tabla1"><td align="center" width="150">';
echo stripslashes($fila['titulo']);
echo '</td>';
echo '<td align="center" width="100">';
echo stripslashes($fila['ano']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['pais']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['duracion']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['calidad']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['formato']);
echo '</td>';
echo '<td align="center" width="100">';
echo stripslashes($fila['critica']);
echo '</td>';
echo '<td align="center" width="100">';
echo stripslashes($fila['espectador']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['vista']);
echo '</td>';
echo '<td align="center" width="200">';
echo stripslashes($fila['genero']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['oscars']);
echo '</td></tr>';
echo '<tr><td align="center" colspan="11"><hr class="linea" /></td>';
}
else{
echo '<tr class="tabla2"><td align="center" width="150">';
echo stripslashes($fila['titulo']);
echo '</td>';
echo '<td align="center" width="100">';
echo stripslashes($fila['ano']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['pais']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['duracion']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['calidad']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['formato']);
echo '</td>';
echo '<td align="center" width="100">';
echo stripslashes($fila['critica']);
echo '</td>';
echo '<td align="center" width="100">';
echo stripslashes($fila['espectador']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['vista']);
echo '</td>';
echo '<td align="center" width="200">';
echo stripslashes($fila['genero']);
echo '</td>';
echo '<td align="center" width="150">';
echo stripslashes($fila['oscars']);
echo '</td></tr>';
echo '<tr><td align="center" colspan="11"><hr class="linea" /></td></tr>';
}
}
echo '</table></center><br>';
Por desgracia no tengo una captura de como estaba la tabla antes, pero ahora he hecho una captura para que veáis.
http://img811.imageshack.us/i/pantallay.jpg/
El estilo de los <tr> es simplemente un color de fondo diferente.

Gracias de antemano.
  #3 (permalink)  
Antiguo 22/03/2011, 06:01
 
Fecha de Ingreso: noviembre-2008
Mensajes: 52
Antigüedad: 15 años, 5 meses
Puntos: 0
Respuesta: Firefox 4 me descoloca una tabla...

Revisando el código por tercera vez he visto que me faltaba un símbolo ">" al final de un center, que por lo visto el firefox anterior lo pasaba de largo pero este nuevo no, siento las molestias.

Etiquetas: firefox, tablas
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:24.