How to center text inn td row of table row with colspan 4
-
I need to have the text Average Wall centered on the 3rd row
Page on https://steelservicecompany.wordpress.com/tubing/
<figure class="wp-block-table aligncenter"><table class="has-fixed-layout"><tbody><tr><td colspan="2">Rectangular Structural Tubing</td><td></td><td></td></tr><tr><td>Carbon Steel</td><td></td><td></td><td></td></tr><tr><td colspan="4">Average Wall</td></tr><tr><td>Size In Inches</td><td>Gauge</td><td>Decimal Inches</td><td>Wt. per Ft. in Lbs.</td></tr><tr><td>1-1/2 x 1 x</td><td>14</td><td>0.0830</td><td>1.32</td></tr><tr><td></td><td>11</td><td>0.1200</td><td>1.84</td></tr><tr><td>2 × 1 x</td><td>16</td><td>0.0650</td><td>1.27</td></tr><tr><td></td><td>15</td><td>0.0720</td><td>1.40</td></tr><tr><td></td><td>14</td><td>0.0830</td><td>1.60</td></tr><tr><td></td><td>11</td><td>0.1200</td><td>2.25</td></tr><tr><td></td><td>3/16</td><td>0.1880</td><td>3.23</td></tr><tr><td>2 × 1-1/4 x</td><td>14</td><td>0.0830</td><td>1.74</td></tr><tr><td>2 × 1-1/2 x</td><td>11</td><td>0.1200</td><td>2.66</td></tr><tr><td>2-1/2 x 1 x</td><td>14</td><td>0.0830</td><td>1.88</td></tr><tr><td>2-1/2 x 1-1/4 x</td><td>14</td><td>0.0830</td><td>2.02</td></tr><tr><td>2-1/2 x 1-1/2 x</td><td>14</td><td>0.0830</td><td>2.16</td></tr><tr><td></td><td>11</td><td>0.1200</td><td>3.05</td></tr><tr><td></td><td>1/4</td><td>0.2500</td><td>5.40</td></tr><tr><td></td><td></td><td></td><td></td></tr><tr><td>3 × 1 x</td><td>16</td><td>0.0650</td><td>1.71</td></tr><tr><td></td><td>14</td><td>0.0830</td><td>2.10</td></tr><tr><td></td><td>11</td><td>0.1200</td><td>3.05</td></tr><tr><td>3 × 1-1/2 x</td><td>16</td><td>0.0650</td><td>1.90</td></tr><tr><td></td><td>14</td><td>0.0830</td><td>2.38</td></tr><tr><td></td><td>11</td><td>0.1200</td><td>3.48</td></tr><tr><td>3 × 2 x</td><td>14</td><td>0.0830</td><td>2.67</td></tr><tr><td></td><td>11</td><td>0.1200</td><td>3.90</td></tr><tr><td></td><td>3/16</td><td>0.1878</td><td>5.59</td></tr><tr><td></td><td>1/4</td><td>0.2500</td><td>7.11</td></tr><tr><td>4 x 2 x</td><td>14</td><td>0.0830</td><td>3.23</td></tr><tr><td></td><td>11</td><td>0.1200</td><td>4.75</td></tr><tr><td></td><td>3/16</td><td>0.1878</td><td>6.87</td></tr><tr><td></td><td>1/4</td><td>0.2500</td><td>8.81</td></tr><tr><td></td><td>5/16</td><td>0.3123</td><td>10.58</td></tr><tr><td>4 x 3 x</td><td>11</td><td>0.1200</td><td>5.60</td></tr><tr><td></td><td>3/16</td><td>0.1878</td><td>8.15</td></tr><tr><td></td><td>1/4</td><td>0.2500</td><td>10.51</td></tr><tr><td></td><td>5/16</td><td>0.3123</td><td>12.70</td></tr></tbody></table></figure>The blog I need help with is: (visible only to logged in users)
-
I tried this code but it doesn’t align the text
<td colspan="4" style="text-align: center;">Your Centered Text</td> -
-
Hi there,
Good morning. I hope you’re doing great.
To change the alignment of the column, first select the column and then adjust the alignment as shown in the screen recording below. The custom CSS code within the HTML table code will not work if you’re using the WordPress FREE plan.

To know more about the table block, please check the article below.
Use the Table block to create structured content in rows and columns to display information. This guide will show you how to insert a table on your website. Add the Table Block To add the Table block, click on the + Block Inserter icon and search for “table.” Click to add the block to a page, post, or template. 💡 Using your keyboard, you can also type /table on a new line andGive it a try, and let me know how that goes!
Have a good day!
Thanks
Faisal -
-
-
Oh, when I center that 3rd row it centers that entire left most column. Is there a way to only center the third row and the left column is left aligned?
-
Hi @cloudsion
I couldn’t find a way to center the third row. It affects all the left columns as well. Is there anything else I can help with?
- The topic ‘How to center text inn td row of table row with colspan 4’ is closed to new replies.
