How to set up Google Webmaster Tools validation in Discourse?

faq-material

#1

Greetings guys, i hope this is not really ‘stupid’ question as it looks like, but i have trouble finding public folder where i can add all sort of files for example; google verification html code.

its suppose to be in www.mydomain.com/google713614167245617.html – but cannot find where is that public folder located for some reason. I’ve installed discourse by following the official guide and i must say it works flawlessly (Thanks for creating such amazing, amazing platform!) Thanks for your time reading this and your patience with me. :smile:


Where is uploads folder?
How to upload google webmasters verify file?
Google crawler errors / Discourse forum down
(Jeff Atwood) #2

Don’t do it that way. Add a HTML header for Google Webmaster verification. You can change headers via, Admin, Customize, HTML, </head>


(Mực Tàu) #3

I actually do not know what exactly I should do. The following line is the one Google asks me to place between and

I do not know anything about code. Is the way I did like the attached picture below right?

Many thanks


(Neil Lalonde) #4

It needs to go in the </head> section.


(Mực Tàu) #5

I have just done!
Thank you so much Neil :smile:


#6

If you setup first Google Analytics, you can add Google Webmaster Tools without adding anything particular. GA code is used to authenticated ownership on GWT.


(Yoan) #7

Hi, sorry for reviving old thread, but, I have some difficulties doing steps above, I have found the Customization tab, but can’t paste the text from the Google Webmaster. I can’t even type anything there, please help me? What should I do? I have no knowledge about code and such.


(Todd B.) #8

Having tried this way myself then check to see if it worked using:

dig +short -t TXT mydomain.com

Adding the meta code to the theme’s HEAD tag does nothing. The same with using the Domain Verification and so on.


(Stephen) #9

You see a totally different version of the site to robots.

TXT records are the way to go.


(Todd B.) #10

I hear you, but is there another means of accessing the Head tag?


(Stephen) #11

Do you not have access to DNS for your domain, or contact with anyone who does?

Is this for LGC? I’ve checked and even with JavaScript disabled your verification tag appears, but it’s in there twice:

From previous experience I know that Google Domain Verification spits the dummy out if you don’t remove old tags before adding new ones, it’s possible it sees two of the same tag in the same way.


(Todd B.) #12

I hear what you’re saying but the main LGC site and the forum are on two different servers.

So the A record points to two separate IP’s.
Thanks for the heads up regarding site verification. Not sure why it shows up twice.

But the Discourse site that is forum.linuxgameconsortium.com.

For the heck of it I added the TXT record for the forum.


(Stephen) #13

The forum is the page I was looking at, and I appreciate that they’re on different servers, hence suggesting you add a tag for the forum subdomain. Either way, forum has has double Google tags in the source.

It appears you’re also blocking crawlers:


(Todd B.) #14

Well I am have added the verification to just the Common area of the Theme in the Head tag.
Removing anything in desktop and mobile.

Okay… it works now. I cleared the ‘crawler bots’ and set ‘cookies’ to LAX. :slight_smile:

Thanks for the help Stephen