Highlighted

Why isn't my image centring?

Explorer ,
Mar 13, 2020

Copy link to clipboard

Copied

Before i adjusted the width of the image, it was centered, however it was also the full width of the page, which stretched the image. After the i adjust the width, it sits to the left of the page and i don't know why? Can someone help me to center it please?HTMLHTMLCSSCSSwhat it looks like in a browserwhat it looks like in a browser

add - align-items: center; to your '.centered-content' css selector. That is what you need if you set the flex-direction to column and you wont need to add the 'text-align: center'

 

 

Views

157

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Why isn't my image centring?

Explorer ,
Mar 13, 2020

Copy link to clipboard

Copied

Before i adjusted the width of the image, it was centered, however it was also the full width of the page, which stretched the image. After the i adjust the width, it sits to the left of the page and i don't know why? Can someone help me to center it please?HTMLHTMLCSSCSSwhat it looks like in a browserwhat it looks like in a browser

add - align-items: center; to your '.centered-content' css selector. That is what you need if you set the flex-direction to column and you wont need to add the 'text-align: center'

 

 

Views

158

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Mar 13, 2020 0
LEGEND ,
Mar 13, 2020

Copy link to clipboard

Copied

add - align-items: center; to your '.centered-content' css selector. That is what you need if you set the flex-direction to column and you wont need to add the 'text-align: center'

 

 

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Mar 13, 2020 0
Explorer ,
Mar 13, 2020

Copy link to clipboard

Copied

AHHHHHHH THANK YOU SO MUCH!!!!!!!

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Mar 13, 2020 0