• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP wp_lostpassword_url函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中wp_lostpassword_url函数的典型用法代码示例。如果您正苦于以下问题:PHP wp_lostpassword_url函数的具体用法?PHP wp_lostpassword_url怎么用?PHP wp_lostpassword_url使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了wp_lostpassword_url函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: wp_login_form

    function wp_login_form($args = array())
    {
        $defaults = array('redirect' => (is_ssl() ? 'https://' : 'http://') . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'], 'form_id' => uniqid('loginform_'), 'label_username' => __('Username', 'dfd'), 'placeholder_username' => __('Enter your login', 'dfd'), 'label_password' => __('Password', 'dfd'), 'placeholder_password' => __('Enter your password', 'dfd'), 'label_lost_password' => __('Lost password', 'dfd'), 'label_log_in' => __('Log In', 'dfd'), 'id_username' => uniqid('user_login_'), 'id_password' => uniqid('user_pass_'), 'id_submit' => uniqid('wp-submit_'), 'lost_password' => true, 'value_username' => '');
        $args = wp_parse_args($args, apply_filters('login_form_defaults', $defaults));
        $registration_link = '';
        if (get_option('users_can_register')) {
            $registration_link = '
			<a href="' . wp_registration_url() . '"><i class="ios7icon-lock"></i>' . __('Registration', 'dfd') . '</a>
		';
        }
        $form = '
		<form name="' . $args['form_id'] . '" id="' . $args['form_id'] . '" action="' . esc_url(site_url('wp-login.php', 'login_post')) . '" method="post">
			' . apply_filters('login_form_top', '', $args) . '
			<p class="login-username">
				<label for="' . esc_attr($args['id_username']) . '">' . esc_html($args['label_username']) . '</label>
				<input type="text" name="log" id="' . esc_attr($args['id_username']) . '" class="input" value="' . esc_attr($args['value_username']) . '" size="20" placeholder="' . esc_html($args['placeholder_username']) . '" />
			</p>
			<p class="login-password">
				<label for="' . esc_attr($args['id_password']) . '">' . esc_html($args['label_password']) . '</label>
				<input type="password" name="pwd" id="' . esc_attr($args['id_password']) . '" class="input" value="" size="20" placeholder="' . esc_html($args['placeholder_password']) . '" />
			</p>
			<p class="login-submit">
				<button type="submit" name="wp-submit" id="' . esc_attr($args['id_submit']) . '" class="button"><i class="icon-arrow-left-1"></i>' . esc_attr($args['label_log_in']) . '</button>
				<input type="hidden" name="redirect_to" value="' . esc_url($args['redirect']) . '" />
			</p>
			' . ($args['lost_password'] ? '<p class="login-lost-password"><label>' . '<a href="' . wp_lostpassword_url() . '">' . esc_attr($args['label_lost_password']) . '</a></label></p>' : '') . '<p class="login-registration">
				' . $registration_link . '
			</p>' . apply_filters('login_form_bottom', '', $args) . '
		</form>';
        echo $form;
    }
开发者ID:sabdev1,项目名称:ljcdevsab,代码行数:31,代码来源:widget-login.php


示例2: ap_scripts_front

function ap_scripts_front()
{
    wp_enqueue_script('jquery');
    wp_enqueue_script('jquery-form', array('jquery'), false);
    wp_enqueue_script('ap-functions-js', ANSPRESS_URL . 'assets/prod/ap-functions.min.js', array('jquery', 'jquery-form'));
    wp_enqueue_script('ap-anspress_script', ANSPRESS_URL . 'assets/prod/anspress_site.min.js', array('jquery', 'jquery-form'), AP_VERSION);
    wp_enqueue_script('peity-js', ap_get_theme_url('js/jquery.peity.min.js'), 'jquery', AP_VERSION);
    wp_enqueue_script('ap-initial.js', ap_get_theme_url('js/initial.min.js'), 'jquery', AP_VERSION);
    wp_enqueue_script('ap-scrollbar.js', ap_get_theme_url('js/jquery.scrollbar.min.js'), 'jquery', AP_VERSION);
    wp_enqueue_script('ap-js', ap_get_theme_url('prod/ap.min.js'), array('jquery', 'jquery-form'), AP_VERSION);
    wp_enqueue_style('ap-style', ap_get_theme_url('css/main.css'), array(), AP_VERSION);
    $custom_css = '
        #anspress .ap-q-cells{
                margin-left: ' . (ap_opt('avatar_size_qquestion') + 10) . 'px;
        }
        #anspress .ap-a-cells{
                margin-left: ' . (ap_opt('avatar_size_qanswer') + 10) . 'px;
        }#anspress .ap-comment-content{
                margin-left: ' . (ap_opt('avatar_size_qcomment') + 15) . 'px;
        }';
    wp_add_inline_style('ap-style', $custom_css);
    wp_enqueue_style('ap-fonts', ap_get_theme_url('fonts/style.css'), array(), AP_VERSION);
    do_action('ap_enqueue');
    wp_enqueue_style('ap-responsive', ap_get_theme_url('css/responsive.css'), array(), AP_VERSION);
    wp_enqueue_style('ap-overrides', ap_get_theme_url('css/overrides.css'), array(), AP_VERSION);
    echo '<script type="text/javascript">';
    echo 'var ajaxurl = "' . admin_url('admin-ajax.php') . '",';
    echo 'ap_nonce 	= "' . wp_create_nonce('ap_ajax_nonce') . '",';
    echo 'ap_max_tags = "' . ap_opt('max_tags') . '",';
    echo 'disable_hover_card = "' . (ap_opt('disable_hover_card') ? true : false) . '"';
    echo '</script>';
    wp_localize_script('ap-anspress_script', 'aplang', array('password_field_not_macthing' => __('Password not matching', 'ap'), 'password_length_less' => __('Password length must be 6 or higher', 'ap'), 'not_valid_email' => __('Not a valid email', 'ap'), 'username_less' => __('Username length must be 4 or higher', 'ap'), 'username_not_avilable' => __('Username not available', 'ap'), 'email_already_in_use' => sprintf(__('Email already in use. %sDo you want to reset your password?%s', 'ap'), '<a href="' . wp_lostpassword_url() . '">', '</a>'), 'loading' => __('Loading', 'ap'), 'sending' => __('Sending request', 'ap'), 'adding_to_fav' => __('Adding question to your favorites', 'ap'), 'voting_on_post' => __('Sending your vote', 'ap'), 'requesting_for_closing' => __('Requesting for closing this question', 'ap'), 'sending_request' => __('Submitting request', 'ap'), 'loading_comment_form' => __('Loading comment form', 'ap'), 'submitting_your_question' => __('Sending your question', 'ap'), 'submitting_your_answer' => __('Sending your answer', 'ap'), 'submitting_your_comment' => __('Sending your comment', 'ap'), 'deleting_comment' => __('Deleting comment', 'ap'), 'updating_comment' => __('Updating comment', 'ap'), 'loading_form' => __('Loading form', 'ap'), 'saving_labels' => __('Saving labels', 'ap'), 'loading_suggestions' => __('Loading suggestions', 'ap'), 'uploading_cover' => __('Uploading cover', 'ap'), 'saving_profile' => __('Saving profile', 'ap'), 'sending_message' => __('Sending message', 'ap'), 'loading_conversation' => __('Loading conversation', 'ap'), 'loading_new_message_form' => __('Loading new message form', 'ap'), 'loading_more_conversations' => __('Loading more conversations', 'ap'), 'searching_conversations' => __('Searching conversations', 'ap'), 'loading_message_edit_form' => __('Loading message form', 'ap'), 'updating_message' => __('Updating message', 'ap'), 'deleting_message' => __('Deleting message', 'ap'), 'uploading' => __('Uploading', 'ap'), 'error' => ap_icon('error'), 'warning' => ap_icon('warning'), 'success' => ap_icon('success'), 'not_valid_response' => __('Something went wrong in server side, not a valid response.', 'ap')));
    wp_localize_script('ap-site-js', 'apoptions', array('ajaxlogin' => ap_opt('ajax_login')));
}
开发者ID:kennyma603,项目名称:anspress,代码行数:34,代码来源:functions.php


示例3: v_forcelogin

function v_forcelogin()
{
    if (!is_user_logged_in() && (v_getUrl() != wp_login_url() && v_getUrl() != wp_registration_url() && v_getUrl() != wp_lostpassword_url())) {
        wp_redirect(wp_login_url(), 302);
        exit;
    }
}
开发者ID:pixeline,项目名称:wp-projecthub,代码行数:7,代码来源:functions.force-login.php


示例4: enqueue_api_scripts

    public function enqueue_api_scripts()
    {
        if (!$this->_data->get_option('accept_api_logins')) {
            return false;
        }
        $domain = get_bloginfo('name');
        $domain = $domain ? $domain : __('WordPress', Eab_EventsHub::TEXT_DOMAIN);
        $show_facebook = !$this->_data->get_option('api_login-hide-facebook');
        $show_twitter = !$this->_data->get_option('api_login-hide-twitter');
        $show_google = !$this->_data->get_option('api_login-hide-google');
        $registration_msg = '';
        $registration_services = array();
        if ($show_facebook) {
            $registration_services[] = 'Facebook';
        }
        if ($show_twitter) {
            $registration_services[] = 'Twitter';
        }
        if ($show_google) {
            $registration_services[] = 'Google';
        }
        // Properly enumerate supported service IDs and construct the registration supplement message.
        if (!empty($registration_services)) {
            if (count($registration_services) > 1) {
                $supported_ids = sprintf(_x('%s or %s', 'Supported registration services: the first variable can be single service or comma-separated enumeration', Eab_EventsHub::TEXT_DOMAIN), join(', ', array_slice($registration_services, 0, count($registration_services) - 1)), end($registration_services));
            } else {
                $supported_ids = end($registration_services);
            }
            $registration_msg = sprintf(_x(' - or just click cancel to register using your %s ID', 'Registration supplemental message part', Eab_EventsHub::TEXT_DOMAIN), $supported_ids);
        }
        wp_enqueue_script('eab_api_js', plugins_url('events-and-bookings/js/eab-api.js'), array('jquery'), Eab_EventsHub::CURRENT_VERSION);
        wp_localize_script('eab_api_js', 'l10nEabApi', apply_filters('eab-javascript-api_vars', array('facebook' => __('Login with Facebook', Eab_EventsHub::TEXT_DOMAIN), 'twitter' => __('Login with Twitter', Eab_EventsHub::TEXT_DOMAIN), 'google' => __('Login with Google', Eab_EventsHub::TEXT_DOMAIN), 'wordpress' => sprintf(__('Login with %s', Eab_EventsHub::TEXT_DOMAIN), $domain), 'cancel' => __('Cancel', Eab_EventsHub::TEXT_DOMAIN), 'please_wait' => __('Please, wait...', Eab_EventsHub::TEXT_DOMAIN), 'wp_register' => __('Register', Eab_EventsHub::TEXT_DOMAIN), 'wp_registration_msg' => sprintf(_x('Create a username in order to register for this event %s', 'The variable is registration supplemental part', Eab_EventsHub::TEXT_DOMAIN), $registration_msg), 'wp_login' => __('Log in', Eab_EventsHub::TEXT_DOMAIN), 'wp_login_msg' => sprintf(_x('Login with your existing username in order to register for this event %s', 'The variable is registration supplemental part', Eab_EventsHub::TEXT_DOMAIN), $registration_msg), 'wp_username' => __('Username', Eab_EventsHub::TEXT_DOMAIN), 'wp_password' => __('Password', Eab_EventsHub::TEXT_DOMAIN), 'wp_email' => __('Email', Eab_EventsHub::TEXT_DOMAIN), 'wp_toggle_on' => __('Already a member? Log in here', Eab_EventsHub::TEXT_DOMAIN), 'wp_toggle_off' => __('Click here to register', Eab_EventsHub::TEXT_DOMAIN), 'wp_lost_pw_text' => __('Forgot your password', Eab_EventsHub::TEXT_DOMAIN), 'wp_lost_pw_url' => wp_lostpassword_url(), 'wp_submit' => __('Submit', Eab_EventsHub::TEXT_DOMAIN), 'wp_cancel' => __('Cancel', Eab_EventsHub::TEXT_DOMAIN), 'data' => array('show_facebook' => $show_facebook, 'show_twitter' => $show_twitter, 'show_google' => $show_google, 'show_wordpress' => !$this->_data->get_option('api_login-hide-wordpress'), 'gg_client_id' => $this->_data->get_option('google-client_id')), 'wp_missing_username_password' => __('Username and password are required!', Eab_EventsHub::TEXT_DOMAIN), 'wp_username_pass_invalid' => __('Invalid username or password!', Eab_EventsHub::TEXT_DOMAIN), 'wp_missing_user_email' => __('Username and email are required!', Eab_EventsHub::TEXT_DOMAIN), 'wp_signup_error' => __('Your email/username is already taken or email is invalid!', Eab_EventsHub::TEXT_DOMAIN))));
        if (!$this->_data->get_option('facebook-no_init')) {
            if (defined('EAB_INTERNAL_FLAG__FB_INIT_ADDED')) {
                return false;
            }
            add_action('wp_footer', create_function('', "echo '" . sprintf('<div id="fb-root"></div><script type="text/javascript">
				window.fbAsyncInit = function() {
					FB.init({
					  appId: "%s",
					  status: true,
					  cookie: true,
					  xfbml: true,
					  version    : "v2.5"
					});
				};
				// Load the FB SDK Asynchronously
				(function(d){
					var js, id = "facebook-jssdk"; if (d.getElementById(id)) {return;}
					js = d.createElement("script"); js.id = id; js.async = true;
					js.src = "//connect.facebook.net/en_US/all.js";
					d.getElementsByTagName("head")[0].appendChild(js);
				}(document));
				</script>', $this->_data->get_option('facebook-app_id')) . "';"));
            define('EAB_INTERNAL_FLAG__FB_INIT_ADDED', true, true);
        }
    }
开发者ID:nayabbukhari,项目名称:circulocristiano,代码行数:57,代码来源:class_eab_api.php


示例5: accesspress_password_recovery_link_shortcode

/**
 * Generate a password recovery link.
 *
 * @since 2.0.2
 */
function accesspress_password_recovery_link_shortcode($atts)
{
    $atts = shortcode_atts(array('text' => __('Lost Password?', 'premise')), $atts);
    if (is_user_logged_in()) {
        return;
    }
    $redirect = add_query_arg('just-logged-in', 'true', get_permalink(accesspress_get_option('login_page')));
    return sprintf('<a href="%s">%s</a>', wp_lostpassword_url(esc_url_raw($redirect)), current_user_can('unfiltered_html') ? $atts['text'] : esc_html($atts['text']));
}
开发者ID:hscale,项目名称:webento,代码行数:14,代码来源:shortcodes.php


示例6: widget

 /**
  * Widget
  * Display the widget in the sidebar
  * Save output to the cache if empty
  *
  * @param  array  sidebar arguments
  * @param  array  instance
  */
 public function widget($args, $instance)
 {
     extract($args);
     // Print the widget wrapper
     echo $before_widget;
     if (is_user_logged_in()) {
         // Get current user instance
         global $current_user;
         // Print title
         $title = $instance['title_user'] ? $instance['title_user'] : __('Hey %s!', 'jigoshop');
         if ($title) {
             echo $before_title . sprintf($title, ucwords($current_user->display_name)) . $after_title;
         }
         // Create the default set of links
         $links = apply_filters('jigoshop_widget_logout_user_links', array(__('My Account', 'jigoshop') => get_permalink(jigoshop_get_page_id('myaccount')), __('Change Password', 'jigoshop') => get_permalink(jigoshop_get_page_id('change_password')), __('Logout', 'jigoshop') => wp_logout_url(home_url())));
     } else {
         // Print title
         $title = $instance['title_guest'] ? $instance['title_guest'] : __('Login', 'jigoshop');
         if ($title) {
             echo $before_title . $title . $after_title;
         }
         do_action('jigoshop_widget_login_before_form');
         // Get redirect URI
         $redirect_to = apply_filters('jigoshop_widget_login_redirect', get_permalink(jigoshop_get_page_id('myaccount')));
         $fields = array();
         // Support for other plugins which uses GET parameters
         $fields = apply_filters('jigoshop_get_hidden_fields', $fields);
         echo "<form action='" . esc_url(wp_login_url($redirect_to)) . "' method='post' class='jigoshop_login_widget'>";
         foreach ($fields as $key => $value) {
             echo '<input type="hidden" name="' . $key . '" value="' . $value . '" />';
         }
         // Username
         echo "\n\t\t\t<p>\n\t\t\t\t<label for='log'>" . __('Username', 'jigoshop') . "</label>\n\t\t\t\t<input type='text' name='log' id='log' class='input-text username' />\n\t\t\t</p>\n\t\t\t";
         // Password
         echo "\n\t\t\t<p>\n\t\t\t\t<label for='pwd'>" . __('Password', 'jigoshop') . "</label>\n\t\t\t\t<input type='password' name='pwd' id='pwd' class='input-text password' />\n\t\t\t</p>\n\t\t\t";
         echo "\n\t\t\t<p>\n\t\t\t\t<input type='submit' name='submit' value='" . __('Login', 'jigoshop') . "' class='input-submit' />\n\t\t\t\t<a class='forgot' href='" . esc_url(wp_lostpassword_url($redirect_to)) . "'>" . __('Forgot it?', 'jigoshop') . "</a>\n\t\t\t</p>\n\t\t\t";
         if (Jigoshop_Base::get_options()->get('jigoshop_enable_signup_form') == 'yes') {
             echo '<p class="register">';
             wp_register(__('New user?', 'jigoshop') . ' ', '');
             echo '</p>';
         }
         echo "</form>";
         do_action('jigoshop_widget_login_after_form');
         $links = apply_filters('jigoshop_widget_login_user_links', array());
     }
     // Loop & print out the links
     if ($links) {
         echo "\n\t\t\t<nav role='navigation'>\n\t\t\t\t<ul class='pagenav'>";
         foreach ($links as $title => $href) {
             $href = esc_url($href);
             echo "<li><a title='Go to {$title}' href='{$href}'>{$title}</a></li>";
         }
         echo "\n\t\t\t\t</ul>\n\t\t\t</nav>";
     }
     // Print closing widget wrapper
     echo $after_widget;
 }
开发者ID:ashik968,项目名称:digiplot,代码行数:65,代码来源:user_login.php


示例7: get_url

 /**
  * @param $page
  */
 function get_url($page)
 {
     switch ($page) {
         case 'lostpassword':
             return esc_url(wp_lostpassword_url());
         case 'logout':
             return wp_logout_url(get_permalink());
     }
 }
开发者ID:hoangsoft90,项目名称:hw-hoangweb-plugin,代码行数:12,代码来源:hw-context-user.php


示例8: pp_password_reset_url

/**
 * Return ProfilePress password reset url.
 *
 * @return bool|string
 */
function pp_password_reset_url()
{
    $data = pp_db_data();
    $db_url = $data['set_lost_password_url'];
    if (!empty($db_url)) {
        return get_permalink($db_url);
    } else {
        return wp_lostpassword_url();
    }
}
开发者ID:artre,项目名称:study,代码行数:15,代码来源:global-functions.php


示例9: wpjb_snipp_password_reminder_link

/**
 * Adds "Remind Password" link to WPJB login forms.
 *
 * This function uses wpjb_shortcode_login filter to create and insert
 * remind password link.
 *
 * @param Daq_View View object to be updated
 * @return Daq_View Updated View object
 */
function wpjb_snipp_password_reminder_link(Daq_View $view)
{
    $buttons = $view->buttons;
    // Add another button (technically this can be any HTML tag)
    $buttons[] = array("tag" => "a", "href" => wp_lostpassword_url(), "html" => "Remind Password");
    // Note you cannot modify $view->buttons array directly,
    // you can only assign value to it.
    $view->buttons = $buttons;
    return $view;
}
开发者ID:simpliko,项目名称:wpjobboard-snippets,代码行数:19,代码来源:password-reminder-link.php


示例10: atcf_shortcode_login_form_bottom

/**
 * Forgot Password/Register links
 *
 * Append helpful links to the bottom of the login form.
 *
 * @since Astoundify Crowdfunding 1.0
 *
 * @return $form
 */
function atcf_shortcode_login_form_bottom()
{
    global $edd_options;
    $add = '<p>
		<a href="' . wp_lostpassword_url() . '">' . __('Forgot Password', 'atcf') . '</a> ';
    if (isset($edd_options['register_page'])) {
        $add .= _x('or', 'login form action divider', 'atcf');
        $add .= ' <a href="' . esc_url(get_permalink($edd_options['register_page'])) . '">' . __('Register', 'atcf') . '</a>';
    }
    $add .= '</p>';
    return $add;
}
开发者ID:ajeremias,项目名称:fundify-child,代码行数:21,代码来源:shortcode-login.php


示例11: tpl_link_reset_password

/**
 * Include the reset password link template
 * @param  string $label   	Link text. Default: 'Reset Password'
 * @param  string $classes 	Classes to add to the <a> tag. Default: 'reset-password'
 */
function tpl_link_reset_password($label = null, $classes = 'reset-password')
{
    if (is_null($label)) {
        $label = __('Reset Password', 'theme');
    }
    if (Settings::frontend_login_enabled()) {
        $url = home_url('reset-password');
    } else {
        $url = wp_lostpassword_url();
    }
    tpl('link', 'reset-password', array('url' => $url, 'label' => $label, 'classes' => $classes));
}
开发者ID:andrewcroce,项目名称:TPL,代码行数:17,代码来源:link_functions.php


示例12: widget

    /**
     * load widget
     *
     * @name    widget
     * @author  Marcelo Mesquita <[email protected]>
     * @since   2012-05-09
     * @updated 2012-05-10
     * @param   array $args - widget structure
     * @param   array $instance - widget data
     * @return  void
     */
    function widget($args, $instance)
    {
        global $wpdb;
        print $args['before_widget'];
        if (!empty($instance['title'])) {
            print $args['before_head'];
            print $args['before_title'] . $instance['title'] . $args['after_title'];
            print $args['after_head'];
        }
        print $args['before_body'];
        if (is_user_logged_in()) {
            global $current_user;
            ?>
				<div class="greetings">
					<p>Olá, <?php 
            print $current_user->display_name;
            ?>
 <a href="<?php 
            print wp_logout_url(site_url());
            ?>
" title="sair">sair</a></p>
				</div>
				<div class="clear"></div>
			<?php 
        } else {
            ?>
				<div class="login">
					<form action="<?php 
            print wp_login_url(site_url());
            ?>
" method="post">
						<input type="text" id="user_login" name="log" value="CPF" class="memory" />
						<input type="password" id="user_pass" name="pwd" value="senha" /><button type="submit" name="wp-submit" id="wp-submit" value="Login">OK</button>
						<a href="<?php 
            print wp_lostpassword_url();
            ?>
" title="Esqueceu a senha?" class="forget">Esqueceu a senha?</a>
					</form>
				</div>
				<div class="register">
					<a href="<?php 
            print site_url('/cadastro/');
            ?>
" title="Ainda não possuo cadastro">Ainda <span>não</span> possuo cadastro.</a>
				</div>
				<div class="clear"></div>
			<?php 
        }
        print $args['after_body'];
        print $args['after_widget'];
    }
开发者ID:CoordCulturaDigital-Minc,项目名称:setoriais,代码行数:62,代码来源:sav-widget-login.php


示例13: cws_do_login_form

function cws_do_login_form()
{
    // Get login status and username
    $loggedin = is_user_logged_in();
    $user = wp_get_current_user();
    // If already logged in, output pleasent message with logout option.
    // The logout option will redirect back to this custom login/logout page.
    if ($loggedin) {
        ?>

		<h3>You are already logged in!</h3>
		<p>Hello <?php 
        echo $user->user_firstname;
        ?>
! Looks like you are already signed in. No need to log in again.</p>
		<p><a href="/">Go to Homepage</a> or <a href="<?php 
        echo wp_logout_url(get_permalink() . "/login");
        ?>
">Log Out</a></p>

	<?php 
    } else {
        // Set up array to pass to login function
        $args = array('form_id' => 'loginform', 'redirect' => get_bloginfo('url'), 'id_username' => 'user_login', 'id_password' => 'user_pass', 'id_remember' => 'rememberme', 'id_submit' => 'wp-submit', 'label_username' => __('Username'), 'label_password' => __('Password'), 'label_remember' => __('Remember Me'), 'label_log_in' => __('Log In'));
        ?>
<!--
	Create content for custom login page.
	Format the login page and provide instructions to visitor.
	Offer links to website front page and password retreival.
	Call WP funciton to display UI.
	Display lost password link.
-->
		<center><h1>Website Login Page</h1><hr>
		<h5>Enter your username and password to access <br>the administrative area of your website,<br>
		<a href="/">or click here for the website Front Page</a></h5>
		<hr>
		Use the '<strong>Lost your password?</strong>' link below <br>to have a password reset link sent to you by email.
		<br><hr><br>
		</center>
		<?php 
        wp_login_form($args);
        ?>
		<a href="<?php 
        echo wp_lostpassword_url();
        ?>
" title="Lost Password">Lost your password?</a>
		<?php 
    }
}
开发者ID:MattRy,项目名称:loginout,代码行数:49,代码来源:login.php


示例14: widget

 /**
  * (non-PHPdoc)
  *
  * @see \Widgets\WidgetBase::widget()
  */
 public function widget($args, $instance)
 {
     /*
      * Put all special URLs
      */
     $instance['logoutUrl'] = wp_logout_url(home_url());
     $instance['loginUrl'] = wp_login_url(home_url());
     $instance['registrationUrl'] = wp_registration_url();
     $instance['lostPasswordUrl'] = wp_lostpassword_url();
     $instance['postsUrl'] = '/wp-admin/edit.php';
     /*
      * And call the widget func from the parent class WidgetBase.
      */
     parent::widget($args, $instance);
 }
开发者ID:chemaclass,项目名称:knob-base,代码行数:20,代码来源:LoginWidget.php


示例15: mo2f_wp_authenticate_username_password

function mo2f_wp_authenticate_username_password($user, $username, $password)
{
    if (is_a($user, 'WP_User')) {
        return $user;
    }
    if (empty($username) || empty($password)) {
        $error = new WP_Error();
        if (empty($username)) {
            $error->add('empty_username', __('<strong>ERROR</strong>: The username field is empty.'));
        }
        if (empty($password)) {
            $error->add('empty_password', __('<strong>ERROR</strong>: The password field is empty.'));
        }
        return $error;
    }
    $userdata = get_user_by('login', $username);
    if (!$userdata) {
        return new WP_Error('invalid_username', sprintf(__('<strong>ERROR</strong>: Invalid username. <a href="%s" title="Password Lost and Found">Lost your password</a>?'), wp_lostpassword_url()));
    }
    if (is_multisite()) {
        // Is user marked as spam?
        if (1 == $userdata->spam) {
            return new WP_Error('invalid_username', __('<strong>ERROR</strong>: Your account has been marked as a spammer.'));
        }
        // Is a user's blog marked as spam?
        if (!is_super_admin($userdata->ID) && isset($userdata->primary_blog)) {
            $details = get_blog_details($userdata->primary_blog);
            if (is_object($details) && $details->spam == 1) {
                return new WP_Error('blog_suspended', __('Site Suspended.'));
            }
        }
    }
    $userdata = apply_filters('wp_authenticate_user', $userdata, $password);
    if (is_wp_error($userdata)) {
        return $userdata;
    }
    if (!wp_check_password($password, $userdata->user_pass, $userdata->ID)) {
        return new WP_Error('incorrect_password', sprintf(__('<strong>ERROR</strong>: The password you entered for the username <strong>%1$s</strong> is incorrect. <a href="%2$s" title="Password Lost and Found">Lost your password</a>?'), $username, wp_lostpassword_url()));
    }
    $user = new WP_User($userdata->ID);
    return $user;
}
开发者ID:sekane81,项目名称:ratoninquietoweb,代码行数:42,代码来源:miniorange_2_factor_common_login.php


示例16: et_fb_backend_helpers

function et_fb_backend_helpers()
{
    global $post, $paged;
    $layout_type = '';
    $post_type = isset($post->post_type) ? $post->post_type : false;
    $post_id = isset($post->ID) ? $post->ID : false;
    $post_status = isset($post->post_status) ? $post->post_status : false;
    if ('et_pb_layout' === $post_type) {
        $layout_type = et_fb_get_layout_type($post_id);
    }
    $google_fonts = array_merge(array('Default' => array()), et_builder_get_google_fonts());
    $current_user = wp_get_current_user();
    $current_url = (is_ssl() ? 'https://' : 'http://') . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];
    $export_url = add_query_arg(array('et_core_portability' => true, 'context' => 'et_builder', 'name' => 'temp_name', 'nonce' => wp_create_nonce('et_core_portability_nonce')), admin_url());
    $fb_modules_array = apply_filters('et_fb_modules_array', ET_Builder_Element::get_modules_array($post_type, true, true));
    $helpers = array('debug' => true, 'postId' => $post_id, 'postStatus' => $post_status, 'postType' => $post_type, 'layoutType' => $layout_type, 'publishCapability' => is_page() && !current_user_can('publish_pages') || !is_page() && !current_user_can('publish_posts') ? 'no_publish' : 'publish', 'shortcodeObject' => array(), 'ajaxUrl' => admin_url('admin-ajax.php'), 'tinymceSkinUrl' => ET_FB_ASSETS_URI . '/vendors/tinymce-skin', 'tinymceCSSFiles' => esc_url(includes_url('js/tinymce') . '/skins/wordpress/wp-content.css'), 'images_uri' => ET_BUILDER_URI . '/images', 'generalFields' => array(), 'advancedFields' => array(), 'customCssFields' => array(), 'moduleParentShortcodes' => ET_Builder_Element::get_parent_shortcodes($post_type), 'moduleChildShortcodes' => ET_Builder_Element::get_child_shortcodes($post_type), 'moduleChildSlugs' => ET_Builder_Element::get_child_slugs($post_type), 'moduleRawContentShortcodes' => ET_Builder_Element::get_raw_content_shortcodes($post_type), 'modules' => $fb_modules_array, 'modulesCount' => count($fb_modules_array), 'modulesWithChildren' => ET_Builder_Element::get_shortcodes_with_children($post_type), 'structureModules' => ET_Builder_Element::get_structure_modules($post_type), 'et_builder_css_media_queries' => ET_Builder_Element::get_media_quries('for_js'), 'commentsModuleMarkup' => et_fb_get_comments_markup(), 'shortcode_tags' => et_fb_shortcode_tags(), 'getFontIconSymbols' => et_pb_get_font_icon_symbols(), 'failureNotification' => et_builder_get_failure_notification_modal(), 'exitNotification' => et_builder_get_exit_notification_modal(), 'getTaxonomies' => apply_filters('et_fb_taxonomies', array('category' => get_categories(), 'project_category' => get_categories(array('taxonomy' => 'project_category')), 'product_category' => class_exists('WooCommerce') ? get_terms('product_cat') : '')), 'googleAPIKey' => et_pb_is_allowed('theme_options') ? get_option('et_google_api_settings') : '', 'googleFontsList' => array_keys($google_fonts), 'googleFonts' => $google_fonts, 'gutterWidth' => et_get_option('gutter_width', 3), 'fontIcons' => et_pb_get_font_icon_symbols(), 'fontIconsDown' => et_pb_get_font_down_icon_symbols(), 'widgetAreas' => et_builder_get_widget_areas_list(), 'site_url' => get_site_url(), 'etBuilderAccentColor' => et_builder_accent_color(), 'gmt_offset_string' => et_pb_get_gmt_offset_string(), 'et_builder_fonts_data' => et_builder_get_fonts(), 'currentUserDisplayName' => $current_user->display_name, 'locale' => get_locale(), 'roleSettings' => et_pb_get_role_settings(), 'currentRole' => et_pb_get_current_user_role(), 'exportUrl' => $export_url, 'urls' => array('loginFormUrl' => esc_url(site_url('wp-login.php', 'login_post')), 'forgotPasswordUrl' => esc_url(wp_lostpassword_url()), 'logoutUrl' => esc_url(wp_logout_url()), 'logoutUrlRedirect' => esc_url(wp_logout_url($current_url)), 'themeOptionsUrl' => esc_url(et_pb_get_options_page_link()), 'builderPreviewStyle' => ET_BUILDER_URI . '/styles/preview.css'), 'nonces' => array('moduleContactFormSubmit' => wp_create_nonce('et-pb-contact-form-submit'), 'et_admin_load' => wp_create_nonce('et_admin_load_nonce'), 'computedProperty' => wp_create_nonce('et_pb_process_computed_property_nonce'), 'renderShortcode' => wp_create_nonce('et_pb_render_shortcode_nonce'), 'backendHelper' => wp_create_nonce('et_fb_backend_helper_nonce'), 'renderSave' => wp_create_nonce('et_fb_save_nonce'), 'prepareShortcode' => wp_create_nonce('et_fb_prepare_shortcode_nonce'), 'processImportedData' => wp_create_nonce('et_fb_process_imported_data_nonce'), 'retrieveLibraryModules' => wp_create_nonce('et_fb_retrieve_library_modules_nonce'), 'saveLibraryModules' => wp_create_nonce('et_fb_save_library_modules_nonce'), 'preview' => wp_create_nonce('et_pb_preview_nonce')), 'conditionalTags' => et_fb_conditional_tag_params(), 'currentPage' => et_fb_current_page_params(), 'appPreferences' => et_fb_app_preferences(), 'classNames' => array('hide_on_mobile_class' => 'et-hide-mobile'), 'columnLayouts' => et_builder_get_columns(), 'pageSettingsFields' => et_pb_get_builder_settings_configurations(), 'pageSettingsValues' => et_pb_get_builder_settings_values(), 'splitTestSubjects' => false !== ($all_subjects_raw = get_post_meta($post_id, '_et_pb_ab_subjects', true)) ? explode(',', $all_subjects_raw) : array(), 'defaults' => array('contactFormInputs' => et_fb_process_shortcode(sprintf('[et_pb_contact_field field_title="%1$s" field_type="input" field_id="Name" required_mark="on" fullwidth_field="off" /][et_pb_contact_field field_title="%2$s" field_type="email" field_id="Email" required_mark="on" fullwidth_field="off" /][et_pb_contact_field field_title="%3$s" field_type="text" field_id="Message" required_mark="on" fullwidth_field="on" /]', esc_attr__('Name', 'et_builder'), esc_attr__('Email Address', 'et_builder'), esc_attr__('Message', 'et_builder')))), 'all_modules_default_attrs' => ET_Builder_Element::get_all_modules_default_fields($post_type), 'saveModuleLibraryCategories' => et_fb_prepare_library_cats(), 'columnSettingFields' => array('advanced' => array('bg_img_%s' => array('label' => esc_html__('Column %s Background Image', 'et_builder'), 'type' => 'upload', 'option_category' => 'basic_option', 'upload_button_text' => esc_attr__('Upload an image', 'et_builder'), 'choose_text' => esc_attr__('Choose a Background Image', 'et_builder'), 'update_text' => esc_attr__('Set As Background', 'et_builder'), 'description' => esc_html__('If defined, this image will be used as the background for this module. To remove a background image, simply delete the URL from the settings field.', 'et_builder'), 'tab_slug' => 'advanced'), 'parallax_%s' => array('label' => esc_html__('Column %s Parallax Effect', 'et_builder'), 'type' => 'yes_no_button', 'option_category' => 'configuration', 'options' => array('on' => esc_html__('Yes', 'et_builder'), 'off' => esc_html__('No', 'et_builder')), 'affects' => array('parallax_method_%s'), 'description' => esc_html__('Here you can choose whether or not use parallax effect for the featured image', 'et_builder'), 'tab_slug' => 'advanced'), 'parallax_method_%s' => array('label' => esc_html__('Column %s Parallax Method', 'et_builder'), 'type' => 'select', 'option_category' => 'configuration', 'options' => array('off' => esc_html__('CSS', 'et_builder'), 'on' => esc_html__('True Parallax', 'et_builder')), 'depends_show_if' => 'on', 'depends_to' => array('parallax_%s'), 'description' => esc_html__('Here you can choose which parallax method to use for the featured image', 'et_builder'), 'tab_slug' => 'advanced'), 'background_color_%s' => array('label' => esc_html__('Column %s Background Color', 'et_builder'), 'type' => 'color-alpha', 'custom_color' => true, 'tab_slug' => 'advanced'), 'padding_%s' => array('label' => esc_html__('Column %s Custom Padding', 'et_builder'), 'type' => 'custom_padding', 'mobile_options' => true, 'option_category' => 'layout', 'description' => esc_html__('Adjust padding to specific values, or leave blank to use the default padding.', 'et_builder'), 'tab_slug' => 'advanced')), 'css' => array('module_id_%s' => array('label' => esc_html__('Column %s CSS ID', 'et_builder'), 'type' => 'text', 'option_category' => 'configuration', 'tab_slug' => 'custom_css', 'option_class' => 'et_pb_custom_css_regular'), 'module_class_%s' => array('label' => esc_html__('Column %s CSS Class', 'et_builder'), 'type' => 'text', 'option_category' => 'configuration', 'tab_slug' => 'custom_css', 'option_class' => 'et_pb_custom_css_regular'), 'custom_css_before_%s' => array('label' => esc_html__('Column %s before', 'et_builder'), 'no_space_before_selector' => true, 'selector' => ':before'), 'custom_css_main_%s' => array('label' => esc_html__('Column %s Main Element', 'et_builder')), 'custom_css_after_%s' => array('label' => esc_html__('Column %s After', 'et_builder'), 'no_space_before_selector' => true, 'selector' => ':after'))));
    // Internationalization.
    $helpers['i18n'] = array('modules' => array('audio' => array('meta' => _x('by <strong>%1$s</strong>', 'Audio Module meta information', 'et_builder')), 'contactForm' => array('thankYou' => esc_html__('Thanks for contacting us', 'et_builder'), 'submit' => esc_attr__('Submit', 'et_builder')), 'countdownTimer' => array('dayFull' => esc_html__('Day(s)', 'et_builder'), 'dayShort' => esc_html__('Day', 'et_builder'), 'hourFull' => esc_html__('Hour(s)', 'et_builder'), 'hourShort' => esc_html__('Hrs', 'et_builder'), 'minuteFull' => esc_html__('Minute(s)', 'et_builder'), 'minuteShort' => esc_html__('Min', 'et_builder'), 'secondFull' => esc_html__('Second(s)', 'et_builder'), 'secondShort' => esc_html__('Sec', 'et_builder')), 'signup' => array('emailAddress' => esc_attr__('Email Address', 'et_builder'), 'firstName' => esc_attr__('First Name', 'et_builder'), 'lastName' => esc_attr__('Last Name', 'et_builder'), 'name' => esc_attr__('Name', 'et_builder'), 'email' => esc_attr__('Email', 'et_builder')), 'filterablePortfolio' => array('all' => esc_html__('All', 'et_builder')), 'login' => array('loginAs' => sprintf(esc_html__('Login as %s', 'et_builder'), $current_user->display_name), 'login' => esc_html__('Login', 'et_builder'), 'logout' => esc_html__('Log out', 'et_builder'), 'forgotPassword' => esc_html__('Forgot your password?', 'et_builder'), 'username' => esc_html__('Username', 'et_builder'), 'password' => esc_html__('Password', 'et_builder')), 'search' => array('submitButtonText' => esc_html__('Search', 'et_builder'), 'searchfor' => esc_html__('Search for:', 'et_builder')), 'fullwidthPostSlider' => array('by' => esc_html('by ', 'et_builder'))), 'saveButtonText' => esc_attr__('Save', 'et_builder'), 'saveDraftButtonText' => esc_attr__('Save Draft', 'et_builder'), 'publishButtonText' => is_page() && !current_user_can('publish_pages') || !is_page() && !current_user_can('publish_posts') ? esc_attr__('Submit', 'et_builder') : esc_attr__('Publish', 'et_builder'), 'controls' => array('tinymce' => array('visual' => esc_html__('Visual', 'et_builder'), 'text' => esc_html__('Text', 'et_builder')), 'moduleItem' => array('addNew' => esc_html__('Add New Item', 'et_builder')), 'upload' => array('buttonText' => esc_html__('Upload', 'et_builder')), 'insertMedia' => array('buttonText' => esc_html__('Add Media', 'et_builder'), 'modalTitleText' => esc_html__('Insert Media', 'et_builder')), 'inputMargin' => array('top' => esc_html__('Top', 'et_builder'), 'right' => esc_html__('Right', 'et_builder'), 'bottom' => esc_html__('Bottom', 'et_builder'), 'left' => esc_html__('Left', 'et_builder')), 'colorpicker' => array('clear' => esc_html__('Clear', 'et_builder')), 'uploadGallery' => array('uploadButtonText' => esc_html__('Update Gallery', 'et_builder')), 'centerMap' => array('updateMapButtonText' => esc_html__('Find', 'et_builder'), 'geoCodeError' => esc_html__('Geocode was not successful for the following reason', 'et_builder'), 'geoCodeError_2' => esc_html__('Geocoder failed due to', 'et_builder'), 'noResults' => esc_html__('No results found', 'et_builder'), 'mapPinAddressInvalid' => esc_html__('Invalid Pin and address data. Please try again.', 'et_builder')), 'tabs' => array('general' => esc_html__('General', 'et_builder'), 'design' => esc_html__('Design', 'et_builder'), 'css' => esc_html__('CSS', 'et_builder')), 'additionalButton' => array('changeApiKey' => esc_html__('Change API Key', 'et_builder'), 'generateImageUrlFromVideo' => esc_html__('Generate From Video', 'et_builder'))), 'rightClickMenuItems' => array('undo' => esc_html__('Undo', 'et_builder'), 'redo' => esc_html__('Redo', 'et_builder'), 'lock' => esc_html__('Lock', 'et_builder'), 'unlock' => esc_html__('Unlock', 'et_builder'), 'copy' => esc_html__('Copy', 'et_builder'), 'paste' => esc_html__('Paste', 'et_builder'), 'copyStyle' => esc_html__('Copy Style', 'et_builder'), 'pasteStyle' => esc_html__('Paste Style', 'et_builder'), 'disable' => esc_html__('Disable', 'et_builder'), 'enable' => esc_html__('Enable', 'et_builder'), 'save' => esc_html__('Save to Library', 'et_builder'), 'moduleType' => array('module' => esc_html__('Module', 'et_builder'), 'row' => esc_html__('Row', 'et_builder'), 'section' => esc_html__('Section', 'et_builder')), 'disableGlobal' => esc_html__('Disable Global', 'et_builder')), 'tooltips' => array('insertModule' => esc_html__('Insert Module', 'et_builder'), 'insertColumn' => esc_html__('Insert Columns', 'et_builder'), 'insertSection' => esc_html__('Insert Section', 'et_builder'), 'insertRow' => esc_html__('Insert Row', 'et_builder'), 'newModule' => esc_html__('New Module', 'et_builder'), 'newRow' => esc_html__('New Row', 'et_builder'), 'newSection' => esc_html__('New Section', 'et_builder'), 'addFromLibrary' => esc_html 

鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP wp_mail函数代码示例发布时间:2022-05-23
下一篇:
PHP wp_logout_url函数代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap