0

Trabajo en html tengo la nesescidad que todas las celdas que están en una columna tengan el mismo ancho tengo el siguiente código pero no lo he podido conseguir

<body>


 <table border="1" width="100%">
  <caption>Ejemplo de tabla</caption>
  <tbody>
    <tr>
      <td></td>
      <th style="display: block; width: 100%;"></th>  <!-- Los th son los encabezados -->
      <th colspan="8">Lengua y Literatura</th>
      <th colspan="8">Matemática</th>
      <th colspan="8">Entorno Natural y Social</th>
      <th colspan="8">Educación Cultural y Artistica</th>
      <th colspan="8">Educación Física</th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
      <th></th>
    </tr>
    <tr style="height: 120px" >
      <th></th> <!-- Las celdas se encriben dentro de td -->
      <td >Apellidos y Nombres</td>
      <td><p style="writing-mode: vertical-lr; transform: rotate(180deg);">Investigaciones <br> Tarea</Tarea> </p></td>
      <td><p style="float: left; text-align: left; writing-mode: vertical-lr; transform: rotate(180deg);">Individuales <br> Actividades </p></td>
      <td><p style="writing-mode: vertical-lr; transform: rotate(180deg);">Grupales <br> Actividades </p></td>
      <td><p style="writing-mode: vertical-lr; transform: rotate(180deg);">Lecciones</p></td>
      <td><p style="writing-mode: vertical-lr; transform: rotate(180deg);">Promedio</p></td>
      <td><p style="writing-mode: vertical-lr; transform: rotate(180deg);">E. Sumativa</p></td>
      <td style="background-color: gray;"><p style="writing-mode: vertical-lr; transform: rotate(180deg);">PROMEDIO</p></td>
      <td style="background-color: gray;"><p style="writing-mode: vertical-lr; transform: rotate(180deg);">E. Cualitativa</p></td>
      <!-- Segundo -->

El donde se encuentra apellidos y nombres debe tener un ancho en el cual se pueda ingresar cierto datos.

Apellidos y Nombres

Con el tamaño que se muestra en la imagen es muy pequeña, como lo puedo solucionar?

3
  • Asigna ancho en pixeles y no lo conviertas en bloque: <th style="width:200px"></th>
    – Triby
    el 21 dic. 2020 a las 19:47
  • @Triby No hace cambio alguno, es el lugar adecuado para que cambie el tamaño de toda la columna? el 21 dic. 2020 a las 20:02
  • @Triby si funciono pero tuve que poner el siguiente código en ´<table style="table-layout: fixed; width: 100%;" border=1>´ el 21 dic. 2020 a las 21:33

1 respuesta 1

0

Prueba con poner un ancho en píxeles, ya que ahí está tomando el 100% de su capacidad, si le ponex PX, va a romper el molde establecido en %. Prueba con:

<th style="width:350px"></th>
1
  • No hay cambio alguno, es el lugar adecuado para que toda la columna tenga el mismo tamaño? el 21 dic. 2020 a las 20:03

Tu Respuesta

By clicking “Publica tu respuesta”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

¿No es la respuesta que buscas? Examina otras preguntas con la etiqueta o formula tu propia pregunta.