summaryrefslogtreecommitdiff
path: root/templates/header.html
diff options
context:
space:
mode:
authorczaks <marcin@6irc.net>2014-01-29 22:43:09 +0100
committerczaks <marcin@6irc.net>2014-01-29 22:53:31 +0100
commit4636f5b6efeabbdb8ead0b6f2ce96212fbed75b7 (patch)
tree8f4af74ffa47d34614cb75584a09bb2c15f55b24 /templates/header.html
parent31584986e47b2e796f10c547c115080e028937ed (diff)
fix watch.js on nonstandard paths; fixes vichan-devel#38
this commit also adds a modRoot js variable that makes proper modlinks. also fixed in watch.js
Diffstat (limited to 'templates/header.html')
-rw-r--r--templates/header.html6
1 files changed, 5 insertions, 1 deletions
diff --git a/templates/header.html b/templates/header.html
index 0f4bd260..63725b73 100644
--- a/templates/header.html
+++ b/templates/header.html
@@ -5,7 +5,11 @@
{% if config.meta_keywords %}<meta name="keywords" content="{{ config.meta_keywords }}">{% endif %}
{% if config.default_stylesheet.1 != '' %}<link rel="stylesheet" type="text/css" id="stylesheet" href="{{ config.uri_stylesheets }}{{ config.default_stylesheet.1 }}">{% endif %}
{% if config.font_awesome %}<link rel="stylesheet" media="screen" href="{{ config.root }}{{ config.font_awesome_css }}">{% endif %}
- <script type="text/javascript">var configRoot="{{ config.root }}";</script>
+ <script type="text/javascript">
+ var configRoot="{{ config.root }}";
+ var inMod = {% if mod %}true{% else %}false{% end %};
+ var modRoot="{{ config.root }}"+(inMod ? "mod.php?/" : "");
+ </script>
{% if not nojavascript %}
<script type="text/javascript" src="{{ config.url_javascript }}"></script>
{% if not config.additional_javascript_compile %}