Centering line element

Hi! I´m having trouble centering the Line element, I tried centering the section, the column and the row, it is still not centered, I can mange to center it by putting width to 12% and a left margin for 44% but this is not optimal, is there no setting where you can just set it to center?

Hello @annekling,

Thanks for asking. :slight_smile:

Can I just take a look at your website? Would you mind sharing website URL?

Thanks.

Its on a local server… Is there anyway I could copy the code from somewhere for you to have a look at? Is it supposed to work when you center the section etc?

Hi @annekling,

This site below will help you to center kind of elements or div.

https://www.w3schools.com/css/css_align.asp

You can play with the CSS above to be added in your inline CSS of your line element.

Let us know how it goes.

Thanks.

I added this to the custom css for the line element:

display: block;
margin-left: auto;
margin-right: auto;

text-align: center;

it not nothing, how can I add it inline?

Hi There,

Giving a 12% width and auto margins on both sides should center your line element:


If this is not the case on your end, then there must be something that is conflicting these settings. If you don’t mind, please export your page template and customizer settings and upload it to a sharing site (e.g. Google Drive, Dropbox, etc.) and share us the link, so we can try to replicate your issue on our end.

Thanks,

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.