?
Choose the correct HTML tag to left-align the content inside a table cell
Choose the correct HTML tag to left-align the content inside a table cell
1. <td leftalign>
2. <td align=”left”>
3. <td valign=”left”>
4. <td="left">
Answer & Solution
Correct Answer:
Option
B
To left-align the content inside a table cell in HTML, you should use the tag with the align attribute.
The correct syntax is.
Here's why the other options are incorrect:
1. : This is not a valid HTML attribute.
3. : The valign attribute is used for vertical alignment, not horizontal alignment.
4. : This is an incorrect syntax for attributes in HTML.
Thus, Option 2 correctly uses the align attribute to achieve left alignment.
The correct syntax is
Here's why the other options are incorrect:
1.
3.
4.
Thus, Option 2 correctly uses the align attribute to achieve left alignment.
Join the Discussion
Login to post a comment or share your explanation.
Login