summaryrefslogtreecommitdiff
path: root/mod.php
diff options
context:
space:
mode:
authorSavetheinternet <savetheinternet@n0v4.com>2011-04-06 18:31:26 +1000
committerSavetheinternet <savetheinternet@n0v4.com>2011-04-06 18:31:26 +1000
commit08bbd3f9127204aa4bc8be18fdc6ca6d68d88ff1 (patch)
tree28c204c3907e70f0e49620658f8736d9258c4dce /mod.php
parent10bd465ea366023769b047050d48b0e81d513b9b (diff)
Post saving/cache and Google Analytics integration
Diffstat (limited to 'mod.php')
-rw-r--r--mod.php18
1 files changed, 18 insertions, 0 deletions
diff --git a/mod.php b/mod.php
index c7ee054b..15a602c2 100644
--- a/mod.php
+++ b/mod.php
@@ -174,6 +174,24 @@
destroyCookies();
header('Location: ?/', true, $config['redirect_http']);
+ } elseif(preg_match('/^\/confirm\/(.+)$/', $query, $matches)) {
+ $uri = $matches[1];
+
+ $body = '<p style="text-align:center">' .
+ '<span class="heading" style="margin-bottom:6px">Are you sure you want to do that?</span>' .
+ 'You clicked ' .
+ '<strong>?/' . htmlentities($uri) . '</strong>' .
+ ' but had Javascript disabled, so we weren\'t able to serve the confirmation dialog.' .
+ '</p>' .
+ '<p style="text-align:center"><a style="margin:block;font-size:150%;font-weight:bold" href="?/' . htmlentities($uri) . '">Confirm.</a></p>';
+
+ echo Element('page.html', Array(
+ 'config'=>$config,
+ 'title'=>'Confirm',
+ 'body'=>$body,
+ 'mod'=>true
+ )
+ );
} elseif(preg_match('/^\/log$/', $query)) {
if($mod['type'] < $config['mod']['modlog']) error($config['error']['noaccess']);