Boston College Create a CSS Code Computer Coding Task
Description
So this is the original code. I added <div> tag from line 38 but I’m not sure if Im supposed to do that. Can you pls take a look at the instruction. Thanks Step 2. The CSS text-align property is used for aligning the inner content of a block element. To align content center, use text-align: center; To center align a block element itself, use margin: auto; which evenly set the right and left margin of the element. To do: Uncomment line 6 in center-ex1.html. Check if all the “Lorem Ipsum” text on this page is centered. Can you explain why some texts are not centered? Fix this problem and center all text by adding a single CSS rule in the CSS class selector textdiv. Step 3. To center align an <img> element, which is an inline element, you can use different approaches. Approach 1: Use text-align: center; to center the image within its parent container. Approach 2: Turn the <img> into a block element by changing its display property from the default inline value to a block using display: block; and then use margin: auto; so the image is centered within its parent container. To do: Add a single rule in the CSS class selector .imgdiv to center the “number two” image on the page.
Have a similar assignment? "Place an order for your assignment and have exceptional work written by our team of experts, guaranteeing you A results."