]> git.mxchange.org Git - friendica.git/blobdiff - mod/removeme.php
Merge pull request #2118 from annando/1511-supported-networks
[friendica.git] / mod / removeme.php
index 62b9a6d13aa561491ca8af6d9f7cfcdfcf6ae84e..904606fd57cb77b69a1a0b7ef48a9025ff012f25 100644 (file)
@@ -5,6 +5,9 @@ function removeme_post(&$a) {
        if(! local_user())
                return;
 
+       if(x($_SESSION,'submanage') && intval($_SESSION['submanage']))
+               return;
+
        if((! x($_POST,'qxz_password')) || (! strlen(trim($_POST['qxz_password']))))
                return;
 
@@ -24,18 +27,19 @@ function removeme_post(&$a) {
 
 }
 
-
-
 function removeme_content(&$a) {
 
        if(! local_user())
-               goaway($a->get_baseurl());
+               goaway(z_root());
 
        $hash = random_string();
 
+        require_once("mod/settings.php");
+        settings_init($a);
+
        $_SESSION['remove_account_verify'] = $hash;
 
-       $tpl = load_view_file('view/removeme.tpl');
+       $tpl = get_markup_template('removeme.tpl');
        $o .= replace_macros($tpl, array(
                '$basedir' => $a->get_baseurl(),
                '$hash' => $hash,
@@ -45,6 +49,6 @@ function removeme_content(&$a) {
                '$submit' => t('Remove My Account')
        ));
 
-       return $o;              
+       return $o;
 
-}
\ No newline at end of file
+}