Adding language attribute to header


#1

Hi
I have a few web pages, which are actually only for Indonesian users. How can I add the lang=“id” attribute to the HTML tag, in the header of these pages?

Thanks in advance.
Virginie


#2

I believe you can do this by by clicking JavaScripts in the bottom left, selecting Head for the placement and pasting it into the box.


#3

Hi Nicholas, thanks for your reply.
I can add a tag in the Javascript section, but I don’t know exactly what to put there.

According to the W3C recommendation, we should declare the primary language for each Web page with the lang attribute inside the tag, like this:

I am not a code expert. Currently, I don’t know how to “dynamically” edit the HTML tag of Hubspot, using Javascript. Is someone could help by sharing the line of code, it would be great!

Best.