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.0 3.6.1 3.6.2 3.6.3 3.6.4 3.7.0 3.7.1 3.7.2 3.7.3 3.7.4 3.8.0 3.8.1 3.8.2 3.8.3 3.9.0 3.9.1 3.9.10 3.9.2 3.9.3 3.9.4 3.9.5 3.9.6 3.9.7 3.9.8 3.9.9
tutor / templates / global / login.php
tutor / templates / global Last commit date
attachments.php 5 years ago course-archive-filter-bar.php 5 years ago login.php 5 years ago
login.php
118 lines
1 <?php
2
3 /**
4 * Display global login
5 *
6 * @since v.1.0.0
7 * @author themeum
8 * @url https://themeum.com
9 *
10 * @package TutorLMS/Templates
11 * @version 1.4.3
12 */
13
14
15 if ( ! defined( 'ABSPATH' ) )
16 exit;
17 ?>
18
19 <div class="tutor-login-form-wrap">
20 <?php do_action("tutor_before_login_form");?>
21
22 <?php
23 $current_url = tutils()->get_current_url();
24 $register_page = tutor_utils()->student_register_url();
25 $register_url = add_query_arg ('redirect_to', $current_url, $register_page);
26
27 //redirect_to
28 $args = array(
29 'echo' => true,
30 // Default 'redirect' value takes the user back to the request URI.
31 'redirect' => ( is_ssl() ? 'https://' : 'http://' ) . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'],
32 'form_id' => 'loginform',
33 'label_username' => __( 'Username or Email Address', 'tutor' ),
34 'label_password' => __( 'Password', 'tutor' ),
35 'label_remember' => __( 'Remember Me', 'tutor' ),
36 'label_log_in' => __( 'Log In', 'tutor' ),
37 'label_create_new_account' => __( 'Create a new account', 'tutor' ),
38 'id_username' => 'user_login',
39 'id_password' => 'user_pass',
40 'id_remember' => 'rememberme',
41 'id_submit' => 'wp-submit',
42 'remember' => true,
43 'value_username' => tutils()->input_old('log'),
44 // Set 'value_remember' to true to default the "Remember me" checkbox to checked.
45 'value_remember' => false,
46 'wp_lostpassword_url' => apply_filters('tutor_lostpassword_url', wp_lostpassword_url()),
47 'wp_lostpassword_label' => __('Forgot Password?', 'tutor'),
48 );
49
50 //action="' . esc_url( site_url( 'wp-login.php', 'login_post' ) ) . '"
51
52 tutor_alert(null, 'warning');
53
54 ob_start();
55 tutor_nonce_field();
56 $nonce_field = ob_get_clean();
57 ?>
58
59 <form name="<?= $args['form_id']?>" id="<?= $args['form_id']?>" method="post">
60
61 <?php do_action("tutor_login_form_start");?>
62
63 <?php echo $nonce_field;?>
64
65 <input type="hidden" name="tutor_action" value="tutor_user_login" />
66 <p class="login-username">
67 <input type="text" placeholder="<?= esc_html( $args['label_username'] )?>" name="log" id="<?= esc_attr( $args['id_username'] )?>" class="input" value="<?= esc_attr( $args['value_username'] )?>" size="20" />
68 </p>
69
70 <p class="login-password">
71 <input type="password" placeholder="<?= esc_html( $args['label_password'] )?>" name="pwd" id="<?= esc_attr( $args['id_password'] )?>" class="input" value="" size="20"/>
72
73 </p>
74
75 <?php
76 do_action("tutor_login_form_middle");
77 do_action("login_form");
78 apply_filters("login_form_middle",'','');
79 ?>
80
81
82 <div class="tutor-login-rememeber-wrap">
83 <?php if($args['remember']):?>
84 <p class="login-remember">
85 <label>
86 <input name="rememberme" type="checkbox" id="<?= esc_attr( $args['id_remember'] )?>"
87 value="forever"
88 <?php $args['value_remember'] ? 'checked' : '';?>
89 >
90 <?= esc_html($args['label_remember']);?>
91 </label>
92 </p>
93 <?php endif;?>
94 <a href="<?= esc_url($args['wp_lostpassword_url'])?>">
95 <?= esc_html($args['wp_lostpassword_label']);?>
96 </a>
97 </div>
98
99 <?php do_action("tutor_login_form_end");?>
100
101 <p class="login-submit">
102 <input type="submit" name="wp-submit" id="<?= esc_attr( $args['id_submit'] )?>" class="button button-primary" value="<?= esc_attr( $args['label_log_in'] )?>" />
103 <input type="hidden" name="redirect_to" value="<?= esc_url( $args['redirect'] )?>" />
104 </p>
105
106 <p class="tutor-form-register-wrap">
107 <a href="<?= esc_url($register_url)?>">
108 <?= esc_html($args['label_create_new_account']);?>
109 </a>
110 </p>
111 </form>
112
113 <?php
114 //#@TODO: student_register_url() return false, it must be an valid url.
115 do_action("tutor_after_login_form");
116 ?>
117 </div>
118