Google Codes - Question | JoomShaper
SP Page Builder 6 is Here! Learn More →

Google Codes

P

Pascal

SP Page Builder 4 years ago

I have a multi language site with 4 languages. Each have 2 templates (pages + blogs)

In each template custom code I pasted google site tag in 'Before </body>'

While checking pagespeed I have issues with these scripts:

  • 'Remove unused JavaScript to reduce bytes consumed by network activity.'
  • 'Remove dead rules from stylesheets and defer the loading of CSS not used for above-the-fold content to reduce unnecessary bytes consumed by network activity. '

Issues about www.googletagmanager.com and www.gstatic.com and also recaptcha.

I there better / another way to add these scripts to my multilanguage site to solve the speed issues?

Thanks and regards, Pascal

0
9 Answers
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 4 years ago #5975

This is trusted method used by Joomla webmasters since 2015 at least.

Of course there are more similar modules. It was one of them.

0
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 4 years ago #4723

Hi, As I remember on Joomla Extension Directory (JED) there are plugin(s) that works faster than default Google code. You have to search.

Anyway you can also search for tips used in WordPress - their community is XX langer, more blogs, tutorials - basic speed rules are similar. Maybe there is better way than just copy-paste ready code.

0
P
Pascal
Accepted Answer
4 years ago #4770

Thanks, I'd rather not add more extentions. Just like to know what options I have in pagebuilder/helix to add the code in multilanguage site. Is it possible to add codes any other way... to index.php after pageload?

Regards, Pascal

0
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 4 years ago #5069

Of course You can customize template code, but as you know, it's at your risk and responsibility.

0
P
Pascal
Accepted Answer
4 years ago #5157

Thanks Paul, Was hoping you could explain another approach to load scripts after pageload to tackle this issue. If something pops up feel free to share this ;)

Regards, Pas

0
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 4 years ago #5161

I use plugin or module. But you said that you don't want to install any. So you should admit that we have a very limited choice.

What is ironic... google want to load his scripts on the top of website, then he "cries" that it slown down the website. Madness, don't you think.

0
P
Pascal
Accepted Answer
4 years ago #5163

Indeed Madness. What plugin works nicely with pagebuilder (in combination with JCH)? Maybe I could give it a try and make google happy ;)

0
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 4 years ago #5201

HDAnyCode module - that you can publish in any module position or inside SPPB Page using Module addon.

0
P
Pascal
Accepted Answer
4 years ago #5917

Thanks! will check if this helpes to reduce the madness.

0