Maintenance - Version 2.0

Version Description

// 17.12.2013

  • New features
  • New PRO version
  • New design
  • New dashboard
  • Core plugin changes
  • Backstretch fullscreen background
  • Blur background effect
  • 503 error switcher
Download this release

Release Info

Developer fruitfulcode
Plugin Icon 128x128 Maintenance
Version 2.0
Comparing to
See all releases

Code changes from version 1.2.3 to 2.0

Files changed (57) hide show
  1. assets/banner-772x250.png +0 -0
  2. css/admin.css +49 -55
  3. functions.php +0 -102
  4. images/background.png +0 -0
  5. images/body_bg.jpg +0 -0
  6. images/buttons.png +0 -0
  7. images/header_bg.jpg +0 -0
  8. images/ie.png +0 -0
  9. images/mini-logo.png +0 -0
  10. images/star.png +0 -0
  11. images/support.png +0 -0
  12. images/worker.png +0 -0
  13. includes/admin.php +88 -0
  14. includes/functions.php +254 -0
  15. includes/update.php +32 -0
  16. index.php +0 -79
  17. js/init.js +15 -16
  18. js/init.min.js +1 -0
  19. js/uploads_.js +55 -0
  20. js/uploads_.min.js +1 -0
  21. languages/maintenance-ru_RU.mo +0 -0
  22. languages/maintenance-ru_RU.po +160 -48
  23. lib/functions.php +0 -55
  24. lib/images/error.png +0 -0
  25. lib/images/fruitfulcode.png +0 -0
  26. lib/images/logo-bg-default.png +0 -0
  27. lib/images/pass-icon.png +0 -0
  28. lib/images/theme-bg-default.jpg +0 -0
  29. lib/images/user-icon.png +0 -0
  30. lib/index.php +0 -214
  31. lib/js/DD_belatedPNG_0.0.7a-min.js +0 -14
  32. lib/js/jquery.countdown.js +0 -7
  33. lib/js/jquery.placeholder.js +0 -106
  34. lib/options.php +0 -30
  35. lib/style.css +0 -254
  36. load/functions.php +256 -0
  37. load/images/fonts-icon/general_foundicons.eot +0 -0
  38. load/images/fonts-icon/general_foundicons.svg +15 -0
  39. load/images/fonts-icon/general_foundicons.ttf +0 -0
  40. load/images/fonts-icon/general_foundicons.woff +0 -0
  41. load/images/fonts-icon/icons.style.css +21 -0
  42. load/images/fonts-icon/social_foundicons.eot +0 -0
  43. load/images/fonts-icon/social_foundicons.svg +15 -0
  44. load/images/fonts-icon/social_foundicons.ttf +0 -0
  45. load/images/fonts-icon/social_foundicons.woff +0 -0
  46. load/index.php +50 -0
  47. load/js/jquery.backstretch.min.js +10 -0
  48. load/js/jquery.blur.min.js +5 -0
  49. load/js/jquery.frontend.js +53 -0
  50. load/js/jquery.frontend.min.js +1 -0
  51. load/js/jquery.placeholder.js +1 -0
  52. load/style.css +388 -0
  53. maintenance.php +102 -0
  54. page-options.php +0 -66
  55. readme.txt +34 -12
  56. screenshot-1.png +0 -0
  57. screenshot-2.png +0 -0
assets/banner-772x250.png DELETED
Binary file
css/admin.css CHANGED
@@ -1,63 +1,57 @@
1
- #confirmOverlay{width:100%;height:100%;position:fixed;top:0;left:0;background:url( '../images/ie.png ');background:-moz-linear-gradient(rgba(11,11,11,0.1),rgba(11,11,11,0.6)) repeat-x rgba(11,11,11,0.2);background:-webkit-gradient(linear,0% 0%,0% 100%,from(rgba(11,11,11,0.1)),to(rgba(11,11,11,0.6))) repeat-x rgba(11,11,11,0.2);z-index:100000;}
2
- #confirmBox{background:url( '../images/body_bg.jpg ') repeat-x left bottom #e5e5e5;width:460px;position:fixed;left:50%;top:50%;margin:-130px 0 0 -230px;border:1px solid rgba(33,33,33,0.6);-moz-box-shadow:0 0 2px rgba(255,255,255,0.6) inset;-webkit-box-shadow:0 0 2px rgba(255,255,255,0.6) inset;box-shadow:0 0 2px rgba(255,255,255,0.6) inset;}
3
- #confirmBox h1,#confirmBox p{font:26px/1 'Cuprum ', 'Lucida Sans Unicode ', 'Lucida Grande ',sans-serif;background:url( '../images/header_bg.jpg ') repeat-x left bottom #f5f5f5;padding:18px 25px;text-shadow:1px 1px 0 rgba(255,255,255,0.6);color:#666;}
4
- #confirmBox h1{letter-spacing:0.3px;color:#888;margin:0;}
5
- #confirmBox p{background:none;font-size:16px;line-height:1.4;padding-top:35px;}
6
- #confirmButtons{padding:15px 0 25px;text-align:center;}
7
- #confirmBox .button{display:inline-block;background:url( '../images/buttons.png ') no-repeat;color:white;position:relative;height:33px;font:17px/33px 'Cuprum ', 'Lucida Sans Unicode ', 'Lucida Grande ',sans-serif;margin-right:15px;padding:0 35px 0 40px;text-decoration:none;border:none;}
8
- #confirmBox .button:last-child{margin-right:0;}
9
- #confirmBox .button span{position:absolute;top:0;right:-5px;background:url( '../images/buttons.png ') no-repeat;width:5px;height:33px}
10
- #confirmBox .blue{background-position:left top;text-shadow:1px 1px 0 #5889a2;-webkit-border-radius:0;-moz-border-radius:0;border-radius:0;}
11
- #confirmBox .blue span{background-position:-195px 0;}
12
- #confirmBox .blue:hover{background-position:left bottom;}
13
- #confirmBox .blue:hover span{background-position:-195px bottom;}
14
- #confirmBox .gray{background-position:-200px top;text-shadow:1px 1px 0 #707070;-webkit-border-radius:0;-moz-border-radius:0;border-radius:0;}
15
- #confirmBox .gray span{background-position:-395px 0;}
16
- #confirmBox .gray:hover{background-position:-200px bottom;}
17
- #confirmBox .gray:hover span{background-position:-395px bottom;}
18
- #maintenance-options { position: relative; width: 430px; }
19
- #maintenance-options h1 {font-size:35px;}
20
- #maintenance-options h1,
21
- #maintenance-options h2{float:left;font-family: 'Open Sans ',Arial,Helvetica,sans-serif;font-size:35px;font-weight:bold;}
22
- #maintenance-options select{margin:0 0 20px 6px;}
23
- #maintenance-options .nav{position:absolute;top:25px;right:50px;text-align:right;}
24
- #maintenance-options .nav li{display:inline;padding:0 5px;}
25
- #maintenance-options .nav li a{color:#656656;font-size:11px;}
26
- #maintenance-options .description{color:#ff0000;padding:0 0 20px 10px;width:450px;}
27
- #maintenance-options h3{margin:0 0 16px 4px;}
28
- #maintenance-options #steps{margin:0 0 20px 15px;padding:0 0 0 14px;}
29
- #maintenance-options #steps li{margin:0 0 5px 0;padding:0;}
30
- .theme-options{border:0;margin:0;padding:0;width:508px; float: left;}
31
- .theme-options h4{margin-top:0;}
32
- .theme-options div{border:0;margin:0 0 30px 0;padding:10px 0 0 0px;}
33
- .theme-options label{display:block;float:left;margin:0 0 5px;padding-right:15px;text-align:right;width:150px;padding-top:4px;}
34
- .theme-options input,#options #tabs .theme-options textarea{margin:0 0 15px 0;width:300px;}
35
- .theme-options textarea{height:80px;}
36
- .theme-options .explanation{margin-top:-15px;font-size:10px;color:#ccc;}
37
- #maintenance-options input.button{width:auto !important;}
38
- #maintenance-options #credits{color:#d54e21;font-size:11px;}
39
- .fl{width:100%;float:left;}
40
- #theme{width:20%}
41
- .title{display:block;float:left;width:100%; margin-bottom: 20px;}
42
  /*Checkbox*/
43
- .tzCheckBox{background:url( '../images/background.png ') no-repeat right bottom;display:inline-block;min-width:60px;height:33px;white-space:nowrap;position:relative;cursor:pointer;margin:18px 0 0 20px;}
44
- .tzCheckBox.checked{background-position:top left;margin:18px 0 0 6px;}
45
  .tzCheckBox .tzCBContent{color:white;line-height:31px;padding-right:38px;text-align:right;}
46
  .tzCheckBox.checked .tzCBContent{text-align:left;padding:0 0 0 38px;}
47
  .tzCBPart{background:url( '../images/background.png ') no-repeat left bottom;width:14px;position:absolute;top:0;left:-14px;height:33px;overflow:hidden;}
48
  .tzCheckBox.checked .tzCBPart{background-position:top right;left:auto;right:-14px;}
49
- .logo{float:left;margin-right:20px;padding-top:15px;}
50
- .button-primary{float: right; margin-right: 41px !important; width: 95px !important;}
 
 
 
 
 
51
 
52
- #contact-support {background-image: url("../images/mini-logo.png"); background-position: 0 3px; background-repeat: no-repeat; display: block; float: left; height: 30px; margin-left: 16px; margin-top: 50px; padding: 4px 42px;}
53
- #admin_bar_enabled {float: left; margin: 5px 0 0 0; width: 16px;}
54
- .theme-options .option-box {float:left; width:100%; display:block; padding:0; margin:0}
 
 
 
 
 
 
 
 
 
 
 
55
 
56
- @media screen and (-webkit-min-device-pixel-ratio:0) {
57
- .theme-options .option-box .option-box input#theme_logo,
58
- .theme-options .option-box .option-box input#body_bg { width:292px }
59
- }
60
 
61
- *+html #maintenance-options.wrap form #general .title h1 {line-height:1em !important; margin-top:15px; }
62
- *+html .time-block, .video-block, .html-block {margin-top:20px;}
63
- *+html .button-primary {width:100px !important}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #maintenance-options { position: relative; }
2
+ #maintenance-options #icon-maintenance {background:url('../images/icon.png') no-repeat center center transparent;}
3
+ #maintenance-options input.upload_btn { clear: left; display: block; float: left; margin: 20px 0; padding: 5px; text-align: center; width: 100%; }
4
+ #maintenance-options h2 {float:left}
5
+ #wpbody-content .metabox-holder {float:left; width:100%;}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
6
  /*Checkbox*/
7
+ .tzCheckBox {background:url( '../images/background.png ') no-repeat right bottom;display:inline-block;min-width:60px;height:33px;white-space:nowrap;position:relative;cursor:pointer;margin:8px 0 0 20px;}
8
+ .tzCheckBox.checked{background-position:top left;margin:8px 0 0 6px;}
9
  .tzCheckBox .tzCBContent{color:white;line-height:31px;padding-right:38px;text-align:right;}
10
  .tzCheckBox.checked .tzCBContent{text-align:left;padding:0 0 0 38px;}
11
  .tzCBPart{background:url( '../images/background.png ') no-repeat left bottom;width:14px;position:absolute;top:0;left:-14px;height:33px;overflow:hidden;}
12
  .tzCheckBox.checked .tzCBPart{background-position:top right;left:auto;right:-14px;}
13
+ .img-container {float:left; display:block; width: 300px;}
14
+ .upload_logo, .upload_background { float:right; }
15
+ .box-logo {max-width:298px; max-height:148px; height:148px; }
16
+ .box-bg {max-width:298px; max-height:298px; height:298px; background-size:cover;}
17
+ .box-logo, .box-bg {background-position: center center; background-repeat:no-repeat; position:relative; float:left; border:1px dashed #DFDFDF; width:100%; padding:0; margin:0;}
18
+ .img-container .boxes input.button.remove {position:absolute; display:none !important; right:10px; top:10px; }
19
+ .img-container .boxes:hover > input.button { display:block !important;cursor:pointer; }
20
 
21
+ .sidebar-promo { display: block; margin: 15px 0 0; min-height: 150px; }
22
+ .sidebar-promo h4 {color: #3E3E3E; font-size: 16px; font-weight: bold; margin: 0 0 20px; padding: 6px 0 6px 40px; }
23
+ .sidebar-promo h4.support {background: url("../images/support.png") no-repeat scroll 0 0 rgba(0, 0, 0, 0);}
24
+ .sidebar-promo h4.star {background: url("../images/star.png") no-repeat scroll 0 0 rgba(0, 0, 0, 0);}
25
+ .sidebar-promo p {color: #3E3E3E; font-family: Arial; font-size: 14px; line-height: 24px; margin: 0 0 1.5em; padding: 0; }
26
+ .sidebar-promo a {color:#21759b; text-decoration:none;}
27
+ .sidebar-promo.worker { background-image: url("../images/worker.png"); background-repeat:no-repeat; background-position: 100% 20px;}
28
+ #maintenance-options input#page_title,
29
+ #maintenance-options input#heading,
30
+ #maintenance-options textarea { width:100%; }
31
+ #maintenance-options input[type="checkbox"] { margin:0 5px 0 0; }
32
+ #maintenance-options #poststuff .metabox-holder .postbox-container.column-1 {float: left; width: 65%;}
33
+ #maintenance-options #poststuff .metabox-holder .postbox-container.column-2 {float: right; width: 28%; min-width:300px;}
34
+ #maintenance-options.wrap form p.submit {clear:both;}
35
 
36
+ @media screen and (max-width: 1024px) {
37
+ #maintenance-options #poststuff .metabox-holder .postbox-container.column-1 {float: left; width: 100%;}
38
+ #maintenance-options #poststuff .metabox-holder .postbox-container.column-2 {float: left; width: 100%;}
39
+ }
40
 
41
+ @media only screen
42
+ and (min-device-width : 320px)
43
+ and (max-device-width : 568px) {
44
+ #maintenance-options #poststuff .metabox-holder .postbox-container.column-1 {float: left; width: 100%;}
45
+ #maintenance-options #poststuff .metabox-holder .postbox-container.column-2 {float: left; width: 100%;}
46
+ }
47
+
48
+ @media only screen
49
+ and (min-device-width : 768px)
50
+ and (max-device-width : 1024px) {
51
+ #maintenance-options #poststuff .metabox-holder .postbox-container.column-1 {float: left; width: 100%;}
52
+ #maintenance-options #poststuff .metabox-holder .postbox-container.column-2 {float: left; width: 100%;}
53
+ }
54
+
55
+ @media screen and (-webkit-min-device-pixel-ratio:0) {
56
+ #maintenance-options input.upload_btn {padding:0;}
57
+ }
functions.php DELETED
@@ -1,102 +0,0 @@
1
- <?php
2
- function css_activate () {
3
- $str_css = "<link href='http://fonts.googleapis.com/css?family=Open+Sans:400,300,600,700|Arvo:400,400italic,700,700italic' rel='stylesheet' type='text/css'>";
4
- return $str_css;
5
- }
6
-
7
- function user_logout() {
8
- wp_safe_redirect(get_bloginfo('url'));
9
- exit;
10
- }
11
-
12
-
13
- function mt_template_redirect($template)
14
- {
15
- global $mt_options;
16
-
17
- $mt_options = mt_get_option();
18
- if ( $mt_options['logged_in_permission'] ) {
19
- mt_handle_template($mt_options);
20
- }
21
-
22
- }
23
-
24
- function mt_get_option()
25
- {
26
- $option = get_option( basename(dirname(__FILE__)) );
27
- if ( !$option ) {
28
- $option = array( 'state' => 'live', 'logged_in_permission' => true );
29
- add_option(basename(dirname(__FILE__)), $option);
30
- }
31
- return $option;
32
- }
33
-
34
-
35
- function mt_update_option($data)
36
- {
37
- return update_option(basename(dirname(__FILE__)), $data);
38
- }
39
-
40
-
41
- function mt_get_lib_var()
42
- {
43
- global $mt_themes;
44
- $mt_themes = array();
45
-
46
- $dir = dirname(__FILE__).'/'.LIB_DIR.'/';
47
- if ($handle = opendir($dir)) {
48
- while (false !== ($file = readdir($handle))) {
49
- if ($file != "." && $file != ".." && !is_file($file) && file_exists($dir.$file) ) {
50
- $mt_themes[] = ucfirst($file);
51
- }
52
- }
53
- closedir($handle);
54
- }
55
-
56
- return true;
57
- }
58
-
59
-
60
- function mt_handle_template($option)
61
- {
62
- $dir = get_template_directory().'/';
63
- if (!is_user_logged_in()) {
64
- switch ( $option['state'] ) {
65
- case 'maintenance':
66
- {
67
- /* load selected theme */
68
- if ( isset($option['expiry_date']) ) {
69
- list( $date,$time ) = explode( '|', $option['expiry_date'] );
70
- list( $month, $day, $year ) = explode( '.', $date );
71
- list( $hour, $minute, $second ) = explode ( ':', $time );
72
- $timestamp = mktime( $hour, $minute, $second, $month, $day, $year );
73
-
74
- /* if page should be opened now, return true and break function */
75
- if ( time() > $timestamp ) {
76
- return true;
77
- }
78
- }
79
-
80
- $lib_dir = dirname( __FILE__ ) . '/' . LIB_DIR . '/';
81
- if ( file_exists( $lib_dir . 'index.php' ) ) {
82
- mt_prepare_template_vars();
83
- include_once $lib_dir . 'index.php';
84
- exit();
85
- }
86
- }
87
- break;
88
- }
89
-
90
- }
91
- }
92
-
93
-
94
- function mt_prepare_template_vars()
95
- {
96
- global $mt_lib, $mt_options;
97
- $mt_lib = $mt_options['lib_options'];
98
- return true;
99
-
100
- }
101
-
102
- ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
images/background.png CHANGED
Binary file
images/body_bg.jpg DELETED
Binary file
images/buttons.png DELETED
Binary file
images/header_bg.jpg DELETED
Binary file
images/ie.png DELETED
Binary file
images/mini-logo.png DELETED
Binary file
images/star.png ADDED
Binary file
images/support.png ADDED
Binary file
images/worker.png ADDED
Binary file
includes/admin.php ADDED
@@ -0,0 +1,88 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ add_action( 'admin_menu', 'maintenance_admin_setup' );
3
+
4
+ function maintenance_admin_setup() {
5
+ global $maintenance_variable;
6
+ $maintenance_variable->options_page = add_menu_page('Maintenance', 'Maintenance', 'manage_options', 'maintenance', 'manage_options', MAINTENANCE_URI . '/images/icon-small.png');
7
+ add_action( "admin_init", 'mt_register_settings');
8
+ add_action( "admin_head-{$maintenance_variable->options_page}", 'maintenace_metaboxes_scripts' );
9
+ add_action( "admin_print_styles-{$maintenance_variable->options_page}", 'admin_print_custom_styles');
10
+ add_action( "load-{$maintenance_variable->options_page}", 'maintenance_page_add_meta_boxes' );
11
+ }
12
+
13
+ function maintenance_page_add_meta_boxes() {
14
+ global $maintenance_variable;
15
+ do_action('add_meta_boxes', $maintenance_variable->options_page);
16
+
17
+ }
18
+
19
+ function mt_register_settings() {
20
+ if ( !empty($_POST['lib_options']) && check_admin_referer('maintenance_edit_post','maintenance_nonce') ) {
21
+ if (!isset($_POST['lib_options']['state'])) { $_POST['lib_options']['state'] = 0; }
22
+ else { $_POST['lib_options']['state'] = 1; }
23
+
24
+ if (isset($_POST['lib_options']['htmlcss'])) {
25
+ $_POST['lib_options']['htmlcss'] = wp_kses_post(stripslashes($_POST['lib_options']['htmlcss']));
26
+ }
27
+ if (isset($_POST['lib_options'])) {
28
+ update_option( 'maintenance_options', $_POST['lib_options']);
29
+ }
30
+ }
31
+ }
32
+
33
+ function admin_print_custom_styles() {
34
+ if( function_exists( 'wp_enqueue_media' ) ){
35
+ wp_enqueue_media();
36
+ } else {
37
+ wp_enqueue_script('media-upload');
38
+ wp_enqueue_script('thickbox');
39
+ wp_enqueue_style ('thickbox');
40
+ }
41
+
42
+ wp_enqueue_script( 'common' );
43
+ wp_enqueue_script( 'wp-lists' );
44
+ wp_enqueue_script( 'postbox' );
45
+
46
+ wp_enqueue_style ('arvo', 'http://fonts.googleapis.com/css?family=Open+Sans:400,300,600,700|Arvo:400,400italic,700,700italic' );
47
+ wp_enqueue_style ('wp-color-picker' );
48
+
49
+ wp_enqueue_script ('uplaods_', MAINTENANCE_URI .'js/uploads_.min.js' );
50
+ wp_enqueue_script ('maintenance', MAINTENANCE_URI .'js/init.min.js', array( 'wp-color-picker' ), false, true );
51
+ wp_enqueue_style ('maintenance', MAINTENANCE_URI .'css/admin.css' );
52
+ }
53
+
54
+ function manage_options() {
55
+ generate_plugin_page();
56
+ }
57
+
58
+ function generate_plugin_page() {
59
+ global $maintenance_variable;
60
+ $mt_option = mt_get_plugin_options(true);
61
+ ?>
62
+ <div id="maintenance-options" class="wrap">
63
+ <form method="post" action="" enctype="multipart/form-data" name="options-form">
64
+ <?php wp_nonce_field('maintenance_edit_post','maintenance_nonce'); ?>
65
+ <?php wp_nonce_field('meta-box-order', 'meta-box-order-nonce', false ); ?>
66
+ <?php wp_nonce_field('closedpostboxes', 'closedpostboxesnonce', false ); ?>
67
+ <?php screen_icon(); ?>
68
+ <h2>Maintenance</h2>
69
+ <input type="checkbox" id="state" name="lib_options[state]" <?php checked($mt_option['state'], 1); ?> />
70
+ <div class="clear"></div>
71
+ <div id="poststuff">
72
+ <div class="metabox-holder">
73
+ <div id="all-fileds" class="postbox-container column-1 normal">
74
+ <?php do_meta_boxes($maintenance_variable->options_page,'normal',null); ?>
75
+ <?php do_meta_boxes($maintenance_variable->options_page,'advanced',null); ?>
76
+ </div>
77
+
78
+ <div id="promo" class="postbox-container column-2 normal">
79
+ <?php do_meta_boxes($maintenance_variable->options_page,'side',null); ?>
80
+ </div>
81
+
82
+ </div>
83
+ </div>
84
+ <?php submit_button(__('Save changes', 'maintenance'), 'primary'); ?>
85
+ </form>
86
+ </div>
87
+ <?php
88
+ }
includes/functions.php ADDED
@@ -0,0 +1,254 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ function mt_get_plugin_options($is_current = false) {
4
+ $saved = (array) get_option('maintenance_options');
5
+ if (!$is_current) {
6
+ $defaults = mt_get_default_array();
7
+ $defaults = apply_filters('mt_plugin_default_options', $defaults );
8
+ $options = wp_parse_args($saved, $defaults );
9
+ $options = array_intersect_key( $options, $defaults );
10
+ } else {
11
+ $options = $saved;
12
+ }
13
+
14
+ return $options;
15
+ }
16
+
17
+ function generate_input_filed($title, $id, $name, $value) {
18
+ $out_filed = '';
19
+ $out_filed .= '<tr valign="top">';
20
+ $out_filed .= '<th scope="row">' . esc_attr($title) .'</th>';
21
+ $out_filed .= '<td>';
22
+ $out_filed .= '<filedset>';
23
+ $out_filed .= '<input type="text" id="'.esc_attr($id).'" name="lib_options['.$name.']" value="'. wp_kses_post(stripslashes($value)) .'" />';
24
+ $out_filed .= '</filedset>';
25
+ $out_filed .= '</td>';
26
+ $out_filed .= '</tr>';
27
+ echo $out_filed;
28
+ }
29
+
30
+
31
+ function generate_textarea_filed($title, $id, $name, $value) {
32
+ $out_filed = '';
33
+ $out_filed .= '<tr valign="top">';
34
+ $out_filed .= '<th scope="row">' . esc_attr($title) .'</th>';
35
+ $out_filed .= '<td>';
36
+ $out_filed .= '<filedset>';
37
+ $out_filed .= '<textarea name="lib_options['.$name.']" id="'.esc_attr($id).'" cols="30" rows="10">'. wp_kses_post(stripslashes($value)) .'</textarea>';
38
+ $out_filed .= '</filedset>';
39
+ $out_filed .= '</td>';
40
+ $out_filed .= '</tr>';
41
+ echo $out_filed;
42
+ }
43
+
44
+ function generate_check_filed($title, $label, $id, $name, $value) {
45
+ $out_filed = '';
46
+ $out_filed .= '<tr valign="top">';
47
+ $out_filed .= '<th scope="row">' . esc_attr($title) .'</th>';
48
+ $out_filed .= '<td>';
49
+ $out_filed .= '<filedset>';
50
+ $out_filed .= '<label for='.esc_attr($id).'>';
51
+ $out_filed .= '<input type="checkbox" id="'.esc_attr($id).'" name="lib_options['.$name.']" value="1" '. checked( true, $value, false ) .'/>';
52
+ $out_filed .= $label;
53
+ $out_filed .= '</label>';
54
+ $out_filed .= '</filedset>';
55
+ $out_filed .= '</td>';
56
+ $out_filed .= '</tr>';
57
+ echo $out_filed;
58
+ }
59
+
60
+ function generate_image_filed($title, $id, $name, $value, $class, $name_btn, $class_btn) {
61
+ $out_filed = '';
62
+
63
+ $out_filed .= '<tr valign="top">';
64
+ $out_filed .= '<th scope="row">' . esc_attr($title) .'</th>';
65
+ $out_filed .= '<td>';
66
+ $out_filed .= '<filedset>';
67
+ $out_filed .= '<input type="hidden" id="'.esc_attr($id).'" name="lib_options['.$name.']" value="'.esc_attr($value).'" />';
68
+ $out_filed .= '<div class="img-container">';
69
+ $url = '';
70
+ if($value != '') {
71
+ $image = wp_get_attachment_image_src( $value, 'full');
72
+ $url = esc_url($image[0]);
73
+ }
74
+
75
+ $out_filed .= '<div class="'.esc_attr($class).'" style="background-image:url('.$url.')">';
76
+ if ( $value ) {
77
+ $out_filed .= '<input class="button button-primary delete-img remove" type="button" value="x" />';
78
+ }
79
+ $out_filed .= '</div>';
80
+ $out_filed .= '<input type="button" class="'.esc_attr($class_btn).'" value="'.esc_attr($name_btn).'"/>';
81
+
82
+ $out_filed .= '</div>';
83
+ $out_filed .= '</filedset>';
84
+ $out_filed .= '</td>';
85
+ $out_filed .= '</tr>';
86
+ echo $out_filed;
87
+ }
88
+
89
+ function get_color_field($title, $id, $name, $value, $default_color) {
90
+ $out_filed = '';
91
+ $out_filed .= '<tr valign="top">';
92
+ $out_filed .= '<th scope="row">'. esc_attr($title) .'</th>';
93
+ $out_filed .= '<td>';
94
+ $out_filed .= '<filedset>';
95
+ $out_filed .= '<input type="text" id="'.esc_attr($id).'" name="lib_options['.$name.']" data-default-color="'.esc_attr($default_color).'" value="'. wp_kses_post(stripslashes($value)) .'" />';
96
+ $out_filed .= '<filedset>';
97
+ $out_filed .= '</td>';
98
+ $out_filed .= '</tr>';
99
+ echo $out_filed;
100
+ }
101
+
102
+ function maintenance_page_create_meta_boxes() {
103
+ global $maintenance_variable;
104
+ add_meta_box( 'maintenance-general', __( 'General Settings', 'maintenance' ), 'add_data_fields', $maintenance_variable->options_page, 'normal', 'default');
105
+ add_meta_box( 'promo-extended', __( 'Pro version', 'maintenance' ), 'maintenanace_extended_version', $maintenance_variable->options_page, 'side', 'default' );
106
+ add_meta_box( 'promo-content', __( 'Support', 'maintenance' ), 'maintenanace_contact_support', $maintenance_variable->options_page, 'side', 'default' );
107
+ }
108
+ add_action('add_meta_boxes', 'maintenance_page_create_meta_boxes', 10);
109
+
110
+ function add_data_fields ($object, $box) {
111
+ $mt_option = mt_get_plugin_options(true);
112
+ echo '<table class="form-table">';
113
+ echo '<tbody>';
114
+ generate_input_filed(__('Page title', 'maintenance'), 'page_title', 'page_title', wp_kses_post($mt_option['page_title']));
115
+ generate_input_filed(__('Headline', 'maintenance'), 'heading', 'heading', wp_kses_post($mt_option['heading']));
116
+ generate_textarea_filed(__('Description', 'maintenance'), 'description', 'description', wp_kses_post($mt_option['description']));
117
+ generate_image_filed(__('Logo', 'maintenance'), 'logo', 'logo', intval($mt_option['logo']), 'boxes box-logo', __('Upload Logo', 'maintenance'), 'upload_logo upload_btn button');
118
+ do_action('maintenance_background_field');
119
+ do_action('maintenance_color_fields');
120
+ generate_check_filed(__('Admin bar', 'maintenance'), __('Show admin bar', 'maintenance'), 'admin_bar_enabled', 'admin_bar_enabled', isset($mt_option['admin_bar_enabled']));
121
+ generate_check_filed(__('503', 'maintenance'), __('Service temporarily unavailable', 'maintenance'), '503_enabled', '503_enabled', isset($mt_option['503_enabled']));
122
+ generate_input_filed(__('Blur intensity', 'maintenance'), 'blur_intensity', 'blur_intensity', intval($mt_option['blur_intensity']));
123
+ generate_check_filed(__('Background blur', 'maintenance'), __('Apply a blur', 'maintenance'), 'is_blur', 'is_blur', isset($mt_option['is_blur']));
124
+ echo '</tbody>';
125
+ echo '</table>';
126
+ }
127
+
128
+ function get_background_fileds_action() {
129
+ $mt_option = mt_get_plugin_options(true);
130
+ generate_image_filed(__('Background image', 'maintenance'), 'body_bg', 'body_bg', esc_attr($mt_option['body_bg']), 'boxes box-bg', __('Upload Background', 'maintenance'), 'upload_background upload_btn button');
131
+ }
132
+ add_action ('maintenance_background_field', 'get_background_fileds_action', 10);
133
+
134
+ function get_color_fileds_action() {
135
+ $mt_option = mt_get_plugin_options(true);
136
+ get_color_field(__('Background color', 'maintenance'), 'body_bg_color', 'body_bg_color', esc_attr($mt_option['body_bg_color']), '#333333');
137
+ get_color_field(__('Font color', 'maintenance'), 'font_color', 'font_color', esc_attr($mt_option['font_color']), '#ffffff');
138
+ }
139
+ add_action ('maintenance_color_fields', 'get_color_fileds_action', 10);
140
+
141
+
142
+ function maintenanace_contact_support() {
143
+ $promo_text = '';
144
+ $promo_text .= '<div class="sidebar-promo" id="sidebar-promo">';
145
+ $promo_text .= '<h4 class="support">'. __('Have any questions?','maintenance'). '</h3>';
146
+ $promo_text .= '<p>'. sprintf(__('You may find answers to your questions at <a target="_blank" href="http://wordpress.org/support/plugin/maintenance">support forum</a><br>You may <a target="_blank" href="mailto:mail@fruitfulcode.com?subject=Maintenance plugin">contact us</a> with customization requests and suggestions.<br> Please visit our website to learn about us and our services <a href="%1$s" title="%2$s">%2$s</a>', 'maintenance'),
147
+ 'http://fruitfulcode.com',
148
+ 'fruitfulcode.com'
149
+ ).'</p>';
150
+ $promo_text .= '</div>';
151
+ echo $promo_text;
152
+ }
153
+
154
+ function maintenanace_extended_version() {
155
+ $promo_text = '';
156
+ $promo_text .= '<div class="sidebar-promo worker" id="sidebar-promo">';
157
+ $promo_text .= '<h4 class="star">'. __('Extended functionality','maintenance') .'</h3>';
158
+ $promo_text .= '<p>' . sprintf(__('Purchase <a href="http://codecanyon.net/item/maintenance-wordpress-plugin/2781350?ref=fruitfulcode" target="_blank">PRO</a> version with extended functionality. %1$s If you like our plugin please <a target="_blank" href="http://wordpress.org/support/view/plugin-reviews/maintenance?filter=5">rate it</a>, <a title="leave feedbacks" href="%2$s" target="_blank">leave feedbacks</a>.', 'maintenance'),
159
+ '<br />',
160
+ 'http://wordpress.org/support/view/plugin-reviews/maintenance') .'</p>';
161
+ $promo_text .= sprintf('<a class="button button-primary" title="%1$s" href="%2$s" target="_blank">%1$s</a>',
162
+ __('Demo website', 'maintenance'),
163
+ 'http://plugins.fruitfulcode.com/maintenance/'
164
+ );
165
+ $promo_text .= '</div>';
166
+ echo $promo_text;
167
+ }
168
+ function load_maintenace_page() {
169
+ global $mt_options;
170
+ $vCurrDate = '';
171
+ $mt_options = mt_get_plugin_options(true);
172
+ if (!is_user_logged_in()) {
173
+ if ($mt_options['state']) {
174
+ if (!empty($mt_options['expiry_date'])) {
175
+ $vCurrDate = DateTime::createFromFormat('d/m/Y', $mt_options['expiry_date']);
176
+ list( $date, $time ) = explode( ' ', current($vCurrDate));
177
+ list( $year, $month, $day ) = explode( '-', $date );
178
+ list( $hour, $minute, $second ) = explode ( ':', $time );
179
+ $timestamp = mktime( $hour, $minute, $second, $month, $day, $year );
180
+
181
+ if ( time() > $timestamp ) {
182
+ return true;
183
+ }
184
+ }
185
+
186
+ if ( file_exists (MAINTENANCE_LOAD . 'index.php')) {
187
+ include_once MAINTENANCE_LOAD . 'index.php';
188
+ exit;
189
+ }
190
+ }
191
+ }
192
+ }
193
+
194
+ function maintenace_metaboxes_scripts() {
195
+ global $maintenance_variable;
196
+ ?>
197
+ <script type="text/javascript">
198
+ //<![CDATA[
199
+ jQuery(document).ready( function() {
200
+ jQuery('.if-js-closed').removeClass('if-js-closed').addClass('closed');
201
+ postboxes.add_postbox_toggles( '<?php echo esc_js($maintenance_variable->options_page); ?>' );
202
+ });
203
+ //]]>
204
+ </script>
205
+ <?php }
206
+
207
+ function maintenace_add_toolbar_items(){
208
+ global $wp_admin_bar, $wpdb;
209
+ $mt_options = mt_get_plugin_options(true);
210
+ $check = '';
211
+ if ( !is_super_admin() || !is_admin_bar_showing() ) return;
212
+ $url_to = admin_url( 'admin.php?page=maintenance');
213
+
214
+ if ($mt_options['state']) {
215
+ $check = 'On';
216
+ } else {
217
+ $check = 'Off';
218
+ }
219
+ $wp_admin_bar->add_menu( array( 'id' => 'maintenance_options', 'title' => __( 'Maintenace', 'maintenance' ) . ' is ' . $check, 'href' => $url_to, 'meta' => array( 'title' => __( 'Maintenace', 'maintenance' ) . ' is ' . $check)));
220
+ }
221
+
222
+
223
+ function hex2rgb($hex) {
224
+ $hex = str_replace("#", "", $hex);
225
+
226
+ if(strlen($hex) == 3) {
227
+ $r = hexdec(substr($hex,0,1).substr($hex,0,1));
228
+ $g = hexdec(substr($hex,1,1).substr($hex,1,1));
229
+ $b = hexdec(substr($hex,2,1).substr($hex,2,1));
230
+ } else {
231
+ $r = hexdec(substr($hex,0,2));
232
+ $g = hexdec(substr($hex,2,2));
233
+ $b = hexdec(substr($hex,4,2));
234
+ }
235
+ $rgb = array($r, $g, $b);
236
+ return implode(",", $rgb);
237
+ }
238
+
239
+ function mt_get_default_array() {
240
+ return array(
241
+ 'state' => true,
242
+ 'page_title' => __('Website is under construction', 'maintenance'),
243
+ 'heading' => __('Maintenance mode is on', 'maintenance'),
244
+ 'description' => __('Website will be available soon', 'maintenance'),
245
+ 'logo' => '',
246
+ 'body_bg' => '',
247
+ 'body_bg_color' => '#333333',
248
+ 'font_color' => '#ffffff',
249
+ 'is_blur' => false,
250
+ 'blur_intensity' => 5,
251
+ 'admin_bar_enabled' => true,
252
+ '503_enabled' => true
253
+ );
254
+ }
includes/update.php ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ add_action( 'admin_init', 'maintenance_version_check' );
3
+ function maintenance_version_check() {
4
+ $old_version = get_option( 'maintenance_db_version' );
5
+ $options = get_option( 'maintenance_options' );
6
+
7
+ if ( empty( $old_version ) && false === $options )
8
+ maintenance_install();
9
+ elseif ( empty( $old_version ) && !empty( $options ) )
10
+ maintenance_update();
11
+ elseif ( intval( $old_version ) < intval( MAINTENANCE_DB_VERSION ) )
12
+ maintenance_update();
13
+ }
14
+
15
+ function maintenance_install() {
16
+ $options = mt_get_plugin_options();
17
+ add_option( 'maintenance_db_version', MAINTENANCE_DB_VERSION );
18
+ add_option( 'maintenance_options', $options);
19
+ }
20
+
21
+ function maintenance_update() {
22
+ $options = mt_get_plugin_options();
23
+ $settings = get_option( 'maintenance_options' );
24
+
25
+ update_option( 'maintenance_db_version', MAINTENANCE_DB_VERSION);
26
+
27
+ foreach ( $options as $key => $value ) {
28
+ if ( !isset( $settings[$key] ) )
29
+ $settings[$key] = $value;
30
+ }
31
+ update_option( 'maintenance_options', $options);
32
+ }
index.php DELETED
@@ -1,79 +0,0 @@
1
- <?php
2
- /*
3
- Plugin Name: Maintenance
4
- Plugin URI: http://wordpress.org/extend/plugins/maintenance/
5
- Description: Take your site down from public view with a click of a button hiding the site when you need to change a few things or run an upgrade, making it only accessible by login and password. There is also an area to add a custom message which will be shown to the users while your site is down. Users stay on the same page when they input wrong initials.
6
- Version: 1.2.3
7
- Author: fruitfulcode
8
- Author URI: http://fruitfulcode.com
9
- License: GPL2
10
- */
11
- /* Copyright 2013 Fruitful Code (email : support@fruitfulcode.com)
12
-
13
- This program is free software; you can redistribute it and/or modify
14
- it under the terms of the GNU General Public License, version 2, as
15
- published by the Free Software Foundation.
16
-
17
- This program is distributed in the hope that it will be useful,
18
- but WITHOUT ANY WARRANTY; without even the implied warranty of
19
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20
- GNU General Public License for more details.
21
-
22
- You should have received a copy of the GNU General Public License
23
- along with this program; if not, write to the Free Software
24
- Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
25
- */
26
-
27
-
28
- define( 'LIB_DIR', 'lib' );
29
- define( 'PLUGIN_URL', WP_PLUGIN_URL . '/' . basename (dirname ( __FILE__ ) ) . '/' );
30
-
31
- include_once 'functions.php';
32
-
33
- $mt_options = mt_get_option();
34
-
35
- if ($mt_options['state'] == "maintenance") {
36
- if (($mt_options['lib_options']['admin_bar_enabled'] == "1")) {
37
- add_filter('show_admin_bar', '__return_true');
38
- } else {
39
- add_filter('show_admin_bar', '__return_false');
40
- }
41
- }
42
-
43
-
44
- /*maintenance mode is active*/
45
-
46
- add_action( 'template_redirect', 'mt_template_redirect' );
47
- add_action( 'admin_menu', 'dashboard_menu' );
48
- add_action( 'wp_logout','user_logout');
49
- register_deactivation_hook( __FILE__, 'deactivate_plugin' );
50
-
51
- include_once 'page-options.php';
52
-
53
- function dashboard_menu()
54
- {
55
- $page = add_menu_page('Maintenance', 'Maintenance', 'manage_options', 'maintenance', 'mt_manage_options', PLUGIN_URL . '/images/icon-small.png');
56
- add_action( "admin_print_styles-$page", 'admin_head' );
57
- }
58
-
59
-
60
- function mn_plugin_init() {
61
- load_plugin_textdomain( 'maintenance', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );
62
- }
63
- add_action('plugins_loaded', 'mn_plugin_init');
64
-
65
- function admin_head()
66
- {
67
-
68
- echo css_activate ();
69
- wp_enqueue_script( 'maintenance', PLUGIN_URL .'js/init.js' );
70
- wp_enqueue_style ('maintenance', PLUGIN_URL .'css/admin.css' );
71
- }
72
-
73
- function deactivate_plugin()
74
- {
75
- return delete_option( basename(dirname(__FILE__)) );
76
- }
77
-
78
-
79
- ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
js/init.js CHANGED
@@ -1,8 +1,5 @@
1
  jQuery(window).ready(function(){
2
  jQuery.fn.tzCheckbox = function(options){
3
-
4
- // Default On / Off labels:
5
-
6
  options = jQuery.extend({
7
  labels : ['ON','OFF']
8
  },options);
@@ -10,38 +7,40 @@ jQuery(window).ready(function(){
10
  return this.each(function(){
11
  var originalCheckBox = jQuery(this),
12
  labels = [];
13
-
14
- // Checking for the data-on / data-off HTML5 data attributes:
15
  if(originalCheckBox.data('on')){
16
  labels[0] = originalCheckBox.data('on');
17
  labels[1] = originalCheckBox.data('off');
18
  }
19
  else labels = options.labels;
20
-
21
- // Creating the new checkbox markup:
22
  var checkBox = jQuery('<span>');
23
  checkBox.addClass(this.checked?' tzCheckBox checked':'tzCheckBox');
24
  checkBox.prepend('<span class="tzCBContent">'+labels[this.checked?0:1]+ '</span><span class="tzCBPart"></span>');
25
-
26
- // Inserting the new checkbox, and hiding the original:
27
  checkBox.insertAfter(originalCheckBox.hide());
28
 
29
  checkBox.click(function(){
30
  checkBox.toggleClass('checked');
31
-
32
  var isChecked = checkBox.hasClass('checked');
33
-
34
- // Synchronizing the original checkbox:
35
  originalCheckBox.attr('checked',isChecked);
36
  checkBox.find('.tzCBContent').html(labels[isChecked?0:1]);
37
  });
38
-
39
- // Listening for changes on the original and affecting the new one:
40
  originalCheckBox.bind('change',function(){
41
  checkBox.click();
42
  });
43
  });
44
  };
45
 
46
- jQuery('#ch_location').tzCheckbox({labels:['On','Off']});
47
- });
 
 
 
 
 
 
 
 
 
 
 
 
1
  jQuery(window).ready(function(){
2
  jQuery.fn.tzCheckbox = function(options){
 
 
 
3
  options = jQuery.extend({
4
  labels : ['ON','OFF']
5
  },options);
7
  return this.each(function(){
8
  var originalCheckBox = jQuery(this),
9
  labels = [];
 
 
10
  if(originalCheckBox.data('on')){
11
  labels[0] = originalCheckBox.data('on');
12
  labels[1] = originalCheckBox.data('off');
13
  }
14
  else labels = options.labels;
 
 
15
  var checkBox = jQuery('<span>');
16
  checkBox.addClass(this.checked?' tzCheckBox checked':'tzCheckBox');
17
  checkBox.prepend('<span class="tzCBContent">'+labels[this.checked?0:1]+ '</span><span class="tzCBPart"></span>');
 
 
18
  checkBox.insertAfter(originalCheckBox.hide());
19
 
20
  checkBox.click(function(){
21
  checkBox.toggleClass('checked');
 
22
  var isChecked = checkBox.hasClass('checked');
 
 
23
  originalCheckBox.attr('checked',isChecked);
24
  checkBox.find('.tzCBContent').html(labels[isChecked?0:1]);
25
  });
26
+
 
27
  originalCheckBox.bind('change',function(){
28
  checkBox.click();
29
  });
30
  });
31
  };
32
 
33
+ jQuery('#state').tzCheckbox({labels:['On','Off']});
34
+ var vColorPickerOptions = {
35
+ defaultColor: false,
36
+ change: function(event, ui){},
37
+ clear: function() {},
38
+ hide: true,
39
+ palettes: true
40
+ };
41
+
42
+ jQuery('#body_bg_color, #font_color, #body_bg_blur_color').wpColorPicker(vColorPickerOptions);
43
+
44
+
45
+
46
+ });
js/init.min.js ADDED
@@ -0,0 +1 @@
 
1
+ jQuery(window).ready(function(){jQuery.fn.tzCheckbox=function(options){options=jQuery.extend({labels:["ON","OFF"]},options);return this.each(function(){var originalCheckBox=jQuery(this),labels=[];if(originalCheckBox.data("on")){labels[0]=originalCheckBox.data("on");labels[1]=originalCheckBox.data("off")}else labels=options.labels;var checkBox=jQuery("<span>");checkBox.addClass(this.checked?" tzCheckBox checked":"tzCheckBox");checkBox.prepend('<span class="tzCBContent">'+labels[this.checked?0:1]+'</span><span class="tzCBPart"></span>'); checkBox.insertAfter(originalCheckBox.hide());checkBox.click(function(){checkBox.toggleClass("checked");var isChecked=checkBox.hasClass("checked");originalCheckBox.attr("checked",isChecked);checkBox.find(".tzCBContent").html(labels[isChecked?0:1])});originalCheckBox.bind("change",function(){checkBox.click()})})};jQuery("#state").tzCheckbox({labels:["On","Off"]});var vColorPickerOptions={defaultColor:false,change:function(event,ui){},clear:function(){},hide:true,palettes:true};jQuery("#body_bg_color, #font_color, #body_bg_blur_color").wpColorPicker(vColorPickerOptions)});
js/uploads_.js ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ function uploads_multimedia_init (title, btnName, editing, multiple) {
2
+ var outArray = [];
3
+ var file_frame;
4
+ if (file_frame) {
5
+ file_frame.open();
6
+ return;
7
+ }
8
+
9
+ file_frame = wp.media.editor.send.attachment = wp.media({
10
+ title: title,
11
+ button: {
12
+ text: btnName
13
+ },
14
+ editing: editing,
15
+ multiple: multiple,
16
+ });
17
+ return file_frame;
18
+ }
19
+
20
+ jQuery(document).ready(function() {
21
+ jQuery('.upload_btn').live('click', function( event ) {
22
+ event.preventDefault();
23
+ var vLinkElem = jQuery(this);
24
+ var customData = vLinkElem.data('imagetype');
25
+ var customClass = '';
26
+
27
+ var file_frame = uploads_multimedia_init('Upload Image', 'Select Image', true, false);
28
+ file_frame.on( 'select', function() {
29
+ var selection = file_frame.state().get('selection');
30
+ selection.map( function( attachment ) {
31
+ attachment = attachment.toJSON();
32
+ var image_url = attachment.url,
33
+ image_id = attachment.id;
34
+
35
+ vLinkElem.parent().find('.boxes').css('background-image', 'url(' + image_url + ')');
36
+ vLinkElem.parent().find('.boxes').append('<input class="button delete-img remove" type="submit" name="remove_bg" value="x" />');
37
+ vLinkElem.parent().parent().find('input[type="hidden"]').val(image_id);
38
+ });
39
+
40
+ });
41
+
42
+ file_frame.open();
43
+ return false;
44
+ });
45
+
46
+ jQuery('.delete-img').live('click', function( event ) {
47
+ event.preventDefault();
48
+ var vLinkElem = jQuery(this);
49
+ vLinkElem.parent().css('background-image', 'none');
50
+ vLinkElem.parent().parent().parent().find('input[type="hidden"]').val('');
51
+ vLinkElem.remove();
52
+ return false;
53
+ });
54
+
55
+ });
js/uploads_.min.js ADDED
@@ -0,0 +1 @@
 
1
+ function uploads_multimedia_init(e,f,b,a){var c=[];var d;if(d){d.open();return}d=wp.media.editor.send.attachment=wp.media({title:e,button:{text:f},editing:b,multiple:a});return d}jQuery(document).ready(function(){jQuery(".upload_btn").live("click",function(c){c.preventDefault();var e=jQuery(this);var d=e.data("imagetype");var b="";var a=uploads_multimedia_init("Upload Image","Select Image",true,false);a.on("select",function(){var f=a.state().get("selection");f.map(function(h){h=h.toJSON();var i=h.url,g=h.id;e.parent().find(".boxes").css("background-image","url("+i+")");e.parent().find(".boxes").append('<input class="button delete-img remove" type="submit" name="remove_bg" value="x" />');e.parent().parent().find('input[type="hidden"]').val(g)})});a.open();return false});jQuery(".delete-img").live("click",function(a){a.preventDefault();var b=jQuery(this);b.parent().css("background-image","none");b.parent().parent().parent().find('input[type="hidden"]').val("");b.remove();return false})});
languages/maintenance-ru_RU.mo CHANGED
Binary file
languages/maintenance-ru_RU.po CHANGED
@@ -1,81 +1,193 @@
1
  msgid ""
2
  msgstr ""
3
  "Project-Id-Version: maintenance\n"
4
- "POT-Creation-Date: 2012-12-21 15:51+0200\n"
5
- "PO-Revision-Date: 2012-12-21 16:11+0200\n"
6
  "Last-Translator: \n"
7
- "Language-Team: fruitfulcode.com\n"
8
- "Language: Russian\n"
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
  "X-Generator: Poedit 1.5.4\n"
13
- "X-Poedit-KeywordsList: _;gettext;gettext_noop;__;_e\n"
14
- "X-Poedit-Basepath: C:\\wamp\\www\\yakovlev\\wr_browser\\wp-content\\plugins"
15
- "\\maintenance\n"
16
- "X-Poedit-SearchPath-0: C:\\wamp\\www\\yakovlev\\wr_browser\\wp-content"
17
- "\\plugins\\maintenance\\lib\n"
18
 
19
- #: lib/index.php:94
20
- msgid "Your session has expired."
21
- msgstr "Ваша сессия истеклаю"
22
 
23
- #: lib/index.php:195
24
- msgid "Sign In"
25
- msgstr "Войти"
26
 
27
- #: lib/options.php:2
 
 
 
 
 
 
 
 
 
 
28
  msgid "Page title"
29
  msgstr "Заголовок страницы"
30
 
31
- #: lib/options.php:3
32
- msgid "Website is under construction"
33
- msgstr "Сайт находится на стадии разработки"
34
-
35
- #: lib/options.php:4
36
  msgid "Headline"
37
  msgstr "Заголовок"
38
 
39
- #: lib/options.php:5
40
- msgid "Customer login"
41
- msgstr "Вход для администратора"
42
-
43
- #: lib/options.php:6
44
  msgid "Description"
45
  msgstr "Описание"
46
 
47
- #: lib/options.php:7
48
- msgid "Please login to see website"
49
- msgstr "Пожалуйста, войдите, чтобы сайт стал доступным"
50
-
51
- #: lib/options.php:8
52
  msgid "Logo"
53
  msgstr "Логотип"
54
 
55
- #: lib/options.php:11
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
56
  msgid "Background image"
57
  msgstr "Фоновое изображение"
58
 
59
- #: lib/options.php:14
 
 
 
 
60
  msgid "Background color"
61
  msgstr "Цвет фона"
62
 
63
- #: lib/options.php:16
64
- msgid "Admin Bar"
65
- msgstr "Админ. панель"
66
 
67
- #: page-options:44
68
- msgid "Save changes"
69
- msgstr "Сохранить"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
70
 
71
- #: page-options:52
72
- msgid "Contact Support"
73
- msgstr "Контактная информация"
74
 
75
- #: page-options:54
76
- msgid "Premium version"
77
- msgstr "Premium версия"
78
 
79
- #: page-options:55
80
- msgid "Check out our extended version of plugin with new features"
81
- msgstr "Узнайте возможности расширенной версии"
1
  msgid ""
2
  msgstr ""
3
  "Project-Id-Version: maintenance\n"
4
+ "POT-Creation-Date: 2013-12-06 14:52+0200\n"
5
+ "PO-Revision-Date: 2013-12-06 14:53+0200\n"
6
  "Last-Translator: \n"
7
+ "Language-Team: fruitfulcode\n"
 
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
11
  "X-Generator: Poedit 1.5.4\n"
12
+ "X-Poedit-KeywordsList: _;_e;__;_x\n"
13
+ "X-Poedit-Basepath: .\n"
14
+ "X-Poedit-SourceCharset: UTF-8\n"
 
 
15
 
16
+ #: includes/admin.php:84
17
+ msgid "Save changes"
18
+ msgstr "Сохранить"
19
 
20
+ #: includes/functions.php:104
21
+ msgid "General Settings"
22
+ msgstr "Общие настройки"
23
 
24
+ #: includes/functions.php:105
25
+ #: includes/functions.php:157
26
+ msgid "Extended version"
27
+ msgstr "Расширенная версия"
28
+
29
+ #: includes/functions.php:106
30
+ #: includes/functions.php:145
31
+ msgid "Contact support"
32
+ msgstr "Служба поддержки"
33
+
34
+ #: includes/functions.php:114
35
  msgid "Page title"
36
  msgstr "Заголовок страницы"
37
 
38
+ #: includes/functions.php:115
 
 
 
 
39
  msgid "Headline"
40
  msgstr "Заголовок"
41
 
42
+ #: includes/functions.php:116
 
 
 
 
43
  msgid "Description"
44
  msgstr "Описание"
45
 
46
+ #: includes/functions.php:117
 
 
 
 
47
  msgid "Logo"
48
  msgstr "Логотип"
49
 
50
+ #: includes/functions.php:117
51
+ msgid "Upload Logo"
52
+ msgstr "Загрузить логотип"
53
+
54
+ #: includes/functions.php:120
55
+ msgid "Admin bar"
56
+ msgstr "Админ-панель"
57
+
58
+ #: includes/functions.php:120
59
+ msgid "Show admin bar"
60
+ msgstr "Показать админ-панель"
61
+
62
+ #: includes/functions.php:121
63
+ msgid "503"
64
+ msgstr ""
65
+
66
+ #: includes/functions.php:121
67
+ msgid "Service temporarily unavailable"
68
+ msgstr "Сервис врменно недоступен"
69
+
70
+ #: includes/functions.php:122
71
+ msgid "Blur intensity"
72
+ msgstr "Интенсивность размытия"
73
+
74
+ #: includes/functions.php:123
75
+ msgid "Background blur"
76
+ msgstr "Размытие фона"
77
+
78
+ #: includes/functions.php:123
79
+ msgid "Apply a blur"
80
+ msgstr "Применить размытие"
81
+
82
+ #: includes/functions.php:130
83
  msgid "Background image"
84
  msgstr "Фоновое изображение"
85
 
86
+ #: includes/functions.php:130
87
+ msgid "Upload Background"
88
+ msgstr "Загрузить фон"
89
+
90
+ #: includes/functions.php:136
91
  msgid "Background color"
92
  msgstr "Цвет фона"
93
 
94
+ #: includes/functions.php:137
95
+ msgid "Font color"
96
+ msgstr "Цвет шрифта"
97
 
98
+ #: includes/functions.php:146
99
+ #, php-format
100
+ msgid ""
101
+ "If you faced with any problems, have a question or suggestion you always can "
102
+ "contact us with any request on our website <a href=\"%1$s\" title=\"%2$s\">"
103
+ "%2$s</a>"
104
+ msgstr ""
105
+ "Если вы столкнулись с любыми проблемами, есть вопрос или предложение, вы "
106
+ "всегда можете обратиться к нам с любым предложением на нашем сайте <a href="
107
+ "\"%1$s\" title=\"%2$s\">%2$s</a>"
108
+
109
+ #: includes/functions.php:158
110
+ #, php-format
111
+ msgid ""
112
+ "If you like our plugin please rate it, %1$s <a title=\"leave feedback\" href="
113
+ "\"%2$s\" target=\"_blank\">leave feedback</a> or purchase extended version "
114
+ "%1$s with more other features."
115
+ msgstr ""
116
+ "Если Вам нравиться наш плагин, оцените его %1$s <a title=\"оставить "
117
+ "комментарий\" href=\"%2$s\" target=\"_blank\">оставить комментарий</a> или "
118
+ "купите расширенную версию %1$s с дополнительными возможностями."
119
+
120
+ #: includes/functions.php:162
121
+ msgid "Purchase"
122
+ msgstr "Купить"
123
+
124
+ #: includes/functions.php:219
125
+ msgid "Maintenace"
126
+ msgstr ""
127
+
128
+ #: includes/functions.php:242
129
+ msgid "Website is under construction"
130
+ msgstr "Сайт находится в стадии разработки"
131
+
132
+ #: includes/functions.php:243
133
+ msgid "Maintenance mode is on"
134
+ msgstr "Режим обслуживания включен"
135
+
136
+ #: includes/functions.php:244
137
+ msgid "Website will be available soon"
138
+ msgstr "Сайт скоро бдует доступен "
139
+
140
+ #: load/functions.php:37
141
+ msgid "Permission access denied!"
142
+ msgstr "Доступ запрещен!"
143
+
144
+ #: load/functions.php:45
145
+ msgid "You entered your login are incorrect!"
146
+ msgstr "Вы ввели неверный логин! "
147
+
148
+ #: load/functions.php:49
149
+ msgid "You entered your password are incorrect!"
150
+ msgstr "Вы ввели неверный пароль!"
151
+
152
+ #: load/functions.php:52
153
+ msgid "You entered your login and password are incorrect!"
154
+ msgstr "Вы ввели неверный логин или пароль!"
155
+
156
+ #: load/functions.php:215
157
+ msgid "Username"
158
+ msgstr "Логин"
159
+
160
+ #: load/functions.php:216
161
+ msgid "Password"
162
+ msgstr "Пароль"
163
+
164
+ #: load/functions.php:217
165
+ msgid "Sign In"
166
+ msgstr "Войти"
167
+
168
+ #~ msgid "We have time until launch"
169
+ #~ msgstr "Осталось времени до запуска"
170
+
171
+ #~ msgid "Be first of your friends who will know when the website goes live."
172
+ #~ msgstr "Будь первым из твоих друзей, кто узнает о запуске сайта."
173
+
174
+ #~ msgid "Premium version"
175
+ #~ msgstr "Премиум версия"
176
+
177
+ #~ msgid "Check out our extended version of plugin with new features"
178
+ #~ msgstr "Проверьте возможности расширенной версии плагина"
179
+
180
+ #~ msgid "Your session has expired."
181
+ #~ msgstr "Ваша сессия истекла."
182
+
183
+ #~ msgid "Customer login"
184
+ #~ msgstr "Вход для клиентов"
185
 
186
+ #~ msgid "Please login to see website"
187
+ #~ msgstr "Пожалуйста авторезируйтесь"
 
188
 
189
+ #~ msgid "User roles"
190
+ #~ msgstr "Роли пользователей"
 
191
 
192
+ #~ msgid "Choose users access permissions in maintenance mode."
193
+ #~ msgstr "Выберите права доступа пользователей в режиме обслуживания."
 
lib/functions.php DELETED
@@ -1,55 +0,0 @@
1
- <?php
2
- add_filter( 'lib_update', 'lib_update' );
3
-
4
- function lib_update( $options )
5
- {
6
-
7
- $options['lib_options']['logo'] = lib_file_upload( 'logo' );
8
- $options['lib_options']['body_bg'] = lib_file_upload( 'body_bg' );
9
-
10
- if ( $_POST['remove_logo'] ) {
11
- $options['lib_options']['logo'] = '';
12
- }
13
- elseif ( $_POST['remove_bg'] ) {
14
- $options['lib_options']['body_bg'] = '';
15
- }
16
- return $options;
17
- }
18
-
19
- function lib_file_upload( $type )
20
- {
21
-
22
- $field_name = $type;
23
-
24
- $file = array(
25
- 'tmp_name' => $_FILES['lib_options']['tmp_name'][$field_name],
26
- 'name' => $_FILES['lib_options']['name'][$field_name],
27
- 'size' => $_FILES['lib_options']['size'][$field_name],
28
- 'error' => $_FILES['lib_options']['error'][$field_name]
29
- );
30
-
31
- /*$dir = WP_CONTENT_DIR . '/uploads/maintenance/';*/
32
- $upload_dir = wp_upload_dir();
33
- $dir = $upload_dir[ 'basedir' ] . '/maintenance/';
34
- $url = $upload_dir[ 'baseurl' ] . '/maintenance/';
35
-
36
- if ( !file_exists( dirname($dir) ) ) {
37
- mkdir( dirname($dir) );
38
- }
39
- if ( !file_exists( $dir ) ) {
40
- mkdir( $dir );
41
- }
42
-
43
- if ( $file['name'] ) {
44
- $filename = strtolower($field_name.'.'.end( explode( '.', $file['name'] ) ));
45
- move_uploaded_file( $file['tmp_name'], $dir . $filename );
46
- /*return WP_CONTENT_URL . '/uploads/maintenance/'.$filename;*/
47
- return $url . $filename;
48
- }
49
- else {
50
- $options = mt_get_option();
51
- return $options['lib_options'][$field_name];
52
- }
53
- }
54
-
55
- ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
lib/images/error.png DELETED
Binary file
lib/images/fruitfulcode.png DELETED
Binary file
lib/images/logo-bg-default.png DELETED
Binary file
lib/images/pass-icon.png DELETED
Binary file
lib/images/theme-bg-default.jpg DELETED
Binary file
lib/images/user-icon.png DELETED
Binary file
lib/index.php DELETED
@@ -1,214 +0,0 @@
1
- <?php
2
- global $wpdb,
3
- $error,
4
- $wp_query,
5
- $current_theme_locale_name,
6
- $mt_lib;
7
-
8
- if (!is_array($wp_query->query_vars))
9
- $wp_query->query_vars = array();
10
-
11
- if (count($_REQUEST) > 0) {
12
- $action = $_REQUEST['action'];
13
- } else {
14
- $action = null;
15
- }
16
-
17
- $info = $error = '';
18
- nocache_headers();
19
- $class_login = "user-icon";
20
- $class_password = "pass-icon";
21
-
22
- header('Content-Type: '.get_bloginfo('html_type').'; charset='.get_bloginfo('charset'));
23
-
24
- if ( defined('RELOCATE') )
25
- { // Move flag is set
26
- if ( isset( $_SERVER['PATH_INFO'] ) && ($_SERVER['PATH_INFO'] != $_SERVER['PHP_SELF']) )
27
- $_SERVER['PHP_SELF'] = str_replace( $_SERVER['PATH_INFO'], '', $_SERVER['PHP_SELF'] );
28
-
29
- $schema = ( isset($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS']) == 'on' ) ? 'https://' : 'http://';
30
- if ( dirname($schema . $_SERVER['HTTP_HOST'] . $_SERVER['PHP_SELF']) != get_bloginfo('url') )
31
- update_option('siteurl', dirname($schema . $_SERVER['HTTP_HOST'] . $_SERVER['PHP_SELF']) );
32
- }
33
-
34
- switch($action)
35
- {
36
- case 'login' :
37
- default:
38
- $user_login = '';
39
- $user_pass = '';
40
- $using_cookie = false;
41
-
42
- if ( !isset( $_REQUEST['redirect_to'] ) ) {
43
- $redirect_to = get_bloginfo('url');
44
- } else {
45
- $redirect_to = $_REQUEST['redirect_to'];
46
- }
47
-
48
- if(isset($_SESSION['redirect_me_back'])) $redirect_to = $_SESSION['redirect_me_back'];
49
-
50
- if( $_POST ) {
51
- $user_login = $_POST['log'];
52
- $user_login = sanitize_user( $user_login );
53
- $user_pass = $_POST['pwd'];
54
- $rememberme = $_POST['rememberme'];
55
-
56
- $access = array();
57
- $access['user_login'] = $user_login;
58
- $access['user_password'] = $user_pass;
59
- $access['remember'] = false;
60
- $user = wp_signon( $access, false);
61
-
62
- if ( is_wp_error($user) ) {
63
- $info = __('The login and password you entered are incorrect!', $current_theme_locale_name);
64
- $class_login = 'error-login';
65
- $class_password = 'error-password';
66
- }
67
-
68
- } else {
69
- if (function_exists('wp_get_cookie_login'))
70
- {
71
- $cookie_login = wp_get_cookie_login();
72
- if ( ! empty($cookie_login) ) {
73
- $using_cookie = true;
74
- $user_login = $cookie_login['login'];
75
- $user_pass = $cookie_login['password'];
76
- }
77
- }
78
- elseif ( !empty($_COOKIE) )
79
- {
80
- if ( !empty($_COOKIE[USER_COOKIE]) )
81
- $user_login = $_COOKIE[USER_COOKIE];
82
- if ( !empty($_COOKIE[PASS_COOKIE]) ) {
83
- $user_pass = $_COOKIE[PASS_COOKIE];
84
- $using_cookie = true;
85
- }
86
- }
87
- }
88
-
89
- do_action('wp_authenticate', array(&$user_login, &$user_pass));
90
- if ( $user_login && $user_pass ) {
91
- $user = new WP_User(0, $user_login);
92
-
93
- if ( wp_login($user_login,
94
- $user_pass,
95
- $using_cookie) ) {
96
- if ( !$using_cookie )
97
- wp_setcookie($user_login, $user_pass, false, '', '', $rememberme);
98
- do_action('wp_login', $user_login);
99
- wp_redirect($redirect_to);
100
- exit;
101
- } else {
102
- if ( $using_cookie )
103
- $error = __('Your session has expired.', $current_theme_locale_name);
104
- }
105
- }
106
- ?>
107
-
108
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
109
- <html xmlns="http://www.w3.org/1999/xhtml">
110
- <head>
111
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
112
- <title><?php echo $mt_lib['page_title']; ?></title>
113
-
114
- <link rel="stylesheet" type="text/css" href="<?php echo PLUGIN_URL . LIB_DIR; ?>/style.css" />
115
- <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>
116
-
117
- <?php
118
- if (isset($mt_lib['expiry_date']) ):
119
- list( $date,$time ) = explode( '|', $mt_lib['expiry_date'] );
120
- list( $month, $day, $year ) = explode( '.', $date );
121
- list( $hours, $minutes, $seconds ) = explode ( ':', $time );
122
- $month--;
123
- ?>
124
-
125
- <script type="text/javascript" src="<?php echo PLUGIN_URL . LIB_DIR; ?>/js/jquery.countdown.js"></script>
126
- <script type="text/javascript">
127
- $(function () {
128
- var austDay = new Date(<?php echo "$year, $month, $day, $hours, $minutes, $seconds, 0"; ?>);
129
- $('#defaultCountdown').countdown({until: austDay, layout: '{dn} {dl}, {hn} {hl}, {mn} {ml}, and {sn} {sl}'});
130
- $('#year').text(austDay.getFullYear());
131
- });
132
- </script>
133
- <?php endif; ?>
134
-
135
- <?php if ( $mt_lib['body_bg'] || $mt_lib['body_bg_color'] ): ?>
136
- <style type="text/css">
137
- body { background:
138
- <?php echo $mt_lib['body_bg_color']; ?>
139
- <?php if ( $mt_lib['body_bg'] ) {
140
- echo "url({$mt_lib['body_bg']}) repeat-x scroll 0 0";
141
- } else {
142
- echo 'url('. PLUGIN_URL . LIB_DIR . '/images/theme-bg-default.jpg' .') repeat-x scroll 0 0';
143
- }
144
-
145
- ?>;}
146
-
147
- </style>
148
- <?php endif; ?>
149
-
150
- <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
151
- <script type="text/javascript">
152
- $(document).ready(function() {
153
- $(".username").focus(function() { $(".user-icon").css("left","-49px");});
154
- $(".username").blur(function() { $(".user-icon").css("left","0px"); });
155
- $(".password").focus(function() { $(".pass-icon").css("left","-49px");});
156
- $(".password").blur(function() { $(".pass-icon").css("left","0px");});
157
- });
158
-
159
- </script>
160
- <script type="text/javascript" src="<?php echo PLUGIN_URL . LIB_DIR ?>/js/jquery.placeholder.js"></script>
161
- <script type="text/javascript">
162
- $(document).ready(function() {
163
- $('input[placeholder]').placeholder();
164
- });
165
-
166
- $(window).load(function() {
167
- var vWrapWidth = -$("#wrapper").width()/2;
168
- var vWrapHeight = -$("#wrapper").height()/2;
169
- $("#wrapper").css({'margin-left' : vWrapWidth});
170
- $("#wrapper").css({'margin-top' : vWrapHeight});
171
-
172
- var vCompWidth = -$(".company a img").width()/2;
173
- $(".company a img").css({'margin-left' : vCompWidth});
174
- });
175
-
176
- </script>
177
- </head>
178
- <body>
179
- <div id="wrapper">
180
- <div class="company">
181
- <a href="<?php bloginfo('home'); ?>"><img src="<?php if ( $mt_lib['logo'] ) { echo $mt_lib['logo']; } else { echo PLUGIN_URL . LIB_DIR.'/images/fruitfulcode.png'; } ?>" alt="logo"/></a>
182
- </div>
183
-
184
- <form name="loginform" id="loginform" class="login-form" method="post">
185
-
186
- <div class="header">
187
- <h1><?php echo stripslashes($mt_lib['heading']); ?></h1>
188
- <span><?php echo stripslashes($mt_lib['time_text']); ?></span>
189
- </div>
190
-
191
- <div class="content">
192
- <div class="<?php echo $class_login; ?>"></div>
193
- <div class="<?php echo $class_password; ?>"></div>
194
- <div class="inputs">
195
- <input type="text" name="log" id="log" value="<?php echo wp_specialchars(stripslashes($user_login), 1); ?>" size="20" class="input username" placeholder="Username"/>
196
- <input type="password" name="pwd" id="login_password" value="" size="20" class="input password" placeholder="Password" />
197
- </div>
198
- </div>
199
-
200
- <?php do_action('login_form'); ?>
201
-
202
-
203
- <div class="footer">
204
- <input type="submit" class="button" name="submit" id="submit" value="<?php _e('Sign In',$current_theme_locale_name); ?>" tabindex="4" />
205
- <input type="hidden" name="redirect_to" value="<?php echo wp_specialchars($redirect_to); ?>" />
206
- </div>
207
-
208
- </form>
209
- </div> <!-- end wrapper -->
210
- </body>
211
- </html>
212
- <?php die();
213
- break;
214
- } ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
lib/js/DD_belatedPNG_0.0.7a-min.js DELETED
@@ -1,14 +0,0 @@
1
- /**
2
- * DD_belatedPNG: Adds IE6 support: PNG images for CSS background-image and HTML <IMG/>.
3
- * Author: Drew Diller
4
- * Email: drew.diller@gmail.com
5
- * URL: http://www.dillerdesign.com/experiment/DD_belatedPNG/
6
- * Version: 0.0.7a
7
- * Licensed under the MIT License: http://dillerdesign.com/experiment/DD_belatedPNG/#license
8
- *
9
- * Example usage:
10
- * DD_belatedPNG.fix('.png_bg'); // argument is a CSS selector
11
- * DD_belatedPNG.fixPng( someNode ); // argument is an HTMLDomElement
12
- **/
13
-
14
- eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('2 E={J:\'E\',Z:{},1E:7(){4(x.1l&&!x.1l[6.J]){x.1l.23(6.J,\'24:25-26-27:3\')}4(1F.11){1F.11(\'28\',7(){E=29})}},1G:7(){2 a=x.1m(\'8\');x.1H.1b.1n(a,x.1H.1b.1b);2 b=a.1o;b.1c(6.J+\'\\\\:*\',\'{12:2a(#1I#2b)}\');b.1c(6.J+\'\\\\:9\',\'Q:1p;\');b.1c(\'1J.\'+6.J+\'1K\',\'12:y; 1q:y; Q:1p; z-2c:-1; 1d:-1r; 1L:1M;\');6.1o=b},1N:7(){2 a=13.2d;4(13.1e.K(\'2e\')!=-1||13.1e.K(\'1q\')!=-1){E.1f(a)}4(13.1e==\'8.1s\'){2 b=(a.F.1s==\'y\')?\'y\':\'2f\';G(2 v M a.3){a.3[v].9.8.1s=b}}4(13.1e.K(\'14\')!=-1){E.1t(a)}},1t:7(a){4(a.F.14.K(\'2g\')!=-1){2 b=a.F.14;b=1u(b.2h(b.1v(\'=\')+1,b.1v(\')\')),10)/2i;a.3.N.9.8.14=a.F.14;a.3.C.I.2j=b}},15:7(a){2k(7(){E.1f(a)},1)},2l:7(a){2 b=a.1O(\',\');G(2 i=0;i<b.2m;i++){6.1o.1c(b[i],\'12:2n(E.1P(6))\')}},1f:7(a){a.S.1Q=\'\';6.1R(a);6.16(a);6.1t(a);4(a.O){6.1S(a)}},1T:7(b){2 c=6;2 d={2o:\'16\',2p:\'16\'};4(b.17==\'A\'){2 e={2q:\'15\',2r:\'15\',2s:\'15\',2t:\'15\'};G(2 a M e){d[a]=e[a]}}G(2 h M d){b.11(\'1w\'+h,7(){c[d[h]](b)})}b.11(\'2u\',6.1N)},1x:7(a){a.8.2v=1;4(a.F.Q==\'2w\'){a.8.Q=\'2x\'}},1S:7(a){2 b={\'2y\':P,\'2z\':P,\'2A\':P};G(2 s M b){a.3.N.9.8[s]=a.F[s]}},1R:7(a){4(!a.F){1g}U{2 b=a.F}G(2 v M a.3){a.3[v].9.8.1U=b.1U}a.S.18=\'\';a.S.19=\'\';2 c=(b.18==\'1V\');2 d=P;4(b.19!=\'y\'||a.O){4(!a.O){a.D=b.19;a.D=a.D.2B(5,a.D.1v(\'")\')-5)}U{a.D=a.1h}2 e=6;4(!e.Z[a.D]){2 f=x.1m(\'1J\');e.Z[a.D]=f;f.2C=e.J+\'1K\';f.S.1Q=\'12:y; Q:1p; 1y:-1r; 1d:-1r; 1q:y;\';f.11(\'2D\',7(){6.1i=6.2E;6.1j=6.2F;e.16(a)});f.1h=a.D;f.1W(\'1i\');f.1W(\'1j\');x.1X.1n(f,x.1X.1b)}a.3.C.I.1h=a.D;d=V}a.3.C.I.1w=!d;a.3.C.I.N=\'y\';a.3.N.9.8.18=b.18;a.S.19=\'y\';a.S.18=\'1V\'},16:7(e){2 f=e.F;2 g={\'W\':e.2G+1,\'H\':e.2H+1,\'w\':6.Z[e.D].1i,\'h\':6.Z[e.D].1j,\'L\':e.2I,\'T\':e.2J,\'1k\':e.2K,\'1z\':e.2L};2 i=(g.L+g.1k==1)?1:0;2 j=7(a,l,t,w,h,o){a.2M=w+\',\'+h;a.2N=o+\',\'+o;a.2O=\'2P,1Y\'+w+\',1Y\'+w+\',\'+h+\'2Q,\'+h+\' 2R\';a.8.1i=w+\'u\';a.8.1j=h+\'u\';a.8.1y=l+\'u\';a.8.1d=t+\'u\'};j(e.3.N.9,(g.L+(e.O?0:g.1k)),(g.T+(e.O?0:g.1z)),(g.W-1),(g.H-1),0);j(e.3.C.9,(g.L+g.1k),(g.T+g.1z),(g.W),(g.H),1);2 k={\'X\':0,\'Y\':0};2 m=7(a,b){2 c=P;2S(b){1a\'1y\':1a\'1d\':k[a]=0;1A;1a\'2T\':k[a]=.5;1A;1a\'2U\':1a\'2V\':k[a]=1;1A;1I:4(b.K(\'%\')!=-1){k[a]=1u(b)*.2W}U{c=V}}2 d=(a==\'X\');k[a]=2X.2Y(c?((g[d?\'W\':\'H\']*k[a])-(g[d?\'w\':\'h\']*k[a])):1u(b));4(k[a]==0){k[a]++}};G(2 b M k){m(b,f[\'2Z\'+b])}e.3.C.I.Q=(k.X/g.W)+\',\'+(k.Y/g.H);2 n=f.30;2 p={\'T\':1,\'R\':g.W+i,\'B\':g.H,\'L\':1+i};2 q={\'X\':{\'1B\':\'L\',\'1C\':\'R\',\'d\':\'W\'},\'Y\':{\'1B\':\'T\',\'1C\':\'B\',\'d\':\'H\'}};4(n!=\'1D\'){2 c={\'T\':(k.Y),\'R\':(k.X+g.w),\'B\':(k.Y+g.h),\'L\':(k.X)};4(n.K(\'1D-\')!=-1){2 v=n.1O(\'1D-\')[1].31();c[q[v].1B]=1;c[q[v].1C]=g[q[v].d]}4(c.B>g.H){c.B=g.H}e.3.C.9.8.1Z=\'20(\'+c.T+\'u \'+(c.R+i)+\'u \'+c.B+\'u \'+(c.L+i)+\'u)\'}U{e.3.C.9.8.1Z=\'20(\'+p.T+\'u \'+p.R+\'u \'+p.B+\'u \'+p.L+\'u)\'}},1P:7(a){a.8.12=\'y\';4(a.17==\'32\'||a.17==\'33\'||a.17==\'34\'){1g}a.O=V;4(a.17==\'35\'){4(a.1h.21().K(/\\.22$/)!=-1){a.O=P;a.8.1L=\'1M\'}U{1g}}U 4(a.F.19.21().K(\'.22\')==-1){1g}2 b=E;a.3={N:{},C:{}};2 c={9:{},I:{}};G(2 r M a.3){G(2 e M c){2 d=b.J+\':\'+e;a.3[r][e]=x.1m(d)}a.3[r].9.36=V;a.3[r].9.37(a.3[r].I);a.38.1n(a.3[r].9,a)}a.3.C.9.39=\'y\';a.3.C.I.3a=\'3b\';a.3.N.I.1w=V;b.1T(a);b.1x(a);b.1x(a.3c);b.1f(a)}};3d{x.3e("3f",V,P)}3g(r){}E.1E();E.1G();',62,203,'||var|vml|if||this|function|style|shape|||||||||||||||||||||px|||document|none||||image|vmlBg|DD_belatedPNG|currentStyle|for||fill|ns|search||in|color|isImg|true|position||runtimeStyle||else|false||||imgSize||attachEvent|behavior|event|filter|handlePseudoHover|vmlOffsets|nodeName|backgroundColor|backgroundImage|case|firstChild|addRule|top|propertyName|applyVML|return|src|width|height|bLW|namespaces|createElement|insertBefore|styleSheet|absolute|border|10000px|display|vmlOpacity|parseInt|lastIndexOf|on|giveLayout|left|bTW|break|b1|b2|repeat|createVmlNameSpace|window|createVmlStyleSheet|documentElement|default|img|_sizeFinder|visibility|hidden|readPropertyChange|split|fixPng|cssText|vmlFill|copyImageBorders|attachHandlers|zIndex|transparent|removeAttribute|body|0l|clip|rect|toLowerCase|png|add|urn|schemas|microsoft|com|onbeforeunload|null|url|VML|index|srcElement|background|block|lpha|substring|100|opacity|setTimeout|fix|length|expression|resize|move|mouseleave|mouseenter|focus|blur|onpropertychange|zoom|static|relative|borderStyle|borderWidth|borderColor|substr|className|onload|offsetWidth|offsetHeight|clientWidth|clientHeight|offsetLeft|offsetTop|clientLeft|clientTop|coordsize|coordorigin|path|m0|l0|xe|switch|center|right|bottom|01|Math|ceil|backgroundPosition|backgroundRepeat|toUpperCase|BODY|TD|TR|IMG|stroked|appendChild|parentNode|fillcolor|type|tile|offsetParent|try|execCommand|BackgroundImageCache|catch'.split('|'),0,{}))
 
 
 
 
 
 
 
 
 
 
 
 
 
 
lib/js/jquery.countdown.js DELETED
@@ -1,7 +0,0 @@
1
- /* http://keith-wood.name/countdown.html
2
- Countdown for jQuery v1.5.8.
3
- Written by Keith Wood (kbwood{at}iinet.com.au) January 2008.
4
- Dual licensed under the GPL (http://dev.jquery.com/browser/trunk/jquery/GPL-LICENSE.txt) and
5
- MIT (http://dev.jquery.com/browser/trunk/jquery/MIT-LICENSE.txt) licenses.
6
- Please attribute the author if you use it. */
7
- (function($){function Countdown(){this.regional=[];this.regional['']={labels:['Years','Months','Weeks','Days','Hours','Minutes','Seconds'],labels1:['Year','Month','Week','Day','Hour','Minute','Second'],compactLabels:['y','m','w','d'],whichLabels:null,timeSeparator:':',isRTL:false};this._defaults={until:null,since:null,timezone:null,serverSync:null,format:'dHMS',layout:'',compact:false,significant:0,description:'',expiryUrl:'',expiryText:'',alwaysExpire:false,onExpiry:null,onTick:null,tickInterval:1};$.extend(this._defaults,this.regional['']);this._serverSyncs=[]}var w='countdown';var Y=0;var O=1;var W=2;var D=3;var H=4;var M=5;var S=6;$.extend(Countdown.prototype,{markerClassName:'hasCountdown',_timer:setInterval(function(){$.countdown._updateTargets()},980),_timerTargets:[],setDefaults:function(a){this._resetExtraLabels(this._defaults,a);extendRemove(this._defaults,a||{})},UTCDate:function(a,b,c,e,f,g,h,i){if(typeof b=='object'&&b.constructor==Date){i=b.getMilliseconds();h=b.getSeconds();g=b.getMinutes();f=b.getHours();e=b.getDate();c=b.getMonth();b=b.getFullYear()}var d=new Date();d.setUTCFullYear(b);d.setUTCDate(1);d.setUTCMonth(c||0);d.setUTCDate(e||1);d.setUTCHours(f||0);d.setUTCMinutes((g||0)-(Math.abs(a)<30?a*60:a));d.setUTCSeconds(h||0);d.setUTCMilliseconds(i||0);return d},periodsToSeconds:function(a){return a[0]*31557600+a[1]*2629800+a[2]*604800+a[3]*86400+a[4]*3600+a[5]*60+a[6]},_settingsCountdown:function(a,b){if(!b){return $.countdown._defaults}var c=$.data(a,w);return(b=='all'?c.options:c.options[b])},_attachCountdown:function(a,b){var c=$(a);if(c.hasClass(this.markerClassName)){return}c.addClass(this.markerClassName);var d={options:$.extend({},b),_periods:[0,0,0,0,0,0,0]};$.data(a,w,d);this._changeCountdown(a)},_addTarget:function(a){if(!this._hasTarget(a)){this._timerTargets.push(a)}},_hasTarget:function(a){return($.inArray(a,this._timerTargets)>-1)},_removeTarget:function(b){this._timerTargets=$.map(this._timerTargets,function(a){return(a==b?null:a)})},_updateTargets:function(){for(var i=this._timerTargets.length-1;i>=0;i--){this._updateCountdown(this._timerTargets[i])}},_updateCountdown:function(a,b){var c=$(a);b=b||$.data(a,w);if(!b){return}c.html(this._generateHTML(b));c[(this._get(b,'isRTL')?'add':'remove')+'Class']('countdown_rtl');var d=this._get(b,'onTick');if(d){var e=b._hold!='lap'?b._periods:this._calculatePeriods(b,b._show,this._get(b,'significant'),new Date());var f=this._get(b,'tickInterval');if(f==1||this.periodsToSeconds(e)%f==0){d.apply(a,[e])}}var g=b._hold!='pause'&&(b._since?b._now.getTime()<b._since.getTime():b._now.getTime()>=b._until.getTime());if(g&&!b._expiring){b._expiring=true;if(this._hasTarget(a)||this._get(b,'alwaysExpire')){this._removeTarget(a);var h=this._get(b,'onExpiry');if(h){h.apply(a,[])}var i=this._get(b,'expiryText');if(i){var j=this._get(b,'layout');b.options.layout=i;this._updateCountdown(a,b);b.options.layout=j}var k=this._get(b,'expiryUrl');if(k){window.location=k}}b._expiring=false}else if(b._hold=='pause'){this._removeTarget(a)}$.data(a,w,b)},_changeCountdown:function(a,b,c){b=b||{};if(typeof b=='string'){var d=b;b={};b[d]=c}var e=$.data(a,w);if(e){this._resetExtraLabels(e.options,b);extendRemove(e.options,b);this._adjustSettings(a,e);$.data(a,w,e);var f=new Date();if((e._since&&e._since<f)||(e._until&&e._until>f)){this._addTarget(a)}this._updateCountdown(a,e)}},_resetExtraLabels:function(a,b){var c=false;for(var n in b){if(n!='whichLabels'&&n.match(/[Ll]abels/)){c=true;break}}if(c){for(var n in a){if(n.match(/[Ll]abels[0-9]/)){a[n]=null}}}},_adjustSettings:function(a,b){var c;var d=this._get(b,'serverSync');var e=0;var f=null;for(var i=0;i<this._serverSyncs.length;i++){if(this._serverSyncs[i][0]==d){f=this._serverSyncs[i][1];break}}if(f!=null){e=(d?f:0);c=new Date()}else{var g=(d?d.apply(a,[]):null);c=new Date();e=(g?c.getTime()-g.getTime():0);this._serverSyncs.push([d,e])}var h=this._get(b,'timezone');h=(h==null?-c.getTimezoneOffset():h);b._since=this._get(b,'since');if(b._since!=null){b._since=this.UTCDate(h,this._determineTime(b._since,null));if(b._since&&e){b._since.setMilliseconds(b._since.getMilliseconds()+e)}}b._until=this.UTCDate(h,this._determineTime(this._get(b,'until'),c));if(e){b._until.setMilliseconds(b._until.getMilliseconds()+e)}b._show=this._determineShow(b)},_destroyCountdown:function(a){var b=$(a);if(!b.hasClass(this.markerClassName)){return}this._removeTarget(a);b.removeClass(this.markerClassName).empty();$.removeData(a,w)},_pauseCountdown:function(a){this._hold(a,'pause')},_lapCountdown:function(a){this._hold(a,'lap')},_resumeCountdown:function(a){this._hold(a,null)},_hold:function(a,b){var c=$.data(a,w);if(c){if(c._hold=='pause'&&!b){c._periods=c._savePeriods;var d=(c._since?'-':'+');c[c._since?'_since':'_until']=this._determineTime(d+c._periods[0]+'y'+d+c._periods[1]+'o'+d+c._periods[2]+'w'+d+c._periods[3]+'d'+d+c._periods[4]+'h'+d+c._periods[5]+'m'+d+c._periods[6]+'s');this._addTarget(a)}c._hold=b;c._savePeriods=(b=='pause'?c._periods:null);$.data(a,w,c);this._updateCountdown(a,c)}},_getTimesCountdown:function(a){var b=$.data(a,w);return(!b?null:(!b._hold?b._periods:this._calculatePeriods(b,b._show,this._get(b,'significant'),new Date())))},_get:function(a,b){return(a.options[b]!=null?a.options[b]:$.countdown._defaults[b])},_determineTime:function(k,l){var m=function(a){var b=new Date();b.setTime(b.getTime()+a*1000);return b};var n=function(a){a=a.toLowerCase();var b=new Date();var c=b.getFullYear();var d=b.getMonth();var e=b.getDate();var f=b.getHours();var g=b.getMinutes();var h=b.getSeconds();var i=/([+-]?[0-9]+)\s*(s|m|h|d|w|o|y)?/g;var j=i.exec(a);while(j){switch(j[2]||'s'){case's':h+=parseInt(j[1],10);break;case'm':g+=parseInt(j[1],10);break;case'h':f+=parseInt(j[1],10);break;case'd':e+=parseInt(j[1],10);break;case'w':e+=parseInt(j[1],10)*7;break;case'o':d+=parseInt(j[1],10);e=Math.min(e,$.countdown._getDaysInMonth(c,d));break;case'y':c+=parseInt(j[1],10);e=Math.min(e,$.countdown._getDaysInMonth(c,d));break}j=i.exec(a)}return new Date(c,d,e,f,g,h,0)};var o=(k==null?l:(typeof k=='string'?n(k):(typeof k=='number'?m(k):k)));if(o)o.setMilliseconds(0);return o},_getDaysInMonth:function(a,b){return 32-new Date(a,b,32).getDate()},_normalLabels:function(a){return a},_generateHTML:function(c){var d=this._get(c,'significant');c._periods=(c._hold?c._periods:this._calculatePeriods(c,c._show,d,new Date()));var e=false;var f=0;var g=d;var h=$.extend({},c._show);for(var i=Y;i<=S;i++){e|=(c._show[i]=='?'&&c._periods[i]>0);h[i]=(c._show[i]=='?'&&!e?null:c._show[i]);f+=(h[i]?1:0);g-=(c._periods[i]>0?1:0)}var j=[false,false,false,false,false,false,false];for(var i=S;i>=Y;i--){if(c._show[i]){if(c._periods[i]){j[i]=true}else{j[i]=g>0;g--}}}var k=this._get(c,'compact');var l=this._get(c,'layout');var m=(k?this._get(c,'compactLabels'):this._get(c,'labels'));var n=this._get(c,'whichLabels')||this._normalLabels;var o=this._get(c,'timeSeparator');var p=this._get(c,'description')||'';var q=function(a){var b=$.countdown._get(c,'compactLabels'+n(c._periods[a]));return(h[a]?c._periods[a]+(b?b[a]:m[a])+' ':'')};var r=function(a){var b=$.countdown._get(c,'labels'+n(c._periods[a]));return((!d&&h[a])||(d&&j[a])?'<span class="countdown_section"><span class="countdown_amount">'+c._periods[a]+'</span><br/>'+(b?b[a]:m[a])+'</span>':'')};return(l?this._buildLayout(c,h,l,k,d,j):((k?'<span class="countdown_row countdown_amount'+(c._hold?' countdown_holding':'')+'">'+q(Y)+q(O)+q(W)+q(D)+(h[H]?this._minDigits(c._periods[H],2):'')+(h[M]?(h[H]?o:'')+this._minDigits(c._periods[M],2):'')+(h[S]?(h[H]||h[M]?o:'')+this._minDigits(c._periods[S],2):''):'<span class="countdown_row countdown_show'+(d||f)+(c._hold?' countdown_holding':'')+'">'+r(Y)+r(O)+r(W)+r(D)+r(H)+r(M)+r(S))+'</span>'+(p?'<span class="countdown_row countdown_descr">'+p+'</span>':'')))},_buildLayout:function(c,d,e,f,g,h){var j=this._get(c,(f?'compactLabels':'labels'));var k=this._get(c,'whichLabels')||this._normalLabels;var l=function(a){return($.countdown._get(c,(f?'compactLabels':'labels')+k(c._periods[a]))||j)[a]};var m=function(a,b){return Math.floor(a/b)%10};var o={desc:this._get(c,'description'),sep:this._get(c,'timeSeparator'),yl:l(Y),yn:c._periods[Y],ynn:this._minDigits(c._periods[Y],2),ynnn:this._minDigits(c._periods[Y],3),y1:m(c._periods[Y],1),y10:m(c._periods[Y],10),y100:m(c._periods[Y],100),y1000:m(c._periods[Y],1000),ol:l(O),on:c._periods[O],onn:this._minDigits(c._periods[O],2),onnn:this._minDigits(c._periods[O],3),o1:m(c._periods[O],1),o10:m(c._periods[O],10),o100:m(c._periods[O],100),o1000:m(c._periods[O],1000),wl:l(W),wn:c._periods[W],wnn:this._minDigits(c._periods[W],2),wnnn:this._minDigits(c._periods[W],3),w1:m(c._periods[W],1),w10:m(c._periods[W],10),w100:m(c._periods[W],100),w1000:m(c._periods[W],1000),dl:l(D),dn:c._periods[D],dnn:this._minDigits(c._periods[D],2),dnnn:this._minDigits(c._periods[D],3),d1:m(c._periods[D],1),d10:m(c._periods[D],10),d100:m(c._periods[D],100),d1000:m(c._periods[D],1000),hl:l(H),hn:c._periods[H],hnn:this._minDigits(c._periods[H],2),hnnn:this._minDigits(c._periods[H],3),h1:m(c._periods[H],1),h10:m(c._periods[H],10),h100:m(c._periods[H],100),h1000:m(c._periods[H],1000),ml:l(M),mn:c._periods[M],mnn:this._minDigits(c._periods[M],2),mnnn:this._minDigits(c._periods[M],3),m1:m(c._periods[M],1),m10:m(c._periods[M],10),m100:m(c._periods[M],100),m1000:m(c._periods[M],1000),sl:l(S),sn:c._periods[S],snn:this._minDigits(c._periods[S],2),snnn:this._minDigits(c._periods[S],3),s1:m(c._periods[S],1),s10:m(c._periods[S],10),s100:m(c._periods[S],100),s1000:m(c._periods[S],1000)};var p=e;for(var i=Y;i<=S;i++){var q='yowdhms'.charAt(i);var r=new RegExp('\\{'+q+'<\\}(.*)\\{'+q+'>\\}','g');p=p.replace(r,((!g&&d[i])||(g&&h[i])?'$1':''))}$.each(o,function(n,v){var a=new RegExp('\\{'+n+'\\}','g');p=p.replace(a,v)});return p},_minDigits:function(a,b){a=''+a;if(a.length>=b){return a}a='0000000000'+a;return a.substr(a.length-b)},_determineShow:function(a){var b=this._get(a,'format');var c=[];c[Y]=(b.match('y')?'?':(b.match('Y')?'!':null));c[O]=(b.match('o')?'?':(b.match('O')?'!':null));c[W]=(b.match('w')?'?':(b.match('W')?'!':null));c[D]=(b.match('d')?'?':(b.match('D')?'!':null));c[H]=(b.match('h')?'?':(b.match('H')?'!':null));c[M]=(b.match('m')?'?':(b.match('M')?'!':null));c[S]=(b.match('s')?'?':(b.match('S')?'!':null));return c},_calculatePeriods:function(c,d,e,f){c._now=f;c._now.setMilliseconds(0);var g=new Date(c._now.getTime());if(c._since){if(f.getTime()<c._since.getTime()){c._now=f=g}else{f=c._since}}else{g.setTime(c._until.getTime());if(f.getTime()>c._until.getTime()){c._now=f=g}}var h=[0,0,0,0,0,0,0];if(d[Y]||d[O]){var i=$.countdown._getDaysInMonth(f.getFullYear(),f.getMonth());var j=$.countdown._getDaysInMonth(g.getFullYear(),g.getMonth());var k=(g.getDate()==f.getDate()||(g.getDate()>=Math.min(i,j)&&f.getDate()>=Math.min(i,j)));var l=function(a){return(a.getHours()*60+a.getMinutes())*60+a.getSeconds()};var m=Math.max(0,(g.getFullYear()-f.getFullYear())*12+g.getMonth()-f.getMonth()+((g.getDate()<f.getDate()&&!k)||(k&&l(g)<l(f))?-1:0));h[Y]=(d[Y]?Math.floor(m/12):0);h[O]=(d[O]?m-h[Y]*12:0);f=new Date(f.getTime());var n=(f.getDate()==i);var o=$.countdown._getDaysInMonth(f.getFullYear()+h[Y],f.getMonth()+h[O]);if(f.getDate()>o){f.setDate(o)}f.setFullYear(f.getFullYear()+h[Y]);f.setMonth(f.getMonth()+h[O]);if(n){f.setDate(o)}}var p=Math.floor((g.getTime()-f.getTime())/1000);var q=function(a,b){h[a]=(d[a]?Math.floor(p/b):0);p-=h[a]*b};q(W,604800);q(D,86400);q(H,3600);q(M,60);q(S,1);if(p>0&&!c._since){var r=[1,12,4.3482,7,24,60,60];var s=S;var t=1;for(var u=S;u>=Y;u--){if(d[u]){if(h[s]>=t){h[s]=0;p=1}if(p>0){h[u]++;p=0;s=u;t=1}}t*=r[u]}}if(e){for(var u=Y;u<=S;u++){if(e&&h[u]){e--}else if(!e){h[u]=0}}}return h}});function extendRemove(a,b){$.extend(a,b);for(var c in b){if(b[c]==null){a[c]=null}}return a}$.fn.countdown=function(a){var b=Array.prototype.slice.call(arguments,1);if(a=='getTimes'||a=='settings'){return $.countdown['_'+a+'Countdown'].apply($.countdown,[this[0]].concat(b))}return this.each(function(){if(typeof a=='string'){$.countdown['_'+a+'Countdown'].apply($.countdown,[this].concat(b))}else{$.countdown._attachCountdown(this,a)}})};$.countdown=new Countdown()})(jQuery);
 
 
 
 
 
 
 
lib/js/jquery.placeholder.js DELETED
@@ -1,106 +0,0 @@
1
- /*
2
- * Placeholder plugin for jQuery
3
- * ---
4
- * Copyright 2010, Daniel Stocks (http://webcloud.se)
5
- * Released under the MIT, BSD, and GPL Licenses.
6
- */
7
- (function($) {
8
- function Placeholder(input) {
9
- this.input = input;
10
- if (input.attr('type') == 'password') {
11
- this.handlePassword();
12
- }
13
- // Prevent placeholder values from submitting
14
- $(input[0].form).submit(function() {
15
- if (input.hasClass('placeholder') && input[0].value == input.attr('placeholder')) {
16
- input[0].value = '';
17
- }
18
- });
19
- }
20
- Placeholder.prototype = {
21
- show : function(loading) {
22
- // FF and IE saves values when you refresh the page. If the user refreshes the page with
23
- // the placeholders showing they will be the default values and the input fields won't be empty.
24
- if (this.input[0].value === '' || (loading && this.valueIsPlaceholder())) {
25
- if (this.isPassword) {
26
- try {
27
- this.input[0].setAttribute('type', 'text');
28
- } catch (e) {
29
- this.input.before(this.fakePassword.show()).hide();
30
- }
31
- }
32
- this.input.addClass('placeholder');
33
- this.input[0].value = this.input.attr('placeholder');
34
- }
35
- },
36
- hide : function() {
37
- if (this.valueIsPlaceholder() && this.input.hasClass('placeholder')) {
38
- this.input.removeClass('placeholder');
39
- this.input[0].value = '';
40
- if (this.isPassword) {
41
- try {
42
- this.input[0].setAttribute('type', 'password');
43
- } catch (e) { }
44
- // Restore focus for Opera and IE
45
- this.input.show();
46
- this.input[0].focus();
47
- }
48
- }
49
- },
50
- valueIsPlaceholder : function() {
51
- return this.input[0].value == this.input.attr('placeholder');
52
- },
53
- handlePassword: function() {
54
- var input = this.input;
55
- input.attr('realType', 'password');
56
- this.isPassword = true;
57
- // IE < 9 doesn't allow changing the type of password inputs
58
- if ($.browser.msie && input[0].outerHTML) {
59
- var fakeHTML = $(input[0].outerHTML.replace(/type=(['"])?password\1/gi, 'type=$1text$1'));
60
- this.fakePassword = fakeHTML.val(input.attr('placeholder')).addClass('placeholder').focus(function() {
61
- input.trigger('focus');
62
- $(this).hide();
63
- });
64
- $(input[0].form).submit(function() {
65
- fakeHTML.remove();
66
- input.show()
67
- });
68
- }
69
- }
70
- };
71
- var NATIVE_SUPPORT = !!("placeholder" in document.createElement( "input" ));
72
- $.fn.placeholder = function() {
73
- return NATIVE_SUPPORT ? this : this.each(function() {
74
- var input = $(this);
75
- var placeholder = new Placeholder(input);
76
- placeholder.show(true);
77
- input.focus(function() {
78
- placeholder.hide();
79
- });
80
- input.blur(function() {
81
- placeholder.show(false);
82
- });
83
-
84
- // On page refresh, IE doesn't re-populate user input
85
- // until the window.onload event is fired.
86
- if ($.browser.msie) {
87
- $(window).load(function() {
88
- if(input.val()) {
89
- input.removeClass("placeholder");
90
- }
91
- placeholder.show(true);
92
- });
93
- // What's even worse, the text cursor disappears
94
- // when tabbing between text inputs, here's a fix
95
- input.focus(function() {
96
- if(this.value == "") {
97
- var range = this.createTextRange();
98
- range.collapse(true);
99
- range.moveStart('character', 0);
100
- range.select();
101
- }
102
- });
103
- }
104
- });
105
- }
106
- })(jQuery);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
lib/options.php DELETED
@@ -1,30 +0,0 @@
1
- <?php global $mt_option; $lib_options = ''; $lib_options = $mt_option['lib_options']; ?>
2
- <div class="option-box">
3
- <label for="page_title"><?php _e('Page title', 'maintenance');?></label>
4
- <input type="text" id="page_title" name="lib_options[page_title]" value="<?php echo ( isset( $lib_options['page_title'] ) ) ? stripslashes($lib_options['page_title']) : _e('Website is under construction', 'maintenance'); ?>" />
5
- </div>
6
- <div class="option-box">
7
- <label for="heading"><?php _e('Headline', 'maintenance');?></label>
8
- <input type="text" id="heading" name="lib_options[heading]" value="<?php echo ( isset( $lib_options['heading'] ) ) ? stripslashes($lib_options['heading']) : _e('Customer login', 'maintenance'); ?>" />
9
- </div>
10
- <div class="option-box">
11
- <label for="time_text"><?php _e('Description', 'maintenance');?></label>
12
- <input type="text" id="time_text" name="lib_options[time_text]" value="<?php echo ( isset( $lib_options['time_text'] ) ) ? stripslashes($lib_options['time_text']) : _e('Please login to see website', 'maintenance'); ?>" />
13
- <div class="option-box">
14
- <label for="theme_logo"><?php _e('Logo', 'maintenance');?></label>
15
- <input type="file" id="theme_logo" name="lib_options[logo]" />
16
- <?php if ( $lib_options['logo'] ): ?><input class="button remove" type="submit" name="remove_logo" value="x" /><?php endif; ?>
17
- </div>
18
- <div class="option-box">
19
- <label for="body_bg"><?php _e('Background image', 'maintenance');?></label>
20
- <input type="file" id="body_bg" name="lib_options[body_bg]" />
21
- <?php if ( $lib_options['body_bg'] ): ?><input class="button remove" type="submit" name="remove_bg" value="x" /><?php endif; ?>
22
- </div>
23
- <div class="option-box">
24
- <label for="body_bg_color"><?php _e('Background color', 'maintenance');?></label>
25
- <input type="text" id="body_bg_color" name="lib_options[body_bg_color]" value="<?php echo ( isset( $lib_options['body_bg_color'] ) ) ? stripslashes($lib_options['body_bg_color']) : '#fff'; ?>" />
26
- </div>
27
- <div class="option-box">
28
- <label for='Admin Bar'><?php _e('Admin Bar', 'maintenance');?></label>
29
- <input type="checkbox" id="admin_bar_enabled" name="lib_options[admin_bar_enabled]" value="1" <?php if (isset($lib_options['admin_bar_enabled'])) { if ($lib_options['admin_bar_enabled'] == "1") { echo 'checked="checked"'; }} ?>/>
30
- </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
lib/style.css DELETED
@@ -1,254 +0,0 @@
1
- @import url(http://fonts.googleapis.com/css?family=Open+Sans:400,300,600,700|Arvo:400,400italic,700,700italic);
2
-
3
- ::selection {
4
- color: #fff;
5
- background: #f676b2; /* Safari */
6
- }
7
- ::-moz-selection {
8
- color: #fff;
9
- background: #f676b2; /* Firefox */
10
- }
11
-
12
- * {
13
- margin: 0;
14
- padding: 0;
15
- border: 0;
16
- }
17
-
18
- body {
19
-
20
- font-family: 'Open Sans', Arial, Helvetica, sans-serif;
21
- font-weight:300;
22
- text-align: left;
23
- text-decoration: none;
24
- }
25
-
26
- #wrapper {
27
- position: absolute;
28
- left: 50%;
29
- top: 50%;
30
- z-index: 1;
31
- }
32
-
33
- .login-form {
34
- width: 300px;
35
- margin: 0 auto;
36
- position: relative;
37
- z-index:5;
38
- border-radius:5px;
39
- background: #fff;
40
- border: 1px solid #fff;
41
- box-shadow: 0px 1px 5px rgba(0,0,0,0.5);
42
- -moz-box-shadow: 0px 1px 5px rgba(0,0,0,0.5);
43
- -webkit-box-shadow: 0px 1px 5px rgba(0,0,0,0.5);
44
- }
45
-
46
-
47
- .login-form .header {
48
- padding: 20px 30px 30px 30px;
49
- text-align: center;
50
- }
51
-
52
- .login-form .header h1 {
53
- font-weight: 300;
54
- font-size: 28px;
55
- line-height:34px;
56
- color: #414848;
57
- text-shadow: 1px 1px 0 rgba(256,256,256,1.0);
58
- margin-bottom: 10px;
59
- text-align: center;
60
- margin-top: 15px;
61
- }
62
-
63
- .login-form .header span {
64
- font-size: 13px;
65
- line-height: 16px;
66
- color:#678889;
67
- font-weight:400;
68
- text-shadow: 1px 1px 0 rgba(256,256,256,1.0);
69
- }
70
-
71
-
72
- .login-form .content {
73
- padding: 0;
74
- position:relative;
75
- z-index:1;
76
- }
77
-
78
- .login-form .content .input {
79
- width: 188px !important;
80
- padding: 15px 25px;
81
-
82
- font-family: "HelveticaNeue-Light", "Helvetica Neue Light", "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif;
83
- font-weight: 400;
84
- font-size: 14px;
85
- color: #9d9e9e;
86
- text-shadow: 1px 1px 0 rgba(256,256,256,1.0);
87
-
88
- /*background: #dfe9ec;*/
89
- border: 1px solid #fff;
90
- border-radius: 5px;
91
-
92
- box-shadow: inset 0 1px 3px rgba(0,0,0,0.50);
93
- -moz-box-shadow: inset 0 1px 3px rgba(0,0,0,0.50);
94
- -webkit-box-shadow: inset 0 1px 3px rgba(0,0,0,0.50);
95
- }
96
-
97
- /* Second input field */
98
- .login-form .content .password, .login-form .content .pass-icon {
99
- margin-top: 25px;
100
- }
101
-
102
- .error-password {top:73px;}
103
-
104
- .login-form .content .input:hover {
105
- /*background: #fff;*/
106
- color: #414848;
107
- }
108
-
109
- .login-form .content .input:focus {
110
- background: #fff;
111
- color: #414848;
112
- box-shadow: inset 0 1px 2px rgba(0,0,0,0.25);
113
- -moz-box-shadow: inset 0 1px 2px rgba(0,0,0,0.25);
114
- -webkit-box-shadow: inset 0 1px 2px rgba(0,0,0,0.25);
115
- }
116
-
117
- input {
118
- outline: none;
119
- }
120
-
121
- .user-icon, .pass-icon, .error-login, .error-password {
122
- width: 46px;
123
- height: 47px;
124
- display: block;
125
- position: absolute;
126
- left: 0px;
127
- padding-right: 2px;
128
- z-index: -3;
129
-
130
- -moz-border-radius-topleft: 5px;
131
- -moz-border-radius-bottomleft: 5px;
132
- -webkit-border-top-left-radius: 5px;
133
- -webkit-border-bottom-left-radius: 5px;
134
- border-top-left-radius:5px;
135
- border-bottom-left-radius:5px;
136
- }
137
-
138
-
139
- .user-icon {
140
- top: 0;
141
- background: #171717 url(images/user-icon.png) no-repeat center;
142
- }
143
-
144
- .pass-icon {
145
- top:48px;
146
- background: #171717 url(images/pass-icon.png) no-repeat center;
147
- }
148
-
149
- /* Animation */
150
- .input, .user-icon, .pass-icon, .button, .register {
151
- transition: all 0.5s;
152
- -moz-transition: all 0.5s;
153
- -webkit-transition: all 0.5s;
154
- -o-transition: all 0.5s;
155
- -ms-transition: all 0.5s;
156
- }
157
-
158
-
159
- .login-form .footer {
160
- padding: 20px 30px 30px;
161
- overflow: auto;
162
-
163
- }
164
-
165
- /* Login button */
166
- .login-form .footer .button {
167
- float:right;
168
- padding: 11px 25px;
169
- font-weight: 300;
170
- font-size: 18px;
171
- color: #fff;
172
- text-shadow: 0px 1px 0 rgba(0,0,0,0.25);
173
- border-radius:5px;
174
- background: #F15A29;
175
- border: 1px solid #fff;
176
- cursor: pointer;
177
-
178
- box-shadow: inset 0 0 2px rgba(256,256,256,0.75);
179
- -moz-box-shadow: inset 0 0 2px rgba(256,256,256,0.75);
180
- -webkit-box-shadow: inset 0 0 2px rgba(256,256,256,0.75);
181
- }
182
-
183
- .login-form .footer .button:hover {
184
- background: #171717;
185
- border: 1px solid rgba(256,256,256,0.75);
186
-
187
- box-shadow: inset 0 1px 3px rgba(0,0,0,0.5);
188
- -moz-box-shadow: inset 0 1px 3px rgba(0,0,0,0.5);
189
- -webkit-box-shadow: inset 0 1px 3px rgba(0,0,0,0.5);
190
- }
191
-
192
- .login-form .footer .button:focus {
193
- position: relative;
194
- bottom: -1px;
195
-
196
- background: #56c2e1;
197
-
198
- box-shadow: inset 0 1px 6px rgba(256,256,256,0.75);
199
- -moz-box-shadow: inset 0 1px 6px rgba(256,256,256,0.75);
200
- -webkit-box-shadow: inset 0 1px 6px rgba(256,256,256,0.75);
201
- }
202
-
203
- /* Register button */
204
- .login-form .footer .register {
205
- display: block;
206
- float: right;
207
- padding: 10px;
208
- margin-right: 20px;
209
-
210
- background: none;
211
- border: none;
212
- cursor: pointer;
213
-
214
- font-family: 'Bree Serif', serif;
215
- font-weight: 300;
216
- font-size: 18px;
217
- color: #414848;
218
- text-shadow: 0px 1px 0 rgba(256,256,256,0.5);
219
- }
220
-
221
- .login-form .footer .register:hover {
222
- color: #3f9db8;
223
- }
224
-
225
- .login-form .footer .register:focus {
226
- position: relative;
227
- bottom: -1px;
228
- }
229
-
230
- .company {
231
- margin-bottom: 45px;
232
- min-width: 600px;
233
- }
234
-
235
- .company a {
236
- width: 100%;
237
- max-width: 600px;
238
-
239
- }
240
-
241
- .company a img {
242
- left: 50%;
243
- position: relative;
244
- }
245
- .inputs{
246
- background:#FFFFFF;
247
- padding:0 30px 15px;
248
- }
249
-
250
- .error-login, .error-password { background:url("images/error.png") no-repeat scroll center center #171717; left: -49px;}
251
-
252
- .company {
253
- margin-bottom: 20px;
254
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
load/functions.php ADDED
@@ -0,0 +1,256 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ function get_custom_login_code() {
4
+ global $wp_query,
5
+ $error;
6
+ $mt_options = mt_get_plugin_options(true);
7
+ $user_connect = false;
8
+ if (!is_array($wp_query->query_vars)) $wp_query->query_vars = array();
9
+ $error_message = $user_login = $user_pass = $error = '';
10
+ $is_role_check = false;
11
+ $class_login = "user-icon";
12
+ $class_password = "pass-icon";
13
+ $using_cookie = false;
14
+
15
+ if(isset($_POST['is_custom_login'])) {
16
+ $user_login = esc_attr($_POST['log']);
17
+ $user_login = sanitize_user( $user_login );
18
+ $user_pass = esc_attr($_POST['pwd']);
19
+ $access = array();
20
+ $access['user_login'] = esc_attr($user_login);
21
+ $access['user_password'] = esc_attr($user_pass);
22
+ $access['remember'] = true;
23
+
24
+ $user = null;
25
+ $user = new WP_User(0, $user_login);
26
+ $current_role = current($user->roles);
27
+
28
+ if (!empty($mt_options['roles_array'])) {
29
+ foreach (array_keys($mt_options['roles_array']) as $key) {
30
+ if ($key == $current_role) { $is_role_check = true; }
31
+ }
32
+ } else {
33
+ $is_role_check = true;
34
+ }
35
+
36
+ if ( !$is_role_check) {
37
+ $error_message = __('Permission access denied!', 'maintenance');
38
+ $class_login = 'error';
39
+ $class_password = 'error';
40
+ } else {
41
+
42
+ $user_connect = wp_signon( $access, false);
43
+ if ( is_wp_error($user_connect) ) {
44
+ if ($user_connect->get_error_code() == 'invalid_username') {
45
+ $error_message = __('You entered your login are incorrect!', 'maintenance');;
46
+ $class_login = 'error';
47
+ $class_password = 'error';
48
+ } else if ($user_connect->get_error_code() == 'incorrect_password') {
49
+ $error_message = __('You entered your password are incorrect!', 'maintenance');
50
+ $class_password = 'error';
51
+ } else {
52
+ $error_message = __('You entered your login and password are incorrect!', 'maintenance');
53
+ $class_login = 'error';
54
+ $class_password = 'error';
55
+ }
56
+ } else {
57
+ wp_redirect(site_url('/'));
58
+ exit;
59
+ }
60
+ }
61
+ }
62
+
63
+ if (!$user_connect) {
64
+ get_headers_503();
65
+ }
66
+
67
+ return array($error_message, $class_login, $class_password, $user_login);
68
+ }
69
+
70
+ function add_custom_style() {
71
+ global $wp_styles;
72
+ wp_register_style('_opensans','http://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800&subset=latin,cyrillic-ext');
73
+ wp_register_style('_iconstyle', MAINTENANCE_URI .'load/images/fonts-icon/icons.style.css');
74
+ wp_register_style('_style', MAINTENANCE_URI .'load/style.css');
75
+ $wp_styles->do_items('_iconstyle');
76
+ $wp_styles->do_items('_opensans');
77
+ $wp_styles->do_items('_style');
78
+ }
79
+
80
+ function add_custom_scripts() {
81
+ global $wp_scripts;
82
+ wp_register_script( '_placeholder', MAINTENANCE_URI .'load/js/jquery.placeholder.js', 'jquery');
83
+ wp_register_script( '_backstretch', MAINTENANCE_URI .'load/js/jquery.backstretch.min.js', 'jquery');
84
+ wp_register_script( '_frontend', MAINTENANCE_URI .'load/js/jquery.frontend.min.js', 'jquery');
85
+ wp_register_script( '_blur', MAINTENANCE_URI .'load/js/jquery.blur.min.js', 'jquery');
86
+
87
+ $wp_scripts->do_items('jquery');
88
+ $wp_scripts->do_items('_placeholder');
89
+ $wp_scripts->do_items('_backstretch');
90
+ $wp_scripts->do_items('_blur');
91
+ $wp_scripts->do_items('_frontend');
92
+ }
93
+
94
+ add_action ('load_custom_scripts', 'add_custom_style', 5);
95
+ add_action ('load_custom_scripts', 'add_custom_scripts', 15);
96
+
97
+ function get_page_title($error_message) {
98
+ $mt_options = mt_get_plugin_options(true);
99
+ $title = $options_title = '';
100
+ if (empty($mt_options['page_title'])) {
101
+ $options_title = wp_title( '|', false);
102
+ } else {
103
+ $options_title = $mt_options['page_title'];
104
+ }
105
+
106
+ if ($error_message != '') {
107
+ $title = $options_title . ' - ' . $error_message;
108
+ } else {
109
+ $title = $options_title;
110
+ }
111
+ echo "<title>$title</title>";
112
+ }
113
+
114
+ function get_options_style() {
115
+ $mt_options = mt_get_plugin_options(true);
116
+ $options_style = '';
117
+ $options_style = '<style type="text/css">';
118
+
119
+ if ( !empty($mt_options['body_bg_color']) ) {
120
+ $options_style .= 'body {background-color: '. esc_attr($mt_options['body_bg_color']) .'}';
121
+ $options_style .= '.preloader {background-color: '. esc_attr($mt_options['body_bg_color']) .'}';
122
+ }
123
+
124
+ if ( !empty($mt_options['font_color']) ) {
125
+ $font_color = esc_attr($mt_options['font_color']);
126
+ $options_style .= '.site-title {color: '. $font_color .'} ';
127
+ $options_style .= '.preloader i {color: '. $font_color .'} ';
128
+ $options_style .= '.login-form {color: '. $font_color .'} ';
129
+ $options_style .= '.ie7 .login-form input[type="text"], .ie7 .login-form input[type="password"], .ie7 .login-form input[type="submit"] {color: '. $font_color .'} ';
130
+ $options_style .= '.site-content {color: '. $font_color .'} ';
131
+ $options_style .= 'footer {color: '. $font_color .'} ';
132
+ $options_style .= '.ie7 .company-name {color: '. $font_color .'} ';
133
+ }
134
+ $options_style .= '</style>';
135
+ echo $options_style;
136
+ }
137
+ add_action('options_style', 'get_options_style', 10);
138
+
139
+ function get_logo_box() {
140
+ $mt_options = mt_get_plugin_options(true);
141
+ $out_html = '';
142
+ $out_html = '<a class="logo" rel="home" href="'.esc_url(site_url('')) .'">';
143
+ if ( !empty($mt_options['logo']) ) {
144
+ $logo = wp_get_attachment_image_src( $mt_options['logo'], 'full');
145
+ $out_html .= '<div class="img-inner">';
146
+ $out_html .= '<img src="'. esc_url($logo[0]) .'" alt="logo"/>';
147
+ $out_html .= '</div>';
148
+ } else {
149
+ $out_html .= '<h1 class="site-title">'. get_bloginfo( 'name' ) .'</h1>';
150
+ }
151
+ $out_html .= '</a>';
152
+ echo $out_html;
153
+ }
154
+ add_action ('logo_box', 'get_logo_box', 10);
155
+
156
+
157
+ function get_content_section() {
158
+ $mt_options = mt_get_plugin_options(true);
159
+ $out_content = '';
160
+ if (!empty($mt_options['heading'])) {
161
+ $out_content .= '<h2 class="heading font-center">' . wp_kses_post(stripslashes($mt_options['heading'])) .'</h3>';
162
+ }
163
+
164
+ if (!empty($mt_options['description'])) {
165
+ $out_content .= '<h3 class="description font-center">' . wp_kses_post(stripslashes($mt_options['description'])) .'</h4>';
166
+ }
167
+
168
+ echo $out_content;
169
+ }
170
+ add_action('content_section', 'get_content_section', 10);
171
+
172
+
173
+ function add_single_background() {
174
+ $out_ = '';
175
+ $mt_options = mt_get_plugin_options(true);
176
+ $intensity = 5;
177
+ if (!empty($mt_options['body_bg'])) {
178
+ if (empty($mt_options['gallery_array']['attachment_ids'])) {
179
+ $out_ .= '<script type="text/javascript">'. "\r\n";
180
+ $out_ .= 'jQuery(document).ready(function() { ' . "\r\n";
181
+ if (!empty($mt_options['body_bg'])) {
182
+ $bg = wp_get_attachment_image_src( $mt_options['body_bg'], 'full');
183
+ $out_ .= 'jQuery.backstretch("'. esc_url($bg[0]) .'");' . "\r\n" ;
184
+ }
185
+
186
+ if (!empty($mt_options['is_blur'])) {
187
+ /*Blur image background*/
188
+ if (!empty($mt_options['blur_intensity'])) {
189
+ $intensity = absint($mt_options['blur_intensity']);
190
+ }
191
+ $out_ .= 'var vblur = jQuery(".backstretch").Vague({intensity:'.$intensity.'}); vblur.blur()' . "\r\n";
192
+ }
193
+
194
+ $out_ .= '});';
195
+ $out_ .= '</script>';
196
+ }
197
+ echo $out_;
198
+ }
199
+ }
200
+ add_action ('add_single_backstretch_background', 'add_single_background', 10);
201
+
202
+ function get_footer_section() {
203
+ $out_ftext = '';
204
+ $out_ftext .= '<a class="company-name" rel="footer" href="'.esc_url(site_url('')) .'">';
205
+ $out_ftext .= '&copy; ' . get_bloginfo( 'name' ) . ' ' . date('Y');
206
+ $out_ftext .= '</a>';
207
+ echo $out_ftext;
208
+ }
209
+ add_action('footer_section', 'get_footer_section', 10);
210
+
211
+ function do_login_form($user_login, $class_login, $class_password) {
212
+ $out_login_form = $form_error = '';
213
+ if (($class_login == 'error') || ($class_password == 'error')) {
214
+ $form_error = ' active error';
215
+ }
216
+ $out_login_form .= '<form name="login-form" id="login-form" class="login-form'.$form_error.'" method="post">';
217
+ $out_login_form .= '<span class="licon '.$class_login.'"><input type="text" name="log" id="log" value="'. $user_login .'" size="20" class="input username" placeholder="'. __('Username', 'maintenance') .'"/></span>';
218
+ $out_login_form .= '<span class="picon '.$class_password.'"><input type="password" name="pwd" id="login_password" value="" size="20" class="input password" placeholder="'. __('Password', 'maintenance') .'" /></span>';
219
+ $out_login_form .= '<input type="submit" class="button" name="submit" id="submit" value="'.__('Sign In','maintenance') .'" tabindex="4" />';
220
+ $out_login_form .= '<input type="hidden" name="is_custom_login" value="1" />';
221
+ $out_login_form .= '</form>';
222
+ echo $out_login_form;
223
+ }
224
+
225
+ function get_preloader_element() {
226
+ $out = '';
227
+ $out = '<div class="preloader"><i></i></div>';
228
+ echo $out;
229
+ }
230
+ add_action('before_content_section', 'get_preloader_element', 5);
231
+
232
+ function maintenance_fruitful_metadevice() {
233
+ $browser = '';
234
+ $browser_ip = strpos($_SERVER['HTTP_USER_AGENT'],"iPhone");
235
+ $browser_an = strpos($_SERVER['HTTP_USER_AGENT'],"Android");
236
+ $browser_ipad = strpos($_SERVER['HTTP_USER_AGENT'],"iPad");
237
+
238
+ if ($browser_ip == true) { $browser = 'iphone'; }
239
+ if ($browser_an == true) { $browser = 'android'; }
240
+ if ($browser_ipad == true) { $browser = 'ipad'; }
241
+
242
+ if($browser == 'iphone') { /*echo '<meta name="viewport" content="width=480px, initial-scale=0.4">'; */ }
243
+ if($browser == 'android') { echo '<meta name="viewport" content="target-densitydpi=device-dpi, width=device-width" />'; }
244
+ if($browser == 'ipad') { echo '<meta name="viewport" content="width=768px, minimum-scale=1.0, maximum-scale=1.0" />'; }
245
+ }
246
+
247
+ function get_headers_503() {
248
+ $mt_options = mt_get_plugin_options(true);
249
+ nocache_headers();
250
+ if (isset($mt_options['503_enabled'])) {
251
+ header('HTTP/1.1 503 Service Temporarily Unavailable');
252
+ header('Status: 503 Service Temporarily Unavailable');
253
+ header('Retry-After: 3600');
254
+ header('X-Powered-By:');
255
+ }
256
+ }
load/images/fonts-icon/general_foundicons.eot ADDED
Binary file
load/images/fonts-icon/general_foundicons.svg ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd" > <svg xmlns="http://www.w3.org/2000/svg" width="100%" height="100%">
2
+ <defs >
3
+ <font id="generalfoundicons" horiz-adv-x="955" ><font-face
4
+ font-family="General Foundicons"
5
+ units-per-em="1000"
6
+ panose-1="0 0 0 0 0 0 0 0 0 0"
7
+ ascent="1000"
8
+ descent="0"
9
+ alphabetic="0" />
10
+ <missing-glyph horiz-adv-x="250" />
11
+ <glyph unicode=" " glyph-name="space" horiz-adv-x="250" />
12
+ <glyph unicode="~" glyph-name="asciitilde" horiz-adv-x="1000" />
13
+ </font>
14
+ </defs>
15
+ </svg>
load/images/fonts-icon/general_foundicons.ttf ADDED
Binary file
load/images/fonts-icon/general_foundicons.woff ADDED
Binary file
load/images/fonts-icon/icons.style.css ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ @font-face {
2
+ font-family: "SocialFoundicons";
3
+ src: url("social_foundicons.eot");
4
+ src: url("social_foundicons.eot?#iefix") format("embedded-opentype"),
5
+ url("social_foundicons.woff") format("woff"),
6
+ url("social_foundicons.ttf") format("truetype"),
7
+ url("social_foundicons.svg#SocialFoundicons") format("svg");
8
+ font-weight: normal;
9
+ font-style: normal;
10
+ }
11
+
12
+ @font-face {
13
+ font-family: "GeneralFoundicons";
14
+ src: url("general_foundicons.eot");
15
+ src: url("general_foundicons.eot?#iefix") format("embedded-opentype"),
16
+ url("general_foundicons.woff") format("woff"),
17
+ url("general_foundicons.ttf") format("truetype"),
18
+ url("general_foundicons.svg#GeneralFoundicons") format("svg");
19
+ font-weight: normal;
20
+ font-style: normal;
21
+ }
load/images/fonts-icon/social_foundicons.eot ADDED
Binary file
load/images/fonts-icon/social_foundicons.svg ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd" > <svg xmlns="http://www.w3.org/2000/svg" width="100%" height="100%">
2
+ <defs >
3
+ <font id="socialfoundicons" horiz-adv-x="933" ><font-face
4
+ font-family="Social Foundicons"
5
+ units-per-em="1000"
6
+ panose-1="0 0 0 0 0 0 0 0 0 0"
7
+ ascent="1000"
8
+ descent="0"
9
+ alphabetic="0" />
10
+ <missing-glyph horiz-adv-x="250" />
11
+ <glyph unicode=" " glyph-name="space" horiz-adv-x="250" />
12
+ <glyph unicode="~" glyph-name="asciitilde" horiz-adv-x="1000" />
13
+ </font>
14
+ </defs>
15
+ </svg>
load/images/fonts-icon/social_foundicons.ttf ADDED
Binary file
load/images/fonts-icon/social_foundicons.woff ADDED
Binary file
load/index.php ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ $mess_arr = array();
3
+ $mess_arr = get_custom_login_code();
4
+ ?>
5
+ <!DOCTYPE html>
6
+ <!--[if IE 7]>
7
+ <html class="ie ie7" <?php language_attributes(); ?>>
8
+ <![endif]-->
9
+ <!--[if IE 8]>
10
+ <html class="ie ie8" <?php language_attributes(); ?>>
11
+ <![endif]-->
12
+ <!--[if !(IE 7) | !(IE 8) ]><!-->
13
+ <html <?php language_attributes(); ?>>
14
+ <!--<![endif]-->
15
+ <head>
16
+ <meta charset="<?php bloginfo( 'charset' ); ?>" />
17
+ <?php maintenance_fruitful_metadevice(); ?>
18
+ <?php get_page_title(esc_attr($mess_arr[0])); ?>
19
+ <link rel="profile" href="http://gmpg.org/xfn/11" />
20
+ <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
21
+ <?php do_action('load_custom_scripts'); ?>
22
+ <?php do_action('options_style'); ?>
23
+ <?php do_action('add_single_backstretch_background'); ?>
24
+ </head>
25
+ <body>
26
+ <?php do_action('before_content_section'); ?>
27
+ <div id="wrapper">
28
+ <div class="center">
29
+ <header>
30
+ <?php do_action('logo_box'); ?>
31
+ <?php do_login_form(esc_attr($mess_arr[3]), esc_attr($mess_arr[1]), esc_attr($mess_arr[2])); ?>
32
+ </header>
33
+ </div>
34
+
35
+ <div id="content" class="site-content">
36
+ <div class="center">
37
+ <?php do_action('content_section'); ?>
38
+ </div>
39
+ </div>
40
+
41
+ </div> <!-- end wrapper -->
42
+ <footer role="contentinfo">
43
+ <div class="center">
44
+ <?php do_action('footer_section'); ?>
45
+ </div>
46
+ </footer>
47
+
48
+ <?php do_action('after_content_section'); ?>
49
+ </body>
50
+ </html>
load/js/jquery.backstretch.min.js ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ (function($,window,undefined){$.fn.backstretch=function(images,options){if(images===undefined||images.length===0)$.error("No images were supplied for Backstretch");if($(window).scrollTop()===0)window.scrollTo(0,0);return this.each(function(){var $this=$(this),obj=$this.data("backstretch");if(obj){options=$.extend(obj.options,options);obj.destroy(true)}obj=new Backstretch(this,images,options);$this.data("backstretch",obj)})};$.backstretch=function(images,options){return $("body").backstretch(images,
2
+ options).data("backstretch")};$.expr[":"].backstretch=function(elem){return $(elem).data("backstretch")!==undefined};$.fn.backstretch.defaults={centeredX:true,centeredY:true,duration:5E3,fade:0};var styles={wrap:{left:0,top:0,overflow:"hidden",margin:0,padding:0,height:"100%",width:"100%",zIndex:-999999},img:{position:"absolute",display:"none",margin:0,padding:0,border:"none",width:"auto",height:"auto",maxWidth:"none",zIndex:-999999}};var Backstretch=function(container,images,options){this.options=
3
+ $.extend({},$.fn.backstretch.defaults,options||{});this.images=$.isArray(images)?images:[images];$.each(this.images,function(){$("<img />")[0].src=this});this.isBody=container===document.body;this.$container=$(container);this.$root=this.isBody?supportsFixedPosition?$(window):$(document):this.$container;var $existing=this.$container.children(".backstretch").first();this.$wrap=$existing.length?$existing:$('<div class="backstretch"></div>').css(styles.wrap).appendTo(this.$container);if(!this.isBody){var position=
4
+ this.$container.css("position"),zIndex=this.$container.css("zIndex");this.$container.css({position:position==="static"?"relative":position,zIndex:zIndex==="auto"?0:zIndex,background:"none"});this.$wrap.css({zIndex:-999998})}this.$wrap.css({position:this.isBody&&supportsFixedPosition?"fixed":"absolute"});this.index=0;this.show(this.index);$(window).on("resize.backstretch",$.proxy(this.resize,this)).on("orientationchange.backstretch",$.proxy(function(){if(this.isBody&&window.pageYOffset===0){window.scrollTo(0,
5
+ 1);this.resize()}},this))};Backstretch.prototype={resize:function(){try{var bgCSS={left:0,top:0},rootWidth=this.isBody?this.$root.width():this.$root.innerWidth(),bgWidth=rootWidth,rootHeight=this.isBody?window.innerHeight?window.innerHeight:this.$root.height():this.$root.innerHeight(),bgHeight=bgWidth/this.$img.data("ratio"),bgOffset;if(bgHeight>=rootHeight){bgOffset=(bgHeight-rootHeight)/2;if(this.options.centeredY)bgCSS.top="-"+bgOffset+"px"}else{bgHeight=rootHeight;bgWidth=bgHeight*this.$img.data("ratio");
6
+ bgOffset=(bgWidth-rootWidth)/2;if(this.options.centeredX)bgCSS.left="-"+bgOffset+"px"}this.$wrap.css({width:rootWidth,height:rootHeight}).find("img:not(.deleteable)").css({width:bgWidth,height:bgHeight}).css(bgCSS)}catch(err){}return this},show:function(index){if(Math.abs(index)>this.images.length-1)return;else this.index=index;var self=this,oldImage=self.$wrap.find("img").addClass("deleteable"),evt=$.Event("backstretch.show",{relatedTarget:self.$container[0]});clearInterval(self.interval);self.$img=
7
+ $("<img />").css(styles.img).bind("load",function(e){var imgWidth=this.width||$(e.target).width(),imgHeight=this.height||$(e.target).height();$(this).data("ratio",imgWidth/imgHeight);$(this).fadeIn(self.options.speed||self.options.fade,function(){oldImage.remove();if(!self.paused)self.cycle();self.$container.trigger(evt,self)});self.resize()}).appendTo(self.$wrap);self.$img.attr("src",self.images[index]);return self},next:function(){return this.show(this.index<this.images.length-1?this.index+1:0)},
8
+ prev:function(){return this.show(this.index===0?this.images.length-1:this.index-1)},pause:function(){this.paused=true;return this},resume:function(){this.paused=false;this.next();return this},cycle:function(){if(this.images.length>1){clearInterval(this.interval);this.interval=setInterval($.proxy(function(){if(!this.paused)this.next()},this),this.options.duration)}return this},destroy:function(preserveBackground){$(window).off("resize.backstretch orientationchange.backstretch");clearInterval(this.interval);
9
+ if(!preserveBackground)this.$wrap.remove();this.$container.removeData("backstretch")}};var supportsFixedPosition=function(){var ua=navigator.userAgent,platform=navigator.platform,wkmatch=ua.match(/AppleWebKit\/([0-9]+)/),wkversion=!!wkmatch&&wkmatch[1],ffmatch=ua.match(/Fennec\/([0-9]+)/),ffversion=!!ffmatch&&ffmatch[1],operammobilematch=ua.match(/Opera Mobi\/([0-9]+)/),omversion=!!operammobilematch&&operammobilematch[1],iematch=ua.match(/MSIE ([0-9]+)/),ieversion=!!iematch&&iematch[1];return!((platform.indexOf("iPhone")>
10
+ -1||(platform.indexOf("iPad")>-1||platform.indexOf("iPod")>-1))&&(wkversion&&wkversion<534)||(window.operamini&&{}.toString.call(window.operamini)==="[object OperaMini]"||(operammobilematch&&omversion<7458||(ua.indexOf("Android")>-1&&(wkversion&&wkversion<533)||(ffversion&&ffversion<6||("palmGetResource"in window&&(wkversion&&wkversion<534)||(ua.indexOf("MeeGo")>-1&&ua.indexOf("NokiaBrowser/8.5.0")>-1||ieversion&&ieversion<=6)))))))}()})(jQuery,window);
load/js/jquery.blur.min.js ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
1
+ (function(window,document,$){var cache={filterId:0};var Vague=function(elm,customOptions){var defaultOptions={intensity:5},options=$.extend(defaultOptions,customOptions);this.$elm=elm instanceof $?elm:$(elm);var blurred=false;var browserPrefixes=" -webkit- -moz- -o- -ms- ".split(" ");var cssPrefixString={};var cssPrefix=function(property){if(cssPrefixString[property]||cssPrefixString[property]==="")return cssPrefixString[property]+property;var e=document.createElement("div");var prefixes=["","Moz",
2
+ "Webkit","O","ms","Khtml"];for(var i in prefixes)if(typeof e.style[prefixes[i]+property]!=="undefined"){cssPrefixString[property]=prefixes[i];return prefixes[i]+property}return property.toLowerCase()};var cssfilters=function(){var el=document.createElement("div");el.style.cssText=browserPrefixes.join("filter"+":blur(2px); ");return!!el.style.length&&(document.documentMode===undefined||document.documentMode>9)}();var svgfilters=function(){var result=false;try{result=typeof SVGFEColorMatrixElement!==
3
+ undefined&&SVGFEColorMatrixElement.SVG_FECOLORMATRIX_TYPE_SATURATE==2}catch(e){}return result}();var appendSVGFilter=function(){var filterMarkup="<svg id='vague-svg-blur'>"+"<filter id='blur-effect-id-"+cache.filterId+"'>"+"<feGaussianBlur stdDeviation='"+options.intensity+"' />"+"</filter>"+"</svg>";$("body").append(filterMarkup)};this.init=function(){if(svgfilters)appendSVGFilter();this.$elm.data("vague-filter-id",cache.filterId);cache.filterId++};this.blur=function(){var filterValue,filterId=this.$elm.data("vague-filter-id"),
4
+ cssProp={};if(cssfilters)filterValue="blur("+options.intensity+"px)";else if(svgfilters)filterValue="url(#blur-effect-id-"+filterId+")";else filterValue="progid:DXImageTransform.Microsoft.Blur(pixelradius="+options.intensity+")";cssProp[cssPrefix("Filter")]=filterValue;this.$elm.css(cssProp);blurred=true};this.unblur=function(){var cssProp={};cssProp[cssPrefix("Filter")]="none";this.$elm.css(cssProp);blurred=false};this.toggleblur=function(){if(blurred)this.unblur();else this.blur()};this.destroy=
5
+ function(){if(svgfilters)$("filter#blur-effect-id-"+this.$elm.data("vague-filter-id")).parent().remove();this.unblur()};return this.init()};$.fn.Vague=function(options){return new Vague(this,options)};window.Vague=Vague})(window,document,jQuery);
load/js/jquery.frontend.js ADDED
@@ -0,0 +1,53 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ jQuery(document).ready(function() {
2
+ jQuery('input[placeholder], textarea[placeholder]').placeholder();
3
+ jQuery('#login-form').submit(function() {
4
+ if (!jQuery(this).hasClass('active')) {
5
+ jQuery(this).find('span.licon').fadeIn(300);
6
+ jQuery(this).find('span.picon').fadeIn(300);
7
+ jQuery(this).addClass('active');
8
+ jQuery(this).find('input[type="text"]').focus();
9
+ return false;
10
+ }
11
+ });
12
+
13
+ if (jQuery('#login-form').hasClass('error')){
14
+ jQuery('#login-form').find('span.licon').fadeIn(100);
15
+ jQuery('#login-form').find('span.picon').fadeIn(100);
16
+ jQuery('#login-form').find('input[type="text"]').focus();
17
+ }
18
+
19
+ jQuery(window).resize();
20
+ jQuery('body > div:not(".preloader")').each(function() {
21
+ jQuery(this).css({'visibility': 'hidden'});
22
+ });
23
+ });
24
+
25
+ jQuery(window).load(function() {
26
+ jQuery('#content').center();
27
+ jQuery('body > div:not(".preloader")').each(function() {
28
+ jQuery(this).css({'visibility': 'visible'});
29
+ });
30
+ setInterval( function() { jQuery('body > .preloader').fadeOut(300); }, 1000);
31
+ });
32
+
33
+ jQuery(window).resize(function() {
34
+ if ((jQuery(window).width() < 1025) || (jQuery(window).width() < 769)) {
35
+ jQuery('#login-form').find('span.licon').fadeIn(300);
36
+ jQuery('#login-form').find('span.picon').fadeIn(300);
37
+ jQuery('#login-form').addClass('active');
38
+ } else {
39
+ if (!jQuery('#login-form').hasClass('error')) {
40
+ jQuery('#login-form').find('span.licon').fadeOut(300);
41
+ jQuery('#login-form').find('span.picon').fadeOut(300);
42
+ jQuery('#login-form').removeClass('active');
43
+ }
44
+ }
45
+
46
+ jQuery('#content').center();
47
+ });
48
+
49
+ jQuery.fn.center = function () {
50
+ this.css("position","absolute");
51
+ this.css("top", Math.max(0, ((jQuery(window).height() - jQuery(this).outerHeight()) / 2) + jQuery(window).scrollTop()) + "px");
52
+ return this;
53
+ }
load/js/jquery.frontend.min.js ADDED
@@ -0,0 +1 @@
 
1
+ jQuery(document).ready(function(){jQuery("input[placeholder], textarea[placeholder]").placeholder();jQuery("#login-form").submit(function(){if(!jQuery(this).hasClass("active")){jQuery(this).find("span.licon").fadeIn(300);jQuery(this).find("span.picon").fadeIn(300);jQuery(this).addClass("active");jQuery(this).find('input[type="text"]').focus();return false}});if(jQuery("#login-form").hasClass("error")){jQuery("#login-form").find("span.licon").fadeIn(100);jQuery("#login-form").find("span.picon").fadeIn(100); jQuery("#login-form").find('input[type="text"]').focus()}jQuery(window).resize();jQuery('body > div:not(".preloader")').each(function(){jQuery(this).css({"visibility":"hidden"})})});jQuery(window).load(function(){jQuery("#content").center();jQuery('body > div:not(".preloader")').each(function(){jQuery(this).css({"visibility":"visible"})});setInterval(function(){jQuery("body > .preloader").fadeOut(300)},1E3)}); jQuery(window).resize(function(){if(jQuery(window).width()<1025||jQuery(window).width()<769){jQuery("#login-form").find("span.licon").fadeIn(300);jQuery("#login-form").find("span.picon").fadeIn(300);jQuery("#login-form").addClass("active")}else if(!jQuery("#login-form").hasClass("error")){jQuery("#login-form").find("span.licon").fadeOut(300);jQuery("#login-form").find("span.picon").fadeOut(300);jQuery("#login-form").removeClass("active")}jQuery("#content").center()}); jQuery.fn.center=function(){this.css("position","absolute");this.css("top",Math.max(0,(jQuery(window).height()-jQuery(this).outerHeight())/2+jQuery(window).scrollTop())+"px");return this};
load/js/jquery.placeholder.js ADDED
@@ -0,0 +1 @@
 
1
+ (function(b){function a(d){this.input=d;if(d.attr("type")=="password"){this.handlePassword()}b(d[0].form).submit(function(){if(d.hasClass("placeholder")&&d[0].value==d.attr("placeholder")){d[0].value=""}})}a.prototype={show:function(f){if(this.input[0].value===""||(f&&this.valueIsPlaceholder())){if(this.isPassword){try{this.input[0].setAttribute("type","text")}catch(d){this.input.before(this.fakePassword.show()).hide()}}this.input.addClass("placeholder");this.input[0].value=this.input.attr("placeholder")}},hide:function(){if(this.valueIsPlaceholder()&&this.input.hasClass("placeholder")){this.input.removeClass("placeholder");this.input[0].value="";if(this.isPassword){try{this.input[0].setAttribute("type","password")}catch(d){}this.input.show();this.input[0].focus()}}},valueIsPlaceholder:function(){return this.input[0].value==this.input.attr("placeholder")},handlePassword:function(){var d=this.input;d.attr("realType","password");this.isPassword=true;if(b.browser.msie&&d[0].outerHTML){var e=b(d[0].outerHTML.replace(/type=(['"])?password\1/gi,"type=$1text$1"));this.fakePassword=e.val(d.attr("placeholder")).addClass("placeholder").focus(function(){d.trigger("focus");b(this).hide()});b(d[0].form).submit(function(){e.remove();d.show()})}}};var c=!!("placeholder" in document.createElement("input"));b.fn.placeholder=function(){return c?this:this.each(function(){var d=b(this);var e=new a(d);e.show(true);d.focus(function(){e.hide()});d.blur(function(){e.show(false)});if(b.browser.msie){b(window).load(function(){if(d.val()){d.removeClass("placeholder")}e.show(true)});d.focus(function(){if(this.value==""){var f=this.createTextRange();f.collapse(true);f.moveStart("character",0);f.select()}})}})}})(jQuery);
load/style.css ADDED
@@ -0,0 +1,388 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ *:before,
2
+ *:after { -moz-box-sizing: border-box; -webkit-box-sizing: border-box; box-sizing: border-box; }
3
+
4
+ * { margin: 0; padding: 0; border: 0; outline:none;}
5
+
6
+ html {
7
+ height:100%;
8
+ width: 100%;
9
+ overflow:hidden;
10
+ }
11
+
12
+ body {
13
+ font-family:"Open Sans", sans-serif;
14
+ height:100%;
15
+ width: 100%;
16
+ overflow:auto;
17
+ }
18
+
19
+ body > #wrapper {height: auto; min-height: 100%; width:100%;}
20
+
21
+ .center {
22
+ clear: both;
23
+ content: "";
24
+ display: block;
25
+ margin: 0 auto;
26
+ max-width: 1020px;
27
+ min-width: 640px;
28
+ width: 100%;
29
+ }
30
+
31
+ #wrapper {
32
+ width:100%;
33
+ height:100%;
34
+ position:relative;
35
+ min-width:640px;
36
+ }
37
+
38
+ header {
39
+ position:relative;
40
+ display:block;
41
+ width:95%;
42
+ float:left;
43
+ padding:25px 20px;
44
+ max-width:980px
45
+ min-width:640px;
46
+ z-index:9999999;
47
+ }
48
+
49
+ .site-content {
50
+ position:relative;
51
+ float:left;
52
+ display:block;
53
+ width:100%;
54
+ left:0;
55
+ top:0;
56
+ color:#fff;
57
+ }
58
+
59
+ .site-content .font-center {
60
+ text-align:center;
61
+ }
62
+
63
+ .site-content h2,
64
+ .site-content h3 {
65
+ width:100%;
66
+ display:block;
67
+ }
68
+
69
+ .site-content h2.heading {
70
+ font-size:45px;
71
+ font-weight:lighter;
72
+ }
73
+
74
+ .site-content h3.description {
75
+ font-size:28px;
76
+ font-weight:lighter;
77
+ }
78
+
79
+ .site-content p {
80
+ font-size: 16px;
81
+ margin: 0 0 15px 0;
82
+ line-height: 24px;
83
+ }
84
+
85
+ footer {
86
+ position: relative;
87
+ margin-top: -100px;
88
+ height: 100px;
89
+ clear:both;
90
+ display:block;
91
+ width:100%;
92
+ float:left;
93
+ color:#fff;
94
+ }
95
+
96
+
97
+ .company-name {
98
+ width:100%;
99
+ display:block;
100
+ text-decoration:none;
101
+ font-family: 'Open Sans';
102
+ font-weight:bold;
103
+ color:inherit;
104
+ font-size:16px;
105
+ text-align:center;
106
+ float:left;
107
+ }
108
+
109
+ .logo {
110
+ font-family: 'Open Sans', sans-serif;
111
+ font-weight:normal;
112
+ text-decoration:none;
113
+ float:left;
114
+ }
115
+
116
+ .logo .img-inner {
117
+ max-width:200px;
118
+ max-height:200px;
119
+ float:left;
120
+ display:block;
121
+ }
122
+
123
+ .logo img {
124
+ float:left;
125
+ height:100%;
126
+ width:100%;
127
+ }
128
+
129
+ .site-title {
130
+ font-family: 'Open Sans', sans-serif;
131
+ font-weight:lighter;
132
+ }
133
+
134
+
135
+ .login-form {
136
+ float:right;
137
+ display:block;
138
+ width:auto;
139
+ margin:7px 0 0 0;
140
+ }
141
+
142
+ .login-form input[type="text"],
143
+ .login-form input[type="password"] {
144
+ color:inherit;
145
+ background-color: rgba(113,113,113, 0.6);
146
+ background-position: 14px center;
147
+ background-repeat: no-repeat;
148
+ float: left;
149
+ font-family: 'Open Sans',sans-serif;
150
+ font-size: 20px;
151
+ font-weight: 400;
152
+ line-height: 20px;
153
+ margin: 0 14px 0 0;
154
+ max-width: 100px;
155
+ padding: 5px 16px 5px 40px;
156
+ width: 100px;
157
+ display:block;
158
+ line-height: 28px;
159
+ outline:none;
160
+ }
161
+
162
+
163
+
164
+ .ie8 .login-form input[type="text"],
165
+ .ie8 .login-form input[type="password"],
166
+ .ie7 .login-form input[type="text"],
167
+ .ie7 .login-form input[type="password"] {
168
+ background-color:#717171;
169
+ }
170
+
171
+
172
+ .login-form .licon,
173
+ .login-form .picon {
174
+ position:relative;
175
+ float:left;
176
+ display:none;
177
+ -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=50)";
178
+ filter: alpha(opacity=50);
179
+ -moz-opacity: .5;
180
+ -khtml-opacity: .5;
181
+ opacity: .5;
182
+ -webkit-transition: opacity .3s ease-in-out;
183
+ -moz-transition: opacity .3s ease-in-out;
184
+ -ms-transition: opacity .3s ease-in-out;
185
+ -o-transition: opacity .3s ease-in-out;
186
+ transition: opacity .3s ease-in-out;
187
+ }
188
+
189
+ .ie7 .login-form .licon,
190
+ .ie7 .login-form .picon {
191
+ margin:8px 0 0 0;
192
+ }
193
+
194
+ .login-form .licon:before,
195
+ .login-form .picon:before {
196
+ position:absolute;
197
+ font-weight: normal;
198
+ font-style: normal;
199
+ font-size:20px;
200
+ color:inherit;
201
+ text-decoration: inherit;
202
+ display: block;
203
+ width: auto;
204
+ height: auto;
205
+ line-height: inherit;
206
+ vertical-align: baseline;
207
+ background-image: none;
208
+ background-position: 0 0;
209
+ background-repeat: repeat;
210
+ top: 8px;
211
+ left: 10px;
212
+ }
213
+
214
+ .login-form .licon:before {
215
+ content: "\f019";
216
+ font-family: "SocialFoundicons";
217
+ }
218
+
219
+ .ie7 .login-form .licon:before {
220
+ *zoom: expression(this.runtimeStyle['zoom'] = "1", this.innerHTML = "&#xf019;");
221
+ }
222
+
223
+
224
+ .login-form .picon:before {
225
+ content: "\f01b";
226
+ font-family: "GeneralFoundicons";
227
+ }
228
+
229
+ .login-form .licon.error:before,
230
+ .login-form .picon.error:before {
231
+ content: "\f006";
232
+ font-family: "GeneralFoundicons";
233
+ color:red;
234
+ }
235
+
236
+ .login-form input[type="submit"] {
237
+ color:inherit;
238
+ font-size:25px;
239
+ font-family: 'Open Sans', sans-serif;
240
+ background:none;
241
+ font-weight:bold;
242
+ float: left;
243
+ cursor:pointer;
244
+ -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=50)";
245
+ filter: alpha(opacity=50);
246
+ -moz-opacity: .5;
247
+ -khtml-opacity: .5;
248
+ opacity: .5;
249
+ -webkit-transition: opacity .3s ease-in-out;
250
+ -moz-transition: opacity .3s ease-in-out;
251
+ -ms-transition: opacity .3s ease-in-out;
252
+ -o-transition: opacity .3s ease-in-out;
253
+ transition: opacity .3s ease-in-out;
254
+ }
255
+ .login-form.active:hover .licon,
256
+ .login-form.active:hover .picon,
257
+ .login-form.active:hover input[type="submit"] {
258
+ -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=100)";
259
+ filter: alpha(opacity=100);
260
+ -moz-opacity: 1;
261
+ -khtml-opacity: 1;
262
+ opacity: 1;
263
+ }
264
+
265
+ .preloader {
266
+ display: block;
267
+ height: 100%;
268
+ position: absolute;
269
+ width: 100%;
270
+ z-index: 99999991;
271
+ }
272
+
273
+
274
+ .preloader i {
275
+ background: none repeat scroll 0 0 rgba(0, 0, 0, 0);
276
+ display: block;
277
+ height: 58px;
278
+ left: 50%;
279
+ margin: -29px 0 0 -25px;
280
+ position: absolute;
281
+ top: 50%;
282
+ width: 50px;
283
+ }
284
+
285
+ .preloader i:before {
286
+ position:absolute;
287
+ font-weight: normal;
288
+ font-style: normal;
289
+ font-size:50px;
290
+ color:inherit;
291
+ text-decoration: inherit;
292
+ display: block;
293
+ width: auto;
294
+ height: auto;
295
+ line-height: inherit;
296
+ vertical-align: baseline;
297
+ background-image: none;
298
+ background-position: center center;
299
+ background-repeat: repeat;
300
+ }
301
+
302
+ .preloader i:before {
303
+ content: "\f000";
304
+ font-family: "GeneralFoundicons";
305
+
306
+ -webkit-animation-name: spin;
307
+ -webkit-animation-duration: 2200ms;
308
+ -webkit-animation-iteration-count: infinite;
309
+ -webkit-animation-timing-function: linear;
310
+ -moz-animation-name: spin;
311
+ -moz-animation-duration: 2200ms;
312
+ -moz-animation-iteration-count: infinite;
313
+ -moz-animation-timing-function: linear;
314
+ -ms-animation-name: spin;
315
+ -ms-animation-duration: 2200ms;
316
+ -ms-animation-iteration-count: infinite;
317
+ -ms-animation-timing-function: linear;
318
+
319
+ animation-name: spin;
320
+ animation-duration: 2200ms;
321
+ animation-iteration-count: infinite;
322
+ animation-timing-function: linear;
323
+ }
324
+
325
+ @-ms-keyframes spin {
326
+ from { -ms-transform: rotate(0deg); }
327
+ to { -ms-transform: rotate(360deg); }
328
+ }
329
+ @-moz-keyframes spin {
330
+ from { -moz-transform: rotate(0deg); }
331
+ to { -moz-transform: rotate(360deg); }
332
+ }
333
+ @-webkit-keyframes spin {
334
+ from { -webkit-transform: rotate(0deg); }
335
+ to { -webkit-transform: rotate(360deg); }
336
+ }
337
+ @keyframes spin {
338
+ from {transform:rotate(0deg);}
339
+ to {transform:rotate(360deg);}
340
+ }
341
+
342
+ ::-webkit-input-placeholder { /* WebKit browsers */
343
+ font-size:20px;
344
+ color:inherit;
345
+ font-family: 'Open Sans', sans-serif;
346
+ opacity:1;
347
+ }
348
+ :-moz-placeholder { /* Mozilla Firefox 4 to 18 */
349
+ font-size:20px;
350
+ color:inherit;
351
+ font-family: 'Open Sans', sans-serif;
352
+ opacity:1;
353
+ }
354
+ ::-moz-placeholder { /* Mozilla Firefox 19+ */
355
+ font-size:20px;
356
+ color:inherit;
357
+ font-family: 'Open Sans', sans-serif;
358
+ opacity:1;
359
+ }
360
+ :-ms-input-placeholder { /* Internet Explorer 10+ */
361
+ font-size:20px;
362
+ color:inherit;
363
+ font-family: 'Open Sans', sans-serif;
364
+ opacity:1;
365
+ }
366
+
367
+
368
+ @media screen and (max-width: 768px) {
369
+ .logo {width:100%; text-align:center; margin:0 0 20px 0;}
370
+ header {padding:25px 0;}
371
+ .login-form { margin:0 auto; float:none; width:100%; max-width:430px;}
372
+ }
373
+
374
+ @media only screen
375
+ and (min-device-width : 320px)
376
+ and (max-device-width : 568px) {
377
+ .logo {width:100%; text-align:center; margin:0 0 20px 0;}
378
+ header {padding:25px 0;}
379
+ .login-form { margin:0 auto; float:none; width:100%; max-width:430px;}
380
+ }
381
+
382
+ @media only screen
383
+ and (min-device-width : 768px)
384
+ and (max-device-width : 1024px) {
385
+ .logo {width:100%; text-align:center; margin:0 0 20px 0;}
386
+ header {padding:25px 0;}
387
+ .login-form { margin:0 auto; float:none; width:100%; max-width:430px;}
388
+ }
maintenance.php ADDED
@@ -0,0 +1,102 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /*
3
+ Plugin Name: Maintenance
4
+ Plugin URI: http://wordpress.org/extend/plugins/maintenance/
5
+ Description: Easily close your wordpress website for maintenance. Try free version or purchase maintenance PRO with more useful features and extended HTML template.
6
+ Version: 2.0.0
7
+ Author: fruitfulcode
8
+ Author URI: http://fruitfulcode.com
9
+ License: GPL2
10
+ */
11
+ /* Copyright 2013 Fruitful Code (email : support@fruitfulcode.com)
12
+
13
+ This program is free software; you can redistribute it and/or modify
14
+ it under the terms of the GNU General Public License, version 2, as
15
+ published by the Free Software Foundation.
16
+
17
+ This program is distributed in the hope that it will be useful,
18
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
19
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20
+ GNU General Public License for more details.
21
+
22
+ You should have received a copy of the GNU General Public License
23
+ along with this program; if not, write to the Free Software
24
+ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
25
+ */
26
+
27
+ class maintenance {
28
+ function __construct() {
29
+ global $maintenance_variable;
30
+ $maintenance_variable = new stdClass;
31
+
32
+ add_action( 'plugins_loaded', array( &$this, 'constants'), 1);
33
+ add_action( 'plugins_loaded', array( &$this, 'lang'), 2);
34
+ add_action( 'plugins_loaded', array( &$this, 'includes'), 3);
35
+ add_action( 'plugins_loaded', array( &$this, 'admin'), 4);
36
+
37
+
38
+ register_activation_hook ( __FILE__, array( &$this, 'activation' ));
39
+ register_deactivation_hook( __FILE__, array( &$this,'deactivation') );
40
+
41
+ add_action('template_redirect', array( &$this, 'mt_template_redirect'));
42
+ add_action('wp_logout', array( &$this, 'mt_user_logout'));
43
+ add_action('init', array( &$this, 'mt_admin_bar'));
44
+ }
45
+
46
+ function constants() {
47
+ define( 'MAINTENANCE_VERSION', '2.0.0' );
48
+ define( 'MAINTENANCE_DB_VERSION', 1 );
49
+ define( 'MAINTENANCE_WP_VERSION', get_bloginfo( 'version' ));
50
+ define( 'MAINTENANCE_DIR', trailingslashit( plugin_dir_path( __FILE__ ) ) );
51
+ define( 'MAINTENANCE_URI', trailingslashit( plugin_dir_url( __FILE__ ) ) );
52
+ define( 'MAINTENANCE_INCLUDES', MAINTENANCE_DIR . trailingslashit( 'includes' ) );
53
+ define( 'MAINTENANCE_LOAD', MAINTENANCE_DIR . trailingslashit( 'load' ) );
54
+ }
55
+
56
+ function lang() {
57
+ load_plugin_textdomain( 'maintenance', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );
58
+ }
59
+
60
+ function includes() {
61
+ require_once( MAINTENANCE_INCLUDES . 'functions.php' );
62
+ require_once( MAINTENANCE_INCLUDES . 'update.php' );
63
+ require_once( MAINTENANCE_DIR . 'load/functions.php' );
64
+ }
65
+
66
+ function admin() {
67
+ if ( is_admin() ) {
68
+ require_once( MAINTENANCE_INCLUDES . 'admin.php' );
69
+ }
70
+ }
71
+
72
+ function activation() {
73
+ }
74
+ function deactivation() {
75
+ delete_option('maintenance_options');
76
+ delete_option('maintenance_db_version');
77
+ }
78
+
79
+ function mt_user_logout() {
80
+ wp_safe_redirect(get_bloginfo('url'));
81
+ exit;
82
+ }
83
+
84
+ function mt_template_redirect() {
85
+ load_maintenace_page();
86
+ }
87
+
88
+ function mt_admin_bar() {
89
+ add_action('admin_bar_menu', 'maintenace_add_toolbar_items', 100);
90
+ if (!is_admin() ) {
91
+ $mt_options = mt_get_plugin_options(true);
92
+ if (isset($mt_options['admin_bar_enabled']) && is_user_logged_in()) {
93
+ add_filter('show_admin_bar', '__return_true');
94
+ } else {
95
+ add_filter('show_admin_bar', '__return_false');
96
+ }
97
+ }
98
+ }
99
+ }
100
+
101
+ $maintenance = new maintenance();
102
+ ?>
page-options.php DELETED
@@ -1,66 +0,0 @@
1
- <?php
2
-
3
- function mt_manage_options()
4
- {
5
- global $mt_option;
6
-
7
- $mt_option = mt_get_option();
8
-
9
- if ( $_POST ) {
10
- $state = $_POST['state'];
11
- if (!$state) { $mt_option['state'] = 'live'; }
12
- else { $mt_option['state'] = 'maintenance'; }
13
-
14
- $mt_option['lib_options'] = $_POST['lib_options'];
15
-
16
- /* trigger theme activation */
17
- if ( file_exists( dirname( __FILE__ ).'/'.LIB_DIR.'/functions.php' ) ) {
18
- include_once dirname( __FILE__ ).'/'.LIB_DIR.'/functions.php';
19
- $mt_option = apply_filters( 'lib_update', $mt_option );
20
- }
21
-
22
- /* counter */
23
- $mt_option['expiry_date'] = $_POST['lib_options']['expiry_date'] ? $_POST['lib_options']['expiry_date'] : '';
24
- if ( !$mt_option['expiry_date'] ) {
25
- unset( $mt_option['expiry_date'] );
26
- }
27
- mt_update_option($mt_option);
28
- }
29
-
30
- mt_get_lib_var();
31
- ?>
32
-
33
- <div id="maintenance-options" class="wrap">
34
- <form method="post" action="" enctype="multipart/form-data" name="options-form">
35
- <div id="general">
36
- <div class="title">
37
- <img src="<?php echo PLUGIN_URL ?>images/icon.png" alt="Logo" class="logo" />
38
- <h1>Maintenance -</h1>
39
- <input name="state" type="checkbox" id="ch_location" name="ch_location" <?php if ( $mt_option['state'] == 'maintenance' ) echo 'checked="true"' ?> />
40
- </div>
41
-
42
- <div class="theme-options">
43
- <?php include_once dirname( __FILE__ ).'/'.LIB_DIR.'/options.php'; ?>
44
- <input type="submit" id="mt-submit" name="save_changes" class="button-primary" value="<?php _e('Save changes', 'maintenance');?>" />
45
- </div>
46
- </div>
47
- </form>
48
-
49
- <!-- Contact Support-->
50
- <div id="contact-support">
51
- <a href="mailto:support@fruitfulcode.com" title="<?php _e('Contact Support', 'maintenance');?>" target="_blank">
52
- <?php _e('Contact Support', 'maintenance');?>
53
- </a><br>
54
- <a href="http://codecanyon.net/item/maintenance-wordpress-plugin/2781350" title="<?php _e('Premium version', 'maintenance');?>" target="_blank">
55
- <?php _e('Check out our extended version of plugin with new features', 'maintenance');?>
56
- </a><br>
57
- </div>
58
- <!-- End Contact Support-->
59
-
60
- </div>
61
-
62
- <?php
63
-
64
- }
65
-
66
- ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
readme.txt CHANGED
@@ -3,27 +3,39 @@ Contributors: fruitfulcode
3
  Donate link: http://fruitfulcode.com/
4
  Tags: maintenance, login, under-construction, administration, offline, unavailable, landing page
5
  Requires at least: 3.0
6
- Tested up to: 3.6
7
- Stable tag: 1.2.3
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
11
- Close your website on maintenance. Search engines and regular users don't see your site. Access only by login
12
 
13
  == Description ==
14
 
15
- Take your site down from public view with a click of a button hiding the site when you need to change a few things or run an upgrade, making it only accessible by login and password. There is also an area to add a custom message which will be shown to the users while your site is down. Users stay on the same page when they input wrong initials.
16
 
 
 
 
 
 
 
 
 
 
 
 
 
17
 
18
- <h3>Links:</h3>
19
- <a target="_blank" href="http://fruitfulcode.com/maintenance/free">DEMO</a><br>
20
- <a target="_blank" href="http://fruitfulcode.com/blog/wordpress-maintenance-plugin/">More information</a>
21
 
22
 
23
- <h3>Extended version</h3>
 
 
 
24
 
25
- You can purchase an extended version of our plug-in and support our team <br>
26
- <a target="_blank" href="http://codecanyon.net/item/maintenance-wordpress-plugin/2781350?ref=fruitfulcode">Purchase extended maintenance</a>
27
 
28
  == Installation ==
29
 
@@ -33,7 +45,6 @@ You can purchase an extended version of our plug-in and support our team <br>
33
 
34
  == Screenshots ==
35
  1. Dashboard
36
- 1. Login page
37
 
38
  == Frequently Asked Questions ==
39
 
@@ -48,7 +59,18 @@ No, it will be display error on current maintenance page, without redirect to wp
48
 
49
  == Changelog ==
50
 
51
- = 1.2.3 = // 28.08.2013
 
 
 
 
 
 
 
 
 
 
 
52
 
53
  * Wordpress 3.6 support
54
  * Bug fix
3
  Donate link: http://fruitfulcode.com/
4
  Tags: maintenance, login, under-construction, administration, offline, unavailable, landing page
5
  Requires at least: 3.0
6
+ Tested up to: 3.8
7
+ Stable tag: 2.0
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
11
+ Install maintenance page on your WordPress website in few easy steps.
12
 
13
  == Description ==
14
 
15
+ Easily close your wordpress website for maintenance. Try free version or purchase maintenance PRO with more useful features and extended HTML template.
16
 
17
+ <h3>FEATURES</h3>
18
+ <ul>
19
+ <li>Html/CSS layout without images (retina ready) </li>
20
+ <li>Backstretch fullscreen background</li>
21
+ <li>Upload own logo</li>
22
+ <li>Select color scheme</li>
23
+ <li>Add your title, headline, text</li>
24
+ <li>User login with validation</li>
25
+ <li>Admin bar: show/hide</li>
26
+ <li>503 error switcher</li>
27
+ <li>Blur background effect</li>
28
+ </ul>
29
 
30
+ <h3>DEMO</h3>
31
+ <a target="_blank" href="http://plugins.fruitfulcode.com/maintenance/">Promo website</a>
 
32
 
33
 
34
+ <h3>PRO version</h3>
35
+
36
+ Purchase PRO version with extended functionality and new features <br>
37
+ <a target="_blank" href="http://codecanyon.net/item/maintenance-wordpress-plugin/2781350?ref=fruitfulcode">Maintenance PRO</a>
38
 
 
 
39
 
40
  == Installation ==
41
 
45
 
46
  == Screenshots ==
47
  1. Dashboard
 
48
 
49
  == Frequently Asked Questions ==
50
 
59
 
60
  == Changelog ==
61
 
62
+ = 2.0 = // 17.12.2013
63
+
64
+ * New features
65
+ * New PRO version
66
+ * New design
67
+ * New dashboard
68
+ * Core plugin changes
69
+ * Backstretch fullscreen background
70
+ * Blur background effect
71
+ * 503 error switcher
72
+
73
+ = 1.2.3 = // 28.08.2013
74
 
75
  * Wordpress 3.6 support
76
  * Bug fix
screenshot-1.png CHANGED
Binary file
screenshot-2.png DELETED
Binary file