aboutsummaryrefslogtreecommitdiff
path: root/index.php
diff options
context:
space:
mode:
authorMaZderMind2015-07-13 14:03:13 +0200
committerMaZderMind2015-07-13 14:03:13 +0200
commita3becf276c03ed21e7a3a5a18b8698a90dbe6fa3 (patch)
treef0a6a56794170abcc0a46a395a8b5cef4dd12c40 /index.php
parentf581ebf00c7443c7b346b2085279fe60438e8954 (diff)
Prepare URLs in index
Diffstat (limited to '')
-rw-r--r--index.php10
1 files changed, 9 insertions, 1 deletions
diff --git a/index.php b/index.php
index 097c61e..11495df 100644
--- a/index.php
+++ b/index.php
@@ -28,8 +28,9 @@ $conference = new Conference();
$tpl = new PhpTemplate('template/page.phtml');
$tpl->set(array(
- 'baseurl' => baseurl(),
+ 'baseurl' => forceslash(baseurl()),
'route' => $route,
+ 'canonicalurl' => forceslash(baseurl()).forceslash($route),
'assemblies' => './template/assemblies/',
'conference' => $conference,
@@ -37,6 +38,13 @@ $tpl->set(array(
'schedule' => new Schedule(),
));
+if(startswith('//', @$GLOBALS['CONFIG']['BASEURL']))
+{
+ $tpl->set(array(
+ 'httpsurl' => forceslash('https:'.$GLOBALS['CONFIG']['BASEURL']).forceslash($route),
+ 'httpurl' => forceslash('http:'. $GLOBALS['CONFIG']['BASEURL']).forceslash($route),
+ ));
+}
ob_start();
try {