From: Andrew Bonventre Date: Thu, 3 Aug 2017 16:33:26 +0000 (-0400) Subject: doc: hide blog content for golang.google.cn X-Git-Tag: go1.9rc2~1^2~17 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=cc402c2c4dd835e98b274aa7d80504cca76b2370;p=gostls13.git doc: hide blog content for golang.google.cn /blog redirects to blog.golang.org (currently blocked in China) unless there is a local checkout of golang.org/x/blog, which is not possible on App Engine Classic. Change-Id: Ia695e663c9bebcc6c3bedea324c630299eaad4dc Reviewed-on: https://go-review.googlesource.com/53051 Reviewed-by: Chris Broadfoot --- diff --git a/doc/root.html b/doc/root.html index 0b3c74954b..9bdf927480 100644 --- a/doc/root.html +++ b/doc/root.html @@ -77,15 +77,14 @@ Linux, Mac OS X, Windows, and more. -{{end}} -
+
Featured articles
-
- +
+{{end}}
@@ -93,7 +92,25 @@ Linux, Mac OS X, Windows, and more. (function() { 'use strict'; - function readableTime(t) { + window.initFuncs.push(function() { + // Set up playground if enabled. + if (window.playground) { + window.playground({ + "codeEl": "#learn .code", + "outputEl": "#learn .output", + "runEl": "#learn .run", + "shareEl": "#learn .share", + "shareRedirect": "//play.golang.org/p/", + "toysEl": "#learn .toys select" + }); + } else { + $('#learn').hide() + } + }); + + {{if not $.GoogleCN}} + + function readableTime(t) { var m = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"]; var p = t.substring(0, t.indexOf("T")).split("-"); @@ -123,29 +140,11 @@ Linux, Mac OS X, Windows, and more. } window.initFuncs.push(function() { - // Set up playground if enabled. - if (window.playground) { - window.playground({ - "codeEl": "#learn .code", - "outputEl": "#learn .output", - "runEl": "#learn .run", - "shareEl": "#learn .share", - "shareRedirect": "//play.golang.org/p/", - "toysEl": "#learn .toys select" - }); - } else { - $('#learn').hide() - } - // Load blog feed. $('