X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fregmod.php;h=bbe733003a56dfe11ea9affceabd03f7be00fcb0;hb=af42e5e481832353550aea9b4373fba3c7ae1a6a;hp=96708eeaa4d521085cbee536a0d87e64477a6e94;hpb=3b4a20f9878b5179fceb222c857599f657b9d1a4;p=friendica.git diff --git a/mod/regmod.php b/mod/regmod.php index 96708eeaa4..bbe733003a 100644 --- a/mod/regmod.php +++ b/mod/regmod.php @@ -1,6 +1,7 @@ get_baseurl() . '/profile/' . $user[0]['nickname']; - if($url && strlen(get_config('system','directory_submit_url'))) - proc_run('php',"include/directory.php","$url"); + if($url && strlen(get_config('system','directory'))) + proc_run(PRIORITY_LOW, "include/directory.php", $url); } push_lang($register[0]['language']); - $email_tpl = get_intltext_template("register_open_eml.tpl"); - $email_tpl = replace_macros($email_tpl, array( - '$sitename' => $a->config['sitename'], - '$siteurl' => $a->get_baseurl(), - '$username' => $user[0]['username'], - '$email' => $user[0]['email'], - '$password' => $register[0]['password'], - '$uid' => $user[0]['uid'] - )); - - $res = mail($user[0]['email'], email_header_encode( sprintf(t('Registration details for %s'), $a->config['sitename']), 'UTF-8'), - $email_tpl, - 'From: ' . 'Administrator' . '@' . $_SERVER['SERVER_NAME'] . "\n" - . 'Content-type: text/plain; charset=UTF-8' . "\n" - . 'Content-transfer-encoding: 8bit' ); + send_register_open_eml( + $user[0]['email'], + $a->config['sitename'], + $a->get_baseurl(), + $user[0]['username'], + $register[0]['password']); pop_lang(); @@ -128,10 +120,14 @@ function regmod_content(&$a) { if($cmd === 'deny') { - if (!user_deny($hash)) killme(); + user_deny($hash); + goaway($a->get_baseurl()."/admin/users/"); + killme(); } if($cmd === 'allow') { - if (!user_allow($hash)) killme(); + user_allow($hash); + goaway($a->get_baseurl()."/admin/users/"); + killme(); } }