Custom Login Page Customizer | LoginPress - Version 1.0.6

Version Description

  • 2017-01-20 =
  • Bug fix: site lock out bug fixed.
Download this release

Release Info

Developer hiddenpearls
Plugin Icon 128x128 Custom Login Page Customizer | LoginPress
Version 1.0.6
Comparing to
See all releases

Code changes from version 1.0.5 to 1.0.6

classes/control-presets.php ADDED
@@ -0,0 +1,345 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Class for Presets.
5
+ *
6
+ * @since 1.0.0
7
+ * @access public
8
+ */
9
+ class LoginPress_Presets extends WP_Customize_Control {
10
+
11
+ /**
12
+ * The type of customize control being rendered.
13
+ *
14
+ * @since 1.0.0
15
+ * @access public
16
+ * @var string
17
+ */
18
+ public $type = 'checkbox-multiple';
19
+
20
+ /**
21
+ * Enqueue scripts/styles.
22
+ *
23
+ * @since 1.0.0
24
+ * @access public
25
+ * @return void
26
+ */
27
+ public function enqueue() {
28
+ // wp_enqueue_script( 'jt-customize-controls', plugins_url( '/customize-controls.js' , __FILE__ ), array( 'jquery' ) );
29
+ wp_enqueue_script( 'jquery-ui-button' );
30
+ }
31
+
32
+ /**
33
+ * Displays the control content.
34
+ *
35
+ * @since 1.0.0
36
+ * @access public
37
+ * @return void
38
+ */
39
+ public function render_content() {
40
+
41
+
42
+ if ( empty( $this->choices ) )
43
+ return;
44
+ $name = 'loginpress_preset-' . $this->id; ?>
45
+
46
+ <span class="customize-control-title">
47
+ <?php echo esc_attr( $this->label ); ?>
48
+ <?php if ( ! empty( $this->description ) ) : ?>
49
+ <span class="description customize-control-description"><?php echo esc_html( $this->description ); ?></span>
50
+ <?php endif; ?>
51
+ </span>
52
+
53
+ <?php $multi_values = !is_array( $this->value() ) ? explode( ',', $this->value() ) : $this->value(); ?>
54
+
55
+
56
+ <div id="input_<?php echo $this->id; ?>" class="image">
57
+
58
+ <?php foreach ( $this->choices as $val ) : ?>
59
+
60
+ <?php $_disbaled = isset( $val['pro'] ) ? 'disabled' : ''; ?>
61
+ <div class="loginpress_thumbnail">
62
+ <input <?php echo $_disbaled ?> class="image-select" type="radio" value="<?php echo esc_attr( $val['id'] ); ?>" id="<?php echo $this->id . $val['id']; ?>" name="<?php echo esc_attr( $name ); ?>" <?php checked( $this->value(), $val['id'] ); ?> />
63
+ <label for="<?php echo $this->id . $val['id']; ?>">
64
+ <div class="loginpress_thumbnail_img">
65
+ <img src="<?php echo $val['thumbnail']; ?>" alt="<?php echo esc_attr( $val['id'] ); ?>" title="<?php echo esc_attr( $val['id'] ); ?>">
66
+ </div> <!-- .img -->
67
+ <h3><?php echo $val['name'] ?></h3>
68
+ </label>
69
+ <a href="http://www.wpbrigade.com" target="_blank" class="no-available">
70
+ <span>Available For Pro</span>
71
+ </a>
72
+ <!-- </input> -->
73
+ </div> <!-- .loginpress_thumbnail -->
74
+
75
+ <?php endforeach; ?>
76
+ </div>
77
+
78
+ <input name='presets_hidden' type="hidden" <?php $this->link(); ?> value="<?php echo esc_attr( implode( ',', $multi_values ) ); ?>" />
79
+ <?php }
80
+
81
+
82
+ }
83
+
84
+ function loginpress_presets_control_css() {
85
+ ?>
86
+ <style>
87
+ .customize-control-checkbox-multiple .image.ui-buttonset input[type=radio] {
88
+ height: auto;
89
+ }
90
+ .customize-control-checkbox-multiple .image.ui-buttonset label {
91
+ display: inline-block;
92
+ margin-right: 5px;
93
+ margin-bottom: 5px;
94
+ }
95
+ .customize-control-checkbox-multiple .image.ui-buttonset label.ui-state-active {
96
+ background: none;
97
+ }
98
+ .customize-control-checkbox-multiple .customize-control-radio-buttonset label {
99
+ padding: 5px 10px;
100
+ background: #f7f7f7;
101
+ border-left: 1px solid #dedede;
102
+ line-height: 35px;
103
+ }
104
+ .customize-control-checkbox-multiple label img {
105
+ border: 1px solid #bbb;
106
+ opacity: 0.5;
107
+ }
108
+ #customize-controls .customize-control-checkbox-multiple label img {
109
+ max-width: 250px;
110
+ height: auto;
111
+ width: 100%;
112
+ margin-bottom: 0;
113
+ border: 0;
114
+ display: block;
115
+ }
116
+ .customize-control-checkbox-multiple label.ui-state-active img {
117
+ background: #dedede;
118
+ border-color: #000;
119
+ opacity: 1;
120
+ margin-bottom: 0;
121
+ }
122
+ .customize-control-checkbox-multiple label.ui-state-hover img {
123
+ opacity: 0.9;
124
+ border-color: #999;
125
+ }
126
+ .customize-control-radio-buttonset label.ui-corner-left {
127
+ border-radius: 3px 0 0 3px;
128
+ border-left: 0;
129
+ }
130
+ .customize-control-radio-buttonset label.ui-corner-right {
131
+ border-radius: 0 3px 3px 0;
132
+ }
133
+ #customize-control-customize_presets_settings input[type=radio]{
134
+ display: none;
135
+ }
136
+ #customize-control-customize_presets_settings label{
137
+ display: block;
138
+ position: relative;
139
+ width: 100%;
140
+ }
141
+ #customize-control-customize_presets_settings .loginpress_thumbnail{
142
+ width: calc(50% - 10px);
143
+ margin-bottom: 10px;
144
+ position: relative;
145
+ }
146
+ #customize-control-customize_presets_settings .loginpress_thumbnail:nth-child(odd){
147
+ float: left;
148
+ }
149
+ #customize-control-customize_presets_settings .loginpress_thumbnail:nth-child(even){
150
+ float: right;
151
+ }
152
+ #customize-control-customize_presets_settings .image:after{
153
+ content: '';
154
+ display: table;
155
+ clear: both;
156
+ }
157
+ #customize-control-customize_presets_settings h3{
158
+ margin: 0;
159
+ font: 400 14px 'Open Sans', Arial, Helvetica, sans-serif;
160
+ line-height: 1.1;
161
+ padding: 3px;
162
+ text-align: center;
163
+ background: #eee;
164
+ color: #777777;
165
+ }
166
+ #customize-control-customize_presets_settings label .loginpress_thumbnail_img:after {
167
+ content: '';
168
+ width: 20px;
169
+ height: 20px;
170
+ border-radius: 50%;
171
+ background: #2EB150;
172
+ position: absolute;
173
+ top: -5px;
174
+ left: -5px;
175
+ border-radius: 50%;
176
+ visibility: hidden;
177
+ }
178
+ #customize-control-customize_presets_settings label .loginpress_thumbnail_img:before {
179
+ height: 6px;
180
+ width: 3px;
181
+ -webkit-transform-origin: left top;
182
+ -moz-transform-origin: left top;
183
+ -ms-transform-origin: left top;
184
+ -o-transform-origin: left top;
185
+ transform-origin: left top;
186
+ border-right: 3px solid white;
187
+ border-top: 3px solid white;
188
+ border-radius: 2.5px !important;
189
+ content: '';
190
+ position: absolute;
191
+ z-index: 2;
192
+ opacity: 0;
193
+ margin-top: 0px;
194
+ margin-left: -7px;
195
+ top: 5px;
196
+ left: 4px;
197
+ }
198
+ #customize-control-customize_presets_settings .loginpress_thumbnail_img{
199
+ display: block;
200
+ position: relative;
201
+ }
202
+ #customize-control-customize_presets_settings input[type="radio"]:checked + label .loginpress_thumbnail_img:before {
203
+ -webkit-animation-delay: 100ms;
204
+ -moz-animation-delay: 100ms;
205
+ animation-delay: 100ms;
206
+ -webkit-animation-duration: 1s;
207
+ -moz-animation-duration: 1s;
208
+ animation-duration: 1s;
209
+ -webkit-animation-timing-function: ease;
210
+ -moz-animation-timing-function: ease;
211
+ animation-timing-function: ease;
212
+ -webkit-animation-name: checkmark;
213
+ -moz-animation-name: checkmark;
214
+ animation-name: checkmark;
215
+ -webkit-transform: scaleX(-1) rotate(135deg);
216
+ -moz-transform: scaleX(-1) rotate(135deg);
217
+ -ms-transform: scaleX(-1) rotate(135deg);
218
+ -o-transform: scaleX(-1) rotate(135deg);
219
+ transform: scaleX(-1) rotate(135deg);
220
+ -webkit-animation-fill-mode: forwards;
221
+ -moz-animation-fill-mode: forwards;
222
+ animation-fill-mode: forwards;
223
+ z-index: 2;
224
+ }
225
+ #customize-control-customize_presets_settings input[type="radio"]:checked + label .loginpress_thumbnail_img:after{
226
+ visibility: visible;
227
+ }
228
+ /*#customize-control-customize_presets_settings input[type="radio"]:disabled + label .loginpress_thumbnail_img:before{
229
+ visibility: hidden;
230
+ }
231
+ #customize-control-customize_presets_settings input[type="radio"]:disabled + label .loginpress_thumbnail_img:after{
232
+ visibility: hidden;
233
+ }*/
234
+ #customize-control-customize_presets_settings img{
235
+ margin-bottom: 0;
236
+ }
237
+ #customize-control-customize_presets_settings input[type="radio"]:checked + label img{
238
+ opacity: 1;
239
+ }
240
+ .no-available{
241
+ top: 0;
242
+ left: 0;
243
+ background: rgba(0, 0, 0, 0.7);
244
+ content: '';
245
+ position: absolute;
246
+ bottom: 0;
247
+ right: 0;
248
+ z-index: 100;
249
+ padding: 20px;
250
+ text-align: center;
251
+ color: #fff;
252
+ -webkit-transition:all 0.3s ease-in-out;
253
+ -moz-transition:all 0.3s ease-in-out;
254
+ -ms-transition:all 0.3s ease-in-out;
255
+ transition:all 0.3s ease-in-out;
256
+ opacity: 0;
257
+ visibility: hidden;
258
+ -webkit-transform: scale(.5);
259
+ -moz-transform: scale(.5);
260
+ -ms-transform: scale(.5);
261
+ transform: scale(.5);
262
+ text-decoration: none !important;
263
+ }
264
+ #customize-control-customize_presets_settings .loginpress_thumbnail:hover input[type="radio"]:disabled ~ .no-available{
265
+ opacity: 1;
266
+ visibility: visible;
267
+ color: #fff;
268
+ -webkit-transform: scale(1);
269
+ -moz-transform: scale(1);
270
+ -ms-transform: scale(1);
271
+ transform: scale(1);
272
+ }
273
+
274
+ @-webkit-keyframes checkmark {
275
+ 0% {
276
+ height: 0;
277
+ width: 0;
278
+ opacity: 1;
279
+ }
280
+ 20% {
281
+ height: 0;
282
+ width: 5px;
283
+ opacity: 1;
284
+ }
285
+ 40% {
286
+ height: 10px;
287
+ width: 5px;
288
+ opacity: 1;
289
+ }
290
+ 100% {
291
+ height: 10px;
292
+ width: 5px;
293
+ opacity: 1;
294
+ }
295
+ }
296
+ @-moz-keyframes checkmark {
297
+ 0% {
298
+ height: 0;
299
+ width: 0;
300
+ opacity: 1;
301
+ }
302
+ 20% {
303
+ height: 0;
304
+ width: 5px;
305
+ opacity: 1;
306
+ }
307
+ 40% {
308
+ height: 10px;
309
+ width: 5px;
310
+ opacity: 1;
311
+ }
312
+ 100% {
313
+ height: 10px;
314
+ width: 5px;
315
+ opacity: 1;
316
+ }
317
+ }
318
+ @keyframes checkmark {
319
+ 0% {
320
+ height: 0;
321
+ width: 0;
322
+ opacity: 1;
323
+ }
324
+ 20% {
325
+ height: 0;
326
+ width: 5px;
327
+ opacity: 1;
328
+ }
329
+ 40% {
330
+ height: 10px;
331
+ width: 5px;
332
+ opacity: 1;
333
+ }
334
+ 100% {
335
+ height: 10px;
336
+ width: 5px;
337
+ opacity: 1;
338
+ }
339
+ }
340
+
341
+ </style>
342
+ <?php
343
+ }
344
+ add_action( 'customize_controls_print_styles', 'loginpress_presets_control_css' );
345
+ ?>
css/style-login.php CHANGED
@@ -1,10 +1,13 @@
1
  <?php
 
 
2
  /**
3
  * Get option and check the key exists in it.
4
  *
5
  * @since 1.0.0
6
  * * * * * * * * * * * * * * * */
7
 
 
8
  /**
9
  * @var loginpress_array get_option
10
  * @since 1.0.0
@@ -19,7 +22,6 @@ function loginpress_get_option_key( $loginpress_key, $loginpress_array ) {
19
  }
20
  }
21
 
22
-
23
  $loginpress_logo_img = loginpress_get_option_key( 'setting_logo', $loginpress_array );
24
  $loginpress_logo_width = loginpress_get_option_key( 'customize_logo_width', $loginpress_array );
25
  $loginpress_logo_height = loginpress_get_option_key( 'customize_logo_height', $loginpress_array );
@@ -74,6 +76,7 @@ $loginpress_footer_link_bg_clr = loginpress_get_option_key( 'login_footer_backgr
74
  $loginpress_custom_css = loginpress_get_option_key( 'loginpress_custom_css', $loginpress_array );
75
  $loginpress_custom_js = loginpress_get_option_key( 'loginpress_custom_js', $loginpress_array );
76
 
 
77
  // ob_start();
78
  ?>
79
  <style type="text/css">
@@ -81,219 +84,134 @@ $loginpress_custom_js = loginpress_get_option_key( 'loginpress_custom_js',
81
  box-sizing: border-box;
82
  }
83
  body.login {
84
- <?php if ( isset( $loginpress_background_img ) ) : ?>
85
- background-image: url(<?php echo $loginpress_background_img; ?>) !important;
86
- <?php else : ?>
87
- background-image: url(<?php echo plugins_url( 'img/bg.jpg', dirname(__FILE__) ); ?>) !important;
88
  <?php endif; ?>
89
  <?php if ( ! empty( $loginpress_background_color ) ) : ?>
90
- background-color: <?php echo $loginpress_background_color; ?> !important;
91
- <?php else : ?>
92
- background-color: #ddd5c3 !important;
93
  <?php endif; ?>
94
  <?php if ( ! empty( $loginpress_background_repeat ) ) : ?>
95
- background-repeat: <?php echo $loginpress_background_repeat; ?> !important;
96
- <?php else : ?>
97
- background-repeat: no-repeat !important;
98
  <?php endif; ?>
99
  <?php if ( ! empty( $loginpress_background_postion ) ) : ?>
100
- background-position: <?php echo $loginpress_background_postion; ?> !important;
101
- <?php else : ?>
102
- background-position: center !important;
103
  <?php endif; ?>
104
  <?php if ( ! empty( $loginpress_background_image_size ) ) : ?>
105
- background-size: <?php echo $loginpress_background_image_size; ?> !important;
106
- <?php else : ?>
107
- background-size: cover !important;
108
- <?php endif; ?>
109
- background-attachment: fixed;
110
- display: table;
111
- min-height: 100vh;
112
- width: 100%;
113
- padding: 0;
114
- /*background-size: cover;*/
115
- }
116
- .header-wrapper{
117
- display: table-row;
118
  }
 
119
  .login h1 a {
120
  <?php if ( ! empty( $loginpress_logo_img ) ) : ?>
121
- background-image: url( <?php echo $loginpress_logo_img; ?> ) !important;
122
  <?php endif; ?>
123
  <?php if ( ! empty( $loginpress_logo_width ) ) : ?>
124
- width: <?php echo $loginpress_logo_width; ?> !important;
125
  <?php endif; ?>
126
  <?php if ( ! empty( $loginpress_logo_height ) ) : ?>
127
- height: <?php echo $loginpress_logo_height; ?> !important;
128
  <?php endif; ?>
129
  <?php if ( ! empty( $loginpress_logo_width ) || ! empty( $loginpress_logo_height ) ) : ?>
130
- background-size: <?php echo $loginpress_logo_width; ?> <?php echo $loginpress_logo_height; ?> !important;
131
  <?php endif; ?>
132
  <?php if ( ! empty( $loginpress_logo_padding ) ) : ?>
133
- padding-bottom: <?php echo $loginpress_logo_padding; ?> !important;
134
  <?php endif; ?>
135
 
136
  }
137
 
138
- .wp-core-ui .button-primary {
139
  <?php if ( ! empty( $loginpress_btn_bg ) ) : ?>
140
- background: <?php echo $loginpress_btn_bg; ?> !important;
141
  <?php endif; ?>
142
  <?php if ( ! empty( $loginpress_btn_border ) ) : ?>
143
- border-color: <?php echo $loginpress_btn_border; ?> !important;
144
  <?php endif; ?>
145
  <?php if ( ! empty( $loginpress_btn_shadow ) ) : ?>
146
  box-shadow: 0px 1px 0px <?php echo $loginpress_btn_shadow; ?> inset, 0px 1px 0px rgba(0, 0, 0, 0.15);
147
  <?php endif; ?>
148
  <?php if ( ! empty( $loginpress_btn_color ) ) : ?>
149
- color: <?php echo $loginpress_btn_color; ?> !important;
150
  <?php endif; ?>
151
  }
152
 
153
- .wp-core-ui .button-primary.focus, .wp-core-ui .button-primary.hover, .wp-core-ui .button-primary:focus, .wp-core-ui .button-primary:hover {
154
  <?php if ( ! empty( $loginpress_btn_hover_bg ) ) : ?>
155
- background: <?php echo $loginpress_btn_hover_bg; ?> !important;
156
  <?php endif; ?>
157
  <?php if ( ! empty( $loginpress_btn_hover_border ) ) : ?>
158
- border-color: <?php echo $loginpress_btn_hover_border; ?> !important;
159
  <?php endif; ?>
160
  }
161
- #login{
162
- /*background: white;*/
163
- padding: 28px 27px;
164
- margin-top: 2%;
165
- background: #fff;
166
- position: relative;
167
- -webkit-border-radius: 5px;
168
- -moz-border-radius: 5px;
169
- -ms-border-radius: 5px;
170
- -o-border-radius: 5px;
171
- border-radius: 5px;
172
- -webkit-box-shadow: 0 0 15px rgba(0,0,0,.8);
173
- box-shadow: 0 0 15px rgba(0,0,0,.8);
174
- }
175
  #loginform {
176
  <?php if ( ! empty( $loginpress_form_background_img ) ) : ?>
177
- background-image: url(<?php echo $loginpress_form_background_img; ?>) !important;
178
  <?php endif; ?>
179
  <?php if ( ! empty( $loginpress_form_background_clr ) ) : ?>
180
- background-color: <?php echo $loginpress_form_background_clr; ?> !important;
181
  <?php endif; ?>
182
  <?php if ( ! empty( $loginpress_form_height ) ) : ?>
183
- min-height: <?php echo $loginpress_form_height; ?> !important;
184
  <?php endif; ?>
185
  <?php if ( ! empty( $loginpress_form_padding ) ) : ?>
186
- padding: <?php echo $loginpress_form_padding; ?> !important;
187
  <?php endif; ?>
188
  <?php if ( ! empty( $loginpress_form_border ) ) : ?>
189
- border: <?php echo $loginpress_form_border; ?> !important;
190
  <?php endif; ?>
191
  }
192
 
193
  #login {
194
  <?php if ( ! empty( $loginpress_form_width ) ) : ?>
195
- max-width: <?php echo $loginpress_form_width; ?> !important;
196
  <?php else : ?>
197
- max-width: 350px;
198
  <?php endif; ?>
199
- padding: 26px 26px 6px 26px;
200
- width: 100% !important;
201
- }
202
- .login form {
203
- margin-top: 20px;
204
- margin-left: 0;
205
- padding: 0 24px 12px;
206
- background: #fff;
207
- -webkit-box-shadow: none;
208
- /*0 1px 3px rgba(0,0,0,.13);*/
209
- box-shadow: none;
210
  }
211
  .login label {
212
  <?php if ( ! empty( $loginpress_form_field_label ) ) : ?>
213
- color: <?php echo $loginpress_form_field_label; ?> !important;
214
  <?php endif; ?>
215
  }
216
 
217
  .login form .input, .login input[type="text"] {
218
  <?php if ( ! empty( $loginpress_form_field_width ) ) : ?>
219
- width: <?php echo $loginpress_form_field_width; ?> !important;
220
  <?php endif; ?>
221
  <?php if ( ! empty( $loginpress_form_field_margin ) ) : ?>
222
- margin: <?php echo $loginpress_form_field_margin; ?> !important;
223
  <?php endif; ?>
224
  <?php if ( ! empty( $loginpress_form_field_bg ) ) : ?>
225
- background: <?php echo $loginpress_form_field_bg; ?> !important;
226
  <?php endif; ?>
227
  <?php if ( ! empty( $loginpress_form_field_color ) ) : ?>
228
- color: <?php echo $loginpress_form_field_color; ?> !important;
229
- <?php endif; ?>
230
- height: 48px;
231
- background: #fff;
232
- -webkit-border-radius: 5px !important;
233
- -moz-border-radius: 5px !important;
234
- -ms-border-radius: 5px !important;
235
- border-radius: 5px !important;
236
- margin-bottom: 18px;
237
- font: normal 15px "Roboto", sans-serif;
238
- color: #7f7f7f !important;
239
- border-color: #bdbdbd !important;
240
- padding-left: 27px !important;
241
- font-weight: normal !important;
242
- }
243
- .login form .input, .login input[type="submit"] {
244
- background: #fff;
245
- color: #fff;
246
- margin: 7px 0 7px;
247
- height: 46px;
248
- -webkit-border-radius: 5px;
249
- -moz-border-radius: 5px;
250
- -ms-border-radius: 5px;
251
- border-radius: 5px;
252
- font: normal 15px "Roboto", sans-serif;
253
- color: #fff;
254
- width: 100%;
255
- }
256
- .wp-core-ui .button-group.button-large .button, .wp-core-ui .button.button-large{
257
- height: 46px;
258
- line-height: 0;
259
- /*border: 0;*/
260
- background: #008ec2;
261
- }
262
- .login #nav {
263
- text-align: center;
264
- /*float: left;*/
265
  }
 
266
  #lostpasswordform {
267
  <?php if ( ! empty( $loginpress_forget_form_bg_img ) ) : ?>
268
- background-image: url(<?php echo $loginpress_forget_form_bg_img; ?>) !important;
269
  <?php endif; ?>
270
  <?php if ( ! empty( $loginpress_forget_form_bg_clr ) ) : ?>
271
- background-color: <?php echo $loginpress_forget_form_bg_clr; ?> !important;
272
  <?php endif; ?>
273
  }
274
 
275
- #login_error { display:block; }
276
- .message { display:none; }
277
- .custom-message {
278
- -moz-border-radius:3px 3px 3px 3px;
279
- border-style:solid;
280
- border-width:1px;
281
- margin:0 0 16px 8px;
282
- padding:12px;
283
- }
284
 
285
  .login .custom-message {
286
  <?php if ( ! empty( $loginpress_welcome_bg_color ) ) : ?>
287
- background-color: <?php echo $loginpress_welcome_bg_color; ?> !important;
288
  <?php endif; ?>
289
  <?php if ( ! empty( $loginpress_welcome_bg_border ) ) : ?>
290
- border: <?php echo $loginpress_welcome_bg_border; ?> !important;
291
  <?php endif; ?>
292
  }
293
 
294
  .login #nav {
295
  <?php if ( ! empty( $loginpress_footer_bg_color ) ) : ?>
296
- background-color: <?php echo $loginpress_footer_bg_color; ?> !important;
297
  <?php endif; ?>
298
  <?php if ( ! empty( $loginpress_footer_display ) ) : ?>
299
  display: <?php echo $loginpress_footer_display; ?>
@@ -302,38 +220,38 @@ body.login {
302
 
303
  .login #nav a{
304
  <?php if ( ! empty( $loginpress_footer_decoration ) ) : ?>
305
- text-decoration: <?php echo $loginpress_footer_decoration; ?> !important;
306
  <?php endif; ?>
307
  <?php if ( ! empty( $loginpress_footer_text_color ) ) : ?>
308
- color: <?php echo $loginpress_footer_text_color; ?> !important;
309
  <?php endif; ?>
310
  <?php if ( ! empty( $loginpress_footer_font_size ) ) : ?>
311
- font-size: <?php echo $loginpress_footer_font_size; ?> !important;
312
  <?php endif; ?>
313
 
314
  }
315
 
316
  .login #nav a:hover{
317
  <?php if ( ! empty( $loginpress_footer_text_hover ) ) : ?>
318
- color: <?php echo $loginpress_footer_text_hover; ?> !important;
319
  <?php endif; ?>
320
  }
321
 
322
  .login #backtoblog{
323
  <?php if ( ! empty( $loginpress_back_bg_color ) ) : ?>
324
- background-color: <?php echo $loginpress_back_bg_color; ?> !important;
325
  <?php endif; ?>
326
  }
327
 
328
  .login #backtoblog a{
329
  <?php if ( ! empty( $loginpress_back_decoration ) ) : ?>
330
- text-decoration: <?php echo $loginpress_back_decoration; ?> !important;
331
  <?php endif; ?>
332
  <?php if ( ! empty( $loginpress_back_text_color ) ) : ?>
333
- color: <?php echo $loginpress_back_text_color; ?> !important;
334
  <?php endif; ?>
335
  <?php if ( ! empty( $loginpress_back_font_size ) ) : ?>
336
- font-size: <?php echo $loginpress_back_font_size; ?> !important;
337
  <?php endif; ?>
338
  <?php if ( ! empty( $loginpress_back_display ) ) : ?>
339
  display: <?php echo $loginpress_back_display; ?>
@@ -342,217 +260,63 @@ body.login {
342
 
343
  .login #backtoblog a:hover{
344
  <?php if ( ! empty( $loginpress_back_text_hover ) ) : ?>
345
- color: <?php echo $loginpress_back_text_hover; ?> !important;
346
  <?php endif; ?>
347
  }
348
- #backtoblog{
349
- text-align: center;
350
- }
351
- .header-cell{
352
- display: table-cell;
353
- height: 100px;
354
- }
355
- .loginHeaderMenu{
356
- text-align: center;
357
- position: relative;
358
- z-index: 10;
359
- list-style: none;
360
- background: #333;
361
-
362
- }
363
- .loginHeaderMenu>ul>li{
364
- display: inline-block;
365
- vertical-align: top;
366
- position: relative;
367
- list-style: none;
368
- }
369
- .loginHeaderMenu>ul>li>a{
370
- color: #fff;
371
- text-transform: uppercase;
372
- text-decoration: none;
373
- font-size: 16px;
374
- padding: 17px 20px;
375
- display: inline-block;
376
- }
377
- .loginHeaderMenu>ul>li:hover>a{
378
- background: #4CAF50;
379
- color: #fff;
380
- }
381
- .loginHeaderMenu>ul>li>ul{
382
- position: absolute;
383
- width: 200px;
384
- padding: 0;
385
- top: 100%;
386
- left: 0;
387
- background: #fff;
388
- list-style: none;
389
- text-align: left;
390
- border-radius: 0 0 5px 5px;
391
- -webkit-box-shadow: 0px 5px 10px -1px rgba(0,0,0,0.31);
392
- -moz-box-shadow: 0px 5px 10px -1px rgba(0,0,0,0.31);
393
- box-shadow: 0px 5px 10px -1px rgba(0,0,0,0.31);
394
- overflow: hidden;
395
- opacity: 0;
396
- visibility: hidden;
397
- }
398
- .loginHeaderMenu>ul>li:hover>ul{
399
- opacity: 1;
400
- visibility: visible;
401
- }
402
- .loginHeaderMenu>ul>li>ul>li{
403
- font-size: 15px;
404
- color: #333;
405
- }
406
- .loginHeaderMenu>ul>li>ul>li>a{
407
- color: #333;
408
- padding: 10px;
409
- display: block;
410
- text-decoration: none;
411
- }
412
- .loginHeaderMenu>ul>li>ul>li>a:hover {
413
- background: rgba(51, 51, 51, 0.35);
414
- color: #fff;
415
- }
416
- .login-wrapper{
417
- display: table-row;
418
- }
419
- .login-cell{
420
- display: table-cell;
421
- vertical-align: middle;
422
- }
423
- .clear{
424
- display: none;
425
- }
426
- .footer-wrapper{
427
- display: table-row;
428
- }
429
- .footer-cont{
430
-
431
- right: 0;
432
- bottom: 0;
433
- left: 0;
434
- /*background-color: #efefef;*/
435
- text-align: center;
436
- display: table-cell;
437
- vertical-align: bottom;
438
- height: 100px;
439
- }
440
- .loginFooterMenu{
441
- text-align: center;
442
- /*background-color: #333;*/
443
- background-color: rgba(0,0,0,.7);
444
- }
445
- .loginFooterMenu>ul{
446
- display: inline-flex;
447
- /*padding: 10px 10px;*/
448
- }
449
 
450
- /*.loginFooterMenu>ul>li {
451
- padding: 10px 10px;
452
-
453
- }*/
454
-
455
- .loginFooterMenu>ul>li{
456
- display: inline-block;
457
- padding: 18px;
458
- }
459
- .loginFooterMenu>ul>li:focus{
460
- outline: none;
461
- border: 0;
462
- }
463
- .loginFooterMenu>ul>li>a:focus{
464
- outline: none;
465
- border: 0;
466
- }
467
- .loginFooterMenu>ul>li>a{
468
- color: #fff;
469
- text-transform: uppercase;
470
- text-decoration: none;
471
- font-size: 14px;
472
- /*padding: 17px 20px;*/
473
- }
474
- .loginFooterMenu>ul>li>a:hover{
475
- /*background-color: #4CAF50;*/
476
- /*font-size: 18px;*/
477
- }
478
  .loginHead {
479
- width:100%;
480
  <?php if ( ! empty( $loginpress_header_bg_color ) ) : ?>
481
- background: <?php echo $loginpress_header_bg_color; ?> !important;
482
- <?php endif; ?>
483
- text-align: center;
484
- margin-top: 0;
485
- margin-bottom: 20px;
486
- padding: 13px 0 0;
487
- position: relative;
488
- margin: 0;
489
  }
490
 
491
  .loginHead p a {
492
  <?php if ( ! empty( $loginpress_header_text_color ) ) : ?>
493
- color: <?php echo $loginpress_header_text_color; ?> !important;
494
  <?php endif; ?>
495
  <?php if ( ! empty( $loginpress_header_font_size ) ) : ?>
496
- font-size: <?php echo $loginpress_header_font_size; ?> !important;
497
  <?php endif; ?>
498
- text-decoration: none;
499
  }
500
 
501
  .loginHead p a:hover {
502
  <?php if ( ! empty( $loginpress_header_text_hover ) ) : ?>
503
- color: <?php echo $loginpress_header_text_hover; ?> !important;
504
  <?php endif; ?>
505
  }
506
 
507
- .loginFooter {
508
- display: table-footer-group;
509
- /*width:100%;
510
- position:absolute;
511
- bottom:0;
512
- left:0;*/
513
- }
514
-
515
  .loginFooter p a {
516
- display: inline-block;
517
  margin: 0 5px;
518
  <?php if ( ! empty( $loginpress_footer_link_color ) ) : ?>
519
- color: <?php echo $loginpress_footer_link_color; ?> !important;
520
  <?php endif; ?>
521
  <?php if ( ! empty( $loginpress_footer_links_font_size ) ) : ?>
522
- font-size: <?php echo $loginpress_footer_links_font_size; ?> !important;
523
  <?php endif; ?>
524
  }
525
 
526
  .loginFooter p a:hover {
527
  <?php if ( ! empty( $loginpress_footer_link_hover ) ) : ?>
528
- color: <?php echo $loginpress_footer_link_hover; ?> !important;
529
  <?php endif; ?>
530
  <?php if ( ! empty( $loginpress_footer_links_hover_size ) ) : ?>
531
- font-size: <?php echo $loginpress_footer_links_hover_size; ?> !important;
532
  <?php endif; ?>
533
  }
534
 
535
  .loginInner {
536
- /* max-width: 570px;*/
537
- margin: 0 auto;
538
  <?php if ( ! empty( $loginpress_footer_link_bg_clr ) ) : ?>
539
- background: <?php echo $loginpress_footer_link_bg_clr; ?> !important;
540
  <?php endif; ?>
541
- text-align: center;
542
- margin-top: 20px;
543
- margin-bottom: 0;
544
- padding: 13px 0;
545
- position: relative;
546
- }
547
- .copyRight{
548
- text-align: center;
549
- padding: 12px;
550
- background-color: #efefef;
551
  }
552
 
553
  <?php if ( ! empty( $loginpress_custom_css ) ) : ?>
554
  <?php echo $loginpress_custom_css; ?>
555
  <?php endif; ?>
 
 
 
 
556
  </style>
557
 
558
  <?php // $content = ob_get_clean(); ?>
1
  <?php
2
+ // testing error notices OFF
3
+ // ini_set("display_errors", 0);
4
  /**
5
  * Get option and check the key exists in it.
6
  *
7
  * @since 1.0.0
8
  * * * * * * * * * * * * * * * */
9
 
10
+
11
  /**
12
  * @var loginpress_array get_option
13
  * @since 1.0.0
22
  }
23
  }
24
 
 
25
  $loginpress_logo_img = loginpress_get_option_key( 'setting_logo', $loginpress_array );
26
  $loginpress_logo_width = loginpress_get_option_key( 'customize_logo_width', $loginpress_array );
27
  $loginpress_logo_height = loginpress_get_option_key( 'customize_logo_height', $loginpress_array );
76
  $loginpress_custom_css = loginpress_get_option_key( 'loginpress_custom_css', $loginpress_array );
77
  $loginpress_custom_js = loginpress_get_option_key( 'loginpress_custom_js', $loginpress_array );
78
 
79
+
80
  // ob_start();
81
  ?>
82
  <style type="text/css">
84
  box-sizing: border-box;
85
  }
86
  body.login {
87
+
88
+ <?php if ( ! empty( $loginpress_background_img ) ) : ?>
89
+ background-image: url(<?php echo $loginpress_background_img; ?>);
 
90
  <?php endif; ?>
91
  <?php if ( ! empty( $loginpress_background_color ) ) : ?>
92
+ background-color: <?php echo $loginpress_background_color; ?>;
 
 
93
  <?php endif; ?>
94
  <?php if ( ! empty( $loginpress_background_repeat ) ) : ?>
95
+ background-repeat: <?php echo $loginpress_background_repeat; ?>;
 
 
96
  <?php endif; ?>
97
  <?php if ( ! empty( $loginpress_background_postion ) ) : ?>
98
+ background-position: <?php echo $loginpress_background_postion; ?>;
 
 
99
  <?php endif; ?>
100
  <?php if ( ! empty( $loginpress_background_image_size ) ) : ?>
101
+ background-size: <?php echo $loginpress_background_image_size; ?>;
102
+ <?php endif; ?>
 
 
 
 
 
 
 
 
 
 
 
103
  }
104
+
105
  .login h1 a {
106
  <?php if ( ! empty( $loginpress_logo_img ) ) : ?>
107
+ background-image: url( <?php echo $loginpress_logo_img; ?> );
108
  <?php endif; ?>
109
  <?php if ( ! empty( $loginpress_logo_width ) ) : ?>
110
+ width: <?php echo $loginpress_logo_width; ?>;
111
  <?php endif; ?>
112
  <?php if ( ! empty( $loginpress_logo_height ) ) : ?>
113
+ height: <?php echo $loginpress_logo_height; ?>;
114
  <?php endif; ?>
115
  <?php if ( ! empty( $loginpress_logo_width ) || ! empty( $loginpress_logo_height ) ) : ?>
116
+ background-size: cover; <?php //echo $loginpress_logo_width; ?> <?php //echo $loginpress_logo_height; ?>;
117
  <?php endif; ?>
118
  <?php if ( ! empty( $loginpress_logo_padding ) ) : ?>
119
+ padding-bottom: <?php echo $loginpress_logo_padding; ?>;
120
  <?php endif; ?>
121
 
122
  }
123
 
124
+ .wp-core-ui #login .button-primary{
125
  <?php if ( ! empty( $loginpress_btn_bg ) ) : ?>
126
+ background: <?php echo $loginpress_btn_bg; ?>;
127
  <?php endif; ?>
128
  <?php if ( ! empty( $loginpress_btn_border ) ) : ?>
129
+ border-color: <?php echo $loginpress_btn_border; ?>;
130
  <?php endif; ?>
131
  <?php if ( ! empty( $loginpress_btn_shadow ) ) : ?>
132
  box-shadow: 0px 1px 0px <?php echo $loginpress_btn_shadow; ?> inset, 0px 1px 0px rgba(0, 0, 0, 0.15);
133
  <?php endif; ?>
134
  <?php if ( ! empty( $loginpress_btn_color ) ) : ?>
135
+ color: <?php echo $loginpress_btn_color; ?>;
136
  <?php endif; ?>
137
  }
138
 
139
+ .wp-core-ui #login .button-primary:hover{
140
  <?php if ( ! empty( $loginpress_btn_hover_bg ) ) : ?>
141
+ background: <?php echo $loginpress_btn_hover_bg; ?>;
142
  <?php endif; ?>
143
  <?php if ( ! empty( $loginpress_btn_hover_border ) ) : ?>
144
+ border-color: <?php echo $loginpress_btn_hover_border; ?>;
145
  <?php endif; ?>
146
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
147
  #loginform {
148
  <?php if ( ! empty( $loginpress_form_background_img ) ) : ?>
149
+ background-image: url(<?php echo $loginpress_form_background_img; ?>);
150
  <?php endif; ?>
151
  <?php if ( ! empty( $loginpress_form_background_clr ) ) : ?>
152
+ background-color: <?php echo $loginpress_form_background_clr; ?>;
153
  <?php endif; ?>
154
  <?php if ( ! empty( $loginpress_form_height ) ) : ?>
155
+ min-height: <?php echo $loginpress_form_height; ?>;
156
  <?php endif; ?>
157
  <?php if ( ! empty( $loginpress_form_padding ) ) : ?>
158
+ padding: <?php echo $loginpress_form_padding; ?>;
159
  <?php endif; ?>
160
  <?php if ( ! empty( $loginpress_form_border ) ) : ?>
161
+ border: <?php echo $loginpress_form_border; ?>;
162
  <?php endif; ?>
163
  }
164
 
165
  #login {
166
  <?php if ( ! empty( $loginpress_form_width ) ) : ?>
167
+ max-width: <?php echo $loginpress_form_width; ?>;
168
  <?php else : ?>
 
169
  <?php endif; ?>
 
 
 
 
 
 
 
 
 
 
 
170
  }
171
  .login label {
172
  <?php if ( ! empty( $loginpress_form_field_label ) ) : ?>
173
+ color: <?php echo $loginpress_form_field_label; ?>;
174
  <?php endif; ?>
175
  }
176
 
177
  .login form .input, .login input[type="text"] {
178
  <?php if ( ! empty( $loginpress_form_field_width ) ) : ?>
179
+ width: <?php echo $loginpress_form_field_width; ?>;
180
  <?php endif; ?>
181
  <?php if ( ! empty( $loginpress_form_field_margin ) ) : ?>
182
+ margin: <?php echo $loginpress_form_field_margin; ?>;
183
  <?php endif; ?>
184
  <?php if ( ! empty( $loginpress_form_field_bg ) ) : ?>
185
+ background: <?php echo $loginpress_form_field_bg; ?>;
186
  <?php endif; ?>
187
  <?php if ( ! empty( $loginpress_form_field_color ) ) : ?>
188
+ color: <?php echo $loginpress_form_field_color; ?>;
189
+ <?php endif; ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
190
  }
191
+
192
  #lostpasswordform {
193
  <?php if ( ! empty( $loginpress_forget_form_bg_img ) ) : ?>
194
+ background-image: url(<?php echo $loginpress_forget_form_bg_img; ?>);
195
  <?php endif; ?>
196
  <?php if ( ! empty( $loginpress_forget_form_bg_clr ) ) : ?>
197
+ background-color: <?php echo $loginpress_forget_form_bg_clr; ?>;
198
  <?php endif; ?>
199
  }
200
 
201
+
 
 
 
 
 
 
 
 
202
 
203
  .login .custom-message {
204
  <?php if ( ! empty( $loginpress_welcome_bg_color ) ) : ?>
205
+ background-color: <?php echo $loginpress_welcome_bg_color; ?>;
206
  <?php endif; ?>
207
  <?php if ( ! empty( $loginpress_welcome_bg_border ) ) : ?>
208
+ border: <?php echo $loginpress_welcome_bg_border; ?>;
209
  <?php endif; ?>
210
  }
211
 
212
  .login #nav {
213
  <?php if ( ! empty( $loginpress_footer_bg_color ) ) : ?>
214
+ background-color: <?php echo $loginpress_footer_bg_color; ?>;
215
  <?php endif; ?>
216
  <?php if ( ! empty( $loginpress_footer_display ) ) : ?>
217
  display: <?php echo $loginpress_footer_display; ?>
220
 
221
  .login #nav a{
222
  <?php if ( ! empty( $loginpress_footer_decoration ) ) : ?>
223
+ text-decoration: <?php echo $loginpress_footer_decoration; ?>;
224
  <?php endif; ?>
225
  <?php if ( ! empty( $loginpress_footer_text_color ) ) : ?>
226
+ color: <?php echo $loginpress_footer_text_color; ?>;
227
  <?php endif; ?>
228
  <?php if ( ! empty( $loginpress_footer_font_size ) ) : ?>
229
+ font-size: <?php echo $loginpress_footer_font_size . ';'; ?>;
230
  <?php endif; ?>
231
 
232
  }
233
 
234
  .login #nav a:hover{
235
  <?php if ( ! empty( $loginpress_footer_text_hover ) ) : ?>
236
+ color: <?php echo $loginpress_footer_text_hover; ?>;
237
  <?php endif; ?>
238
  }
239
 
240
  .login #backtoblog{
241
  <?php if ( ! empty( $loginpress_back_bg_color ) ) : ?>
242
+ background-color: <?php echo $loginpress_back_bg_color; ?>;
243
  <?php endif; ?>
244
  }
245
 
246
  .login #backtoblog a{
247
  <?php if ( ! empty( $loginpress_back_decoration ) ) : ?>
248
+ text-decoration: <?php echo $loginpress_back_decoration; ?>;
249
  <?php endif; ?>
250
  <?php if ( ! empty( $loginpress_back_text_color ) ) : ?>
251
+ color: <?php echo $loginpress_back_text_color; ?>;
252
  <?php endif; ?>
253
  <?php if ( ! empty( $loginpress_back_font_size ) ) : ?>
254
+ font-size: <?php echo $loginpress_back_font_size; ?>;
255
  <?php endif; ?>
256
  <?php if ( ! empty( $loginpress_back_display ) ) : ?>
257
  display: <?php echo $loginpress_back_display; ?>
260
 
261
  .login #backtoblog a:hover{
262
  <?php if ( ! empty( $loginpress_back_text_hover ) ) : ?>
263
+ color: <?php echo $loginpress_back_text_hover; ?>;
264
  <?php endif; ?>
265
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
266
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
267
  .loginHead {
 
268
  <?php if ( ! empty( $loginpress_header_bg_color ) ) : ?>
269
+ background: <?php echo $loginpress_header_bg_color; ?>;
270
+ <?php endif; ?>
 
 
 
 
 
 
271
  }
272
 
273
  .loginHead p a {
274
  <?php if ( ! empty( $loginpress_header_text_color ) ) : ?>
275
+ color: <?php echo $loginpress_header_text_color; ?>;
276
  <?php endif; ?>
277
  <?php if ( ! empty( $loginpress_header_font_size ) ) : ?>
278
+ font-size: <?php echo $loginpress_header_font_size; ?>;
279
  <?php endif; ?>
 
280
  }
281
 
282
  .loginHead p a:hover {
283
  <?php if ( ! empty( $loginpress_header_text_hover ) ) : ?>
284
+ color: <?php echo $loginpress_header_text_hover; ?>;
285
  <?php endif; ?>
286
  }
287
 
 
 
 
 
 
 
 
 
288
  .loginFooter p a {
 
289
  margin: 0 5px;
290
  <?php if ( ! empty( $loginpress_footer_link_color ) ) : ?>
291
+ color: <?php echo $loginpress_footer_link_color; ?>;
292
  <?php endif; ?>
293
  <?php if ( ! empty( $loginpress_footer_links_font_size ) ) : ?>
294
+ font-size: <?php echo $loginpress_footer_links_font_size; ?>;
295
  <?php endif; ?>
296
  }
297
 
298
  .loginFooter p a:hover {
299
  <?php if ( ! empty( $loginpress_footer_link_hover ) ) : ?>
300
+ color: <?php echo $loginpress_footer_link_hover; ?>;
301
  <?php endif; ?>
302
  <?php if ( ! empty( $loginpress_footer_links_hover_size ) ) : ?>
303
+ font-size: <?php echo $loginpress_footer_links_hover_size; ?>;
304
  <?php endif; ?>
305
  }
306
 
307
  .loginInner {
 
 
308
  <?php if ( ! empty( $loginpress_footer_link_bg_clr ) ) : ?>
309
+ background: <?php echo $loginpress_footer_link_bg_clr; ?>;
310
  <?php endif; ?>
 
 
 
 
 
 
 
 
 
 
311
  }
312
 
313
  <?php if ( ! empty( $loginpress_custom_css ) ) : ?>
314
  <?php echo $loginpress_custom_css; ?>
315
  <?php endif; ?>
316
+
317
+ .wp-core-ui .button-primary{
318
+ text-shadow: none;
319
+ }
320
  </style>
321
 
322
  <?php // $content = ob_get_clean(); ?>
css/style-presets.php ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // $multi_values = ! is_array( get_option( 'customize_presets_settings' ) ) ? explode( ',', get_option( 'customize_presets_settings' ) ) : get_option( 'customize_presets_settings' );
4
+ //
5
+ // $selected_preset = get_option( 'customize_presets_settings', true );
6
+
7
+ $selected_preset = 'default1';
8
+ ?>
9
+
10
+ <?php
11
+ if ( $selected_preset == 'default1' ) {
12
+ include_once LOGINPRESS_ROOT_PATH . '/css/themes/default-1.php';
13
+ echo first_presets();
14
+ } else if ( $selected_preset == 'default2' ) {
15
+ include_once LOGINPRESS_ROOT_PATH . '/css/themes/default-2.php';
16
+ echo second_presets();
17
+ } else {
18
+ do_action( 'loginpress_add_pro_theme', $selected_preset );
19
+ }
20
+ ?>
css/themes/default-1.php ADDED
@@ -0,0 +1,248 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ function first_presets() {
4
+ ob_start();
5
+ ?>
6
+ <style media="screen">
7
+ body.login {
8
+ background-image: url(<?php echo plugins_url( 'img/bg.jpg', LOGINPRESS_PLUGIN_BASENAME ) ?>);
9
+ background-color: #ddd5c3;
10
+ background-repeat: no-repeat;
11
+ background-position: center;
12
+ background-size: cover;
13
+ background-attachment: fixed;
14
+ display: table;
15
+ min-height: 100vh;
16
+ width: 100%;
17
+ padding: 0;
18
+ }
19
+ .header-wrapper{
20
+ display: table-row;
21
+ }
22
+ .wp-core-ui .button-primary {
23
+ color : red;
24
+ background-color : red;
25
+ }
26
+ #login{
27
+ margin-top: 2%;
28
+ background: #fff;
29
+ position: relative;
30
+ -webkit-border-radius: 5px;
31
+ -moz-border-radius: 5px;
32
+ -ms-border-radius: 5px;
33
+ -o-border-radius: 5px;
34
+ border-radius: 5px;
35
+ -webkit-box-shadow: 0 0 15px rgba(0,0,0,.8);
36
+ box-shadow: 0 0 15px rgba(0,0,0,.8);
37
+ max-width: 350px;
38
+ padding: 26px 26px 6px 26px;
39
+ width: 100%;
40
+ }
41
+ .login form {
42
+ margin-top: 20px;
43
+ margin-left: 0;
44
+ padding: 0 24px 12px;
45
+ background: #fff;
46
+ -webkit-box-shadow: none;
47
+ box-shadow: none;
48
+ }
49
+ .login form .input, .login input[type="text"]{
50
+ height: 48px;
51
+ background: #fff;
52
+ -webkit-border-radius: 5px;
53
+ -moz-border-radius: 5px;
54
+ -ms-border-radius: 5px;
55
+ border-radius: 5px;
56
+ margin-bottom: 18px;
57
+ font: normal 15px "Roboto", sans-serif;
58
+ color: #7f7f7f;
59
+ border-color: #bdbdbd;
60
+ padding-left: 27px;
61
+ font-weight: normal;
62
+ }
63
+ .login form .input, .login input[type="submit"] {
64
+ background: #fff;
65
+ color: #fff;
66
+ margin: 7px 0 7px;
67
+ height: 46px;
68
+ -webkit-border-radius: 5px;
69
+ -moz-border-radius: 5px;
70
+ -ms-border-radius: 5px;
71
+ border-radius: 5px;
72
+ font: normal 15px "Roboto", sans-serif;
73
+ color: #fff;
74
+ width: 100%;
75
+ }
76
+ .wp-core-ui .button-group.button-large .button, .wp-core-ui .button.button-large{
77
+ height: 46px;
78
+ line-height: 0;
79
+ background: #008ec2;
80
+ }
81
+ .login #nav {
82
+ text-align: center;
83
+ }
84
+ #login_error { display:block; }
85
+ .message { display:none; }
86
+ .custom-message {
87
+ -moz-border-radius:3px 3px 3px 3px;
88
+ border-style:solid;
89
+ border-width:1px;
90
+ margin:0 0 16px 8px;
91
+ padding:12px;
92
+ }
93
+
94
+ #backtoblog{
95
+ text-align: center;
96
+ }
97
+ .header-cell{
98
+ display: table-cell;
99
+ height: 100px;
100
+ }
101
+ .loginHeaderMenu{
102
+ text-align: center;
103
+ position: relative;
104
+ z-index: 10;
105
+ list-style: none;
106
+ background: #333;
107
+
108
+ }
109
+ .loginHeaderMenu>ul>li{
110
+ display: inline-block;
111
+ vertical-align: top;
112
+ position: relative;
113
+ list-style: none;
114
+ }
115
+ .loginHeaderMenu>ul>li>a{
116
+ color: #fff;
117
+ text-transform: uppercase;
118
+ text-decoration: none;
119
+ font-size: 16px;
120
+ padding: 17px 20px;
121
+ display: inline-block;
122
+ }
123
+ .loginHeaderMenu>ul>li:hover>a{
124
+ background: #4CAF50;
125
+ color: #fff;
126
+ }
127
+ .loginHeaderMenu>ul>li>ul{
128
+ position: absolute;
129
+ width: 200px;
130
+ padding: 0;
131
+ top: 100%;
132
+ left: 0;
133
+ background: #fff;
134
+ list-style: none;
135
+ text-align: left;
136
+ border-radius: 0 0 5px 5px;
137
+ -webkit-box-shadow: 0px 5px 10px -1px rgba(0,0,0,0.31);
138
+ -moz-box-shadow: 0px 5px 10px -1px rgba(0,0,0,0.31);
139
+ box-shadow: 0px 5px 10px -1px rgba(0,0,0,0.31);
140
+ overflow: hidden;
141
+ opacity: 0;
142
+ visibility: hidden;
143
+ }
144
+ .loginHeaderMenu>ul>li:hover>ul{
145
+ opacity: 1;
146
+ visibility: visible;
147
+ }
148
+ .loginHeaderMenu>ul>li>ul>li{
149
+ font-size: 15px;
150
+ color: #333;
151
+ }
152
+ .loginHeaderMenu>ul>li>ul>li>a{
153
+ color: #333;
154
+ padding: 10px;
155
+ display: block;
156
+ text-decoration: none;
157
+ }
158
+ .loginHeaderMenu>ul>li>ul>li>a:hover {
159
+ background: rgba(51, 51, 51, 0.35);
160
+ color: #fff;
161
+ }
162
+ .login-wrapper{
163
+ display: table-row;
164
+ }
165
+ .login-cell{
166
+ display: table-cell;
167
+ vertical-align: middle;
168
+ }
169
+ .clear{
170
+ display: none;
171
+ }
172
+ .footer-wrapper{
173
+ display: table-footer-group;
174
+ }
175
+ .footer-cont{
176
+
177
+ right: 0;
178
+ bottom: 0;
179
+ left: 0;
180
+ text-align: center;
181
+ display: table-cell;
182
+ vertical-align: bottom;
183
+ height: 100px;
184
+ }
185
+ .loginFooterMenu{
186
+ text-align: center;
187
+ background-color: rgba(0,0,0,.7);
188
+ }
189
+ .loginFooterMenu>ul{
190
+ display: inline-flex;
191
+ }
192
+
193
+ .loginFooterMenu>ul>li{
194
+ display: inline-block;
195
+ padding: 18px;
196
+ }
197
+ .loginFooterMenu>ul>li:focus{
198
+ outline: none;
199
+ border: 0;
200
+ }
201
+ .loginFooterMenu>ul>li>a:focus{
202
+ outline: none;
203
+ border: 0;
204
+ }
205
+ .loginFooterMenu>ul>li>a{
206
+ color: #fff;
207
+ text-transform: uppercase;
208
+ text-decoration: none;
209
+ font-size: 14px;
210
+ }
211
+ .loginHead {
212
+ width:100%;
213
+ text-align: center;
214
+ margin-top: 0;
215
+ margin-bottom: 20px;
216
+ padding: 13px 0 0;
217
+ position: relative;
218
+ margin: 0;
219
+ }
220
+ .loginHead p a {
221
+ text-decoration: none;
222
+ }
223
+ .loginFooter {
224
+ display: table-footer-group;
225
+ }
226
+ .loginFooter p a {
227
+ display: inline-block;
228
+ margin: 0 5px;
229
+ }
230
+ .loginInner {
231
+ margin: 0 auto;
232
+ text-align: center;
233
+ margin-top: 20px;
234
+ margin-bottom: 0;
235
+ padding: 13px 0;
236
+ position: relative;
237
+ }
238
+ .copyRight{
239
+ text-align: center;
240
+ padding: 12px;
241
+ background-color: #efefef;
242
+ }
243
+ </style>
244
+
245
+ <?php
246
+ $content = ob_get_clean();
247
+ return $content;
248
+ }
css/themes/default-2.php ADDED
@@ -0,0 +1,132 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ <?php
3
+ function second_presets() {
4
+ ob_start();
5
+ ?>
6
+ <style media="screen">
7
+ html, body.login {
8
+ height: auto !important;
9
+ }
10
+ body.login {
11
+ background-image: url(<?php echo plugins_url( 'img/bg2.jpg', LOGINPRESS_PLUGIN_BASENAME ) ?>);
12
+ background-size: cover;
13
+ display: table;
14
+ min-height: 100vh;
15
+ width: 100%;
16
+ padding: 0;
17
+ }
18
+ .login label{
19
+ font-size:0;
20
+ line-height:0;
21
+ margin-top: 0;
22
+ display: block;
23
+ margin-bottom:
24
+ }
25
+ #login form p + p:not(.forgetmenot){
26
+ margin-top: 35px;
27
+ }
28
+ .login form .input, .login input[type=text]{
29
+ background: rgba(255,255,255,.2);
30
+ display: block;
31
+ color: #fff;
32
+ font-size: 16px;
33
+ font-family: 'Open Sans';
34
+ width:100%;
35
+ border:0;
36
+ height: 50px;
37
+ padding: 0 15px;
38
+ }
39
+ .login form{
40
+ background: none;
41
+ padding: 0;
42
+ box-shadow: none;
43
+ }
44
+ .login form br{
45
+ display: none;
46
+ }
47
+ #login form p.submit{
48
+ clear: both;
49
+ padding-top: 35px;
50
+ }
51
+ .wp-core-ui #login .button-primary{
52
+ width:100% !important;
53
+ display: block;
54
+ float: none;
55
+ background-color : #f78f1e;
56
+ font-weight: 700;
57
+ font-size: 18px;
58
+ font-family: 'Open Sans';
59
+ color : #ffffff;
60
+ height: 56px;
61
+ border-radius: 0;
62
+ border:0;
63
+ box-shadow: none;
64
+ }
65
+ .wp-core-ui #login .button-primary:hover{
66
+ background-color: #fff;
67
+ color : #f78f1e;
68
+ }
69
+ .login form .forgetmenot label{
70
+ font-size: 13px;
71
+ font-family: 'Open Sans';
72
+ color: #d5d5d5;
73
+ }
74
+ .login form input[type=checkbox]{
75
+ background: none;
76
+ border: 1px solid #d5d5d5;
77
+ height: 13px;
78
+ width: 13px;
79
+ min-width: 13px;
80
+ }
81
+ .login #nav, .login #backtoblog {
82
+ margin: 17px 0 0;
83
+ padding: 0;
84
+ font-size: 14px;
85
+ font-family: "Open Sans";
86
+ color: #d5d5d5;
87
+ }
88
+ .login #nav a, .login #backtoblog a{
89
+ font-size: 14px;
90
+ font-family: "Open Sans";
91
+ color: #d5d5d5;
92
+ }
93
+ .login #backtoblog{
94
+ float: left;
95
+ }
96
+ .login #nav{
97
+ float: right;
98
+ }
99
+ .login #backtoblog a:hover, .login #nav a:hover, .login h1 a:hover{
100
+ color: #fff;
101
+ }
102
+ .footer-wrapper{
103
+ display: table-footer-group;
104
+ }
105
+ .footer-cont{
106
+
107
+ right: 0;
108
+ bottom: 0;
109
+ left: 0;
110
+ text-align: center;
111
+ display: table-cell;
112
+ vertical-align: bottom;
113
+ height: 100px;
114
+ }
115
+ .copyRight{
116
+ text-align: center;
117
+ padding: 12px;
118
+ /*background-color: #303030;*/
119
+ color: #fff;
120
+ }
121
+ #login form p + p:not(.forgetmenot){
122
+ color: #d5d5d5;
123
+ }
124
+ input[type=checkbox]:checked:before{
125
+ font-size: 18px;
126
+ }
127
+ </style>
128
+
129
+ <?php
130
+ $content = ob_get_clean();
131
+ return $content;
132
+ }
custom.php CHANGED
@@ -1,1274 +1,1395 @@
1
- <?php
2
-
3
- class LoginPress_Entities {
4
-
5
- /**
6
- * Variable that Check for LoginPress Key.
7
- *
8
- * @var string
9
- * @since 1.0.0
10
- */
11
- public $loginpress_key;
12
-
13
- /**
14
- * Class constructor
15
- */
16
- public function __construct() {
17
-
18
- $this->loginpress_key = get_option( 'loginpress_customization' );
19
- $this->_hooks();
20
- }
21
-
22
-
23
- /**
24
- * Hook into actions and filters
25
- *
26
- * @since 1.0.0
27
- */
28
- private function _hooks() {
29
-
30
- add_filter( 'login_headerurl', array( $this, 'login_page_logo_url' ) );
31
- add_filter( 'login_headertitle', array( $this, 'login_page_logo_title' ) );
32
- add_filter( 'login_errors', array( $this, 'login_error_messages' ) );
33
- add_filter( 'gettext', array( $this, 'change_lostpassword_message' ) );
34
- add_filter( 'login_message', array( $this, 'change_welcome_message' ) );
35
- add_action( 'customize_register', array( $this, 'customize_login_panel' ) );
36
- add_action( 'login_footer', array( $this, 'login_page_custom_footer' ) );
37
- add_action( 'login_head', array( $this, 'login_page_custom_head' ) );
38
- add_action( 'init', array( $this, 'redirect_to_custom_page' ) );
39
- add_action( 'admin_menu', array( $this, 'menu_url' ), 99 );
40
-
41
- }
42
-
43
- /**
44
- * Register plugin settings Panel in WP Customizer
45
- *
46
- * @param $wp_customize
47
- * @since 1.0.0
48
- */
49
- public function customize_login_panel( $wp_customize ){
50
-
51
- // =============================
52
- // = Panel for the LoginPress =
53
- // =============================
54
- $wp_customize->add_panel( 'loginpress_panel', array(
55
- 'title' => __( 'LoginPress', 'loginpress' ),
56
- 'description' => __( 'Customize Your WordPress Login Page with LoginPress :)', 'loginpress' ),
57
- 'priority' => 30,
58
- ));
59
-
60
- // =============================
61
- // = Section for Login Logo =
62
- // =============================
63
- $wp_customize->add_section(
64
- 'customize_logo_section',
65
- array(
66
- 'title' => __( 'Logo', 'loginpress' ),
67
- 'description' => __( 'Customize Your Logo Section', 'loginpress' ),
68
- 'priority' => 5,
69
- 'panel' => 'loginpress_panel',
70
- ));
71
-
72
- $wp_customize->add_setting(
73
- 'loginpress_customization[setting_logo]',
74
- array(
75
- 'type' => 'option',
76
- 'capability' => 'edit_theme_options',
77
- ));
78
-
79
- $wp_customize->add_control(
80
- new WP_Customize_Image_Control(
81
- $wp_customize,
82
- 'setting_logo',
83
- array(
84
- 'label' => __( 'Logo Image:', 'loginpress' ),
85
- 'section' => 'customize_logo_section',
86
- 'priority' => 5,
87
- 'settings' => 'loginpress_customization[setting_logo]'
88
- )));
89
-
90
- $logo_control = array( 'customize_logo_width', 'customize_logo_height', 'customize_logo_padding', 'customize_logo_hover', 'customize_logo_hover_title' );
91
- $logo_default = array( '84px', '84px', '5px', '', '' );
92
- $logo_label = array(
93
- __( 'Logo Width:', 'loginpress' ),
94
- __( 'Logo Height:', 'loginpress' ),
95
- __( 'Padding Bottom:', 'loginpress' ),
96
- __( 'Logo URL:', 'loginpress' ),
97
- __( 'Logo Hover Title:', 'loginpress' )
98
- );
99
-
100
- $logo = 0;
101
- while ( $logo < 5 ) :
102
-
103
- $wp_customize->add_setting( "loginpress_customization[{$logo_control[$logo]}]", array(
104
- 'default' => $logo_default[$logo],
105
- 'type' => 'option',
106
- 'capability' => 'edit_theme_options',
107
- ));
108
-
109
- $wp_customize->add_control( $logo_control[$logo], array(
110
- 'label' => $logo_label[$logo],
111
- 'section' => 'customize_logo_section',
112
- 'priority' => 10,
113
- 'settings' => "loginpress_customization[{$logo_control[$logo]}]"
114
- ));
115
-
116
- $logo++;
117
- endwhile;
118
-
119
- // =============================
120
- // = Section for Background =
121
- // =============================
122
- $wp_customize->add_section(
123
- 'section_background',
124
- array(
125
- 'title' => __( 'Background', 'loginpress' ),
126
- 'description' => '',
127
- 'priority' => 10,
128
- 'panel' => 'loginpress_panel',
129
- ));
130
-
131
- $wp_customize->add_setting(
132
- 'loginpress_customization[setting_background]',
133
- array(
134
- 'default' => plugins_url( 'img/bg.jpg', __FILE__ ),
135
- 'type' => 'option',
136
- 'capability' => 'edit_theme_options',
137
- ));
138
-
139
- $wp_customize->add_control(
140
- new WP_Customize_Image_Control(
141
- $wp_customize,
142
- 'setting_background',
143
- array(
144
- 'label' => __( 'Background Image:', 'loginpress' ),
145
- 'section' => 'section_background',
146
- 'priority' => 5,
147
- 'settings' => 'loginpress_customization[setting_background]'
148
- )));
149
-
150
- $wp_customize->add_setting( 'loginpress_customization[setting_background_color]', array(
151
- 'default' => '#ddd5c3',
152
- 'type' => 'option',
153
- 'capability' => 'edit_theme_options',
154
- ));
155
-
156
- $wp_customize->add_control(
157
- new WP_Customize_Color_Control(
158
- $wp_customize,
159
- 'setting_background_color',
160
- array(
161
- 'label' => __( 'Background Color:', 'loginpress' ),
162
- 'section' => 'section_background',
163
- 'priority' => 15,
164
- 'settings' => 'loginpress_customization[setting_background_color]'
165
- )));
166
-
167
- $wp_customize->add_setting( 'loginpress_customization[background_repeat_radio]', array(
168
- 'default' => 'no-repeat',
169
- 'capability' => 'edit_theme_options',
170
- 'type' => 'option',
171
- ));
172
-
173
- $wp_customize->add_control( 'background_repeat_radio', array(
174
- 'label' => __( 'Background Repeat:', 'loginpress' ),
175
- 'section' => 'section_background',
176
- 'priority' => 20,
177
- 'settings' => 'loginpress_customization[background_repeat_radio]',
178
- 'type' => 'radio',
179
- 'choices' => array(
180
- 'repeat' => 'repeat',
181
- 'repeat-x' => 'repeat-x',
182
- 'repeat-y' => 'repeat-y',
183
- 'no-repeat' => 'no-repeat',
184
- 'initial' => 'initial',
185
- 'inherit' => 'inherit',
186
- ),
187
- ));
188
-
189
- $wp_customize->add_setting( 'loginpress_customization[background_position]', array(
190
- 'default' => 'center',
191
- 'capability' => 'edit_theme_options',
192
- 'type' => 'option',
193
-
194
- ));
195
- $wp_customize->add_control( 'background_position', array(
196
- 'settings' => 'loginpress_customization[background_position]',
197
- 'label' => __( 'Select Position:', 'loginpress' ),
198
- 'section' => 'section_background',
199
- 'priority' => 25,
200
- 'type' => 'select',
201
- 'choices' => array(
202
- 'left top' => 'left top',
203
- 'left center' => 'left center',
204
- 'left bottom' => 'left bottom',
205
- 'right top' => 'right top',
206
- 'right center' => 'right center',
207
- 'right bottom' => 'right bottom',
208
- 'center top' => 'center top',
209
- 'center' => 'center',
210
- 'center bottom' => 'center bottom',
211
- ),
212
- ));
213
-
214
- $wp_customize->add_setting( 'loginpress_customization[background_image_size]', array(
215
- 'default' => 'cover',
216
- 'type' => 'option',
217
- 'capability' => 'edit_theme_options',
218
- ));
219
-
220
- $wp_customize->add_control( 'background_image_size', array(
221
- 'label' => __( 'Background Image Size: ', 'loginpress' ),
222
- 'section' => 'section_background',
223
- 'priority' => 30,
224
- 'settings' => 'loginpress_customization[background_image_size]',
225
- 'type' => 'select',
226
- 'choices' => array(
227
- 'auto' => 'auto',
228
- 'cover' => 'cover',
229
- 'contain' => 'contain',
230
- 'initial' => 'initial',
231
- 'inherit' => 'inherit',
232
- ),
233
- ));
234
-
235
- // =============================
236
- // = Section for Form Beauty =
237
- // =============================
238
- $wp_customize->add_section(
239
- 'section_form',
240
- array(
241
- 'title' => __( 'Customize Login Form', 'loginpress' ),
242
- 'description' => '',
243
- 'priority' => 15,
244
- 'panel' => 'loginpress_panel',
245
- ));
246
-
247
- $wp_customize->add_setting( 'loginpress_customization[setting_form_background]', array(
248
- 'type' => 'option',
249
- 'capability' => 'edit_theme_options',
250
- ));
251
-
252
- $wp_customize->add_control(
253
- new WP_Customize_Image_Control(
254
- $wp_customize,
255
- 'setting_form_background',
256
- array(
257
- 'label' => __( 'Form Background Image', 'loginpress' ),
258
- 'section' => 'section_form',
259
- 'priority' => 5,
260
- 'settings' => 'loginpress_customization[setting_form_background]'
261
- )));
262
-
263
- $form_control = array( 'customize_form_width', 'customize_form_height', 'customize_form_padding', 'customize_form_border', 'textfield_width', 'textfield_margin' );
264
- $form_default = array( '350px', '200px', '26px 24px 46px', '', '100%', '2px 6px 16px 0px' );
265
- $form_label = array(
266
- __( 'Form Width:', 'loginpress' ),
267
- __( 'Form Minimum Height:', 'loginpress' ),
268
- __( 'Form Padding:', 'loginpress' ),
269
- __( 'Border (Example: 2px dotted black):', 'loginpress' ),
270
- __( 'Input Text Field Width:', 'loginpress' ),
271
- __( 'Input Text Field Margin:', 'loginpress' )
272
- );
273
-
274
- $form = 0;
275
- while ( $form < 6 ) :
276
-
277
- $wp_customize->add_setting( "loginpress_customization[{$form_control[$form]}]", array(
278
- 'default' => $form_default[$form],
279
- 'type' => 'option',
280
- 'capability' => 'edit_theme_options',
281
- ));
282
-
283
- $wp_customize->add_control( $form_control[$form], array(
284
- 'label' => $form_label[$form],
285
- 'section' => 'section_form',
286
- // 'priority' => 15,
287
- 'settings' => "loginpress_customization[{$form_control[$form]}]"
288
- ));
289
-
290
- $form++;
291
- endwhile;
292
-
293
- $form_color_control = array( 'form_background_color', 'textfield_background_color', 'textfield_color', 'textfield_label_color' );
294
- $form_color_default = array( '#FFF', '#FFF', '#333', '#777' );
295
- $form_color_label = array(
296
- __( 'Form Background Color:', 'loginpress' ),
297
- __( 'Input Field Background Color:', 'loginpress' ),
298
- __( 'Input Field Text Color:', 'loginpress' ),
299
- __( 'Label Color:', 'loginpress' ),
300
- );
301
-
302
- $form_color = 0;
303
- while ( $form_color < 4 ) :
304
-
305
- $wp_customize->add_setting( "loginpress_customization[{$form_color_control[$form_color]}]", array(
306
- 'default' => $form_color_default[$form_color],
307
- 'type' => 'option',
308
- 'capability' => 'edit_theme_options',
309
- ));
310
-
311
- $wp_customize->add_control(
312
- new WP_Customize_Color_Control(
313
- $wp_customize,
314
- $form_color_control[$form_color],
315
- array(
316
- 'label' => $form_color_label[$form_color],
317
- 'section' => 'section_form',
318
- // 'priority' => 50,
319
- 'settings' => "loginpress_customization[{$form_color_control[$form_color]}]"
320
- ) ) );
321
-
322
- $form_color++;
323
- endwhile;
324
-
325
- // =============================
326
- // = Section for Forget Form =
327
- // =============================
328
- $wp_customize->add_section(
329
- 'section_forget_form',
330
- array(
331
- 'title' => __( 'Customize Forget Form', 'loginpress' ),
332
- 'description' => '',
333
- 'priority' => 20,
334
- 'panel' => 'loginpress_panel',
335
- ));
336
-
337
- $wp_customize->add_setting( 'loginpress_customization[forget_form_background]', array(
338
- 'type' => 'option',
339
- 'capability' => 'edit_theme_options',
340
- ));
341
-
342
- $wp_customize->add_control(
343
- new WP_Customize_Image_Control(
344
- $wp_customize,
345
- 'forget_form_background',
346
- array(
347
- 'label' => __( 'Forget Form Background Image', 'loginpress' ),
348
- 'section' => 'section_forget_form',
349
- 'priority' => 5,
350
- 'settings' => 'loginpress_customization[forget_form_background]'
351
- )));
352
-
353
- $wp_customize->add_setting( 'loginpress_customization[forget_form_background_color]', array(
354
- 'default' => '#FFF',
355
- 'type' => 'option',
356
- 'capability' => 'edit_theme_options',
357
- ));
358
-
359
- $wp_customize->add_control(
360
- new WP_Customize_Color_Control(
361
- $wp_customize,
362
- 'forget_form_background_color',
363
- array(
364
- 'label' => __( 'Forget Form Background Color', 'loginpress' ),
365
- 'section' => 'section_forget_form',
366
- 'priority' => 10,
367
- 'settings' => 'loginpress_customization[forget_form_background_color]'
368
- )));
369
-
370
- // =============================
371
- // = Section for Button Style =
372
- // =============================
373
- $wp_customize->add_section(
374
- 'section_button',
375
- array(
376
- 'title' => __( 'Button Beauty', 'loginpress' ),
377
- 'description' => '',
378
- 'priority' => 25,
379
- 'panel' => 'loginpress_panel',
380
- ));
381
-
382
- $button_control = array( 'custom_button_color', 'button_border_color', 'button_hover_color', 'button_hover_border', 'custom_button_shadow', 'button_text_color' );
383
- $button_default = array( '#2EA2CC', '#0074A2', '#1E8CBE', '#0074A2', '#78C8E6', '#FFF' );
384
- $button_label = array(
385
- __( 'Button Color:', 'loginpress' ),
386
- __( 'Button Border Color:', 'loginpress' ),
387
- __( 'Button Color (Hover):', 'loginpress' ),
388
- __( 'Button Border (Hover):', 'loginpress' ),
389
- __( 'Button Box Shadow:', 'loginpress' ),
390
- __( 'Button Text Color:', 'loginpress' )
391
- );
392
-
393
- $button = 0;
394
- while ( $button < 6 ) :
395
-
396
- $wp_customize->add_setting( "loginpress_customization[{$button_control[$button]}]", array(
397
- 'default' => $button_default[$button],
398
- 'type' => 'option',
399
- 'capability' => 'edit_theme_options',
400
- ));
401
-
402
- $wp_customize->add_control(
403
- new WP_Customize_Color_Control(
404
- $wp_customize,
405
- $button_control[$button],
406
- array(
407
- 'label' => $button_label[$button],
408
- 'section' => 'section_button',
409
- 'priority' => 5,
410
- 'settings' => "loginpress_customization[{$button_control[$button]}]"
411
- ) ) );
412
-
413
- $button++;
414
- endwhile;
415
-
416
- // =============================
417
- // = Section for Error message =
418
- // =============================
419
- $wp_customize->add_section(
420
- 'section_error',
421
- array(
422
- 'title' => __( 'Error Messages', 'loginpress' ),
423
- 'description' => '',
424
- 'priority' => 30,
425
- 'panel' => 'loginpress_panel',
426
- ));
427
-
428
- $error_control = array( 'incorrect_username', 'incorrect_password', 'empty_username', 'empty_password', 'invalid_email', 'empty_email', 'invalidcombo_message' );
429
- $error_default = array( 'Incorrect Username', 'Incorrect Password', 'Empty Username', 'Empty Password', 'The email address is incorrect.', 'The email address is empty.', 'Invalid Username or Email.' );
430
- $error_label = array(
431
- __( 'Incorrect Username Message:', 'loginpress' ),
432
- __( 'Incorrect Password Message:', 'loginpress' ),
433
- __( 'Empty Username Message:', 'loginpress' ),
434
- __( 'Empty Password Message:', 'loginpress' ),
435
- __( 'Invalid Email Message:', 'loginpress' ),
436
- __( 'Empty Email Message:', 'loginpress' ),
437
- __( 'Forget Password Message:', 'loginpress' ),
438
- );
439
-
440
- $error = 0;
441
- while ( $error < 7 ) :
442
-
443
- $wp_customize->add_setting( "loginpress_customization[{$error_control[$error]}]", array(
444
- 'default' => $error_default[$error],
445
- 'type' => 'option',
446
- 'capability' => 'edit_theme_options',
447
- ));
448
-
449
- $wp_customize->add_control( $error_control[$error], array(
450
- 'label' => $error_label[$error],
451
- 'section' => 'section_error',
452
- 'priority' => 5,
453
- 'settings' => "loginpress_customization[{$error_control[$error]}]",
454
- ));
455
-
456
- $error++;
457
- endwhile;
458
-
459
- // =============================
460
- // = Section for Welcome message
461
- // =============================
462
- $wp_customize->add_section(
463
- 'section_welcome',
464
- array(
465
- 'title' => __( 'Welcome Messages', 'loginpress' ),
466
- 'description' => '',
467
- 'priority' => 35,
468
- 'panel' => 'loginpress_panel',
469
- ));
470
-
471
- $welcome_control = array( 'lostpwd_welcome_message', 'welcome_message', 'register_welcome_message', 'logout_message', 'message_background_border' );
472
- $welcome_default = array( 'Forget ?', 'Welcome', 'Register yourself', 'Logout', '' );
473
- $welcome_label = array(
474
- __( 'Welcome Message on Lost Password:', 'loginpress' ),
475
- __( 'Welcome Message on Front Page:', 'loginpress' ),
476
- __( 'Welcome Message on Registration:', 'loginpress' ),
477
- __( 'Logout Message:', 'loginpress' ),
478
- __( 'Message Field Border: ( Example: 1px solid #00a0d2; )', 'loginpress' ),
479
- );
480
-
481
- $welcome = 0;
482
- while ( $welcome < 5 ) :
483
-
484
- $wp_customize->add_setting( "loginpress_customization[{$welcome_control[ $welcome ]}]", array(
485
- 'default' => $welcome_default[ $welcome ],
486
- 'type' => 'option',
487
- 'capability' => 'edit_theme_options',
488
- ));
489
-
490
- $wp_customize->add_control( $welcome_control[ $welcome ], array(
491
- 'label' => $welcome_label[ $welcome ],
492
- 'section' => 'section_welcome',
493
- 'priority' => 5,
494
- 'settings' => "loginpress_customization[{$welcome_control[ $welcome ]}]",
495
- ));
496
-
497
- $welcome++;
498
- endwhile;
499
-
500
- $wp_customize->add_setting( 'loginpress_customization[message_background_color]', array(
501
- 'default' => '#fff',
502
- 'type' => 'option',
503
- 'capability' => 'edit_theme_options',
504
- ));
505
-
506
- $wp_customize->add_control(
507
- new WP_Customize_Color_Control(
508
- $wp_customize,
509
- 'message_background_color',
510
- array(
511
- 'label' => __( 'Message Field Background Color:', 'loginpress' ),
512
- 'section' => 'section_welcome',
513
- 'priority' => 30,
514
- 'settings' => 'loginpress_customization[message_background_color]'
515
- )));
516
-
517
- // =============================
518
- // = Section for Header message
519
- // =============================
520
- // $wp_customize->add_section(
521
- // 'section_head',
522
- // array(
523
- // 'title' => __( 'Header Message', 'loginpress' ),
524
- // 'description' => '',
525
- // 'priority' => 35,
526
- // 'panel' => 'loginpress_panel',
527
- // ));
528
- //
529
- // $wp_customize->add_setting( 'loginpress_customization[login_hearder_message]', array(
530
- // 'default' => 'Latest NEWS',
531
- // 'type' => 'option',
532
- // 'capability' => 'edit_theme_options',
533
- // ));
534
- //
535
- // $wp_customize->add_control( 'login_hearder_message', array(
536
- // 'label' => __( 'Header Message:', 'loginpress' ),
537
- // 'section' => 'section_head',
538
- // 'priority' => 5,
539
- // 'settings' => 'loginpress_customization[login_hearder_message]',
540
- // ));
541
- //
542
- // $wp_customize->add_setting( 'loginpress_customization[login_hearder_message_link]', array(
543
- // 'default' => '#',
544
- // 'type' => 'option',
545
- // 'capability' => 'edit_theme_options',
546
- // ));
547
- //
548
- // $wp_customize->add_control( 'login_hearder_message_link', array(
549
- // 'label' => __( 'Header Message Link:', 'loginpress' ),
550
- // 'section' => 'section_head',
551
- // 'priority' => 5,
552
- // 'settings' => 'loginpress_customization[login_hearder_message_link]',
553
- // ));
554
- //
555
- // $wp_customize->add_setting( 'loginpress_customization[login_head_color]', array(
556
- // 'default' => '#17a8e3',
557
- // 'type' => 'option',
558
- // 'capability' => 'edit_theme_options',
559
- // ));
560
- //
561
- // $wp_customize->add_control(
562
- // new WP_Customize_Color_Control(
563
- // $wp_customize,
564
- // 'login_head_color',
565
- // array(
566
- // 'label' => __( 'Header Text Color:', 'loginpress' ),
567
- // 'section' => 'section_head',
568
- // 'priority' => 10,
569
- // 'settings' => 'loginpress_customization[login_head_color]'
570
- // )));
571
- //
572
- // $wp_customize->add_setting( 'loginpress_customization[login_head_color_hover]', array(
573
- // // 'default' => '#17a8e3',
574
- // 'type' => 'option',
575
- // 'capability' => 'edit_theme_options',
576
- // ));
577
- //
578
- // $wp_customize->add_control(
579
- // new WP_Customize_Color_Control(
580
- // $wp_customize,
581
- // 'login_head_color_hover',
582
- // array(
583
- // 'label' => __( 'Header Text Hover Color:', 'loginpress' ),
584
- // 'section' => 'section_head',
585
- // 'priority' => 15,
586
- // 'settings' => 'loginpress_customization[login_head_color_hover]'
587
- // )));
588
- //
589
- // $wp_customize->add_setting( 'loginpress_customization[login_head_font_size]', array(
590
- // 'default' => '13px;',
591
- // 'type' => 'option',
592
- // 'capability' => 'edit_theme_options',
593
- // ));
594
- //
595
- // $wp_customize->add_control( 'login_head_font_size', array(
596
- // 'label' => __( 'Text Font Size:', 'loginpress' ),
597
- // 'section' => 'section_head',
598
- // 'priority' => 20,
599
- // 'settings' => 'loginpress_customization[login_head_font_size]',
600
- // ));
601
- //
602
- // $wp_customize->add_setting( 'loginpress_customization[login_head_bg_color]', array(
603
- // // 'default' => '#17a8e3',
604
- // 'type' => 'option',
605
- // 'capability' => 'edit_theme_options',
606
- // ));
607
- //
608
- // $wp_customize->add_control(
609
- // new WP_Customize_Color_Control(
610
- // $wp_customize,
611
- // 'login_head_bg_color',
612
- // array(
613
- // 'label' => __( 'Header Background Color:', 'loginpress' ),
614
- // 'section' => 'section_head',
615
- // 'priority' => 25,
616
- // 'settings' => 'loginpress_customization[login_head_bg_color]'
617
- // )));
618
-
619
- // =============================
620
- // = Custom Header Login menu =
621
- // =============================
622
- // $menuVals = array();
623
- // $menus = get_registered_nav_menus();
624
- //
625
- // foreach ( $menus as $location => $name ) {
626
- // $menuVals[$location] = $name ;
627
- // }
628
- // $wp_customize->add_section(
629
- // 'customize_menu_section',
630
- // array(
631
- // 'title' => __( 'Login Page Menus', 'loginpress' ),
632
- // 'description' => '',
633
- // 'priority' => 32,
634
- // 'panel' => 'loginpress_panel',
635
- // ));
636
- //
637
- // $wp_customize->add_setting('loginpress_customization[header_login_menu]', array(
638
- // 'capability' => 'edit_theme_options',
639
- // 'type' => 'option',
640
- // ));
641
- //
642
- // $wp_customize->add_control('header_login_menu', array(
643
- // 'settings' => 'loginpress_customization[header_login_menu]',
644
- // 'label' => __( 'Display Header Menu?', 'loginpress'),
645
- // 'section' => 'customize_menu_section',
646
- // 'priority' => 5,
647
- // 'type' => 'checkbox',
648
- // ));
649
- //
650
- // $wp_customize->add_setting('loginpress_customization[customize_login_menu]', array(
651
- // 'capability' => 'edit_theme_options',
652
- // 'type' => 'option',
653
- //
654
- // ));
655
- // $wp_customize->add_control( 'customize_login_menu', array(
656
- // 'settings' => 'loginpress_customization[customize_login_menu]',
657
- // 'label' => __( 'Select Menu for Header:', 'loginpress' ),
658
- // 'section' => 'customize_menu_section',
659
- // 'type' => 'select',
660
- // 'priority' => 10,
661
- // 'choices' => $menuVals,
662
- // ));
663
- //
664
- // $wp_customize->add_setting('loginpress_customization[footer_login_menu]', array(
665
- // 'capability' => 'edit_theme_options',
666
- // 'type' => 'option',
667
- // ));
668
- //
669
- // $wp_customize->add_control('footer_login_menu', array(
670
- // 'settings' => 'loginpress_customization[footer_login_menu]',
671
- // 'label' => __( 'Display Footer Menu?', 'loginpress' ),
672
- // 'section' => 'customize_menu_section',
673
- // 'priority' => 15,
674
- // 'type' => 'checkbox',
675
- // ));
676
- //
677
- // $wp_customize->add_setting('loginpress_customization[customize_login_footer_menu]', array(
678
- // 'capability' => 'edit_theme_options',
679
- // 'type' => 'option',
680
- //
681
- // ));
682
- // $wp_customize->add_control( 'customize_login_footer_menu', array(
683
- // 'settings' => 'loginpress_customization[customize_login_footer_menu]',
684
- // 'label' => __( 'Select Menu:', 'loginpress' ),
685
- // 'section' => 'customize_menu_section',
686
- // 'priority' => 20,
687
- // 'type' => 'select',
688
- // 'choices' => $menuVals,
689
- // ));
690
-
691
- // =============================
692
- // = Section for Form Footer =
693
- // =============================
694
- $wp_customize->add_section(
695
- 'section_fotter',
696
- array(
697
- 'title' => __( 'Form Footer', 'loginpress' ),
698
- 'description' => '',
699
- 'priority' => 40,
700
- 'panel' => 'loginpress_panel',
701
- ));
702
-
703
- $wp_customize->add_setting( 'loginpress_customization[login_footer_text]', array(
704
- 'default' => 'Lost your password?',
705
- 'type' => 'option',
706
- 'capability' => 'edit_theme_options',
707
- ));
708
-
709
- $wp_customize->add_control( 'login_footer_text', array(
710
- 'label' => __( 'Lost Password Text', 'loginpress' ),
711
- 'section' => 'section_fotter',
712
- 'priority' => 5,
713
- 'settings' => 'loginpress_customization[login_footer_text]',
714
- ));
715
-
716
- $wp_customize->add_setting( 'loginpress_customization[footer_display_text]', array(
717
- 'default' => 'block',
718
- 'capability' => 'edit_theme_options',
719
- 'type' => 'option',
720
- ));
721
-
722
- $wp_customize->add_control( 'footer_display_text', array(
723
- 'label' => __( 'Footer Text Display:', 'loginpress' ),
724
- 'section' => 'section_fotter',
725
- 'priority' => 10,
726
- 'settings' => 'loginpress_customization[footer_display_text]',
727
- 'type' => 'radio',
728
- 'choices' => array(
729
- 'block' => 'show',
730
- 'none' => 'hide',
731
- ),
732
- ));
733
-
734
- $wp_customize->add_setting( 'loginpress_customization[login_footer_text_decoration]', array(
735
- 'default' => 'none',
736
- 'capability' => 'edit_theme_options',
737
- 'type' => 'option',
738
-
739
- ));
740
- $wp_customize->add_control( 'login_footer_text_decoration', array(
741
- 'settings' => 'loginpress_customization[login_footer_text_decoration]',
742
- 'label' => 'Select Text Decoration:',
743
- 'section' => 'section_fotter',
744
- 'priority' => 15,
745
- 'type' => 'select',
746
- 'choices' => array(
747
- 'none' => 'none',
748
- 'overline' => 'overline',
749
- 'line-through' => 'line-through',
750
- 'underline' => 'underline',
751
- ),
752
- ));
753
-
754
- $wp_customize->add_setting( 'loginpress_customization[login_footer_color]', array(
755
- 'default' => '#17a8e3',
756
- 'type' => 'option',
757
- 'capability' => 'edit_theme_options',
758
- ));
759
-
760
- $wp_customize->add_control(
761
- new WP_Customize_Color_Control(
762
- $wp_customize,
763
- 'login_footer_color',
764
- array(
765
- 'label' => __( 'Footer Text Color:', 'loginpress' ),
766
- 'section' => 'section_fotter',
767
- 'priority' => 20,
768
- 'settings' => 'loginpress_customization[login_footer_color]'
769
- )));
770
-
771
- $wp_customize->add_setting( 'loginpress_customization[login_footer_color_hover]', array(
772
- // 'default' => '#17a8e3',
773
- 'type' => 'option',
774
- 'capability' => 'edit_theme_options',
775
- ));
776
-
777
- $wp_customize->add_control(
778
- new WP_Customize_Color_Control(
779
- $wp_customize,
780
- 'login_footer_color_hover',
781
- array(
782
- 'label' => __( 'Footer Text Hover Color:', 'loginpress' ),
783
- 'section' => 'section_fotter',
784
- 'priority' => 25,
785
- 'settings' => 'loginpress_customization[login_footer_color_hover]'
786
- )));
787
-
788
- $wp_customize->add_setting( 'loginpress_customization[login_footer_font_size]', array(
789
- 'default' => '13px;',
790
- 'type' => 'option',
791
- 'capability' => 'edit_theme_options',
792
- ));
793
-
794
- $wp_customize->add_control( 'login_footer_font_size', array(
795
- 'label' => __( 'Text Font Size:', 'loginpress' ),
796
- 'section' => 'section_fotter',
797
- 'priority' => 30,
798
- 'settings' => 'loginpress_customization[login_footer_font_size]',
799
- ));
800
-
801
- $wp_customize->add_setting( 'loginpress_customization[login_footer_bg_color]', array(
802
- // 'default' => '#17a8e3',
803
- 'type' => 'option',
804
- 'capability' => 'edit_theme_options',
805
- ));
806
-
807
- $wp_customize->add_control(
808
- new WP_Customize_Color_Control(
809
- $wp_customize,
810
- 'login_footer_bg_color',
811
- array(
812
- 'label' => __( 'Footer Background Color:', 'loginpress' ),
813
- 'section' => 'section_fotter',
814
- 'priority' => 35,
815
- 'settings' => 'loginpress_customization[login_footer_bg_color]'
816
- )));
817
- // Fields for Back Link
818
- // $wp_customize->add_setting( 'login_back_text', array(
819
- // 'default' => 'Lost your password?',
820
- // 'type' => 'option',
821
- // 'capability' => 'edit_theme_options',
822
- // ));
823
-
824
- // $wp_customize->add_control( 'login_back_text', array(
825
- // 'label' => __( 'Lost Password Text', 'loginpress' ),
826
- // 'section' => 'section_fotter',
827
- // 'priority' => 40,
828
- // 'settings' => 'login_back_text',
829
- // ));
830
-
831
- $wp_customize->add_setting( 'loginpress_customization[back_display_text]', array(
832
- 'default' => 'block',
833
- 'capability' => 'edit_theme_options',
834
- 'type' => 'option',
835
- ));
836
-
837
- $wp_customize->add_control( 'back_display_text', array(
838
- 'label' => __( '"Back to" Text Display:', 'loginpress' ),
839
- 'section' => 'section_fotter',
840
- 'priority' => 45,
841
- 'settings' => 'loginpress_customization[back_display_text]',
842
- 'type' => 'radio',
843
- 'choices' => array(
844
- 'block' => 'show',
845
- 'none' => 'hide',
846
- ),
847
- ));
848
-
849
- $wp_customize->add_setting( 'loginpress_customization[login_back_text_decoration]', array(
850
- 'default' => 'none',
851
- 'capability' => 'edit_theme_options',
852
- 'type' => 'option',
853
-
854
- ));
855
- $wp_customize->add_control( 'login_back_text_decoration', array(
856
- 'settings' => 'loginpress_customization[login_back_text_decoration]',
857
- 'label' => __( '"Back to" Text Decoration:', 'loginpress' ),
858
- 'section' => 'section_fotter',
859
- 'priority' => 50,
860
- 'type' => 'select',
861
- 'choices' => array(
862
- 'none' => 'none',
863
- 'overline' => 'overline',
864
- 'line-through' => 'line-through',
865
- 'underline' => 'underline',
866
- ),
867
- ));
868
-
869
- $wp_customize->add_setting( 'loginpress_customization[login_back_color]', array(
870
- 'default' => '#17a8e3',
871
- 'type' => 'option',
872
- 'capability' => 'edit_theme_options',
873
- ));
874
-
875
- $wp_customize->add_control(
876
- new WP_Customize_Color_Control(
877
- $wp_customize,
878
- 'login_back_color',
879
- array(
880
- 'label' => __( '"Back to" Text Color:', 'loginpress' ),
881
- 'section' => 'section_fotter',
882
- 'priority' => 55,
883
- 'settings' => 'loginpress_customization[login_back_color]'
884
- )));
885
-
886
- $wp_customize->add_setting( 'loginpress_customization[login_back_color_hover]', array(
887
- // 'default' => '#17a8e3',
888
- 'type' => 'option',
889
- 'capability' => 'edit_theme_options',
890
- ));
891
-
892
- $wp_customize->add_control(
893
- new WP_Customize_Color_Control(
894
- $wp_customize,
895
- 'login_back_color_hover',
896
- array(
897
- 'label' => __( '"Back to" Text Hover Color:', 'loginpress' ),
898
- 'section' => 'section_fotter',
899
- 'priority' => 60,
900
- 'settings' => 'loginpress_customization[login_back_color_hover]'
901
- )));
902
-
903
- $wp_customize->add_setting( 'loginpress_customization[login_back_font_size]', array(
904
- 'default' => '13px;',
905
- 'type' => 'option',
906
- 'capability' => 'edit_theme_options',
907
- ));
908
-
909
- $wp_customize->add_control( 'login_back_font_size', array(
910
- 'label' => __( '"Back to" Text Font Size:', 'loginpress' ),
911
- 'section' => 'section_fotter',
912
- 'priority' => 65,
913
- 'settings' => 'loginpress_customization[login_back_font_size]',
914
- ));
915
-
916
- $wp_customize->add_setting( 'loginpress_customization[login_back_bg_color]', array(
917
- // 'default' => '#17a8e3',
918
- 'type' => 'option',
919
- 'capability' => 'edit_theme_options',
920
- ));
921
-
922
- $wp_customize->add_control(
923
- new WP_Customize_Color_Control(
924
- $wp_customize,
925
- 'login_back_bg_color',
926
- array(
927
- 'label' => __( 'Footer Background Color:', 'loginpress' ),
928
- 'section' => 'section_fotter',
929
- 'priority' => 70,
930
- 'settings' => 'loginpress_customization[login_back_bg_color]'
931
- )));
932
-
933
- $wp_customize->add_setting( 'loginpress_customization[login_footer_copy_right]', array(
934
- 'default' => '© 2016 WPBrigade, All Rights Reserved.',
935
- 'type' => 'option',
936
- 'capability' => 'edit_theme_options',
937
- ));
938
-
939
- $wp_customize->add_control( 'login_footer_copy_right', array(
940
- 'label' => __( 'Copyright Note:', 'loginpress' ),
941
- 'type' => 'textarea',
942
- 'section' => 'section_fotter',
943
- 'priority' => 75,
944
- 'settings' => 'loginpress_customization[login_footer_copy_right]'
945
- ));
946
-
947
- // =============================
948
- // = Section for Custom CSS =
949
- // =============================
950
- $wp_customize->add_section(
951
- 'section_css',
952
- array(
953
- 'title' => __( 'Custom CSS', 'loginpress' ),
954
- 'description' => '',
955
- 'priority' => 50,
956
- 'panel' => 'loginpress_panel',
957
- ));
958
-
959
- $wp_customize->add_setting( 'loginpress_customization[loginpress_custom_css]', array(
960
- 'type' => 'option',
961
- 'capability' => 'edit_theme_options',
962
- ));
963
-
964
- $wp_customize->add_control( 'loginpress_custom_css', array(
965
- 'label' => __( 'Customize CSS', 'loginpress' ),
966
- 'type' => 'textarea',
967
- 'section' => 'section_css',
968
- 'priority' => 5,
969
- 'settings' => 'loginpress_customization[loginpress_custom_css]'
970
- ));
971
-
972
- // =============================
973
- // = Section for Custom JS =
974
- // =============================
975
- $wp_customize->add_section(
976
- 'section_js',
977
- array(
978
- 'title' => __( 'Custom JS', 'loginpress' ),
979
- 'description' => '',
980
- 'priority' => 55,
981
- 'panel' => 'loginpress_panel',
982
- ));
983
-
984
- $wp_customize->add_setting( 'loginpress_customization[loginpress_custom_js]', array(
985
- 'type' => 'option',
986
- 'capability' => 'edit_theme_options',
987
- ));
988
-
989
- $wp_customize->add_control( 'loginpress_custom_js', array(
990
- 'label' => __( 'Customize JS', 'loginpress' ),
991
- 'type' => 'textarea',
992
- 'section' => 'section_js',
993
- 'priority' => 5,
994
- 'settings' => 'loginpress_customization[loginpress_custom_js]'
995
- ));
996
-
997
- }
998
-
999
- /**
1000
- * Manage the Login Footer Links
1001
- *
1002
- * @since 1.0.0
1003
- * * * * * * * * * * * * * * * */
1004
- public function login_page_custom_footer() {
1005
-
1006
- if ( $this->loginpress_key ) {
1007
-
1008
- // echo '</div></div>';
1009
- echo '<div class="footer-wrapper">';
1010
- echo '<div class="footer-cont">';
1011
-
1012
- // if ( array_key_exists( 'footer_login_menu', $this->loginpress_key ) && checked( $this->loginpress_key['footer_login_menu'], true, false ) ) {
1013
- //
1014
- // wp_nav_menu( array(
1015
- // 'theme_location' => $this->loginpress_key['customize_login_footer_menu'],
1016
- // 'container' => false,
1017
- // 'menu_class' => 'loginFooterMenu',
1018
- // 'echo' => true,
1019
- // )
1020
- // );
1021
- //
1022
- // }
1023
-
1024
- if ( array_key_exists( 'login_footer_copy_right', $this->loginpress_key ) ) {
1025
- echo '<div class="copyRight">'.$this->loginpress_key['login_footer_copy_right'].'</div>';
1026
- }
1027
-
1028
- echo '</div></div>';
1029
- }
1030
- }
1031
-
1032
- /**
1033
- * Manage the Login Head
1034
- *
1035
- * @since 1.0.0
1036
- * * * * * * * * * * * */
1037
- public function login_page_custom_head() {
1038
-
1039
- // Include CSS File in heared.
1040
- include( plugin_dir_path( __FILE__ ) . 'css/style-login.php' );
1041
-
1042
- if ( $this->loginpress_key && array_key_exists( 'header_login_menu', $this->loginpress_key ) ) {
1043
-
1044
- // echo '<div class="header-wrapper">';
1045
- // echo '<div class="header-cell">';
1046
- // if ( array_key_exists( 'header_login_menu', $this->loginpress_key ) && checked( $this->loginpress_key['header_login_menu'], true, false ) ) {
1047
- //
1048
- // wp_nav_menu( array(
1049
- // 'theme_location' => $this->loginpress_key['customize_login_menu'],
1050
- // 'container' => false,
1051
- // 'menu_class' => 'loginHeaderMenu',
1052
- // 'echo' => true,
1053
- // )
1054
- // );
1055
- // }
1056
- // echo '</div></div><div class="login-wrapper"><div class="login-cell">';
1057
- }
1058
- }
1059
- /**
1060
- * Set Redirect Path of Logo
1061
- *
1062
- * @since 1.0.0
1063
- * @return mixed
1064
- * * * * * * * * * * * * * */
1065
- public function login_page_logo_url() {
1066
-
1067
- if ( $this->loginpress_key && array_key_exists( 'customize_logo_hover', $this->loginpress_key ) ) {
1068
- return $this->loginpress_key["customize_logo_hover"];
1069
- } else {
1070
- return home_url();
1071
- }
1072
- }
1073
-
1074
- /**
1075
- * Set hover Title of Logo
1076
- *
1077
- * @since 1.0.0
1078
- * @return mixed
1079
- * * * * * * * * * * * * */
1080
- public function login_page_logo_title() {
1081
- if ( $this->loginpress_key && array_key_exists( 'customize_logo_hover_title', $this->loginpress_key ) ) {
1082
- return $this->loginpress_key["customize_logo_hover_title"];
1083
- } else {
1084
- return home_url();
1085
- }
1086
- }
1087
-
1088
- /**
1089
- * Set Errors Messages to Show off
1090
- *
1091
- * @param $error
1092
- * @since 1.0.0
1093
- * @return string
1094
- * * * * * * * * * * * * * * * * */
1095
- public function login_error_messages($error) {
1096
-
1097
- global $errors;
1098
- $error_codes = $errors->get_error_codes();
1099
- if ( $this->loginpress_key ) {
1100
-
1101
- $invalid_usrname = array_key_exists( 'incorrect_username', $this->loginpress_key ) ? $this->loginpress_key['incorrect_username']: esc_html__( 'Invalid Username', 'loginpress' );
1102
-
1103
- $invalid_pasword = array_key_exists( 'incorrect_password', $this->loginpress_key ) ? $this->loginpress_key['incorrect_password']: esc_html__( 'Invalid Password', 'loginpress' );
1104
-
1105
- $empty_username = array_key_exists( 'empty_username', $this->loginpress_key ) ? $this->loginpress_key['empty_username']: esc_html__( 'Empty Username', 'loginpress' );
1106
-
1107
- $empty_password = array_key_exists( 'empty_password', $this->loginpress_key ) ? $this->loginpress_key['empty_password']: esc_html__( 'Empty Password', 'loginpress' );
1108
-
1109
- $invalid_email = array_key_exists( 'invalid_email', $this->loginpress_key ) ? $this->loginpress_key['invalid_email']: esc_html__( 'The email address is incorrect.', 'loginpress' );
1110
-
1111
- $empty_email = array_key_exists( 'empty_email', $this->loginpress_key ) ? $this->loginpress_key['empty_email']: esc_html__( 'The email address is empty.', 'loginpress' );
1112
-
1113
- $invalidcombo = array_key_exists( 'invalidcombo_message', $this->loginpress_key ) ? $this->loginpress_key['invalidcombo_message']: esc_html__( 'Invalid Username or Email.', 'loginpress' );
1114
-
1115
- if ( in_array( 'invalid_username', $error_codes ) ) {
1116
- return $invalid_usrname;
1117
- }
1118
-
1119
- if ( in_array( 'incorrect_password', $error_codes ) ) {
1120
- return $invalid_pasword;
1121
- }
1122
-
1123
- if ( in_array( 'empty_username', $error_codes ) ) {
1124
- return $empty_username;
1125
- }
1126
-
1127
- if ( in_array( 'empty_password', $error_codes ) ) {
1128
- return $empty_password;
1129
- }
1130
-
1131
- // registeration Form enteries
1132
- if ( in_array( 'invalid_email', $error_codes ) ) {
1133
- return $invalid_email;
1134
- }
1135
-
1136
- if ( in_array( 'empty_email', $error_codes ) ) {
1137
- return "</br>" . $empty_email;
1138
- }
1139
-
1140
- //forget password entery
1141
- if ( in_array( 'invalidcombo', $error_codes ) ) {
1142
- return $invalidcombo;
1143
- }
1144
- }
1145
-
1146
- return $error;
1147
- }
1148
-
1149
- /**
1150
- * Change Lost Password Text from Form
1151
- *
1152
- * @param $text
1153
- * @since 1.0.0
1154
- * @return mixed
1155
- * * * * * * * * * * * * * * * * * * */
1156
- public function change_lostpassword_message ( $text ) {
1157
- $savedText = '';
1158
- if ( $this->loginpress_key && array_key_exists( 'login_footer_text', $this->loginpress_key ) ) {
1159
-
1160
- $savedText = $this->loginpress_key['login_footer_text'];
1161
- }
1162
-
1163
- if ( $text == 'Lost your password?' || $text == $savedText ) {
1164
-
1165
- if ( $this->loginpress_key && array_key_exists( 'login_footer_text', $this->loginpress_key ) ) {
1166
-
1167
- $text = $savedText; //$this->loginpress_key['login_footer_text'];
1168
- }
1169
-
1170
- }
1171
-
1172
- return $text;
1173
-
1174
- }
1175
-
1176
- /**
1177
- * Manage Welcome Messages
1178
- *
1179
- * @param $message
1180
- * @since 1.0.0
1181
- * @return string
1182
- * * * * * * * * * * * * */
1183
- public function change_welcome_message ($message) {
1184
- if ( $this->loginpress_key ) {
1185
-
1186
- //Check, User Logedout.
1187
- if ( isset($_GET['loggedout']) && TRUE == $_GET['loggedout'] ) {
1188
-
1189
- if ( array_key_exists( 'logout_message', $this->loginpress_key ) ) {
1190
-
1191
- $message = $this->loginpress_key['logout_message'];
1192
- }
1193
- }
1194
-
1195
- //Logged In messages.
1196
- else if ( strpos( $message,"Please enter your username or email address. You will receive a link to create a new password via email." ) == true ) {
1197
-
1198
- if ( array_key_exists( 'lostpwd_welcome_message', $this->loginpress_key ) ) {
1199
-
1200
- $message = $this->loginpress_key['lostpwd_welcome_message'];
1201
- }
1202
- }
1203
-
1204
- else if( strpos( $message,"Register For This Site" ) == true ) {
1205
-
1206
- if ( array_key_exists( 'register_welcome_message', $this->loginpress_key ) ) {
1207
-
1208
- $message = $this->loginpress_key['register_welcome_message'];
1209
- }
1210
- }
1211
-
1212
- else {
1213
- if ( array_key_exists( 'welcome_message', $this->loginpress_key ) ) {
1214
-
1215
- $message = $this->loginpress_key['welcome_message'];
1216
- }
1217
- }
1218
-
1219
- return !empty($message) ? "<p class='custom-message'>" . $message. "</p>" : '';
1220
- }
1221
- }
1222
-
1223
- /**
1224
- * Hook to Redirect Page for Customize
1225
- *
1226
- * @since 1.0.0
1227
- * * * * * * * * * * * * * * * * * * */
1228
- public function redirect_to_custom_page() {
1229
- if (!empty($_GET['page'])) {
1230
- if(($_GET['page']== "abw")){
1231
- wp_redirect(get_admin_url()."customize.php?url=".wp_login_url());
1232
- }
1233
- }
1234
- }
1235
-
1236
- /**
1237
- * Redirect to the Admin Panel After Closing LoginPress Customizer
1238
- *
1239
- * @since 1.0.0
1240
- * @return null
1241
- * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
1242
- public function menu_url() {
1243
-
1244
- global $submenu;
1245
-
1246
- $parent = 'index.php';
1247
- $page = 'abw';
1248
-
1249
- // Create specific url for login view
1250
- $login_url = wp_login_url();
1251
- $url = add_query_arg(
1252
- array(
1253
- 'url' => urlencode( $login_url ),
1254
- 'return' => admin_url( 'themes.php' ),
1255
- ),
1256
- admin_url( 'customize.php' )
1257
- );
1258
-
1259
- // If is Not Design Menu, return
1260
- if ( ! isset( $submenu[ $parent ] ) ) {
1261
- return NULL;
1262
- }
1263
-
1264
- foreach ( $submenu[ $parent ] as $key => $value ) {
1265
- // Set new URL for menu item
1266
- if ( $page === $value[ 2 ] ) {
1267
- $submenu[ $parent ][ $key ][ 2 ] = $url;
1268
- break;
1269
- }
1270
- }
1271
- }
1272
- }
1273
-
1274
- ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class LoginPress_Entities {
4
+
5
+ /**
6
+ * Variable that Check for LoginPress Key.
7
+ *
8
+ * @var string
9
+ * @since 1.0.0
10
+ */
11
+ public $loginpress_key;
12
+
13
+ /**
14
+ * Class constructor
15
+ */
16
+ public function __construct() {
17
+
18
+ $this->loginpress_key = get_option( 'loginpress_customization' );
19
+ $this->_hooks();
20
+ }
21
+
22
+
23
+ /**
24
+ * Hook into actions and filters
25
+ *
26
+ * @since 1.0.0
27
+ */
28
+ private function _hooks() {
29
+
30
+ add_filter( 'login_headerurl', array( $this, 'login_page_logo_url' ) );
31
+ add_filter( 'login_headertitle', array( $this, 'login_page_logo_title' ) );
32
+ add_filter( 'login_errors', array( $this, 'login_error_messages' ) );
33
+ add_filter( 'gettext', array( $this, 'change_lostpassword_message' ) );
34
+ add_filter( 'login_message', array( $this, 'change_welcome_message' ) );
35
+ add_action( 'customize_register', array( $this, 'customize_login_panel' ) );
36
+ add_action( 'login_footer', array( $this, 'login_page_custom_footer' ) );
37
+ add_action( 'login_head', array( $this, 'login_page_custom_head' ) );
38
+ add_action( 'init', array( $this, 'redirect_to_custom_page' ) );
39
+ add_action( 'admin_menu', array( $this, 'menu_url' ), 99 );
40
+
41
+ add_action( 'customize_controls_enqueue_scripts', array( $this, 'loginpress_customizer_js' ) );
42
+ add_action( 'customize_preview_init', array( $this, 'loginpress_customizer_js' ) );
43
+
44
+
45
+ }
46
+
47
+ function loginpress_customizer_js() {
48
+ wp_enqueue_script('jquery');
49
+ wp_enqueue_script( 'wpt_theme_customizer', plugins_url( 'js/customize-controls.js' , __FILE__ ), array( 'jquery', 'customize-preview' ), '', true );
50
+
51
+ $admin_url = array( 'template_url' => admin_url() );
52
+ wp_localize_script( 'wpt_theme_customizer', 'admin_url', $admin_url );
53
+ }
54
+
55
+
56
+
57
+ /**
58
+ * Register plugin settings Panel in WP Customizer
59
+ *
60
+ * @param $wp_customize
61
+ * @since 1.0.0
62
+ */
63
+ public function customize_login_panel( $wp_customize ){
64
+
65
+ include dirname( __FILE__ ) .'/classes/control-presets.php';
66
+
67
+ // =============================
68
+ // = Panel for the LoginPress =
69
+ // =============================
70
+ $wp_customize->add_panel( 'loginpress_panel', array(
71
+ 'title' => __( 'LoginPress', 'loginpress' ),
72
+ 'description' => __( 'Customize Your WordPress Login Page with LoginPress :)', 'loginpress' ),
73
+ 'priority' => 30,
74
+ ) );
75
+
76
+
77
+ // Start of Presets.
78
+ // $wp_customize->add_section( 'customize_presets', array(
79
+ // 'title' => __( 'Themes', 'loginpress' ),
80
+ // 'description' => __( 'Choose Theme', 'loginpress' ),
81
+ // 'priority' => 1,
82
+ // 'panel' => 'loginpress_panel',
83
+ // ) );
84
+ //
85
+ // $wp_customize->add_setting( 'customize_presets_settings', array(
86
+ // 'default' => 'default1',
87
+ // 'type' => 'option',
88
+ // 'capability' => 'manage_options',
89
+ // ) );
90
+ //
91
+ // $loginpress_free_templates = array(
92
+ // 'default1' => array(
93
+ // 'img' => plugins_url( 'img/bg.jpg', __FILE__ ),
94
+ // 'thumbnail' => plugins_url( 'img/thumbnail/default-1.png', __FILE__ ),
95
+ // 'id' => 'default1',
96
+ // 'name' => 'Default 1'
97
+ // ),
98
+ // 'default2' => array(
99
+ // 'img' => plugins_url( 'img/bg2.jpg', __FILE__ ),
100
+ // 'thumbnail' => plugins_url( 'img/thumbnail/default-2.png', __FILE__ ),
101
+ // 'id' => 'default2',
102
+ // 'name' => 'Default 2'
103
+ // ),
104
+ // // 'default3' => array(
105
+ // // 'thumbnail' => plugins_url( 'img/thumbnail/default-3.png', __FILE__ ),
106
+ // // 'id' => 'default3',
107
+ // // 'name' => 'Default 3',
108
+ // // 'pro' => 'yes'
109
+ // // )
110
+ // );
111
+ // $loginpress_templates = apply_filters( 'loginpress_pro_add_template', $loginpress_free_templates );
112
+ //
113
+ // $wp_customize->add_control( new LoginPress_Presets( $wp_customize, 'customize_presets_settings',
114
+ // array(
115
+ // 'section' => 'customize_presets',
116
+ // // 'label' => __( 'Themes', 'loginpress' ),
117
+ // 'choices' => $loginpress_templates
118
+ // )
119
+ // )
120
+ // );
121
+ //End of Presets.
122
+
123
+
124
+ // =============================
125
+ // = Section for Login Logo =
126
+ // =============================
127
+ $wp_customize->add_section(
128
+ 'customize_logo_section',
129
+ array(
130
+ 'title' => __( 'Logo', 'loginpress' ),
131
+ 'description' => __( 'Customize Your Logo Section', 'loginpress' ),
132
+ 'priority' => 5,
133
+ 'panel' => 'loginpress_panel',
134
+ ));
135
+
136
+ $wp_customize->add_setting(
137
+ 'loginpress_customization[setting_logo]',
138
+ array(
139
+ 'type' => 'option',
140
+ 'capability' => 'manage_options',
141
+ 'transport' => 'postMessage'
142
+ ));
143
+
144
+ $wp_customize->add_control(
145
+ new WP_Customize_Image_Control(
146
+ $wp_customize,
147
+ 'setting_logo',
148
+ array(
149
+ 'label' => __( 'Logo Image:', 'loginpress' ),
150
+ 'section' => 'customize_logo_section',
151
+ 'priority' => 5,
152
+ 'settings' => 'loginpress_customization[setting_logo]'
153
+ )));
154
+
155
+ $logo_control = array( 'customize_logo_width', 'customize_logo_height', 'customize_logo_padding', 'customize_logo_hover', 'customize_logo_hover_title' );
156
+ $logo_default = array( '84px', '84px', '5px', '', '' );
157
+ $logo_label = array(
158
+ __( 'Logo Width:', 'loginpress' ),
159
+ __( 'Logo Height:', 'loginpress' ),
160
+ __( 'Padding Bottom:', 'loginpress' ),
161
+ __( 'Logo URL:', 'loginpress' ),
162
+ __( 'Logo Hover Title:', 'loginpress' )
163
+ );
164
+
165
+ $logo = 0;
166
+ while ( $logo < 5 ) :
167
+
168
+ $wp_customize->add_setting( "loginpress_customization[{$logo_control[$logo]}]", array(
169
+ 'default' => $logo_default[$logo],
170
+ 'type' => 'option',
171
+ 'capability' => 'manage_options',
172
+ 'transport' => 'postMessage'
173
+ ));
174
+
175
+ $wp_customize->add_control( $logo_control[$logo], array(
176
+ 'label' => $logo_label[$logo],
177
+ 'section' => 'customize_logo_section',
178
+ 'priority' => 10,
179
+ 'settings' => "loginpress_customization[{$logo_control[$logo]}]"
180
+ ));
181
+
182
+ $logo++;
183
+ endwhile;
184
+
185
+ // =============================
186
+ // = Section for Background =
187
+ // =============================
188
+ $wp_customize->add_section(
189
+ 'section_background',
190
+ array(
191
+ 'title' => __( 'Background', 'loginpress' ),
192
+ 'description' => '',
193
+ 'priority' => 10,
194
+ 'panel' => 'loginpress_panel',
195
+ ));
196
+
197
+ $wp_customize->add_setting(
198
+ 'loginpress_customization[setting_background]',
199
+ array(
200
+ // 'default' => plugins_url( 'img/bg.jpg', __FILE__ ) ,
201
+ 'type' => 'option',
202
+ 'capability' => 'manage_options',
203
+ 'transport' => 'postMessage'
204
+ ));
205
+
206
+ $wp_customize->add_control(
207
+ new WP_Customize_Image_Control(
208
+ $wp_customize,
209
+ 'setting_background',
210
+ array(
211
+ 'label' => __( 'Background Image:', 'loginpress' ),
212
+ 'section' => 'section_background',
213
+ 'priority' => 5,
214
+ 'settings' => 'loginpress_customization[setting_background]',
215
+ )));
216
+
217
+ $wp_customize->add_setting( 'loginpress_customization[setting_background_color]', array(
218
+ 'default' => '#ddd5c3',
219
+ 'type' => 'option',
220
+ 'capability' => 'manage_options',
221
+ 'transport' => 'postMessage'
222
+
223
+ ));
224
+
225
+ $wp_customize->add_control(
226
+ new WP_Customize_Color_Control(
227
+ $wp_customize,
228
+ 'setting_background_color',
229
+ array(
230
+ 'label' => __( 'Background Color:', 'loginpress' ),
231
+ 'section' => 'section_background',
232
+ 'priority' => 15,
233
+ 'settings' => 'loginpress_customization[setting_background_color]'
234
+ )));
235
+
236
+ $wp_customize->add_setting( 'loginpress_customization[background_repeat_radio]', array(
237
+ 'default' => 'no-repeat',
238
+ 'type' => 'option',
239
+ 'capability' => 'manage_options',
240
+ 'transport' => 'postMessage'
241
+ ));
242
+
243
+ $wp_customize->add_control( 'background_repeat_radio', array(
244
+ 'label' => __( 'Background Repeat:', 'loginpress' ),
245
+ 'section' => 'section_background',
246
+ 'priority' => 20,
247
+ 'settings' => 'loginpress_customization[background_repeat_radio]',
248
+ 'type' => 'radio',
249
+ 'choices' => array(
250
+ 'repeat' => 'repeat',
251
+ 'repeat-x' => 'repeat-x',
252
+ 'repeat-y' => 'repeat-y',
253
+ 'no-repeat' => 'no-repeat',
254
+ 'initial' => 'initial',
255
+ 'inherit' => 'inherit',
256
+ ),
257
+ ));
258
+
259
+ $wp_customize->add_setting( 'loginpress_customization[background_position]', array(
260
+ 'default' => 'center',
261
+ 'type' => 'option',
262
+ 'capability' => 'manage_options',
263
+ 'transport' => 'postMessage'
264
+
265
+ ));
266
+ $wp_customize->add_control( 'background_position', array(
267
+ 'settings' => 'loginpress_customization[background_position]',
268
+ 'label' => __( 'Select Position:', 'loginpress' ),
269
+ 'section' => 'section_background',
270
+ 'priority' => 25,
271
+ 'type' => 'select',
272
+ 'choices' => array(
273
+ 'left top' => 'left top',
274
+ 'left center' => 'left center',
275
+ 'left bottom' => 'left bottom',
276
+ 'right top' => 'right top',
277
+ 'right center' => 'right center',
278
+ 'right bottom' => 'right bottom',
279
+ 'center top' => 'center top',
280
+ 'center' => 'center',
281
+ 'center bottom' => 'center bottom',
282
+ ),
283
+ ));
284
+
285
+ $wp_customize->add_setting( 'loginpress_customization[background_image_size]', array(
286
+ 'default' => 'cover',
287
+ 'type' => 'option',
288
+ 'capability' => 'manage_options',
289
+ 'transport' => 'postMessage'
290
+ ));
291
+
292
+ $wp_customize->add_control( 'background_image_size', array(
293
+ 'label' => __( 'Background Image Size: ', 'loginpress' ),
294
+ 'section' => 'section_background',
295
+ 'priority' => 30,
296
+ 'settings' => 'loginpress_customization[background_image_size]',
297
+ 'type' => 'select',
298
+ 'choices' => array(
299
+ 'auto' => 'auto',
300
+ 'cover' => 'cover',
301
+ 'contain' => 'contain',
302
+ 'initial' => 'initial',
303
+ 'inherit' => 'inherit',
304
+ ),
305
+ ));
306
+
307
+ // =============================
308
+ // = Section for Form Beauty =
309
+ // =============================
310
+ $wp_customize->add_section(
311
+ 'section_form',
312
+ array(
313
+ 'title' => __( 'Customize Login Form', 'loginpress' ),
314
+ 'description' => '',
315
+ 'priority' => 15,
316
+ 'panel' => 'loginpress_panel',
317
+ ));
318
+
319
+ $wp_customize->add_setting( 'loginpress_customization[setting_form_background]', array(
320
+ 'type' => 'option',
321
+ 'capability' => 'manage_options',
322
+ 'transport' => 'postMessage'
323
+ ));
324
+
325
+ $wp_customize->add_control(
326
+ new WP_Customize_Image_Control(
327
+ $wp_customize,
328
+ 'setting_form_background',
329
+ array(
330
+ 'label' => __( 'Form Background Image', 'loginpress' ),
331
+ 'section' => 'section_form',
332
+ 'priority' => 5,
333
+ 'settings' => 'loginpress_customization[setting_form_background]'
334
+ )));
335
+
336
+ $form_control = array( 'customize_form_width', 'customize_form_height', 'customize_form_padding', 'customize_form_border', 'textfield_width', 'textfield_margin' );
337
+ $form_default = array( '350px', '200px', '26px 24px 46px', '', '100%', '2px 6px 16px 0px' );
338
+ $form_label = array(
339
+ __( 'Form Width:', 'loginpress' ),
340
+ __( 'Form Minimum Height:', 'loginpress' ),
341
+ __( 'Form Padding:', 'loginpress' ),
342
+ __( 'Border (Example: 2px dotted black):', 'loginpress' ),
343
+ __( 'Input Text Field Width:', 'loginpress' ),
344
+ __( 'Input Text Field Margin:', 'loginpress' )
345
+ );
346
+
347
+ $form = 0;
348
+ while ( $form < 6 ) :
349
+
350
+ $wp_customize->add_setting( "loginpress_customization[{$form_control[$form]}]", array(
351
+ 'default' => $form_default[$form],
352
+ 'type' => 'option',
353
+ 'capability' => 'manage_options',
354
+ 'transport' => 'postMessage'
355
+ ));
356
+
357
+ $wp_customize->add_control( $form_control[$form], array(
358
+ 'label' => $form_label[$form],
359
+ 'section' => 'section_form',
360
+ // 'priority' => 15,
361
+ 'settings' => "loginpress_customization[{$form_control[$form]}]"
362
+ ));
363
+
364
+ $form++;
365
+ endwhile;
366
+
367
+ $form_color_control = array( 'form_background_color', 'textfield_background_color', 'textfield_color', 'textfield_label_color' );
368
+ $form_color_default = array( '#FFF', '#FFF', '#333', '#777' );
369
+ $form_color_label = array(
370
+ __( 'Form Background Color:', 'loginpress' ),
371
+ __( 'Input Field Background Color:', 'loginpress' ),
372
+ __( 'Input Field Text Color:', 'loginpress' ),
373
+ __( 'Label Color:', 'loginpress' ),
374
+ );
375
+
376
+ $form_color = 0;
377
+ while ( $form_color < 4 ) :
378
+
379
+ $wp_customize->add_setting( "loginpress_customization[{$form_color_control[$form_color]}]", array(
380
+ // 'default' => $form_color_default[$form_color],
381
+ 'type' => 'option',
382
+ 'capability' => 'manage_options',
383
+ 'transport' => 'postMessage'
384
+ ));
385
+
386
+ $wp_customize->add_control(
387
+ new WP_Customize_Color_Control(
388
+ $wp_customize,
389
+ $form_color_control[$form_color],
390
+ array(
391
+ 'label' => $form_color_label[$form_color],
392
+ 'section' => 'section_form',
393
+ // 'priority' => 50,
394
+ 'settings' => "loginpress_customization[{$form_color_control[$form_color]}]"
395
+ ) ) );
396
+
397
+ $form_color++;
398
+ endwhile;
399
+
400
+ // =============================
401
+ // = Section for Forget Form =
402
+ // =============================
403
+ $wp_customize->add_section(
404
+ 'section_forget_form',
405
+ array(
406
+ 'title' => __( 'Customize Forget Form', 'loginpress' ),
407
+ 'description' => '',
408
+ 'priority' => 20,
409
+ 'panel' => 'loginpress_panel',
410
+ ));
411
+
412
+ $wp_customize->add_setting( 'loginpress_customization[forget_form_background]', array(
413
+ 'type' => 'option',
414
+ 'capability' => 'manage_options',
415
+ 'transport' => 'postMessage'
416
+ ));
417
+
418
+ $wp_customize->add_control(
419
+ new WP_Customize_Image_Control(
420
+ $wp_customize,
421
+ 'forget_form_background',
422
+ array(
423
+ 'label' => __( 'Forget Form Background Image', 'loginpress' ),
424
+ 'section' => 'section_forget_form',
425
+ 'priority' => 5,
426
+ 'settings' => 'loginpress_customization[forget_form_background]'
427
+ )));
428
+
429
+ $wp_customize->add_setting( 'loginpress_customization[forget_form_background_color]', array(
430
+ // 'default' => '#FFF',
431
+ 'type' => 'option',
432
+ 'capability' => 'manage_options',
433
+ 'transport' => 'postMessage'
434
+ ));
435
+
436
+ $wp_customize->add_control(
437
+ new WP_Customize_Color_Control(
438
+ $wp_customize,
439
+ 'forget_form_background_color',
440
+ array(
441
+ 'label' => __( 'Forget Form Background Color', 'loginpress' ),
442
+ 'section' => 'section_forget_form',
443
+ 'priority' => 10,
444
+ 'settings' => 'loginpress_customization[forget_form_background_color]'
445
+ )));
446
+
447
+ // =============================
448
+ // = Section for Button Style =
449
+ // =============================
450
+ $wp_customize->add_section(
451
+ 'section_button',
452
+ array(
453
+ 'title' => __( 'Button Beauty', 'loginpress' ),
454
+ 'description' => '',
455
+ 'priority' => 25,
456
+ 'panel' => 'loginpress_panel',
457
+ ));
458
+
459
+ $button_control = array( 'custom_button_color', 'button_border_color', 'button_hover_color', 'button_hover_border', 'custom_button_shadow', 'button_text_color' );
460
+ $button_default = array( '#2EA2CC', '#0074A2', '#1E8CBE', '#0074A2', '#78C8E6', '#FFF' );
461
+ $button_label = array(
462
+ __( 'Button Color:', 'loginpress' ),
463
+ __( 'Button Border Color:', 'loginpress' ),
464
+ __( 'Button Color (Hover):', 'loginpress' ),
465
+ __( 'Button Border (Hover):', 'loginpress' ),
466
+ __( 'Button Box Shadow:', 'loginpress' ),
467
+ __( 'Button Text Color:', 'loginpress' )
468
+ );
469
+
470
+ $button = 0;
471
+ while ( $button < 6 ) :
472
+
473
+ $wp_customize->add_setting( "loginpress_customization[{$button_control[$button]}]", array(
474
+ // 'default' => $button_default[$button],
475
+ 'type' => 'option',
476
+ 'capability' => 'manage_options',
477
+ 'transport' => 'postMessage'
478
+ ));
479
+
480
+ $wp_customize->add_control(
481
+ new WP_Customize_Color_Control(
482
+ $wp_customize,
483
+ $button_control[$button],
484
+ array(
485
+ 'label' => $button_label[$button],
486
+ 'section' => 'section_button',
487
+ 'priority' => 5,
488
+ 'settings' => "loginpress_customization[{$button_control[$button]}]"
489
+ ) ) );
490
+
491
+ $button++;
492
+ endwhile;
493
+
494
+ // =============================
495
+ // = Section for Error message =
496
+ // =============================
497
+ $wp_customize->add_section(
498
+ 'section_error',
499
+ array(
500
+ 'title' => __( 'Error Messages', 'loginpress' ),
501
+ 'description' => '',
502
+ 'priority' => 30,
503
+ 'panel' => 'loginpress_panel',
504
+ ));
505
+
506
+ $error_control = array( 'incorrect_username', 'incorrect_password', 'empty_username', 'empty_password', 'invalid_email', 'empty_email', 'invalidcombo_message' );
507
+ $error_default = array( 'Incorrect Username', 'Incorrect Password', 'Empty Username', 'Empty Password', 'The email address is incorrect.', 'The email address is empty.', 'Invalid Username or Email.' );
508
+ $error_label = array(
509
+ __( 'Incorrect Username Message:', 'loginpress' ),
510
+ __( 'Incorrect Password Message:', 'loginpress' ),
511
+ __( 'Empty Username Message:', 'loginpress' ),
512
+ __( 'Empty Password Message:', 'loginpress' ),
513
+ __( 'Invalid Email Message:', 'loginpress' ),
514
+ __( 'Empty Email Message:', 'loginpress' ),
515
+ __( 'Forget Password Message:', 'loginpress' ),
516
+ );
517
+
518
+ $error = 0;
519
+ while ( $error < 7 ) :
520
+
521
+ $wp_customize->add_setting( "loginpress_customization[{$error_control[$error]}]", array(
522
+ 'default' => $error_default[$error],
523
+ 'type' => 'option',
524
+ 'capability' => 'manage_options',
525
+ 'transport' => 'postMessage'
526
+ ));
527
+
528
+ $wp_customize->add_control( $error_control[$error], array(
529
+ 'label' => $error_label[$error],
530
+ 'section' => 'section_error',
531
+ 'priority' => 5,
532
+ 'settings' => "loginpress_customization[{$error_control[$error]}]",
533
+ ));
534
+
535
+ $error++;
536
+ endwhile;
537
+
538
+ // =============================
539
+ // = Section for Welcome message
540
+ // =============================
541
+ $wp_customize->add_section(
542
+ 'section_welcome',
543
+ array(
544
+ 'title' => __( 'Welcome Messages', 'loginpress' ),
545
+ 'description' => '',
546
+ 'priority' => 35,
547
+ 'panel' => 'loginpress_panel',
548
+ ));
549
+
550
+ $welcome_control = array( 'lostpwd_welcome_message', 'welcome_message', 'register_welcome_message', 'logout_message', 'message_background_border' );
551
+ $welcome_default = array( 'Forget ?', 'Welcome', 'Register yourself', 'Logout', '' );
552
+ $welcome_label = array(
553
+ __( 'Welcome Message on Lost Password:', 'loginpress' ),
554
+ __( 'Welcome Message on Front Page:', 'loginpress' ),
555
+ __( 'Welcome Message on Registration:', 'loginpress' ),
556
+ __( 'Logout Message:', 'loginpress' ),
557
+ __( 'Message Field Border: ( Example: 1px solid #00a0d2; )', 'loginpress' ),
558
+ );
559
+
560
+ $welcome = 0;
561
+ while ( $welcome < 5 ) :
562
+
563
+ $wp_customize->add_setting( "loginpress_customization[{$welcome_control[ $welcome ]}]", array(
564
+ 'default' => $welcome_default[ $welcome ],
565
+ 'type' => 'option',
566
+ 'capability' => 'manage_options',
567
+ 'transport' => 'postMessage'
568
+ ));
569
+
570
+ $wp_customize->add_control( $welcome_control[ $welcome ], array(
571
+ 'label' => $welcome_label[ $welcome ],
572
+ 'section' => 'section_welcome',
573
+ 'priority' => 5,
574
+ 'settings' => "loginpress_customization[{$welcome_control[ $welcome ]}]",
575
+ ));
576
+
577
+ $welcome++;
578
+ endwhile;
579
+
580
+ $wp_customize->add_setting( 'loginpress_customization[message_background_color]', array(
581
+ // 'default' => '#fff',
582
+ 'type' => 'option',
583
+ 'capability' => 'manage_options',
584
+ 'transport' => 'postMessage'
585
+ ));
586
+
587
+ $wp_customize->add_control(
588
+ new WP_Customize_Color_Control(
589
+ $wp_customize,
590
+ 'message_background_color',
591
+ array(
592
+ 'label' => __( 'Message Field Background Color:', 'loginpress' ),
593
+ 'section' => 'section_welcome',
594
+ 'priority' => 30,
595
+ 'settings' => 'loginpress_customization[message_background_color]'
596
+ )));
597
+
598
+ // =============================
599
+ // = Section for Header message
600
+ // =============================
601
+ // $wp_customize->add_section(
602
+ // 'section_head',
603
+ // array(
604
+ // 'title' => __( 'Header Message', 'loginpress' ),
605
+ // 'description' => '',
606
+ // 'priority' => 35,
607
+ // 'panel' => 'loginpress_panel',
608
+ // ));
609
+ //
610
+ // $wp_customize->add_setting( 'loginpress_customization[login_hearder_message]', array(
611
+ // 'default' => 'Latest NEWS',
612
+ // 'type' => 'option',
613
+ // 'capability' => 'edit_theme_options',
614
+ // ));
615
+ //
616
+ // $wp_customize->add_control( 'login_hearder_message', array(
617
+ // 'label' => __( 'Header Message:', 'loginpress' ),
618
+ // 'section' => 'section_head',
619
+ // 'priority' => 5,
620
+ // 'settings' => 'loginpress_customization[login_hearder_message]',
621
+ // ));
622
+ //
623
+ // $wp_customize->add_setting( 'loginpress_customization[login_hearder_message_link]', array(
624
+ // 'default' => '#',
625
+ // 'type' => 'option',
626
+ // 'capability' => 'edit_theme_options',
627
+ // ));
628
+ //
629
+ // $wp_customize->add_control( 'login_hearder_message_link', array(
630
+ // 'label' => __( 'Header Message Link:', 'loginpress' ),
631
+ // 'section' => 'section_head',
632
+ // 'priority' => 5,
633
+ // 'settings' => 'loginpress_customization[login_hearder_message_link]',
634
+ // ));
635
+ //
636
+ // $wp_customize->add_setting( 'loginpress_customization[login_head_color]', array(
637
+ // 'default' => '#17a8e3',
638
+ // 'type' => 'option',
639
+ // 'capability' => 'edit_theme_options',
640
+ // ));
641
+ //
642
+ // $wp_customize->add_control(
643
+ // new WP_Customize_Color_Control(
644
+ // $wp_customize,
645
+ // 'login_head_color',
646
+ // array(
647
+ // 'label' => __( 'Header Text Color:', 'loginpress' ),
648
+ // 'section' => 'section_head',
649
+ // 'priority' => 10,
650
+ // 'settings' => 'loginpress_customization[login_head_color]'
651
+ // )));
652
+ //
653
+ // $wp_customize->add_setting( 'loginpress_customization[login_head_color_hover]', array(
654
+ // // 'default' => '#17a8e3',
655
+ // 'type' => 'option',
656
+ // 'capability' => 'edit_theme_options',
657
+ // ));
658
+ //
659
+ // $wp_customize->add_control(
660
+ // new WP_Customize_Color_Control(
661
+ // $wp_customize,
662
+ // 'login_head_color_hover',
663
+ // array(
664
+ // 'label' => __( 'Header Text Hover Color:', 'loginpress' ),
665
+ // 'section' => 'section_head',
666
+ // 'priority' => 15,
667
+ // 'settings' => 'loginpress_customization[login_head_color_hover]'
668
+ // )));
669
+ //
670
+ // $wp_customize->add_setting( 'loginpress_customization[login_head_font_size]', array(
671
+ // 'default' => '13px;',
672
+ // 'type' => 'option',
673
+ // 'capability' => 'edit_theme_options',
674
+ // ));
675
+ //
676
+ // $wp_customize->add_control( 'login_head_font_size', array(
677
+ // 'label' => __( 'Text Font Size:', 'loginpress' ),
678
+ // 'section' => 'section_head',
679
+ // 'priority' => 20,
680
+ // 'settings' => 'loginpress_customization[login_head_font_size]',
681
+ // ));
682
+ //
683
+ // $wp_customize->add_setting( 'loginpress_customization[login_head_bg_color]', array(
684
+ // // 'default' => '#17a8e3',
685
+ // 'type' => 'option',
686
+ // 'capability' => 'edit_theme_options',
687
+ // ));
688
+ //
689
+ // $wp_customize->add_control(
690
+ // new WP_Customize_Color_Control(
691
+ // $wp_customize,
692
+ // 'login_head_bg_color',
693
+ // array(
694
+ // 'label' => __( 'Header Background Color:', 'loginpress' ),
695
+ // 'section' => 'section_head',
696
+ // 'priority' => 25,
697
+ // 'settings' => 'loginpress_customization[login_head_bg_color]'
698
+ // )));
699
+
700
+ // =============================
701
+ // = Custom Header Login menu =
702
+ // =============================
703
+ // $menuVals = array();
704
+ // $menus = get_registered_nav_menus();
705
+ //
706
+ // foreach ( $menus as $location => $name ) {
707
+ // $menuVals[$location] = $name ;
708
+ // }
709
+ // $wp_customize->add_section(
710
+ // 'customize_menu_section',
711
+ // array(
712
+ // 'title' => __( 'Login Page Menus', 'loginpress' ),
713
+ // 'description' => '',
714
+ // 'priority' => 32,
715
+ // 'panel' => 'loginpress_panel',
716
+ // ));
717
+ //
718
+ // $wp_customize->add_setting('loginpress_customization[header_login_menu]', array(
719
+ // 'capability' => 'edit_theme_options',
720
+ // 'type' => 'option',
721
+ // ));
722
+ //
723
+ // $wp_customize->add_control('header_login_menu', array(
724
+ // 'settings' => 'loginpress_customization[header_login_menu]',
725
+ // 'label' => __( 'Display Header Menu?', 'loginpress'),
726
+ // 'section' => 'customize_menu_section',
727
+ // 'priority' => 5,
728
+ // 'type' => 'checkbox',
729
+ // ));
730
+ //
731
+ // $wp_customize->add_setting('loginpress_customization[customize_login_menu]', array(
732
+ // 'capability' => 'edit_theme_options',
733
+ // 'type' => 'option',
734
+ //
735
+ // ));
736
+ // $wp_customize->add_control( 'customize_login_menu', array(
737
+ // 'settings' => 'loginpress_customization[customize_login_menu]',
738
+ // 'label' => __( 'Select Menu for Header:', 'loginpress' ),
739
+ // 'section' => 'customize_menu_section',
740
+ // 'type' => 'select',
741
+ // 'priority' => 10,
742
+ // 'choices' => $menuVals,
743
+ // ));
744
+ //
745
+ // $wp_customize->add_setting('loginpress_customization[footer_login_menu]', array(
746
+ // 'capability' => 'edit_theme_options',
747
+ // 'type' => 'option',
748
+ // ));
749
+ //
750
+ // $wp_customize->add_control('footer_login_menu', array(
751
+ // 'settings' => 'loginpress_customization[footer_login_menu]',
752
+ // 'label' => __( 'Display Footer Menu?', 'loginpress' ),
753
+ // 'section' => 'customize_menu_section',
754
+ // 'priority' => 15,
755
+ // 'type' => 'checkbox',
756
+ // ));
757
+ //
758
+ // $wp_customize->add_setting('loginpress_customization[customize_login_footer_menu]', array(
759
+ // 'capability' => 'edit_theme_options',
760
+ // 'type' => 'option',
761
+ //
762
+ // ));
763
+ // $wp_customize->add_control( 'customize_login_footer_menu', array(
764
+ // 'settings' => 'loginpress_customization[customize_login_footer_menu]',
765
+ // 'label' => __( 'Select Menu:', 'loginpress' ),
766
+ // 'section' => 'customize_menu_section',
767
+ // 'priority' => 20,
768
+ // 'type' => 'select',
769
+ // 'choices' => $menuVals,
770
+ // ));
771
+
772
+ // =============================
773
+ // = Section for Form Footer =
774
+ // =============================
775
+ $wp_customize->add_section(
776
+ 'section_fotter',
777
+ array(
778
+ 'title' => __( 'Form Footer', 'loginpress' ),
779
+ 'description' => '',
780
+ 'priority' => 40,
781
+ 'panel' => 'loginpress_panel',
782
+ ));
783
+
784
+ $wp_customize->add_setting( 'loginpress_customization[login_footer_text]', array(
785
+ 'default' => 'Lost your password?',
786
+ 'type' => 'option',
787
+ 'capability' => 'manage_options',
788
+ 'transport' => 'postMessage'
789
+ ));
790
+
791
+ $wp_customize->add_control( 'login_footer_text', array(
792
+ 'label' => __( 'Lost Password Text', 'loginpress' ),
793
+ 'section' => 'section_fotter',
794
+ 'priority' => 5,
795
+ 'settings' => 'loginpress_customization[login_footer_text]',
796
+ ));
797
+
798
+ $wp_customize->add_setting( 'loginpress_customization[footer_display_text]', array(
799
+ 'default' => 'block',
800
+ 'type' => 'option',
801
+ 'capability' => 'manage_options',
802
+ 'transport' => 'postMessage'
803
+ ));
804
+
805
+ $wp_customize->add_control( 'footer_display_text', array(
806
+ 'label' => __( 'Footer Text Display:', 'loginpress' ),
807
+ 'section' => 'section_fotter',
808
+ 'priority' => 10,
809
+ 'settings' => 'loginpress_customization[footer_display_text]',
810
+ 'type' => 'radio',
811
+ 'choices' => array(
812
+ 'block' => 'show',
813
+ 'none' => 'hide',
814
+ ),
815
+ ));
816
+
817
+ $wp_customize->add_setting( 'loginpress_customization[login_footer_text_decoration]', array(
818
+ 'default' => 'none',
819
+ 'type' => 'option',
820
+ 'capability' => 'manage_options',
821
+ 'transport' => 'postMessage'
822
+
823
+ ));
824
+ $wp_customize->add_control( 'login_footer_text_decoration', array(
825
+ 'settings' => 'loginpress_customization[login_footer_text_decoration]',
826
+ 'label' => 'Select Text Decoration:',
827
+ 'section' => 'section_fotter',
828
+ 'priority' => 15,
829
+ 'type' => 'select',
830
+ 'choices' => array(
831
+ 'none' => 'none',
832
+ 'overline' => 'overline',
833
+ 'line-through' => 'line-through',
834
+ 'underline' => 'underline',
835
+ ),
836
+ ));
837
+
838
+ $wp_customize->add_setting( 'loginpress_customization[login_footer_color]', array(
839
+ // 'default' => '#17a8e3',
840
+ 'type' => 'option',
841
+ 'capability' => 'manage_options',
842
+ 'transport' => 'postMessage'
843
+ ));
844
+
845
+ $wp_customize->add_control(
846
+ new WP_Customize_Color_Control(
847
+ $wp_customize,
848
+ 'login_footer_color',
849
+ array(
850
+ 'label' => __( 'Footer Text Color:', 'loginpress' ),
851
+ 'section' => 'section_fotter',
852
+ 'priority' => 20,
853
+ 'settings' => 'loginpress_customization[login_footer_color]'
854
+ )));
855
+
856
+ $wp_customize->add_setting( 'loginpress_customization[login_footer_color_hover]', array(
857
+ // 'default' => '#17a8e3',
858
+ 'type' => 'option',
859
+ 'capability' => 'manage_options',
860
+ 'transport' => 'postMessage'
861
+ ));
862
+
863
+ $wp_customize->add_control(
864
+ new WP_Customize_Color_Control(
865
+ $wp_customize,
866
+ 'login_footer_color_hover',
867
+ array(
868
+ 'label' => __( 'Footer Text Hover Color:', 'loginpress' ),
869
+ 'section' => 'section_fotter',
870
+ 'priority' => 25,
871
+ 'settings' => 'loginpress_customization[login_footer_color_hover]'
872
+ )));
873
+
874
+ $wp_customize->add_setting( 'loginpress_customization[login_footer_font_size]', array(
875
+ 'default' => '13px',
876
+ 'type' => 'option',
877
+ 'capability' => 'manage_options',
878
+ 'transport' => 'postMessage'
879
+ ));
880
+
881
+ $wp_customize->add_control( 'login_footer_font_size', array(
882
+ 'label' => __( 'Text Font Size:', 'loginpress' ),
883
+ 'section' => 'section_fotter',
884
+ 'priority' => 30,
885
+ 'settings' => 'loginpress_customization[login_footer_font_size]',
886
+ ));
887
+
888
+ $wp_customize->add_setting( 'loginpress_customization[login_footer_bg_color]', array(
889
+ // 'default' => '#17a8e3',
890
+ 'type' => 'option',
891
+ 'capability' => 'manage_options',
892
+ 'transport' => 'postMessage'
893
+ ));
894
+
895
+ $wp_customize->add_control(
896
+ new WP_Customize_Color_Control(
897
+ $wp_customize,
898
+ 'login_footer_bg_color',
899
+ array(
900
+ 'label' => __( 'Footer Background Color:', 'loginpress' ),
901
+ 'section' => 'section_fotter',
902
+ 'priority' => 35,
903
+ 'settings' => 'loginpress_customization[login_footer_bg_color]'
904
+ )));
905
+ // Fields for Back Link
906
+ // $wp_customize->add_setting( 'login_back_text', array(
907
+ // 'default' => 'Lost your password?',
908
+ // 'type' => 'option',
909
+ // 'capability' => 'edit_theme_options',
910
+ // ));
911
+
912
+ // $wp_customize->add_control( 'login_back_text', array(
913
+ // 'label' => __( 'Lost Password Text', 'loginpress' ),
914
+ // 'section' => 'section_fotter',
915
+ // 'priority' => 40,
916
+ // 'settings' => 'login_back_text',
917
+ // ));
918
+
919
+ $wp_customize->add_setting( 'loginpress_customization[back_display_text]', array(
920
+ 'default' => 'block',
921
+ 'type' => 'option',
922
+ 'capability' => 'manage_options',
923
+ 'transport' => 'postMessage'
924
+ ));
925
+
926
+ $wp_customize->add_control( 'back_display_text', array(
927
+ 'label' => __( '"Back to" Text Display:', 'loginpress' ),
928
+ 'section' => 'section_fotter',
929
+ 'priority' => 45,
930
+ 'settings' => 'loginpress_customization[back_display_text]',
931
+ 'type' => 'radio',
932
+ 'choices' => array(
933
+ 'block' => 'show',
934
+ 'none' => 'hide',
935
+ ),
936
+ ));
937
+
938
+ $wp_customize->add_setting( 'loginpress_customization[login_back_text_decoration]', array(
939
+ 'default' => 'none',
940
+ 'type' => 'option',
941
+ 'capability' => 'manage_options',
942
+ 'transport' => 'postMessage'
943
+
944
+ ));
945
+ $wp_customize->add_control( 'login_back_text_decoration', array(
946
+ 'settings' => 'loginpress_customization[login_back_text_decoration]',
947
+ 'label' => __( '"Back to" Text Decoration:', 'loginpress' ),
948
+ 'section' => 'section_fotter',
949
+ 'priority' => 50,
950
+ 'type' => 'select',
951
+ 'choices' => array(
952
+ 'none' => 'none',
953
+ 'overline' => 'overline',
954
+ 'line-through' => 'line-through',
955
+ 'underline' => 'underline',
956
+ ),
957
+ ));
958
+
959
+ $wp_customize->add_setting( 'loginpress_customization[login_back_color]', array(
960
+ // 'default' => '#17a8e3',
961
+ 'type' => 'option',
962
+ 'capability' => 'manage_options',
963
+ 'transport' => 'postMessage'
964
+ ));
965
+
966
+ $wp_customize->add_control(
967
+ new WP_Customize_Color_Control(
968
+ $wp_customize,
969
+ 'login_back_color',
970
+ array(
971
+ 'label' => __( '"Back to" Text Color:', 'loginpress' ),
972
+ 'section' => 'section_fotter',
973
+ 'priority' => 55,
974
+ 'settings' => 'loginpress_customization[login_back_color]'
975
+ )));
976
+
977
+ $wp_customize->add_setting( 'loginpress_customization[login_back_color_hover]', array(
978
+ // 'default' => '#17a8e3',
979
+ 'type' => 'option',
980
+ 'capability' => 'manage_options',
981
+ 'transport' => 'postMessage'
982
+ ));
983
+
984
+ $wp_customize->add_control(
985
+ new WP_Customize_Color_Control(
986
+ $wp_customize,
987
+ 'login_back_color_hover',
988
+ array(
989
+ 'label' => __( '"Back to" Text Hover Color:', 'loginpress' ),
990
+ 'section' => 'section_fotter',
991
+ 'priority' => 60,
992
+ 'settings' => 'loginpress_customization[login_back_color_hover]'
993
+ )));
994
+
995
+ $wp_customize->add_setting( 'loginpress_customization[login_back_font_size]', array(
996
+ 'default' => '13px;',
997
+ 'type' => 'option',
998
+ 'capability' => 'manage_options',
999
+ 'transport' => 'postMessage'
1000
+ ));
1001
+
1002
+ $wp_customize->add_control( 'login_back_font_size', array(
1003
+ 'label' => __( '"Back to" Text Font Size:', 'loginpress' ),
1004
+ 'section' => 'section_fotter',
1005
+ 'priority' => 65,
1006
+ 'settings' => 'loginpress_customization[login_back_font_size]',
1007
+ ));
1008
+
1009
+ $wp_customize->add_setting( 'loginpress_customization[login_back_bg_color]', array(
1010
+ // 'default' => '#17a8e3',
1011
+ 'type' => 'option',
1012
+ 'capability' => 'manage_options',
1013
+ 'transport' => 'postMessage'
1014
+ ));
1015
+
1016
+ $wp_customize->add_control(
1017
+ new WP_Customize_Color_Control(
1018
+ $wp_customize,
1019
+ 'login_back_bg_color',
1020
+ array(
1021
+ 'label' => __( 'Footer Background Color:', 'loginpress' ),
1022
+ 'section' => 'section_fotter',
1023
+ 'priority' => 70,
1024
+ 'settings' => 'loginpress_customization[login_back_bg_color]'
1025
+ )));
1026
+
1027
+ $wp_customize->add_setting( 'loginpress_customization[login_footer_copy_right]', array(
1028
+ 'default' => '© 2017 WPBrigade, All Rights Reserved.',
1029
+ 'type' => 'option',
1030
+ 'capability' => 'manage_options',
1031
+ 'transport' => 'postMessage'
1032
+ ));
1033
+
1034
+ $wp_customize->add_control( 'login_footer_copy_right', array(
1035
+ 'label' => __( 'Copyright Note:', 'loginpress' ),
1036
+ 'type' => 'textarea',
1037
+ 'section' => 'section_fotter',
1038
+ 'priority' => 75,
1039
+ 'settings' => 'loginpress_customization[login_footer_copy_right]'
1040
+ ));
1041
+
1042
+ // =============================
1043
+ // = Section for Custom CSS =
1044
+ // =============================
1045
+ $wp_customize->add_section(
1046
+ 'section_css',
1047
+ array(
1048
+ 'title' => __( 'Custom CSS', 'loginpress' ),
1049
+ 'description' => '',
1050
+ 'priority' => 50,
1051
+ 'panel' => 'loginpress_panel',
1052
+ ));
1053
+
1054
+ $wp_customize->add_setting( 'loginpress_customization[loginpress_custom_css]', array(
1055
+ 'type' => 'option',
1056
+ 'capability' => 'manage_options',
1057
+ 'transport' => 'postMessage'
1058
+ ));
1059
+
1060
+ $wp_customize->add_control( 'loginpress_custom_css', array(
1061
+ 'label' => __( 'Customize CSS', 'loginpress' ),
1062
+ 'type' => 'textarea',
1063
+ 'section' => 'section_css',
1064
+ 'priority' => 5,
1065
+ 'settings' => 'loginpress_customization[loginpress_custom_css]'
1066
+ ));
1067
+
1068
+ // =============================
1069
+ // = Section for Custom JS =
1070
+ // =============================
1071
+ $wp_customize->add_section(
1072
+ 'section_js',
1073
+ array(
1074
+ 'title' => __( 'Custom JS', 'loginpress' ),
1075
+ 'description' => '',
1076
+ 'priority' => 55,
1077
+ 'panel' => 'loginpress_panel',
1078
+ ));
1079
+
1080
+ $wp_customize->add_setting( 'loginpress_customization[loginpress_custom_js]', array(
1081
+ 'type' => 'option',
1082
+ 'capability' => 'manage_options',
1083
+ 'transport' => 'postMessage'
1084
+ ));
1085
+
1086
+ $wp_customize->add_control( 'loginpress_custom_js', array(
1087
+ 'label' => __( 'Customize JS', 'loginpress' ),
1088
+ 'type' => 'textarea',
1089
+ 'section' => 'section_js',
1090
+ 'priority' => 5,
1091
+ 'settings' => 'loginpress_customization[loginpress_custom_js]'
1092
+ ));
1093
+
1094
+
1095
+ // Resets Panel
1096
+ // $wp_customize->add_section( 'reset_loginpress', array(
1097
+ // 'title' => __( 'Reset All Settings', 'loginpress' ),
1098
+ // 'description' => '',
1099
+ // 'priority' => 60,
1100
+ // 'panel' => 'loginpress_panel',
1101
+ // ) );
1102
+ //
1103
+ // $wp_customize->add_setting( 'reset_loginpress', array(
1104
+ // 'type' => 'option',
1105
+ // 'capability' => 'manage_options',
1106
+ // ) );
1107
+ //
1108
+ // $wp_customize->add_control( 'reset_loginpress', array(
1109
+ // 'label' => __( 'Reset All Settings', 'loginpress' ),
1110
+ // 'type' => 'checkbox',
1111
+ // 'section' => 'reset_loginpress',
1112
+ // 'priority' => 5,
1113
+ // 'settings' => 'reset_loginpress'
1114
+ // ) );
1115
+ }
1116
+
1117
+ /**
1118
+ * Manage the Login Footer Links
1119
+ *
1120
+ * @since 1.0.0
1121
+ * * * * * * * * * * * * * * * */
1122
+ public function login_page_custom_footer() {
1123
+
1124
+ if ( $this->loginpress_key ) {
1125
+
1126
+ // echo '</div></div>';
1127
+ echo '<div class="footer-wrapper">';
1128
+ echo '<div class="footer-cont">';
1129
+
1130
+ // if ( array_key_exists( 'footer_login_menu', $this->loginpress_key ) && checked( $this->loginpress_key['footer_login_menu'], true, false ) ) {
1131
+ //
1132
+ // wp_nav_menu( array(
1133
+ // 'theme_location' => $this->loginpress_key['customize_login_footer_menu'],
1134
+ // 'container' => false,
1135
+ // 'menu_class' => 'loginFooterMenu',
1136
+ // 'echo' => true,
1137
+ // )
1138
+ // );
1139
+ //
1140
+ // }
1141
+
1142
+ if ( array_key_exists( 'login_footer_copy_right', $this->loginpress_key ) && !empty( $this->loginpress_key['login_footer_copy_right'] ) ) {
1143
+
1144
+ echo '<div class="copyRight">'.$this->loginpress_key['login_footer_copy_right'].'</div>';
1145
+ }
1146
+
1147
+ echo '</div></div>';
1148
+ }
1149
+ }
1150
+
1151
+ /**
1152
+ * Manage the Login Head
1153
+ *
1154
+ * @since 1.0.0
1155
+ * * * * * * * * * * * */
1156
+ public function login_page_custom_head() {
1157
+
1158
+ // Include CSS File in heared.
1159
+ include( plugin_dir_path( __FILE__ ) . 'css/style-presets.php' );
1160
+ include( plugin_dir_path( __FILE__ ) . 'css/style-login.php' );
1161
+
1162
+
1163
+ if ( $this->loginpress_key && array_key_exists( 'header_login_menu', $this->loginpress_key ) ) {
1164
+
1165
+ // echo '<div class="header-wrapper">';
1166
+ // echo '<div class="header-cell">';
1167
+ // if ( array_key_exists( 'header_login_menu', $this->loginpress_key ) && checked( $this->loginpress_key['header_login_menu'], true, false ) ) {
1168
+ //
1169
+ // wp_nav_menu( array(
1170
+ // 'theme_location' => $this->loginpress_key['customize_login_menu'],
1171
+ // 'container' => false,
1172
+ // 'menu_class' => 'loginHeaderMenu',
1173
+ // 'echo' => true,
1174
+ // )
1175
+ // );
1176
+ // }
1177
+ // echo '</div></div><div class="login-wrapper"><div class="login-cell">';
1178
+ }
1179
+ }
1180
+ /**
1181
+ * Set Redirect Path of Logo
1182
+ *
1183
+ * @since 1.0.0
1184
+ * @return mixed
1185
+ * * * * * * * * * * * * * */
1186
+ public function login_page_logo_url() {
1187
+
1188
+ if ( $this->loginpress_key && array_key_exists( 'customize_logo_hover', $this->loginpress_key ) ) {
1189
+ return $this->loginpress_key["customize_logo_hover"];
1190
+ } else {
1191
+ return home_url();
1192
+ }
1193
+ }
1194
+
1195
+ /**
1196
+ * Set hover Title of Logo
1197
+ *
1198
+ * @since 1.0.0
1199
+ * @return mixed
1200
+ * * * * * * * * * * * * */
1201
+ public function login_page_logo_title() {
1202
+ if ( $this->loginpress_key && array_key_exists( 'customize_logo_hover_title', $this->loginpress_key ) ) {
1203
+ return $this->loginpress_key["customize_logo_hover_title"];
1204
+ } else {
1205
+ return home_url();
1206
+ }
1207
+ }
1208
+
1209
+ /**
1210
+ * Set Errors Messages to Show off
1211
+ *
1212
+ * @param $error
1213
+ * @since 1.0.0
1214
+ * @return string
1215
+ * * * * * * * * * * * * * * * * */
1216
+ public function login_error_messages($error) {
1217
+
1218
+ global $errors;
1219
+ $error_codes = $errors->get_error_codes();
1220
+ if ( $this->loginpress_key ) {
1221
+
1222
+ $invalid_usrname = array_key_exists( 'incorrect_username', $this->loginpress_key ) ? $this->loginpress_key['incorrect_username']: esc_html__( 'Invalid Username', 'loginpress' );
1223
+
1224
+ $invalid_pasword = array_key_exists( 'incorrect_password', $this->loginpress_key ) ? $this->loginpress_key['incorrect_password']: esc_html__( 'Invalid Password', 'loginpress' );
1225
+
1226
+ $empty_username = array_key_exists( 'empty_username', $this->loginpress_key ) ? $this->loginpress_key['empty_username']: esc_html__( 'Empty Username', 'loginpress' );
1227
+
1228
+ $empty_password = array_key_exists( 'empty_password', $this->loginpress_key ) ? $this->loginpress_key['empty_password']: esc_html__( 'Empty Password', 'loginpress' );
1229
+
1230
+ $invalid_email = array_key_exists( 'invalid_email', $this->loginpress_key ) ? $this->loginpress_key['invalid_email']: esc_html__( 'The email address is incorrect.', 'loginpress' );
1231
+
1232
+ $empty_email = array_key_exists( 'empty_email', $this->loginpress_key ) ? $this->loginpress_key['empty_email']: esc_html__( 'The email address is empty.', 'loginpress' );
1233
+
1234
+ $invalidcombo = array_key_exists( 'invalidcombo_message', $this->loginpress_key ) ? $this->loginpress_key['invalidcombo_message']: esc_html__( 'Invalid Username or Email.', 'loginpress' );
1235
+
1236
+ if ( in_array( 'invalid_username', $error_codes ) ) {
1237
+ return $invalid_usrname;
1238
+ }
1239
+
1240
+ if ( in_array( 'incorrect_password', $error_codes ) ) {
1241
+ return $invalid_pasword;
1242
+ }
1243
+
1244
+ if ( in_array( 'empty_username', $error_codes ) ) {
1245
+ return $empty_username;
1246
+ }
1247
+
1248
+ if ( in_array( 'empty_password', $error_codes ) ) {
1249
+ return $empty_password;
1250
+ }
1251
+
1252
+ // registeration Form enteries
1253
+ if ( in_array( 'invalid_email', $error_codes ) ) {
1254
+ return $invalid_email;
1255
+ }
1256
+
1257
+ if ( in_array( 'empty_email', $error_codes ) ) {
1258
+ return "</br>" . $empty_email;
1259
+ }
1260
+
1261
+ //forget password entery
1262
+ if ( in_array( 'invalidcombo', $error_codes ) ) {
1263
+ return $invalidcombo;
1264
+ }
1265
+ }
1266
+
1267
+ return $error;
1268
+ }
1269
+
1270
+ /**
1271
+ * Change Lost Password Text from Form
1272
+ *
1273
+ * @param $text
1274
+ * @since 1.0.0
1275
+ * @return mixed
1276
+ * * * * * * * * * * * * * * * * * * */
1277
+ public function change_lostpassword_message ( $text ) {
1278
+ $savedText = '';
1279
+ if ( $this->loginpress_key && array_key_exists( 'login_footer_text', $this->loginpress_key ) ) {
1280
+
1281
+ $savedText = $this->loginpress_key['login_footer_text'];
1282
+ }
1283
+
1284
+ if ( $text == 'Lost your password?' || $text == $savedText ) {
1285
+
1286
+ if ( $this->loginpress_key && array_key_exists( 'login_footer_text', $this->loginpress_key ) ) {
1287
+
1288
+ $text = $savedText; //$this->loginpress_key['login_footer_text'];
1289
+ }
1290
+
1291
+ }
1292
+
1293
+ return $text;
1294
+
1295
+ }
1296
+
1297
+ /**
1298
+ * Manage Welcome Messages
1299
+ *
1300
+ * @param $message
1301
+ * @since 1.0.0
1302
+ * @return string
1303
+ * * * * * * * * * * * * */
1304
+ public function change_welcome_message ($message) {
1305
+ if ( $this->loginpress_key ) {
1306
+
1307
+ //Check, User Logedout.
1308
+ if ( isset($_GET['loggedout']) && TRUE == $_GET['loggedout'] ) {
1309
+
1310
+ if ( array_key_exists( 'logout_message', $this->loginpress_key ) ) {
1311
+
1312
+ $message = $this->loginpress_key['logout_message'];
1313
+ }
1314
+ }
1315
+
1316
+ //Logged In messages.
1317
+ else if ( strpos( $message,"Please enter your username or email address. You will receive a link to create a new password via email." ) == true ) {
1318
+
1319
+ if ( array_key_exists( 'lostpwd_welcome_message', $this->loginpress_key ) ) {
1320
+
1321
+ $message = $this->loginpress_key['lostpwd_welcome_message'];
1322
+ }
1323
+ }
1324
+
1325
+ else if( strpos( $message,"Register For This Site" ) == true ) {
1326
+
1327
+ if ( array_key_exists( 'register_welcome_message', $this->loginpress_key ) ) {
1328
+
1329
+ $message = $this->loginpress_key['register_welcome_message'];
1330
+ }
1331
+ }
1332
+
1333
+ else {
1334
+ if ( array_key_exists( 'welcome_message', $this->loginpress_key ) ) {
1335
+
1336
+ $message = $this->loginpress_key['welcome_message'];
1337
+ }
1338
+ }
1339
+
1340
+ return !empty($message) ? "<p class='custom-message'>" . $message. "</p>" : '';
1341
+ }
1342
+ }
1343
+
1344
+ /**
1345
+ * Hook to Redirect Page for Customize
1346
+ *
1347
+ * @since 1.0.0
1348
+ * * * * * * * * * * * * * * * * * * */
1349
+ public function redirect_to_custom_page() {
1350
+ if (!empty($_GET['page'])) {
1351
+ if(($_GET['page']== "abw")){
1352
+ wp_redirect(get_admin_url()."customize.php?url=".wp_login_url());
1353
+ }
1354
+ }
1355
+ }
1356
+
1357
+ /**
1358
+ * Redirect to the Admin Panel After Closing LoginPress Customizer
1359
+ *
1360
+ * @since 1.0.0
1361
+ * @return null
1362
+ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
1363
+ public function menu_url() {
1364
+
1365
+ global $submenu;
1366
+
1367
+ $parent = 'index.php';
1368
+ $page = 'abw';
1369
+
1370
+ // Create specific url for login view
1371
+ $login_url = wp_login_url();
1372
+ $url = add_query_arg(
1373
+ array(
1374
+ 'url' => urlencode( $login_url ),
1375
+ 'return' => admin_url( 'themes.php' ),
1376
+ ),
1377
+ admin_url( 'customize.php' )
1378
+ );
1379
+
1380
+ // If is Not Design Menu, return
1381
+ if ( ! isset( $submenu[ $parent ] ) ) {
1382
+ return NULL;
1383
+ }
1384
+
1385
+ foreach ( $submenu[ $parent ] as $key => $value ) {
1386
+ // Set new URL for menu item
1387
+ if ( $page === $value[ 2 ] ) {
1388
+ $submenu[ $parent ][ $key ][ 2 ] = $url;
1389
+ break;
1390
+ }
1391
+ }
1392
+ }
1393
+ }
1394
+
1395
+ ?>
img/back_arrow.png ADDED
Binary file
img/bg2.jpg ADDED
Binary file
img/thumbnail/default-1.png ADDED
Binary file
img/thumbnail/default-2.png ADDED
Binary file
img/thumbnail/default-3.png ADDED
Binary file
img/thumbnail/default.png ADDED
Binary file
js/customize-controls.js ADDED
@@ -0,0 +1,509 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ jQuery( document ).ready( function() {
2
+
3
+ /* === Checkbox Multiple Control === */
4
+
5
+ jQuery( '.customize-control-checkbox-multiple input[type="radio"]' ).on(
6
+ 'change',
7
+ function() {
8
+
9
+ checkbox_values = jQuery( this ).parents( '.customize-control' ).find( 'input[type="radio"]:checked' ).val();
10
+
11
+ style_values = jQuery( this ).parents( '.customize-control' ).find( 'input[type="radio"]:checked' ).data('style');
12
+
13
+ // console.log(style_values);
14
+ // console.log(checkbox_values);
15
+ var val = [];
16
+ val.push(checkbox_values);
17
+ val.push(style_values);
18
+ console.log(val);
19
+ jQuery( this ).parents( '.customize-control' ).find( 'input[type="hidden"]' ).val( checkbox_values ).delay(500).trigger( 'change' );
20
+ // jQuery( this ).parents( '.customize-control' ).find( 'input[type="hidden"]' ).trigger( 'change' );
21
+
22
+ }
23
+ );
24
+
25
+ } ); // jQuery( document ).ready
26
+
27
+
28
+ ( function( $ ) {
29
+
30
+ // function for change LoginPress background-image in real time...
31
+ function loginpress_background_img( setting, target ) {
32
+ wp.customize( setting, function( value ) {
33
+ value.bind( function( loginPressVal ) {
34
+ if( loginPressVal == '' ) {
35
+ $('#customize-preview iframe').contents().find( target ).css( 'background-image', '' );
36
+ } else {
37
+ $('#customize-preview iframe').contents().find( target ).css( 'background-image', 'url(' + loginPressVal + ')' );
38
+ }
39
+ } );
40
+ } );
41
+ }
42
+
43
+ // function for change LoginPress CSS in real time...
44
+ function loginpress_css_property( setting, target, property ){
45
+ // Update the login logo width in real time...
46
+ wp.customize( setting, function( value ) {
47
+ value.bind( function( loginPressVal ) {
48
+
49
+ if( loginPressVal == '' ) {
50
+ $('#customize-preview iframe').contents().find( target ).css( property, '' );
51
+ } else {
52
+ $('#customize-preview iframe').contents().find( target ).css( property, loginPressVal );
53
+ }
54
+ } );
55
+ } );
56
+ }
57
+ // function for change LoginPress attribute in real time...
58
+ function loginpress_attr_property( setting, target, property ) {
59
+ wp.customize( setting, function( value ) {
60
+ value.bind( function( loginPressVal ) {
61
+
62
+ if( loginPressVal == '' ) {
63
+ $('#customize-preview iframe').contents().find( target ).attr( property, '' );
64
+ } else {
65
+ $('#customize-preview iframe').contents().find( target ).attr( property, loginPressVal );
66
+ }
67
+ } );
68
+ } );
69
+ }
70
+ // function for change LoginPress inout fiels in real time...
71
+ function loginpress_input_property( setting, property ) {
72
+ wp.customize( setting, function( value ) {
73
+ value.bind( function( loginPressVal ) {
74
+ if( loginPressVal == '' ) {
75
+ $('#customize-preview iframe').contents().find('.login input[type="text"]').css( property, '' );
76
+ $('#customize-preview iframe').contents().find('.login input[type="password"]').css( property, '' );
77
+ } else {
78
+ $('#customize-preview iframe').contents().find('.login input[type="text"]').css( property, loginPressVal );
79
+ $('#customize-preview iframe').contents().find('.login input[type="password"]').css( property, loginPressVal );
80
+ }
81
+ } );
82
+ } );
83
+ }
84
+
85
+ // function for change LoginPress error and welcome messages in real time...
86
+ function loginpress_text_message( errorlog, target ) {
87
+ wp.customize( errorlog, function( value ) {
88
+ value.bind( function( loginPressVal ) {
89
+
90
+ if( loginPressVal == '' ) {
91
+ $('#customize-preview iframe').contents().find( target ).text( '' );
92
+ } else {
93
+ $('#customize-preview iframe').contents().find( target ).text( loginPressVal );
94
+ }
95
+ } );
96
+ } );
97
+ }
98
+
99
+
100
+ // function for change LoginPress CSS in real time...
101
+ function loginpress_display_control( setting ){
102
+ // Update the login logo width in real time...
103
+ wp.customize( setting, function( value ) {
104
+ value.bind( function( loginPressVal ) {
105
+
106
+ // Control on footer text.
107
+ if ( 'loginpress_customization[footer_display_text]' == setting && 'none' == loginPressVal ) {
108
+
109
+ $('#customize-control-login_footer_text_decoration').css('display', 'none');
110
+ $('#customize-control-login_footer_color').css('display', 'none');
111
+ $('#customize-control-login_footer_color_hover').css('display', 'none');
112
+ $('#customize-control-login_footer_font_size').css('display', 'none');
113
+ $('#customize-control-login_footer_bg_color').css('display', 'none');
114
+
115
+ } else if ( 'loginpress_customization[footer_display_text]' == setting && 'block' == loginPressVal ) {
116
+
117
+ $('#customize-control-login_footer_text_decoration').css('display', 'list-item');
118
+ $('#customize-control-login_footer_color').css('display', 'list-item');
119
+ $('#customize-control-login_footer_color_hover').css('display', 'list-item');
120
+ $('#customize-control-login_footer_font_size').css('display', 'list-item');
121
+ $('#customize-control-login_footer_bg_color').css('display', 'list-item');
122
+
123
+ }
124
+
125
+ // Control on footer back link text.
126
+ if ( 'loginpress_customization[back_display_text]' == setting && 'none' == loginPressVal ) {
127
+
128
+ $('#customize-control-login_back_text_decoration').css('display', 'none');
129
+ $('#customize-control-login_back_color').css('display', 'none');
130
+ $('#customize-control-login_back_color_hover').css('display', 'none');
131
+ $('#customize-control-login_back_font_size').css('display', 'none');
132
+ $('#customize-control-login_back_bg_color').css('display', 'none');
133
+
134
+ } else if ( 'loginpress_customization[back_display_text]' == setting && 'block' == loginPressVal ) {
135
+
136
+ $('#customize-control-login_back_text_decoration').css('display', 'list-item');
137
+ $('#customize-control-login_back_color').css('display', 'list-item');
138
+ $('#customize-control-login_back_color_hover').css('display', 'list-item');
139
+ $('#customize-control-login_back_font_size').css('display', 'list-item');
140
+ $('#customize-control-login_back_bg_color').css('display', 'list-item');
141
+
142
+ }
143
+ } );
144
+ } );
145
+ }
146
+
147
+ // function for change LoginPress error and welcome messages in real time...
148
+ function loginpress_footer_text_message( errorlog, target ) {
149
+ wp.customize( errorlog, function( value ) {
150
+ value.bind( function( loginPressVal ) {
151
+
152
+ if( loginPressVal == '' ) {
153
+ $('#customize-preview iframe').contents().find( target ).text( '' );
154
+ if ( errorlog == 'loginpress_customization[login_footer_copy_right]') {
155
+ $('#customize-preview iframe').contents().find( target ).css( 'display', 'none' );
156
+ }
157
+ } else {
158
+ $('#customize-preview iframe').contents().find( target ).text( loginPressVal );
159
+ if ( errorlog == 'loginpress_customization[login_footer_copy_right]') {
160
+ $('#customize-preview iframe').contents().find( target ).css( 'display', 'block' );
161
+ }
162
+ }
163
+ } );
164
+ } );
165
+ }
166
+
167
+ // loginpress_display_control( 'loginpress_customization[footer_display_text]' );
168
+ // loginpress_display_control( 'loginpress_customization[back_display_text]' );
169
+
170
+ // Update the login logo in real time...
171
+ wp.customize( 'loginpress_customization[setting_logo]', function( value ) {
172
+ value.bind( function( loginPressVal ) {
173
+
174
+ if( loginPressVal == '' ) {
175
+ $('#customize-preview iframe').contents().find('#login h1 a').css( 'background-image', 'url(' + admin_url.template_url + '/images/wordpress-logo.svg)' );
176
+ } else {
177
+ $('#customize-preview iframe').contents().find('#login h1 a').css( 'background-image', 'url(' + loginPressVal + ')' );
178
+ }
179
+ } );
180
+ } );
181
+
182
+ loginpress_css_property( 'loginpress_customization[customize_logo_width]', '#login h1 a', 'width' );
183
+ loginpress_css_property( 'loginpress_customization[customize_logo_height]', '#login h1 a', 'height' );
184
+ loginpress_css_property( 'loginpress_customization[customize_logo_padding]', '#login h1 a', 'padding-bottom' );
185
+
186
+ loginpress_attr_property( 'loginpress_customization[customize_logo_hover]', '#login h1 a', 'href' );
187
+ loginpress_attr_property( 'loginpress_customization[customize_logo_hover_title]', '#login h1 a', 'title' );
188
+
189
+ loginpress_background_img( 'loginpress_customization[setting_background]', 'body.login' );
190
+
191
+ loginpress_css_property( 'loginpress_customization[setting_background_color]', 'body.login', 'background-color' );
192
+ loginpress_css_property( 'loginpress_customization[background_repeat_radio]', 'body.login', 'background-repeat' );
193
+ loginpress_css_property( 'loginpress_customization[background_image_size]', 'body.login', 'background-size' );
194
+
195
+ loginpress_background_img( 'loginpress_customization[setting_form_background]', '#loginform' );
196
+
197
+ loginpress_css_property( 'loginpress_customization[customize_form_width]', '#login', 'max-width' );
198
+ loginpress_css_property( 'loginpress_customization[customize_form_height]', '#loginform', 'min-height' );
199
+ loginpress_css_property( 'loginpress_customization[customize_form_padding]', '#loginform', 'padding' );
200
+ loginpress_css_property( 'loginpress_customization[customize_form_border]', '#loginform', 'border' );
201
+
202
+ loginpress_input_property( 'loginpress_customization[textfield_width]', 'width' );
203
+ loginpress_input_property( 'loginpress_customization[textfield_margin]', 'margin' );
204
+ loginpress_input_property( 'loginpress_customization[textfield_background_color]', 'background' );
205
+ loginpress_input_property( 'loginpress_customization[textfield_color]', 'color' );
206
+
207
+
208
+ loginpress_css_property( 'loginpress_customization[form_background_color]', '#loginform', 'background-color' );
209
+
210
+ loginpress_css_property( 'loginpress_customization[textfield_label_color]', '.login label', 'color' );
211
+
212
+ loginpress_background_img( 'loginpress_customization[forget_form_background]', '#lostpasswordform' );
213
+ loginpress_css_property( 'loginpress_customization[forget_form_background_color]','#lostpasswordform', 'background-color' );
214
+
215
+ //Buttons starts.
216
+ // Update the login form button background in real time...
217
+ var loginPressBtnClr;
218
+ var loginPressBtnHvr;
219
+ wp.customize( 'loginpress_customization[custom_button_color]', function( value ) {
220
+ value.bind( function( loginPressVal ) {
221
+ if( loginPressVal == '' ) {
222
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').css('background', '');
223
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').on('mouseover', function(){
224
+
225
+ if( typeof loginPressBtnHvr !== "undefined" || loginPressBtnHvr === null ){
226
+ $(this).css('background', loginPressBtnHvr);
227
+ }else{
228
+ $(this).css('background', '');
229
+ }
230
+ }).on('mouseleave',function () {
231
+ $(this).css('background', '');
232
+ });
233
+ } else {
234
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').css( 'background', loginPressVal );
235
+ loginPressBtnClr = loginPressVal;
236
+
237
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').on('mouseover', function(){
238
+
239
+ if( typeof loginPressBtnHvr !== "undefined" || loginPressBtnHvr === null ){
240
+ $(this).css('background', loginPressBtnHvr);
241
+ }else{
242
+ $(this).css('background', '');
243
+ }
244
+ }).on('mouseleave',function () {
245
+ $(this).css('background', loginPressVal);
246
+ });
247
+ }
248
+ } );
249
+ } );
250
+
251
+ var loginPressBtnBrdrClr;
252
+ // Update the login form button border-color in real time...
253
+ wp.customize( 'loginpress_customization[button_border_color]', function( value ) {
254
+ value.bind( function( loginPressVal ) {
255
+ if( loginPressVal == '' ) {
256
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').css( 'border-color', '' );
257
+ } else {
258
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').css( 'border-color', loginPressVal );
259
+ loginPressBtnBrdrClr = loginPressVal;
260
+ }
261
+ } );
262
+ } );
263
+
264
+ // Update the login form button border-color in real time...
265
+ wp.customize( 'loginpress_customization[button_hover_color]', function( value ) {
266
+ value.bind( function( loginPressVal ) {
267
+ if( loginPressVal == '' ) {
268
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').css('background', '');
269
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').on('mouseover', function(){
270
+ $(this).css('background', '');
271
+ }).on('mouseleave',function () {
272
+
273
+ if( typeof loginPressBtnClr !== "undefined" || loginPressBtnClr === null ){
274
+ $(this).css('background', loginPressBtnClr);
275
+ }else{
276
+ $(this).css('background', '');
277
+ }
278
+ });
279
+ } else {
280
+
281
+ loginPressBtnHvr = loginPressVal;
282
+
283
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').on('mouseover', function(){
284
+
285
+ $(this).css('background', loginPressVal);
286
+ }).on('mouseleave',function () {
287
+
288
+ if( typeof loginPressBtnClr !== "undefined" || loginPressBtnClr === null ){
289
+ $(this).css('background', loginPressBtnClr);
290
+ }else{
291
+ $(this).css('background', '');
292
+ }
293
+ });
294
+ }
295
+ } );
296
+ } );
297
+
298
+ // Update the login form button border-color in real time...
299
+ wp.customize( 'loginpress_customization[button_hover_border]', function( value ) {
300
+ value.bind( function( loginPressVal ) {
301
+ if( loginPressVal == '' ) {
302
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').css( 'border-color', '' );
303
+ } else {
304
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').on('mouseover', function(){
305
+ $(this).css('border-color', loginPressVal);
306
+ }).on('mouseleave',function () {
307
+
308
+ if( typeof loginPressBtnBrdrClr !== "undefined" || loginPressBtnBrdrClr === null ){
309
+ $(this).css('border-color', loginPressBtnBrdrClr);
310
+ }else{
311
+ $(this).css('border-color', '');
312
+ }
313
+ });
314
+ }
315
+ } );
316
+ } );
317
+
318
+ // Update the login form button border-color in real time...
319
+ wp.customize( 'loginpress_customization[custom_button_shadow]', function( value ) {
320
+ value.bind( function( loginPressVal ) {
321
+ if( loginPressVal == '' ) {
322
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').css( 'box-shadow', '' );
323
+ } else {
324
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').css( 'box-shadow', loginPressVal );
325
+ }
326
+ } );
327
+ } );
328
+
329
+ // Update the login form button border-color in real time...
330
+ wp.customize( 'loginpress_customization[button_text_color]', function( value ) {
331
+ value.bind( function( loginPressVal ) {
332
+ if( loginPressVal == '' ) {
333
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').css( 'color', '' );
334
+ } else {
335
+ $('#customize-preview iframe').contents().find('.wp-core-ui #login .button-primary').css( 'color', loginPressVal );
336
+ }
337
+ } );
338
+ } );
339
+
340
+ loginpress_text_message( 'loginpress_customization[login_footer_text]', '.login #nav a:nth-child(2)' );
341
+
342
+ loginpress_css_property( 'loginpress_customization[footer_display_text]', '.login #nav', 'display' );
343
+ loginpress_css_property( 'loginpress_customization[login_footer_text_decoration]', '.login #nav a', 'text-decoration' );
344
+
345
+ var loginPressFtrClr;
346
+ var loginPressFtrHvr;
347
+ // Update the login form button border-color in real time...
348
+ wp.customize( 'loginpress_customization[login_footer_color]', function( value ) {
349
+ value.bind( function( loginPressVal ) {
350
+
351
+ if( loginPressVal == '' ) {
352
+ $('#customize-preview iframe').contents().find('.login #nav a').css( 'color', '' );
353
+ $('#customize-preview iframe').contents().find('.login #nav a').on( 'mouseover', function(){
354
+
355
+ if( typeof loginPressFtrHvr !== "undefined" || loginPressFtrHvr === null ){
356
+ $(this).css('color', loginPressFtrHvr);
357
+ }else{
358
+ $(this).css('color', '');
359
+ }
360
+ }).on('mouseleave',function () {
361
+ $(this).css('color', '');
362
+ });
363
+ } else {
364
+ loginPressFtrClr = loginPressVal;
365
+ $('#customize-preview iframe').contents().find('.login #nav a').css( 'color', loginPressVal );
366
+ $('#customize-preview iframe').contents().find('.login #nav a').on('mouseover', function(){
367
+
368
+ if( typeof loginPressFtrHvr !== "undefined" || loginPressFtrHvr === null ){
369
+ $(this).css('color', loginPressFtrHvr);
370
+ }else{
371
+ $(this).css('color', '');
372
+ }
373
+ }).on('mouseleave',function () {
374
+ $(this).css('color', loginPressVal);
375
+ });
376
+ }
377
+ } );
378
+ } );
379
+
380
+ // Update the login form button border-color in real time...
381
+ wp.customize( 'loginpress_customization[login_footer_color_hover]', function( value ) {
382
+ value.bind( function( loginPressVal ) {
383
+
384
+ if( loginPressVal == '' ) {
385
+
386
+ $('#customize-preview iframe').contents().find('.login #nav a').css( 'color', '' );
387
+
388
+ $('#customize-preview iframe').contents().find('.login #nav a').on('mouseover', function(){
389
+ $(this).css('color', '');
390
+ }).on('mouseleave',function () {
391
+
392
+ if( typeof loginPressFtrClr !== "undefined" || loginPressFtrClr === null ){
393
+ $(this).css('color', loginPressFtrClr);
394
+ }else{
395
+ $(this).css('color', '');
396
+ }
397
+ });
398
+ } else {
399
+ loginPressFtrHvr = loginPressVal;
400
+ $('#customize-preview iframe').contents().find('.login #nav a').on('mouseover', function(){
401
+ $(this).css('color', loginPressVal);
402
+ }).on('mouseleave',function () {
403
+
404
+ if( typeof loginPressFtrClr !== "undefined" || loginPressFtrClr === null ){
405
+ $(this).css('color', loginPressFtrClr);
406
+ }else{
407
+ $(this).css('color', '');
408
+ }
409
+ });
410
+ }
411
+ } );
412
+ } );
413
+
414
+ loginpress_css_property( 'loginpress_customization[login_footer_font_size]', '.login #nav a', 'font-size' );
415
+ loginpress_css_property( 'loginpress_customization[login_footer_bg_color]', '.login #nav', 'background-color' );
416
+
417
+ loginpress_css_property( 'loginpress_customization[back_display_text]', '.login #backtoblog', 'display' );
418
+ loginpress_css_property( 'loginpress_customization[login_back_text_decoration]', '.login #backtoblog a', 'text-decoration' );
419
+
420
+ var loginPressFtrBackClr;
421
+ var loginPressFtrBackHvr;
422
+ // Update the login form button border-color in real time...
423
+ wp.customize( 'loginpress_customization[login_back_color]', function( value ) {
424
+ value.bind( function( loginPressVal ) {
425
+
426
+ if( loginPressVal == '' ) {
427
+ $('#customize-preview iframe').contents().find('.login #backtoblog a').css( 'color', '' );
428
+ $('#customize-preview iframe').contents().find('.login #backtoblog a').on( 'mouseover', function(){
429
+
430
+ if( typeof loginPressFtrBackHvr !== "undefined" || loginPressFtrBackHvr === null ){
431
+ $(this).css('color', loginPressFtrBackHvr);
432
+ }else{
433
+ $(this).css('color', '');
434
+ }
435
+ }).on('mouseleave',function () {
436
+ $(this).css('color', '');
437
+ });
438
+ } else {
439
+ loginPressFtrBackClr = loginPressVal;
440
+ $('#customize-preview iframe').contents().find('.login #backtoblog a').css( 'color', loginPressVal );
441
+ $('#customize-preview iframe').contents().find('.login #backtoblog a').on('mouseover', function(){
442
+
443
+ if( typeof loginPressFtrBackHvr !== "undefined" || loginPressFtrBackHvr === null ){
444
+ $(this).css('color', loginPressFtrBackHvr);
445
+ }else{
446
+ $(this).css('color', '');
447
+ }
448
+ }).on('mouseleave',function () {
449
+ $(this).css('color', loginPressVal);
450
+ });
451
+ }
452
+ } );
453
+ } );
454
+
455
+ // Update the login form button border-color in real time...
456
+ wp.customize( 'loginpress_customization[login_back_color_hover]', function( value ) {
457
+ value.bind( function( loginPressVal ) {
458
+
459
+ if( loginPressVal == '' ) {
460
+
461
+ $('#customize-preview iframe').contents().find('.login #backtoblog a').css( 'color', '' );
462
+
463
+ $('#customize-preview iframe').contents().find('.login #backtoblog a').on('mouseover', function(){
464
+ $(this).css('color', '');
465
+ }).on('mouseleave',function () {
466
+
467
+ if( typeof loginPressFtrBackClr !== "undefined" || loginPressFtrBackClr === null ){
468
+ $(this).css('color', loginPressFtrBackClr);
469
+ }else{
470
+ $(this).css('color', '');
471
+ }
472
+ });
473
+ } else {
474
+ loginPressFtrBackHvr = loginPressVal;
475
+ $('#customize-preview iframe').contents().find('.login #backtoblog a').on('mouseover', function(){
476
+ $(this).css('color', loginPressVal);
477
+ }).on('mouseleave',function () {
478
+
479
+ if( typeof loginPressFtrBackClr !== "undefined" || loginPressFtrBackClr === null ){
480
+ $(this).css('color', loginPressFtrBackClr);
481
+ }else{
482
+ $(this).css('color', '');
483
+ }
484
+ });
485
+ }
486
+ } );
487
+ } );
488
+
489
+ loginpress_css_property( 'loginpress_customization[login_back_font_size]', '.login #backtoblog a', 'font-size' );
490
+ loginpress_css_property( 'loginpress_customization[login_back_bg_color]', '.login #backtoblog', 'background-color' );
491
+ loginpress_footer_text_message( 'loginpress_customization[login_footer_copy_right]', '.copyRight' );
492
+
493
+ loginpress_text_message( 'loginpress_customization[incorrect_username]', '#login_error' );
494
+ loginpress_text_message( 'loginpress_customization[incorrect_password]', '#login_error' );
495
+ loginpress_text_message( 'loginpress_customization[empty_username]', '#login_error' );
496
+ loginpress_text_message( 'loginpress_customization[empty_password]', '#login_error' );
497
+ loginpress_text_message( 'loginpress_customization[invalid_email]', '#login_error' );
498
+ loginpress_text_message( 'loginpress_customization[empty_email]', '#login_error' );
499
+ loginpress_text_message( 'loginpress_customization[invalidcombo_message]', '#login_error' );
500
+
501
+ loginpress_text_message( 'loginpress_customization[lostpwd_welcome_message]', '.login .custom-message' );
502
+ loginpress_text_message( 'loginpress_customization[welcome_message]', '.login .custom-message' );
503
+ loginpress_text_message( 'loginpress_customization[register_welcome_message]', '.login .custom-message' );
504
+ loginpress_text_message( 'loginpress_customization[logout_message]', '.login .custom-message' );
505
+
506
+ loginpress_css_property( 'loginpress_customization[message_background_border]', '.login .custom-message', 'border' );
507
+ loginpress_css_property( 'loginpress_customization[message_background_color]', '.login .custom-message', 'background-color' );
508
+
509
+ } )( jQuery );
loginpress.php CHANGED
@@ -1,179 +1,183 @@
1
- <?php
2
- /**
3
- * Plugin Name: LoginPress - Customizing the WordPress Login
4
- * Plugin URI: http://www.WPBrigade.com/wordpress/plugins/loginpress/
5
- * Description: LoginPress is the best Login Page Customizer in WordPress which allows you to completely change the layout of login, register and forgot password forms.
6
- * Version: 1.0.5
7
- * Author: WPBrigade
8
- * Author URI: http://www.WPBrigade.com/
9
- * Requires at least: 4.0
10
- * Tested up to: 4.7.1
11
- * Text Domain: loginpress
12
- * Domain Path: /languages
13
- *
14
- * @package loginpress
15
- * @category Core
16
- * @author WPBrigade
17
- */
18
- if ( ! class_exists( 'LoginPress' ) ) :
19
-
20
- final class LoginPress {
21
-
22
- /**
23
- * @var string
24
- */
25
- public $version = '1.0.5';
26
-
27
- /**
28
- * @var The single instance of the class
29
- * @since 1.0.0
30
- */
31
- protected static $_instance = null;
32
-
33
- /**
34
- * @var WP_Session session
35
- */
36
- public $session = null;
37
-
38
- /**
39
- * @var WP_Query $query
40
- */
41
- public $query = null;
42
-
43
- /**s
44
- * @var WP_Countries $countries
45
- */
46
- public $countries = null;
47
-
48
- /* * * * * * * * * *
49
- * Class constructor
50
- * * * * * * * * * */
51
- public function __construct() {
52
-
53
- $this->define_constants();
54
- $this->includes();
55
- $this->_hooks();
56
- }
57
-
58
- /**
59
- * Define LoginPress Constants
60
- */
61
- private function define_constants() {
62
-
63
- $this->define( 'LOGINPRESS_PLUGIN_BASENAME', plugin_basename( __FILE__ ) );
64
- $this->define( 'LOGINPRESS_VERSION', $this->version );
65
- }
66
-
67
- /**
68
- * Include required core files used in admin and on the frontend.
69
- */
70
- public function includes() {
71
- include_once( 'custom.php' );
72
- }
73
-
74
- /**
75
- * Hook into actions and filters
76
- * @since 1.0.0
77
- */
78
- private function _hooks() {
79
-
80
- add_action( 'admin_menu', array( $this, 'register_options_page' ) );
81
- add_action( 'plugins_loaded', array( $this, 'textdomain' ) );
82
- add_filter( 'plugin_row_meta', array( $this, '_row_meta'), 10, 2 );
83
- }
84
-
85
- /**
86
- * Main Instance
87
- *
88
- * @since 1.0.0
89
- * @static
90
- * @see loginPress_loader()
91
- * @return Main instance
92
- */
93
- public static function instance() {
94
- if ( is_null( self::$_instance ) ) {
95
- self::$_instance = new self();
96
- }
97
- return self::$_instance;
98
- }
99
-
100
-
101
- /**
102
- * Load Languages
103
- * @since 1.0.0
104
- */
105
- public function textdomain() {
106
-
107
- $plugin_dir = dirname( plugin_basename( __FILE__ ) ) ;
108
- load_plugin_textdomain( 'loginpress', false, $plugin_dir . '/languages/');
109
- }
110
-
111
- /**
112
- * Define constant if not already set
113
- * @param string $name
114
- * @param string|bool $value
115
- */
116
- private function define( $name, $value ) {
117
- if ( ! defined( $name ) ) {
118
- define( $name, $value );
119
- }
120
- }
121
-
122
- /**
123
- * Include required ajax files.
124
- */
125
- public function ajax_includes() {
126
- // Ajax functions for admin and the front-end
127
- }
128
- /**
129
- * Init WPBrigade when WordPress Initialises.
130
- */
131
- public function init() {
132
- // Before init action
133
- }
134
- /**
135
- * Add new page in Apperance to customize Login Page
136
- */
137
- public function register_options_page() {
138
- add_theme_page( __( 'LoginPress', 'loginpress' ),
139
- __( 'LoginPress', 'loginpress' ),
140
- 'manage_options',
141
- "abw",
142
- '__return_null' );
143
- }
144
- public function _row_meta( $links, $file ) {
145
-
146
- if ( strpos( $file, 'loginpress.php' ) !== false ) {
147
-
148
- // Set link for Reviews.
149
- $new_links = array('<a href="https://wordpress.org/support/view/plugin-reviews/loginpress" target="_blank"><span class="dashicons dashicons-thumbs-up"></span> ' . __( 'Vote!', 'loginpress' ) . '</a>',
150
- );
151
-
152
- $links = array_merge( $links, $new_links );
153
- }
154
-
155
- return $links;
156
- }
157
- }
158
- endif;
159
-
160
- /**
161
- * Returns the main instance of WP to prevent the need to use globals.
162
- *
163
- * @since 1.0.0
164
- * @return LoginPress
165
- */
166
- function loginPress_loader() {
167
- return LoginPress::instance();
168
- }
169
-
170
- // Call the function
171
- loginPress_loader();
172
-
173
- /**
174
- * Create the Object of Custom Login Entites.
175
- *
176
- * @since 1.0.0
177
- */
178
- new LoginPress_Entities();
179
- ?>
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Plugin Name: LoginPress - Customizing the WordPress Login
4
+ * Plugin URI: http://www.WPBrigade.com/wordpress/plugins/loginpress/
5
+ * Description: LoginPress is the best Login Page Customizer in WordPress which allows you to completely change the layout of login, register and forgot password forms.
6
+ * Version: 1.0.6
7
+ * Author: WPBrigade
8
+ * Author URI: http://www.WPBrigade.com/
9
+ * Requires at least: 4.0
10
+ * Tested up to: 4.7.1
11
+ * Text Domain: loginpress
12
+ * Domain Path: /languages
13
+ *
14
+ * @package loginpress
15
+ * @category Core
16
+ * @author WPBrigade
17
+ */
18
+
19
+
20
+
21
+ if ( ! class_exists( 'LoginPress' ) ) :
22
+
23
+ final class LoginPress {
24
+
25
+ /**
26
+ * @var string
27
+ */
28
+ public $version = '1.0.2';
29
+
30
+ /**
31
+ * @var The single instance of the class
32
+ * @since 1.0.0
33
+ */
34
+ protected static $_instance = null;
35
+
36
+ /**
37
+ * @var WP_Session session
38
+ */
39
+ public $session = null;
40
+
41
+ /**
42
+ * @var WP_Query $query
43
+ */
44
+ public $query = null;
45
+
46
+ /**s
47
+ * @var WP_Countries $countries
48
+ */
49
+ public $countries = null;
50
+
51
+ /* * * * * * * * * *
52
+ * Class constructor
53
+ * * * * * * * * * */
54
+ public function __construct() {
55
+
56
+ $this->define_constants();
57
+ $this->includes();
58
+ $this->_hooks();
59
+ }
60
+
61
+ /**
62
+ * Define LoginPress Constants
63
+ */
64
+ private function define_constants() {
65
+
66
+ $this->define( 'LOGINPRESS_PLUGIN_BASENAME', plugin_basename( __FILE__ ) );
67
+ $this->define( 'LOGINPRESS_ROOT_PATH', dirname( __FILE__ ) );
68
+ $this->define( 'LOGINPRESS_VERSION', $this->version );
69
+ }
70
+
71
+ /**
72
+ * Include required core files used in admin and on the frontend.
73
+ */
74
+ public function includes() {
75
+ include_once( plugin_dir_path( __FILE__ ) . '/custom.php' );
76
+ }
77
+
78
+ /**
79
+ * Hook into actions and filters
80
+ * @since 1.0.0
81
+ */
82
+ private function _hooks() {
83
+
84
+ add_action( 'admin_menu', array( $this, 'register_options_page' ) );
85
+ add_action( 'plugins_loaded', array( $this, 'textdomain' ) );
86
+ add_filter( 'plugin_row_meta', array( $this, '_row_meta'), 10, 2 );
87
+ }
88
+
89
+ /**
90
+ * Main Instance
91
+ *
92
+ * @since 1.0.0
93
+ * @static
94
+ * @see loginPress_loader()
95
+ * @return Main instance
96
+ */
97
+ public static function instance() {
98
+ if ( is_null( self::$_instance ) ) {
99
+ self::$_instance = new self();
100
+ }
101
+ return self::$_instance;
102
+ }
103
+
104
+
105
+ /**
106
+ * Load Languages
107
+ * @since 1.0.0
108
+ */
109
+ public function textdomain() {
110
+
111
+ $plugin_dir = dirname( plugin_basename( __FILE__ ) ) ;
112
+ load_plugin_textdomain( 'loginpress', false, $plugin_dir . '/languages/');
113
+ }
114
+
115
+ /**
116
+ * Define constant if not already set
117
+ * @param string $name
118
+ * @param string|bool $value
119
+ */
120
+ private function define( $name, $value ) {
121
+ if ( ! defined( $name ) ) {
122
+ define( $name, $value );
123
+ }
124
+ }
125
+
126
+ /**
127
+ * Include required ajax files.
128
+ */
129
+ public function ajax_includes() {
130
+ // Ajax functions for admin and the front-end
131
+ }
132
+ /**
133
+ * Init WPBrigade when WordPress Initialises.
134
+ */
135
+ public function init() {
136
+ // Before init action
137
+ }
138
+ /**
139
+ * Add new page in Apperance to customize Login Page
140
+ */
141
+ public function register_options_page() {
142
+ add_theme_page( __( 'LoginPress', 'loginpress' ),
143
+ __( 'LoginPress', 'loginpress' ),
144
+ 'manage_options',
145
+ "abw",
146
+ '__return_null' );
147
+ }
148
+ public function _row_meta( $links, $file ) {
149
+
150
+ if ( strpos( $file, 'loginpress.php' ) !== false ) {
151
+
152
+ // Set link for Reviews.
153
+ $new_links = array('<a href="https://wordpress.org/support/view/plugin-reviews/loginpress" target="_blank"><span class="dashicons dashicons-thumbs-up"></span> ' . __( 'Vote!', 'loginpress' ) . '</a>',
154
+ );
155
+
156
+ $links = array_merge( $links, $new_links );
157
+ }
158
+
159
+ return $links;
160
+ }
161
+ }
162
+ endif;
163
+
164
+ /**
165
+ * Returns the main instance of WP to prevent the need to use globals.
166
+ *
167
+ * @since 1.0.0
168
+ * @return LoginPress
169
+ */
170
+ function loginPress_loader() {
171
+ return LoginPress::instance();
172
+ }
173
+
174
+ // Call the function
175
+ loginPress_loader();
176
+
177
+ /**
178
+ * Create the Object of Custom Login Entites.
179
+ *
180
+ * @since 1.0.0
181
+ */
182
+ new LoginPress_Entities();
183
+ ?>
readme.txt CHANGED
@@ -1,169 +1,172 @@
1
- === Login ===
2
- Version: 1.0.5
3
- Requires at least: 4.0
4
- Tested up to: 4.7.1
5
- Contributors: WPBrigade, hiddenpearls, abdulwahab610
6
- Author URI: https://wpbrigade.com
7
- Tags: customizer, custom login, login logo, login customizer, custom login page, admin, branding, customization, forgot password, login error, login page style, loginpress
8
- Stable tag: 1.0.5
9
- License: GPLv2 or later
10
- License URI: http://www.gnu.org/licenses/gpl-2.0.html
11
-
12
- LOGIN allows you to easily customize the layout of login, admin login, client login, register and forgot password forms/pages.
13
-
14
- == Description ==
15
-
16
- [Login Plugin](http://www.WPBrigade.com/wordpress/plugins/loginpress/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion) holds a lot of customization fields to change the layout of the login page of WordPress. You can modify the look and feel of login page completely even the login error messages, forgot error messages, registration error messages and many more.
17
- Login Plugin would give you and your users a feeling that it is a custom login page and a part of the site layout. You must checkout the Demo video of how you can customize WordPress login page.
18
-
19
- **Getting Started video for customizing login page using LoginPress**
20
-
21
- `[youtube https://www.youtube.com/watch?v=GMAwsHomJlE]`
22
-
23
- Login plugin is built using The Customizer API which is getting popular for live-previewing any changes to the layouts of WordPress. So, with LoginPress you can preview your login page changes instantly. This login customizer plugin is easy enough & required no coding skills. Just have options for each element on the login form and make a new customized login page within seconds.
24
-
25
-
26
- **Features:**
27
-
28
- * Logo: Can change the login logo {image, width, height, padding, URL and Title}.
29
-
30
- * Background: You can customize background Image or Color. Set its position, Size and repeatable property.
31
-
32
- * Login Form: Even you can customize the login form {image or color, width, height, padding and border}. More over customize Input Text Field {width, margin, text color, label color and background color}.
33
-
34
- * Forget Form: Beauty of the plugin here you can change the background or color of the forget form.
35
-
36
- * Button: You can set the color of your button WYSIWYG.
37
-
38
- Error Messages: Main Feature of the plugin. You can change the error log messages as you want to show users form LoginPress → Error Messages.
39
-
40
- * Welcome Messages: Same as error log messages you can customize the welcome messages from LoginPress → Welcome Messages.
41
-
42
- * Form Footer: After the login Button, here is form footer. You can customize the footer {text, display, text decoration, text color, text hover color and text size}. In this section you can also customize the page footer text.
43
-
44
-
45
- > <strong>Making WordPress Login page mobile friendly after customization</strong><br>
46
- > This plugin is also responsive. It means that when you customize login page, It will look good on mobile i.e It is Responsive.
47
-
48
-
49
- **LoginPress Features in Detail:**
50
-
51
- * Customize login error messages. You can change every error message wether it is on login form, forgot password form or register form.
52
- * Customize login logo image.
53
- * Customize login logo image width.
54
- * Customize login logo image height.
55
- * Customize login logo image hover title.
56
- * Customize login logo image hover link.
57
- * Customize login logo padding bottom.
58
- * Customize login page background image.
59
- * Customize login page background color.
60
- * Customize login page background image size.
61
- * Customize login page without background image. You can keep it simple with different login form style.
62
- * Customize login form width.
63
- * Customize login form height.
64
- * Customize login form border style.
65
- * Customize login form input styling.
66
- * Customize login form label styling.
67
- * Customize login form field text color.
68
- * Customize login form background color.
69
- * Customize login page "lost your password?" text.
70
- * Customize login forgot password form background color and image.
71
- * Customize login form button styling.
72
- * Customize login form notice messages.
73
- * Add copyright notice message at the bottom of login page.
74
- * Customize "Back to" text at login page. You can hide or show or change the color or even the text size as well.
75
- * Customize login page footer. We call login page footer area under the login form fields.
76
- * LoginPress has a Custom CSS area which can Customize login page in more advanced way. Recommended for advanced users.
77
- * Customize your login page in more advanced way using our Custom JS area. Add your JS there and make your login page more advanced.
78
- * Customize login page with unlimited features available in loginpress.
79
-
80
- After going through this extensive list of feaures you can imagine Why LoginPress is the best login page customizer in the WordPress market.
81
-
82
- > <strong>Beautify and Innovate your WordPress login page without any coding knowledge!</strong>
83
-
84
- = What's Next =
85
-
86
-
87
- If you like this plugin, then consider checking out our other projects:
88
-
89
- * <a href="https://analytify.io/" rel="friend" title="Google Analytics by Analytify">Google Analytics by Analytify</a> - Google Analytics by Analytify
90
- * <a href="http://wpbrigade.com/" rel="friend" title="Related Posts">Related Posts</a> - Best Related Posts Plugin
91
-
92
- == Notes ==
93
-
94
- LoginPress is absolutely, positively the most <a href="http://www.WPBrigade.com/wordpress/plugins/loginpress/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion" rel="friend" title="Best Custom login form plugin">beginner friendly WordPress custom login form plugin</a> on the market. It is both easy and powerful.
95
-
96
- Also, I'm the founder of <a href="http://www.wpbrigade.com/" rel="friend">WPBrigade</a>, We do custom WordPress themes for clients and can transform any website in WordPress. It was a huge priority for me to make a WordPress custom login form plugin that beginners can use without any training.
97
-
98
- I feel that we have done that here. I hope you enjoy using LoginPress.
99
-
100
- Thank you
101
-
102
- Muhammad Adnan
103
-
104
- == Installation ==
105
-
106
- 1. Upload the plugin to your 'wp-content/plugins' directory, or download and install automatically through your admin panel.
107
- 2. Activate the plugin through the 'Plugins' menu in WordPress.
108
-
109
- == Frequently Asked Questions ==
110
-
111
- = How to get started with LoginPress? =
112
-
113
- In your WordPress Dashboard, navigate to Appearance > LoginPress to get started.
114
-
115
- = Who should use LoginPress? =
116
-
117
- Every WordPress user should use LoginPress. It is easy to use and can tranform your boring wp-login.php login page into a beautiful customized login form page.
118
-
119
- = Do I need to have coding skills to use LoginPress? =
120
-
121
- Absolutely not. You can create and manage custom login page without any coding knowledge. LoginPress is the most beginner friendly custom login form solution in the market.
122
-
123
- = Is LoginPress translation ready? =
124
-
125
- Yes, LoginPress has full translation and localization support via the loginpress textdomain. All .mo and .po translation files should go into the languages folder in the base of the plugin.
126
-
127
- = How to donate or contribute? =
128
-
129
- Please visit <a target="_blank" rel="friend" href="http://www.WPBrigade.com/wordpress/plugins/loginpress/">this link</a> for more info.
130
-
131
- == Screenshots ==
132
-
133
- 1. Custom Login page Example #1 with Background Image
134
- 2. Custom Login page Example #2 with background color only
135
- 3. Custom Login page Example #3
136
- 4. Custom Login page Example #4
137
- 5. Custom Login page Example #5
138
- 6. Custom Login page Example #6
139
- 7. Custom Login page Example #7
140
- 8. Custom Login page Example #8
141
- 9. Custom Login page Example #9
142
- 10. Custom Login page Example #10
143
-
144
- == Changelog ==
145
-
146
- = 1.0.5 - 2017-01-13 =
 
 
 
147
  * Bug fix: Redirect 404 page error.
148
 
149
- = 1.0.4 - 2017-01-12 =
150
- * Bug fix: Default background path fixed.
151
- * Bug fix: bugfix for PHP 5.3
152
-
153
- = 1.0.3 - 2017-01-06 =
154
- * Bug fix: Default background.
155
- * Bug fix: Responsive layout.
156
-
157
- = 1.0.2 - 2016-12-24 =
158
- * code cleanup and readme update.
159
-
160
- = 1.0.1 - 2016-11-08 =
161
- * Changing menu name to LoginPress in WordPress Customizer
162
-
163
- = 1.0.0 - 2016-09-08 =
164
- * Initial Release.
165
-
166
- == Upgrade Notice ==
167
-
168
- = 1.0.5 =
169
- * Bug fix release, please update Immediately.
1
+ === Login ===
2
+ Version: 1.0.6
3
+ Requires at least: 4.0
4
+ Tested up to: 4.7.1
5
+ Contributors: WPBrigade, hiddenpearls, abdulwahab610
6
+ Author URI: https://wpbrigade.com
7
+ Tags: customizer, custom login, login logo, login customizer, custom login page, admin, wp-login, customization, forgot password, login error, login page style, loginpress
8
+ Stable tag: 1.0.6
9
+ License: GPLv2 or later
10
+ License URI: http://www.gnu.org/licenses/gpl-2.0.html
11
+
12
+ LOGIN allows you to easily customize the layout of login, admin login, client login, register and forgot password forms/pages.
13
+
14
+ == Description ==
15
+
16
+ [Login Plugin](http://www.WPBrigade.com/wordpress/plugins/loginpress/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion) holds a lot of customization fields to change the layout of the login page of WordPress. You can modify the look and feel of login page completely even the login error messages, forgot error messages, registration error messages and many more.
17
+ Login Plugin would give you and your users a feeling that it is a custom login page and a part of the site layout. You must checkout the Demo video of how you can customize WordPress login page.
18
+
19
+ **Getting Started video for customizing login page using LoginPress**
20
+
21
+ `[youtube https://www.youtube.com/watch?v=GMAwsHomJlE]`
22
+
23
+ Login plugin is built using The Customizer API which is getting popular for live-previewing any changes to the layouts of WordPress. So, with LoginPress you can preview your login page changes instantly. This login customizer plugin is easy enough & required no coding skills. Just have options for each element on the login form and make a new customized login page within seconds.
24
+
25
+
26
+ **Features:**
27
+
28
+ * Logo: Can change the login logo {image, width, height, padding, URL and Title}.
29
+
30
+ * Background: You can customize background Image or Color. Set its position, Size and repeatable property.
31
+
32
+ * Login Form: Even you can customize the login form {image or color, width, height, padding and border}. More over customize Input Text Field {width, margin, text color, label color and background color}.
33
+
34
+ * Forget Form: Beauty of the plugin here you can change the background or color of the forget form.
35
+
36
+ * Button: You can set the color of your button WYSIWYG.
37
+
38
+ Error Messages: Main Feature of the plugin. You can change the error log messages as you want to show users form LoginPress → Error Messages.
39
+
40
+ * Welcome Messages: Same as error log messages you can customize the welcome messages from LoginPress → Welcome Messages.
41
+
42
+ * Form Footer: After the login Button, here is form footer. You can customize the footer {text, display, text decoration, text color, text hover color and text size}. In this section you can also customize the page footer text.
43
+
44
+
45
+ > <strong>Making WordPress Login page mobile friendly after customization</strong><br>
46
+ > This plugin is also responsive. It means that when you customize login page, It will look good on mobile i.e It is Responsive.
47
+
48
+
49
+ **LoginPress Features in Detail:**
50
+
51
+ * Customize login error messages. You can change every error message wether it is on login form, forgot password form or register form.
52
+ * Customize login logo image.
53
+ * Customize login logo image width.
54
+ * Customize login logo image height.
55
+ * Customize login logo image hover title.
56
+ * Customize login logo image hover link.
57
+ * Customize login logo padding bottom.
58
+ * Customize login page background image.
59
+ * Customize login page background color.
60
+ * Customize login page background image size.
61
+ * Customize login page without background image. You can keep it simple with different login form style.
62
+ * Customize login form width.
63
+ * Customize login form height.
64
+ * Customize login form border style.
65
+ * Customize login form input styling.
66
+ * Customize login form label styling.
67
+ * Customize login form field text color.
68
+ * Customize login form background color.
69
+ * Customize login page "lost your password?" text.
70
+ * Customize login forgot password form background color and image.
71
+ * Customize login form button styling.
72
+ * Customize login form notice messages.
73
+ * Add copyright notice message at the bottom of login page.
74
+ * Customize "Back to" text at login page. You can hide or show or change the color or even the text size as well.
75
+ * Customize login page footer. We call login page footer area under the login form fields.
76
+ * LoginPress has a Custom CSS area which can Customize login page in more advanced way. Recommended for advanced users.
77
+ * Customize your login page in more advanced way using our Custom JS area. Add your JS there and make your login page more advanced.
78
+ * Customize login page with unlimited features available in loginpress.
79
+
80
+ After going through this extensive list of feaures you can imagine Why LoginPress is the best login page customizer in the WordPress market.
81
+
82
+ > <strong>Beautify and Innovate your WordPress login page without any coding knowledge!</strong>
83
+
84
+ = What's Next =
85
+
86
+
87
+ If you like this plugin, then consider checking out our other projects:
88
+
89
+ * <a href="https://analytify.io/" rel="friend" title="Google Analytics by Analytify">Google Analytics by Analytify</a> - Google Analytics by Analytify
90
+ * <a href="http://wpbrigade.com/" rel="friend" title="Related Posts">Related Posts</a> - Best Related Posts Plugin
91
+
92
+ == Notes ==
93
+
94
+ LoginPress is absolutely, positively the most <a href="http://www.WPBrigade.com/wordpress/plugins/loginpress/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion" rel="friend" title="Best Custom login form plugin">beginner friendly WordPress custom login form plugin</a> on the market. It is both easy and powerful.
95
+
96
+ Also, I'm the founder of <a href="http://www.wpbrigade.com/" rel="friend">WPBrigade</a>, We do custom WordPress themes for clients and can transform any website in WordPress. It was a huge priority for me to make a WordPress custom login form plugin that beginners can use without any training.
97
+
98
+ I feel that we have done that here. I hope you enjoy using LoginPress.
99
+
100
+ Thank you
101
+
102
+ Muhammad Adnan
103
+
104
+ == Installation ==
105
+
106
+ 1. Upload the plugin to your 'wp-content/plugins' directory, or download and install automatically through your admin panel.
107
+ 2. Activate the plugin through the 'Plugins' menu in WordPress.
108
+
109
+ == Frequently Asked Questions ==
110
+
111
+ = How to get started with LoginPress? =
112
+
113
+ In your WordPress Dashboard, navigate to Appearance > LoginPress to get started.
114
+
115
+ = Who should use LoginPress? =
116
+
117
+ Every WordPress user should use LoginPress. It is easy to use and can tranform your boring wp-login.php login page into a beautiful customized login form page.
118
+
119
+ = Do I need to have coding skills to use LoginPress? =
120
+
121
+ Absolutely not. You can create and manage custom login page without any coding knowledge. LoginPress is the most beginner friendly custom login form solution in the market.
122
+
123
+ = Is LoginPress translation ready? =
124
+
125
+ Yes, LoginPress has full translation and localization support via the loginpress textdomain. All .mo and .po translation files should go into the languages folder in the base of the plugin.
126
+
127
+ = How to donate or contribute? =
128
+
129
+ Please visit <a target="_blank" rel="friend" href="http://www.WPBrigade.com/wordpress/plugins/loginpress/">this link</a> for more info.
130
+
131
+ == Screenshots ==
132
+
133
+ 1. Custom Login page Example #1 with Background Image
134
+ 2. Custom Login page Example #2 with background color only
135
+ 3. Custom Login page Example #3
136
+ 4. Custom Login page Example #4
137
+ 5. Custom Login page Example #5
138
+ 6. Custom Login page Example #6
139
+ 7. Custom Login page Example #7
140
+ 8. Custom Login page Example #8
141
+ 9. Custom Login page Example #9
142
+ 10. Custom Login page Example #10
143
+
144
+ == Changelog ==
145
+
146
+ = 1.0.6 - 2017-01-20 =
147
+ * Bug fix: site lock out bug fixed.
148
+
149
+ = 1.0.5 - 2017-01-13 =
150
  * Bug fix: Redirect 404 page error.
151
 
152
+ = 1.0.4 - 2017-01-12 =
153
+ * Bug fix: Default background path fixed.
154
+ * Bug fix: bugfix for PHP 5.3
155
+
156
+ = 1.0.3 - 2017-01-06 =
157
+ * Bug fix: Default background.
158
+ * Bug fix: Responsive layout.
159
+
160
+ = 1.0.2 - 2016-12-24 =
161
+ * code cleanup and readme update.
162
+
163
+ = 1.0.1 - 2016-11-08 =
164
+ * Changing menu name to LoginPress in WordPress Customizer
165
+
166
+ = 1.0.0 - 2016-09-08 =
167
+ * Initial Release.
168
+
169
+ == Upgrade Notice ==
170
+
171
+ = 1.0.6 =
172
+ * Bug fix release, please update Immediately.