+ 1

How can i center my buttons please ?

https://code.sololearn.com/W39WTb1vg0M6/?ref=app PS : I'm french :)

18th Jan 2018, 12:41 PM
Valkyrion
Valkyrion - avatar
10 Antworten
+ 17
In this case, "text-align" property must be set for parent of your buttons, i.e. for <div id="content">. Add: #content { text-align: center; }
18th Jan 2018, 9:42 PM
NezhnyjVampir
+ 11
You may try to apply center with text-align for the div wrapper. 😉
18th Jan 2018, 3:23 PM
Zephyr Koo
Zephyr Koo - avatar
+ 5
try this #content { text-align:center; width:100%; } #content button { margin-right: auto; margin-left: auto; display: block; } a fixed code https://code.sololearn.com/WJd0im81Q9MK/?ref=app
19th Jan 2018, 12:09 PM
Amethyst Animion
Amethyst Animion - avatar
+ 3
button { margin-left: auto; margin-right: auto; }
18th Jan 2018, 12:57 PM
Amethyst Animion
Amethyst Animion - avatar
+ 2
Yes but in inline-block
19th Jan 2018, 12:09 PM
Valkyrion
Valkyrion - avatar
+ 2
Thank you a lot JFS 😊
19th Jan 2018, 12:15 PM
Valkyrion
Valkyrion - avatar
+ 1
it doesn't work :(
18th Jan 2018, 3:05 PM
Valkyrion
Valkyrion - avatar
+ 1
The text-align doesn't work
18th Jan 2018, 3:24 PM
Valkyrion
Valkyrion - avatar
0
it doesn't work too, my buttons are in the left side... https://code.sololearn.com/W39WTb1vg0M6/?ref=app
19th Jan 2018, 6:47 AM
Valkyrion
Valkyrion - avatar
0
Can anyone help me...
19th Jan 2018, 6:48 AM
Valkyrion
Valkyrion - avatar