summaryrefslogtreecommitdiffstats
path: root/common/admin/administration.php
diff options
context:
space:
mode:
Diffstat (limited to 'common/admin/administration.php')
-rwxr-xr-xcommon/admin/administration.php11
1 files changed, 7 insertions, 4 deletions
diff --git a/common/admin/administration.php b/common/admin/administration.php
index 1202e91..26f6710 100755
--- a/common/admin/administration.php
+++ b/common/admin/administration.php
@@ -1,9 +1,10 @@
<?php
-require_once dirname(__FILE__) . '/inc/auth.inc.php';
-require_once dirname(__FILE__) . '/../app/app.php';
+require_once __DIR__ . '/../app/app.php';
+require_once __DIR__ . '/inc/auth.inc.php';
-$opml = OpmlManager::load(dirname(__FILE__) . '/../custom/people.opml');
+
+$opml = OpmlManager::load(__DIR__ . '/../custom/people.opml');
$opml_people = $opml->getPeople();
$page_id = 'admin-admin';
$header_extra = <<<"HTML"
@@ -23,6 +24,7 @@ $page_content = <<<"FRAGMENT"
<div class="widget">
<h3>{$l10n->getString('Clear cache')}</h3>
<form action="purgecache.php" method="post" id="frmPurge">
+ <input type="hidden" value="{$csrf->generate('frmPurge')}" name="_csrf">
<p><label>{$l10n->getString('Clear cache:')}</label><input type="submit" class="submit delete" name="purge" id="purge" value="{$l10n->getString('Clear')}" /></p>
<p class="help">{$l10n->getString('Clearing the cache will make moonmoon reload all feeds.')}</p>
</form>
@@ -31,6 +33,7 @@ $page_content = <<<"FRAGMENT"
<div class="widget">
<h3>{$l10n->getString('Change administrator password')}</h3>
<form action="changepassword.php" method="post" id="frmPassword">
+ <input type="hidden" value="{$csrf->generate('frmPassword')}" name="_csrf">
<p><label for="password">{$l10n->getString('New password:')}</label> <input type="password" class="text" value="" name="password" id="password" size="20" /> <input type="submit" class="submit delete" name="changepwd" id="changepwd" value="{$l10n->getString('Change password')}" /></p>
</form>
</div>
@@ -39,4 +42,4 @@ FRAGMENT;
$footer_extra = '';
$admin_access = 1;
-require_once dirname(__FILE__) . '/template.php';
+require_once __DIR__ . '/template.php';