How to make the page title in the center of page.

Solved

How to make the page title in the center of page.

hamzaabbas
Tourist
40 0 2

How i can make the page title text in the center of the page only on specific pages?

https://www.tridentproducts.co.uk/pages/deal-town-rangers-fc

shopify 20.jpg

Accepted Solution (1)
LizHoang
Shopify Partner
154 17 33

This is an accepted solution.

Hi @hamzaabbas

You can follow the instruction here: 

1. Go to Shopify > Theme > Edit code > theme.liquid file

2. copy and paste this code before the </head> tag: https://prnt.sc/FbXi5VLql_lx

 

 

{% if page.id == 120651415818 %}
{% style %}
.main-page-title {
   text-align: center !important;
}
{% endstyle %}
{% endif %}

 

Please let us know if our reply is helpful by giving it a Like or marking it as a Solution!

View solution in original post

Replies 8 (8)

LizHoang
Shopify Partner
154 17 33

Hi @hamzaabbas 

 

Thanks for your questions, to resolve the query, you can follow the instruction here: 

1. Go to Shopify > Theme > Customize > Custom CSS : https://prnt.sc/Voua7Py76UCg 

 

2. Copy the code below and paste to the Custom CSS section  > save 

 

.main-page-title {
   text-align: center !important;
}

 

I hope it helps

 

Avada team - Hana

Please let us know if our reply is helpful by giving it a Like or marking it as a Solution!
hamzaabbas
Tourist
40 0 2

Thank you for your response. I only want for few pages not on whole website pages.

Sivadarshan
Shopify Partner
124 1 13

Place that in pages where to place --> scroll down to custom liquid --> paste the code 

LizHoang
Shopify Partner
154 17 33

Hi @hamzaabbas 

 

Can you share with me these pages?  I will provide you with solutions on it 

Please let us know if our reply is helpful by giving it a Like or marking it as a Solution!
hamzaabbas
Tourist
40 0 2
LizHoang
Shopify Partner
154 17 33

This is an accepted solution.

Hi @hamzaabbas

You can follow the instruction here: 

1. Go to Shopify > Theme > Edit code > theme.liquid file

2. copy and paste this code before the </head> tag: https://prnt.sc/FbXi5VLql_lx

 

 

{% if page.id == 120651415818 %}
{% style %}
.main-page-title {
   text-align: center !important;
}
{% endstyle %}
{% endif %}

 

Please let us know if our reply is helpful by giving it a Like or marking it as a Solution!
hamzaabbas
Tourist
40 0 2

Yes, it is working. Thank you

Sivadarshan
Shopify Partner
124 1 13

base.css

 

.main-page-title{
text-align:center;
}