/** * Return url of password reset page * * @param string $context * * @return string */ function appthemes_get_password_reset_url($context = 'display') { $args = array(); if (!empty($_GET['action']) && 'rp' == $_GET['action'] && !empty($_GET['key']) && !empty($_GET['login'])) { $args = array('action' => $_GET['action'], 'key' => $_GET['key'], 'login' => rawurlencode($_GET['login'])); } if (current_theme_supports('app-login') && ($page_id = APP_Password_Reset::get_id())) { $url = get_permalink($page_id); $url = add_query_arg($args, $url); } else { $url = add_query_arg($args, site_url('wp-login.php')); } return esc_url($url, null, $context); }
function __construct($template) { self::$_template = $template; parent::__construct($template, __('Password Reset', APP_TD)); }