I am making a portfolio and I am trying to center my buttons and text

I am making a portfolio and I am trying to center my buttons and text
0

#1

Hi as the title say I can’t center my buttons or title to the middle when I typed in text-center and have it in a block. I was able to do it with this code on my practice portfolio but it won’t work on my actual portfolio. here is my codepen that I am having trouble with

Here is the practice portfolio I am using as a guide


#2

You have to add this code to your CSS.

.btnList{ text-align:center; }


#3

Thanks for the help it fixed it


#4

Also, if you want to center an entire element, you can set the left and right margins to “auto”. This will push the element to the center.


#5

Thanks for the useful tip