+ 1

How do you put a list in the center of a webpage?

I can't find out a way to do it :(

31st Jul 2018, 2:56 PM
David Lorenzo
David Lorenzo - avatar
5 odpowiedzi
+ 4
Use align="center" or enclose the <ol> or <ul> tags inside <center> tags.
31st Jul 2018, 3:00 PM
Paul Grasser
Paul Grasser - avatar
+ 4
Use ul { display: block; max-width: 20%; margin: 50vh auto; } https://code.sololearn.com/W1UtsWWWo86y/?ref=app
31st Jul 2018, 3:25 PM
Calviղ
Calviղ - avatar
+ 3
thanks
31st Jul 2018, 3:01 PM
David Lorenzo
David Lorenzo - avatar
+ 3
Don't use center tag. Its obsoleted since HTML4. New coming released browsers could no longer support center tag.
31st Jul 2018, 3:10 PM
Calviղ
Calviղ - avatar
+ 2
ok
31st Jul 2018, 3:16 PM
David Lorenzo
David Lorenzo - avatar