Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 840ee6b

Browse files
committed
Add check to disable Disqus when running on file: protocol
1 parent 1321ec0 commit 840ee6b

1 file changed

Lines changed: 8 additions & 6 deletions

File tree

daux.patch

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
From 627771ccbadfbe51cce873f9d8da6826c1f3075a Mon Sep 17 00:00:00 2001
1+
From 875d9a377b7904c47583bbaa070b6e35c5c20638 Mon Sep 17 00:00:00 2001
22
From: Alexander Overvoorde <[email protected]>
3-
Date: Mon, 18 Jul 2016 23:58:13 +0200
3+
Date: Tue, 28 Mar 2017 11:21:50 +0200
44
Subject: [PATCH] Adjust theme for Vulkan tutorial
55

66
---
77
daux/VulkanLinkProcessor.php | 69 ++++
8-
templates/content.php | 24 +-
8+
templates/content.php | 26 +-
99
templates/layout/00_layout.php | 2 +-
1010
templates/layout/05_page.php | 17 +-
1111
themes/daux/css/theme-blue.min.css | 2 +-
@@ -20,7 +20,7 @@ Subject: [PATCH] Adjust theme for Vulkan tutorial
2020
themes/daux/less/structure.less | 27 +-
2121
themes/daux/less/theme-blue.less | 10 +-
2222
themes/daux_singlepage/css/main.min.css | 2 +-
23-
16 files changed, 922 insertions(+), 137 deletions(-)
23+
16 files changed, 924 insertions(+), 137 deletions(-)
2424
create mode 100644 daux/VulkanLinkProcessor.php
2525

2626
diff --git a/daux/VulkanLinkProcessor.php b/daux/VulkanLinkProcessor.php
@@ -99,7 +99,7 @@ index 0000000..82b908c
9999
+ }
100100
+?>
101101
diff --git a/templates/content.php b/templates/content.php
102-
index 2febe38..82e79cd 100644
102+
index 2febe38..03017b7 100644
103103
--- a/templates/content.php
104104
+++ b/templates/content.php
105105
@@ -2,17 +2,14 @@
@@ -122,13 +122,14 @@ index 2febe38..82e79cd 100644
122122
</div>
123123
<?php } ?>
124124

125-
@@ -26,5 +23,22 @@
125+
@@ -26,5 +23,24 @@
126126
</ul>
127127
</nav>
128128
<?php } ?>
129129
+
130130
+ <div id="disqus_thread"></div>
131131
+ <script>
132+
+ if (document.location.host) {
132133
+ var disqus_config = function() {
133134
+ var path = location.pathname;
134135
+ if (path == '/') path = '/Introduction';
@@ -141,6 +142,7 @@ index 2febe38..82e79cd 100644
141142
+ s.setAttribute('data-timestamp', +new Date());
142143
+ (d.head || d.body).appendChild(s);
143144
+ })();
145+
+ }
144146
+ </script>
145147
+ <noscript>Please enable JavaScript to view the <a href="https://disqus.com/?ref_noscript" rel="nofollow">comments powered by Disqus.</a></noscript>
146148
</article>

0 commit comments

Comments
 (0)