How do I get my company name out of my Page Title?

Solved
Highlighted
New Member
7 0 0

Hi Everyone,

I use the free Debut theme from Shopify.  My website is https://www.richardsonseating.com.  All of my page titles automatically have my company name added.  If you go to my site you will see that each page ends with the text - Richardson Seating.  Does anyone know how to edit my theme so it stops doing that?

Thanks,

Ira Lichtenstein

Richardson Seating

0 Likes
Highlighted
Astronaut
1085 177 213

This is an accepted solution.

Richardson, 

I developed a script for you. Try this:

1. In your theme.liquid file, find the </body> (press CTRL + F or command + F on Mac)
2. paste this code right above the </body> tag:

<script>
const renameTitle = (() => {
	const title = document.title;
	const text = `– Richardson Seating`;
	const regex = new RegExp(text, "gi");
	return document.title = regex.test(title) ? title.replace(text, '').trim() : document.title;
})();
</script>

3. Save.

Let me know if it works for you.

◦ Problem Solved? ✔️ Please click on Accept as Solution and like.
◦ Hire me! Recommended by 25+ customers on Facebook. Click here to read their reviews.
◦ Contact me at: diego.boarutto.fortes@gmail.com
1 Like
Highlighted
New Member
7 0 0
It worked! Thank you so much for taking the time to help me!!
0 Likes
Highlighted
Astronaut
1085 177 213

You're welcome!

◦ Problem Solved? ✔️ Please click on Accept as Solution and like.
◦ Hire me! Recommended by 25+ customers on Facebook. Click here to read their reviews.
◦ Contact me at: diego.boarutto.fortes@gmail.com
0 Likes
Highlighted
Shopify Partner
2294 116 352

This is an accepted solution.

Javascript only affects the page title after the page loads it does not actually change the template logic.

This is often the shop.name property

Look for lines like the following in Debut and comment it out

 

    {%- unless escaped_page_title contains shop.name -%}
      &ndash; {{ shop.name }}
    {%- endunless -%}

 

Approximate line https://shopify.com/admin/themes/current?key=layout/theme.liquid&line=27 

Problem Solved? ✔️Accept and ? Like the solution so you can help others.
Buy me a coffee ☕ paypal.me/paulnewton or donate to eff.org
Confused? Busy? Buy a custom solution paull.newton+shopifyforum@gmail.com
0 Likes