Only load Adsense in prod. and reset on each page

This commit is contained in:
Andrew Miner
2015-03-10 21:34:41 -07:00
parent ee75415729
commit 50c3d95440
27 changed files with 214 additions and 117 deletions
+33
View File
@@ -0,0 +1,33 @@
//-
//- Crafting Guide - app.jade
//-
//- Copyright (c) 2014-2015 by Redwood Labs
//- All rights reserved.
//-
doctype html
html
head
title The Ultimate Minecraft Crafting Guide
meta(charset="UTF-8")
link(href="/images/favicon.png", rel="icon", type="image/png")
block styles
link(rel="stylesheet", type="text/css", href="/css/main.css")
link(rel="stylesheet", type="text/css", href="/css/jquery-ui.css")
body
block body
.view__feedback
.view__screen
.content
include ./includes/_header.jade
.page
include ./includes/_footer.jade
block scripts
include ./includes/_standard_scripts.jade
include ./includes/_google_adsense.jade
include ./includes/_google_analytics.jade
include ./includes/_addthis.jade
+8
View File
@@ -0,0 +1,8 @@
//-
//- Crafting Guide - _google_adsense.jade
//-
//- Copyright (c) 2015 by Redwood Labs
//- All rights reserved.
//-
script(async, src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js")
+15
View File
@@ -0,0 +1,15 @@
//-
//- Crafting Guide - _standard_scripts.jade
//-
//- Copyright (c) 2015 by Redwood Labs
//- All rights reserved.
//-
script(src="/js/underscore.js")
script(src="/js/jquery.js")
script(src="/js/backbone.js")
script(src="/js/jade.js")
script(src="/js/markdown.js")
script(src="/js/when.js")
script(src="/js/jquery-ui.js")
script(src="/js/main.js")
View File
-20
View File
@@ -1,20 +0,0 @@
//-
//- Crafting Guide - index.jade
//-
//- Copyright (c) 2014-2015 by Redwood Labs
//- All rights reserved.
//-
extends ./layouts/basic
append styles
link(rel="stylesheet", type="text/css", href="/css/jquery-ui.css")
block content
.page
append scripts
script(src="/js/jquery-ui.js")
script(src="/js/main.js")
include ./includes/_google_analytics.jade
include ./includes/_addthis.jade
-38
View File
@@ -1,38 +0,0 @@
//-
//- Crafting Guide - basic.jade
//-
//- Copyright (c) 2014-2015 by Redwood Labs
//- All rights reserved.
//-
block basic-vars
- var pageTitle = 'Crafting Guide for Minecraft | The Ultimate Step-by-Step Tutorial for Making Anything in Minecraft'
doctype html
html
head
title= pageTitle
meta(charset="UTF-8")
link(href="/images/favicon.png", rel="icon", type="image/png")
block styles
link(rel="stylesheet", type="text/css", href="/css/main.css")
body
block body
.view__feedback
.view__screen
.content
include ../includes/_header.jade
block content
include ../includes/_footer.jade
block scripts
script(src="/js/underscore.js")
script(src="/js/jquery.js")
script(src="/js/backbone.js")
script(src="/js/jade.js")
script(src="/js/markdown.js")
script(src="/js/when.js")
@@ -0,0 +1,8 @@
//-
//- Crafting Guide - _adsense_sidebar_skyscraper.jade
//-
//- Copyright (c) 2015 by Redwood Labs
//- All rights reserved.
//-
ins.adsbygoogle.sidebar_skyscraper(data-ad-client="ca-pub-6593013914878730", data-ad-slot="7613920409")
+1 -1
View File
@@ -7,7 +7,7 @@
.view__browse_page
.sidebar
include ./includes/_sidebar_skyscraper.html
.view__adsense
.mainBody
h2: p Active Mods
+1 -1
View File
@@ -7,7 +7,7 @@
.view__configure_page
.sidebar
include ./includes/_sidebar_skyscraper.html
.view__adsense
.mainBody
.view__mod_pack
+2 -2
View File
@@ -7,6 +7,8 @@
.view__home_page
.sidebar
.view__adsense
.titleImage <a href="/browse/minecraft/"><img src="/browse/minecraft/icon.png"></a>
.titleImage <a href="/browse/buildcraft/"><img src="/browse/buildcraft/icon.png"></a>
.titleImage <a href="/browse/industrial_craft_2/"><img src="/browse/industrial_craft_2/icon.png"></a>
@@ -15,8 +17,6 @@
.titleImage <a href="/browse/enderio/"><img src="/browse/enderio/icon.png"></a>
.titleImage <a href="/browse/railcraft/"><img src="/browse/railcraft/icon.png"></a>
include ./includes/_sidebar_skyscraper.html
.mainBody
.section
h2 Welcome!
@@ -1,9 +0,0 @@
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- Sidebar Skyscraper -->
<ins class="adsbygoogle"
style="display:inline-block;width:160px;height:600px"
data-ad-client="ca-pub-6593013914878730"
data-ad-slot="7613920409"></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>
+1 -1
View File
@@ -10,7 +10,7 @@
.titleImage: a: img
a.craftingPlan.externalLink: p See Crafting Plan
include ./includes/_sidebar_skyscraper.html
.view__adsense
.mainBody
h1.name
+1 -1
View File
@@ -13,7 +13,7 @@
a.documentation.externalLink(target="new"): p Documentation
a.download.externalLink(target="new"): p Download
include ./includes/_sidebar_skyscraper.html
.view__adsense
.mainBody
h1.name
+25 -10
View File
@@ -5,16 +5,31 @@
//- All rights reserved.
//-
extend ./layouts/basic
doctype html
html
head
title Crafting Guide Unit Tests
meta(charset="UTF-8")
link(href="/images/favicon.png", rel="icon", type="image/png")
append styles
link(rel="stylesheet", type="text/css", href="css/mocha.css")
style #mocha-stats { position: absolute; top: 12em; }
block styles
link(rel="stylesheet", type="text/css", href="/css/main.css")
link(rel="stylesheet", type="text/css", href="css/mocha.css")
style #mocha-stats { position: absolute; top: 12em; }
block content
#mocha
body
block body
.view__feedback
.view__screen
append scripts
script(src="/js/mocha.js")
script(src="/js/chai.js")
script(src="/js/test.js")
.content
include ./includes/_header.jade
.page
#mocha
include ./includes/_footer.jade
block scripts
include ./includes/_standard_scripts.jade
script(src="/js/mocha.js")
script(src="/js/chai.js")
script(src="/js/test.js")