update
This commit is contained in:
BIN
wp-content/plugins/secure-downloads/assets/img/ajax-loader.gif
Normal file
BIN
wp-content/plugins/secure-downloads/assets/img/ajax-loader.gif
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.5 KiB |
BIN
wp-content/plugins/secure-downloads/assets/img/icon-16x16.png
Normal file
BIN
wp-content/plugins/secure-downloads/assets/img/icon-16x16.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 245 B |
2
wp-content/plugins/secure-downloads/assets/img/index.php
Normal file
2
wp-content/plugins/secure-downloads/assets/img/index.php
Normal file
@@ -0,0 +1,2 @@
|
||||
<?php
|
||||
// Silence is golden.
|
||||
@@ -0,0 +1,7 @@
|
||||
Libs:
|
||||
Bootstrap v3.3.5 (CSS, JS files): Code licensed under MIT, which is compatible with GPLv2 . More here https://wordpress.org/support/topic/mit-license-in-wordpress-plugins?replies=10#post-5824280
|
||||
(The full Bootstrap license is located https://github.com/twbs/bootstrap/blob/master/LICENSE )
|
||||
|
||||
Fonts:
|
||||
License for GLYPHICONS Halflings in Bootstrap
|
||||
GLYPHICONS Halflings font is also released as an extension of a Bootstrap www.getbootstrap.com for free and it is released under the same license as Bootstrap. ( http://glyphicons.com/license/ ) Jan Kovařík
|
||||
595
wp-content/plugins/secure-downloads/assets/libs/bootstrap/css/bootstrap-theme.css
vendored
Normal file
595
wp-content/plugins/secure-downloads/assets/libs/bootstrap/css/bootstrap-theme.css
vendored
Normal file
@@ -0,0 +1,595 @@
|
||||
/*!
|
||||
* Bootstrap v3.3.5 (http://getbootstrap.com)
|
||||
* Copyright 2011-2015 Twitter, Inc.
|
||||
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
|
||||
*/
|
||||
/*!
|
||||
* Generated using the Bootstrap Customizer (http://getbootstrap.com/customize/?id=f4b4c9cb85df757ca08c)
|
||||
* Config saved to config.json and https://gist.github.com/f4b4c9cb85df757ca08c
|
||||
*/
|
||||
/*!
|
||||
* Bootstrap v3.3.5 (http://getbootstrap.com)
|
||||
* Copyright 2011-2015 Twitter, Inc.
|
||||
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
|
||||
*/
|
||||
.wpdevelop .btn-default,
|
||||
.wpdevelop .btn-primary,
|
||||
.wpdevelop .btn-success,
|
||||
.wpdevelop .btn-info,
|
||||
.wpdevelop .btn-warning,
|
||||
.wpdevelop .btn-danger {
|
||||
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.2);
|
||||
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 1px 1px rgba(0, 0, 0, 0.075);
|
||||
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 1px 1px rgba(0, 0, 0, 0.075);
|
||||
}
|
||||
.wpdevelop .btn-default:active,
|
||||
.wpdevelop .btn-primary:active,
|
||||
.wpdevelop .btn-success:active,
|
||||
.wpdevelop .btn-info:active,
|
||||
.wpdevelop .btn-warning:active,
|
||||
.wpdevelop .btn-danger:active,
|
||||
.wpdevelop .btn-default.active,
|
||||
.wpdevelop .btn-primary.active,
|
||||
.wpdevelop .btn-success.active,
|
||||
.wpdevelop .btn-info.active,
|
||||
.wpdevelop .btn-warning.active,
|
||||
.wpdevelop .btn-danger.active {
|
||||
-webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
|
||||
box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
|
||||
}
|
||||
.wpdevelop .btn-default.disabled,
|
||||
.wpdevelop .btn-primary.disabled,
|
||||
.wpdevelop .btn-success.disabled,
|
||||
.wpdevelop .btn-info.disabled,
|
||||
.wpdevelop .btn-warning.disabled,
|
||||
.wpdevelop .btn-danger.disabled,
|
||||
.wpdevelop .btn-default[disabled],
|
||||
.wpdevelop .btn-primary[disabled],
|
||||
.wpdevelop .btn-success[disabled],
|
||||
.wpdevelop .btn-info[disabled],
|
||||
.wpdevelop .btn-warning[disabled],
|
||||
.wpdevelop .btn-danger[disabled],
|
||||
.wpdevelop fieldset[disabled] .btn-default,
|
||||
.wpdevelop fieldset[disabled] .btn-primary,
|
||||
.wpdevelop fieldset[disabled] .btn-success,
|
||||
.wpdevelop fieldset[disabled] .btn-info,
|
||||
.wpdevelop fieldset[disabled] .btn-warning,
|
||||
.wpdevelop fieldset[disabled] .btn-danger {
|
||||
-webkit-box-shadow: none;
|
||||
box-shadow: none;
|
||||
}
|
||||
.wpdevelop .btn-default .badge,
|
||||
.wpdevelop .btn-primary .badge,
|
||||
.wpdevelop .btn-success .badge,
|
||||
.wpdevelop .btn-info .badge,
|
||||
.wpdevelop .btn-warning .badge,
|
||||
.wpdevelop .btn-danger .badge {
|
||||
text-shadow: none;
|
||||
}
|
||||
.wpdevelop .btn:active,
|
||||
.wpdevelop .btn.active {
|
||||
background-image: none;
|
||||
}
|
||||
.wpdevelop .btn-default {
|
||||
background-image: -webkit-linear-gradient(top, #ffffff 0%, #e0e0e0 100%);
|
||||
background-image: -o-linear-gradient(top, #ffffff 0%, #e0e0e0 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#ffffff), to(#e0e0e0));
|
||||
background-image: linear-gradient(to bottom, #ffffff 0%, #e0e0e0 100%);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe0e0e0', GradientType=0);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
||||
background-repeat: repeat-x;
|
||||
border-color: #dbdbdb;
|
||||
text-shadow: 0 1px 0 #fff;
|
||||
border-color: #ccc;
|
||||
}
|
||||
.wpdevelop .btn-default:hover,
|
||||
.wpdevelop .btn-default:focus {
|
||||
background-color: #e0e0e0;
|
||||
background-position: 0 -15px;
|
||||
}
|
||||
.wpdevelop .btn-default:active,
|
||||
.wpdevelop .btn-default.active {
|
||||
background-color: #e0e0e0;
|
||||
border-color: #dbdbdb;
|
||||
}
|
||||
.wpdevelop .btn-default.disabled,
|
||||
.wpdevelop .btn-default[disabled],
|
||||
.wpdevelop fieldset[disabled] .btn-default,
|
||||
.wpdevelop .btn-default.disabled:hover,
|
||||
.wpdevelop .btn-default[disabled]:hover,
|
||||
.wpdevelop fieldset[disabled] .btn-default:hover,
|
||||
.wpdevelop .btn-default.disabled:focus,
|
||||
.wpdevelop .btn-default[disabled]:focus,
|
||||
.wpdevelop fieldset[disabled] .btn-default:focus,
|
||||
.wpdevelop .btn-default.disabled.focus,
|
||||
.wpdevelop .btn-default[disabled].focus,
|
||||
.wpdevelop fieldset[disabled] .btn-default.focus,
|
||||
.wpdevelop .btn-default.disabled:active,
|
||||
.wpdevelop .btn-default[disabled]:active,
|
||||
.wpdevelop fieldset[disabled] .btn-default:active,
|
||||
.wpdevelop .btn-default.disabled.active,
|
||||
.wpdevelop .btn-default[disabled].active,
|
||||
.wpdevelop fieldset[disabled] .btn-default.active {
|
||||
background-color: #e0e0e0;
|
||||
background-image: none;
|
||||
}
|
||||
.wpdevelop .btn-primary {
|
||||
background-image: -webkit-linear-gradient(top, #337ab7 0%, #265a88 100%);
|
||||
background-image: -o-linear-gradient(top, #337ab7 0%, #265a88 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#265a88));
|
||||
background-image: linear-gradient(to bottom, #337ab7 0%, #265a88 100%);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff265a88', GradientType=0);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
||||
background-repeat: repeat-x;
|
||||
border-color: #245580;
|
||||
}
|
||||
.wpdevelop .btn-primary:hover,
|
||||
.wpdevelop .btn-primary:focus {
|
||||
background-color: #265a88;
|
||||
background-position: 0 -15px;
|
||||
}
|
||||
.wpdevelop .btn-primary:active,
|
||||
.wpdevelop .btn-primary.active {
|
||||
background-color: #265a88;
|
||||
border-color: #245580;
|
||||
}
|
||||
.wpdevelop .btn-primary.disabled,
|
||||
.wpdevelop .btn-primary[disabled],
|
||||
.wpdevelop fieldset[disabled] .btn-primary,
|
||||
.wpdevelop .btn-primary.disabled:hover,
|
||||
.wpdevelop .btn-primary[disabled]:hover,
|
||||
.wpdevelop fieldset[disabled] .btn-primary:hover,
|
||||
.wpdevelop .btn-primary.disabled:focus,
|
||||
.wpdevelop .btn-primary[disabled]:focus,
|
||||
.wpdevelop fieldset[disabled] .btn-primary:focus,
|
||||
.wpdevelop .btn-primary.disabled.focus,
|
||||
.wpdevelop .btn-primary[disabled].focus,
|
||||
.wpdevelop fieldset[disabled] .btn-primary.focus,
|
||||
.wpdevelop .btn-primary.disabled:active,
|
||||
.wpdevelop .btn-primary[disabled]:active,
|
||||
.wpdevelop fieldset[disabled] .btn-primary:active,
|
||||
.wpdevelop .btn-primary.disabled.active,
|
||||
.wpdevelop .btn-primary[disabled].active,
|
||||
.wpdevelop fieldset[disabled] .btn-primary.active {
|
||||
background-color: #265a88;
|
||||
background-image: none;
|
||||
}
|
||||
.wpdevelop .btn-success {
|
||||
background-image: -webkit-linear-gradient(top, #5cb85c 0%, #419641 100%);
|
||||
background-image: -o-linear-gradient(top, #5cb85c 0%, #419641 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#5cb85c), to(#419641));
|
||||
background-image: linear-gradient(to bottom, #5cb85c 0%, #419641 100%);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff419641', GradientType=0);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
||||
background-repeat: repeat-x;
|
||||
border-color: #3e8f3e;
|
||||
}
|
||||
.wpdevelop .btn-success:hover,
|
||||
.wpdevelop .btn-success:focus {
|
||||
background-color: #419641;
|
||||
background-position: 0 -15px;
|
||||
}
|
||||
.wpdevelop .btn-success:active,
|
||||
.wpdevelop .btn-success.active {
|
||||
background-color: #419641;
|
||||
border-color: #3e8f3e;
|
||||
}
|
||||
.wpdevelop .btn-success.disabled,
|
||||
.wpdevelop .btn-success[disabled],
|
||||
.wpdevelop fieldset[disabled] .btn-success,
|
||||
.wpdevelop .btn-success.disabled:hover,
|
||||
.wpdevelop .btn-success[disabled]:hover,
|
||||
.wpdevelop fieldset[disabled] .btn-success:hover,
|
||||
.wpdevelop .btn-success.disabled:focus,
|
||||
.wpdevelop .btn-success[disabled]:focus,
|
||||
.wpdevelop fieldset[disabled] .btn-success:focus,
|
||||
.wpdevelop .btn-success.disabled.focus,
|
||||
.wpdevelop .btn-success[disabled].focus,
|
||||
.wpdevelop fieldset[disabled] .btn-success.focus,
|
||||
.wpdevelop .btn-success.disabled:active,
|
||||
.wpdevelop .btn-success[disabled]:active,
|
||||
.wpdevelop fieldset[disabled] .btn-success:active,
|
||||
.wpdevelop .btn-success.disabled.active,
|
||||
.wpdevelop .btn-success[disabled].active,
|
||||
.wpdevelop fieldset[disabled] .btn-success.active {
|
||||
background-color: #419641;
|
||||
background-image: none;
|
||||
}
|
||||
.wpdevelop .btn-info {
|
||||
background-image: -webkit-linear-gradient(top, #5bc0de 0%, #2aabd2 100%);
|
||||
background-image: -o-linear-gradient(top, #5bc0de 0%, #2aabd2 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#5bc0de), to(#2aabd2));
|
||||
background-image: linear-gradient(to bottom, #5bc0de 0%, #2aabd2 100%);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff2aabd2', GradientType=0);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
||||
background-repeat: repeat-x;
|
||||
border-color: #28a4c9;
|
||||
}
|
||||
.wpdevelop .btn-info:hover,
|
||||
.wpdevelop .btn-info:focus {
|
||||
background-color: #2aabd2;
|
||||
background-position: 0 -15px;
|
||||
}
|
||||
.wpdevelop .btn-info:active,
|
||||
.wpdevelop .btn-info.active {
|
||||
background-color: #2aabd2;
|
||||
border-color: #28a4c9;
|
||||
}
|
||||
.wpdevelop .btn-info.disabled,
|
||||
.wpdevelop .btn-info[disabled],
|
||||
.wpdevelop fieldset[disabled] .btn-info,
|
||||
.wpdevelop .btn-info.disabled:hover,
|
||||
.wpdevelop .btn-info[disabled]:hover,
|
||||
.wpdevelop fieldset[disabled] .btn-info:hover,
|
||||
.wpdevelop .btn-info.disabled:focus,
|
||||
.wpdevelop .btn-info[disabled]:focus,
|
||||
.wpdevelop fieldset[disabled] .btn-info:focus,
|
||||
.wpdevelop .btn-info.disabled.focus,
|
||||
.wpdevelop .btn-info[disabled].focus,
|
||||
.wpdevelop fieldset[disabled] .btn-info.focus,
|
||||
.wpdevelop .btn-info.disabled:active,
|
||||
.wpdevelop .btn-info[disabled]:active,
|
||||
.wpdevelop fieldset[disabled] .btn-info:active,
|
||||
.wpdevelop .btn-info.disabled.active,
|
||||
.wpdevelop .btn-info[disabled].active,
|
||||
.wpdevelop fieldset[disabled] .btn-info.active {
|
||||
background-color: #2aabd2;
|
||||
background-image: none;
|
||||
}
|
||||
.wpdevelop .btn-warning {
|
||||
background-image: -webkit-linear-gradient(top, #f0ad4e 0%, #eb9316 100%);
|
||||
background-image: -o-linear-gradient(top, #f0ad4e 0%, #eb9316 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f0ad4e), to(#eb9316));
|
||||
background-image: linear-gradient(to bottom, #f0ad4e 0%, #eb9316 100%);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffeb9316', GradientType=0);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
||||
background-repeat: repeat-x;
|
||||
border-color: #e38d13;
|
||||
}
|
||||
.wpdevelop .btn-warning:hover,
|
||||
.wpdevelop .btn-warning:focus {
|
||||
background-color: #eb9316;
|
||||
background-position: 0 -15px;
|
||||
}
|
||||
.wpdevelop .btn-warning:active,
|
||||
.wpdevelop .btn-warning.active {
|
||||
background-color: #eb9316;
|
||||
border-color: #e38d13;
|
||||
}
|
||||
.wpdevelop .btn-warning.disabled,
|
||||
.wpdevelop .btn-warning[disabled],
|
||||
.wpdevelop fieldset[disabled] .btn-warning,
|
||||
.wpdevelop .btn-warning.disabled:hover,
|
||||
.wpdevelop .btn-warning[disabled]:hover,
|
||||
.wpdevelop fieldset[disabled] .btn-warning:hover,
|
||||
.wpdevelop .btn-warning.disabled:focus,
|
||||
.wpdevelop .btn-warning[disabled]:focus,
|
||||
.wpdevelop fieldset[disabled] .btn-warning:focus,
|
||||
.wpdevelop .btn-warning.disabled.focus,
|
||||
.wpdevelop .btn-warning[disabled].focus,
|
||||
.wpdevelop fieldset[disabled] .btn-warning.focus,
|
||||
.wpdevelop .btn-warning.disabled:active,
|
||||
.wpdevelop .btn-warning[disabled]:active,
|
||||
.wpdevelop fieldset[disabled] .btn-warning:active,
|
||||
.wpdevelop .btn-warning.disabled.active,
|
||||
.wpdevelop .btn-warning[disabled].active,
|
||||
.wpdevelop fieldset[disabled] .btn-warning.active {
|
||||
background-color: #eb9316;
|
||||
background-image: none;
|
||||
}
|
||||
.wpdevelop .btn-danger {
|
||||
background-image: -webkit-linear-gradient(top, #d9534f 0%, #c12e2a 100%);
|
||||
background-image: -o-linear-gradient(top, #d9534f 0%, #c12e2a 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9534f), to(#c12e2a));
|
||||
background-image: linear-gradient(to bottom, #d9534f 0%, #c12e2a 100%);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc12e2a', GradientType=0);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
||||
background-repeat: repeat-x;
|
||||
border-color: #b92c28;
|
||||
}
|
||||
.wpdevelop .btn-danger:hover,
|
||||
.wpdevelop .btn-danger:focus {
|
||||
background-color: #c12e2a;
|
||||
background-position: 0 -15px;
|
||||
}
|
||||
.wpdevelop .btn-danger:active,
|
||||
.wpdevelop .btn-danger.active {
|
||||
background-color: #c12e2a;
|
||||
border-color: #b92c28;
|
||||
}
|
||||
.wpdevelop .btn-danger.disabled,
|
||||
.wpdevelop .btn-danger[disabled],
|
||||
.wpdevelop fieldset[disabled] .btn-danger,
|
||||
.wpdevelop .btn-danger.disabled:hover,
|
||||
.wpdevelop .btn-danger[disabled]:hover,
|
||||
.wpdevelop fieldset[disabled] .btn-danger:hover,
|
||||
.wpdevelop .btn-danger.disabled:focus,
|
||||
.wpdevelop .btn-danger[disabled]:focus,
|
||||
.wpdevelop fieldset[disabled] .btn-danger:focus,
|
||||
.wpdevelop .btn-danger.disabled.focus,
|
||||
.wpdevelop .btn-danger[disabled].focus,
|
||||
.wpdevelop fieldset[disabled] .btn-danger.focus,
|
||||
.wpdevelop .btn-danger.disabled:active,
|
||||
.wpdevelop .btn-danger[disabled]:active,
|
||||
.wpdevelop fieldset[disabled] .btn-danger:active,
|
||||
.wpdevelop .btn-danger.disabled.active,
|
||||
.wpdevelop .btn-danger[disabled].active,
|
||||
.wpdevelop fieldset[disabled] .btn-danger.active {
|
||||
background-color: #c12e2a;
|
||||
background-image: none;
|
||||
}
|
||||
.wpdevelop .thumbnail,
|
||||
.wpdevelop .img-thumbnail {
|
||||
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.075);
|
||||
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.075);
|
||||
}
|
||||
.wpdevelop .dropdown-menu > li > a:hover,
|
||||
.wpdevelop .dropdown-menu > li > a:focus {
|
||||
background-image: -webkit-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
|
||||
background-image: -o-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f5f5f5), to(#e8e8e8));
|
||||
background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);
|
||||
background-color: #e8e8e8;
|
||||
}
|
||||
.wpdevelop .dropdown-menu > .active > a,
|
||||
.wpdevelop .dropdown-menu > .active > a:hover,
|
||||
.wpdevelop .dropdown-menu > .active > a:focus {
|
||||
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
|
||||
background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4));
|
||||
background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);
|
||||
background-color: #2e6da4;
|
||||
}
|
||||
.wpdevelop .navbar-default {
|
||||
background-image: -webkit-linear-gradient(top, #ffffff 0%, #f8f8f8 100%);
|
||||
background-image: -o-linear-gradient(top, #ffffff 0%, #f8f8f8 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#ffffff), to(#f8f8f8));
|
||||
background-image: linear-gradient(to bottom, #ffffff 0%, #f8f8f8 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#fff8f8f8', GradientType=0);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
||||
border-radius: 4px;
|
||||
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 1px 5px rgba(0, 0, 0, 0.075);
|
||||
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 1px 5px rgba(0, 0, 0, 0.075);
|
||||
}
|
||||
.wpdevelop .navbar-default .navbar-nav > .open > a,
|
||||
.wpdevelop .navbar-default .navbar-nav > .active > a {
|
||||
background-image: -webkit-linear-gradient(top, #dbdbdb 0%, #e2e2e2 100%);
|
||||
background-image: -o-linear-gradient(top, #dbdbdb 0%, #e2e2e2 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#dbdbdb), to(#e2e2e2));
|
||||
background-image: linear-gradient(to bottom, #dbdbdb 0%, #e2e2e2 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdbdbdb', endColorstr='#ffe2e2e2', GradientType=0);
|
||||
-webkit-box-shadow: inset 0 3px 9px rgba(0, 0, 0, 0.075);
|
||||
box-shadow: inset 0 3px 9px rgba(0, 0, 0, 0.075);
|
||||
}
|
||||
.wpdevelop .navbar-brand,
|
||||
.wpdevelop .navbar-nav > li > a {
|
||||
text-shadow: 0 1px 0 rgba(255, 255, 255, 0.25);
|
||||
}
|
||||
.wpdevelop .navbar-inverse {
|
||||
background-image: -webkit-linear-gradient(top, #3c3c3c 0%, #222222 100%);
|
||||
background-image: -o-linear-gradient(top, #3c3c3c 0%, #222222 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#3c3c3c), to(#222222));
|
||||
background-image: linear-gradient(to bottom, #3c3c3c 0%, #222222 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff3c3c3c', endColorstr='#ff222222', GradientType=0);
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
|
||||
border-radius: 4px;
|
||||
}
|
||||
.wpdevelop .navbar-inverse .navbar-nav > .open > a,
|
||||
.wpdevelop .navbar-inverse .navbar-nav > .active > a {
|
||||
background-image: -webkit-linear-gradient(top, #080808 0%, #0f0f0f 100%);
|
||||
background-image: -o-linear-gradient(top, #080808 0%, #0f0f0f 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#080808), to(#0f0f0f));
|
||||
background-image: linear-gradient(to bottom, #080808 0%, #0f0f0f 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff080808', endColorstr='#ff0f0f0f', GradientType=0);
|
||||
-webkit-box-shadow: inset 0 3px 9px rgba(0, 0, 0, 0.25);
|
||||
box-shadow: inset 0 3px 9px rgba(0, 0, 0, 0.25);
|
||||
}
|
||||
.wpdevelop .navbar-inverse .navbar-brand,
|
||||
.wpdevelop .navbar-inverse .navbar-nav > li > a {
|
||||
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
|
||||
}
|
||||
.wpdevelop .navbar-static-top,
|
||||
.wpdevelop .navbar-fixed-top,
|
||||
.wpdevelop .navbar-fixed-bottom {
|
||||
border-radius: 0;
|
||||
}
|
||||
@media (max-width: 767px) {
|
||||
.wpdevelop .navbar .navbar-nav .open .dropdown-menu > .active > a,
|
||||
.wpdevelop .navbar .navbar-nav .open .dropdown-menu > .active > a:hover,
|
||||
.wpdevelop .navbar .navbar-nav .open .dropdown-menu > .active > a:focus {
|
||||
color: #fff;
|
||||
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
|
||||
background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4));
|
||||
background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);
|
||||
}
|
||||
}
|
||||
.wpdevelop .alert {
|
||||
text-shadow: 0 1px 0 rgba(255, 255, 255, 0.2);
|
||||
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 1px 2px rgba(0, 0, 0, 0.05);
|
||||
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 1px 2px rgba(0, 0, 0, 0.05);
|
||||
}
|
||||
.wpdevelop .alert-success {
|
||||
background-image: -webkit-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%);
|
||||
background-image: -o-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#dff0d8), to(#c8e5bc));
|
||||
background-image: linear-gradient(to bottom, #dff0d8 0%, #c8e5bc 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffc8e5bc', GradientType=0);
|
||||
border-color: #b2dba1;
|
||||
}
|
||||
.wpdevelop .alert-info {
|
||||
background-image: -webkit-linear-gradient(top, #d9edf7 0%, #b9def0 100%);
|
||||
background-image: -o-linear-gradient(top, #d9edf7 0%, #b9def0 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9edf7), to(#b9def0));
|
||||
background-image: linear-gradient(to bottom, #d9edf7 0%, #b9def0 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffb9def0', GradientType=0);
|
||||
border-color: #9acfea;
|
||||
}
|
||||
.wpdevelop .alert-warning {
|
||||
background-image: -webkit-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%);
|
||||
background-image: -o-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#fcf8e3), to(#f8efc0));
|
||||
background-image: linear-gradient(to bottom, #fcf8e3 0%, #f8efc0 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fff8efc0', GradientType=0);
|
||||
border-color: #f5e79e;
|
||||
}
|
||||
.wpdevelop .alert-danger {
|
||||
background-image: -webkit-linear-gradient(top, #f2dede 0%, #e7c3c3 100%);
|
||||
background-image: -o-linear-gradient(top, #f2dede 0%, #e7c3c3 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f2dede), to(#e7c3c3));
|
||||
background-image: linear-gradient(to bottom, #f2dede 0%, #e7c3c3 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffe7c3c3', GradientType=0);
|
||||
border-color: #dca7a7;
|
||||
}
|
||||
.wpdevelop .progress {
|
||||
background-image: -webkit-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%);
|
||||
background-image: -o-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#ebebeb), to(#f5f5f5));
|
||||
background-image: linear-gradient(to bottom, #ebebeb 0%, #f5f5f5 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb', endColorstr='#fff5f5f5', GradientType=0);
|
||||
}
|
||||
.wpdevelop .progress-bar {
|
||||
background-image: -webkit-linear-gradient(top, #337ab7 0%, #286090 100%);
|
||||
background-image: -o-linear-gradient(top, #337ab7 0%, #286090 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#286090));
|
||||
background-image: linear-gradient(to bottom, #337ab7 0%, #286090 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff286090', GradientType=0);
|
||||
}
|
||||
.wpdevelop .progress-bar-success {
|
||||
background-image: -webkit-linear-gradient(top, #5cb85c 0%, #449d44 100%);
|
||||
background-image: -o-linear-gradient(top, #5cb85c 0%, #449d44 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#5cb85c), to(#449d44));
|
||||
background-image: linear-gradient(to bottom, #5cb85c 0%, #449d44 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff449d44', GradientType=0);
|
||||
}
|
||||
.wpdevelop .progress-bar-info {
|
||||
background-image: -webkit-linear-gradient(top, #5bc0de 0%, #31b0d5 100%);
|
||||
background-image: -o-linear-gradient(top, #5bc0de 0%, #31b0d5 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#5bc0de), to(#31b0d5));
|
||||
background-image: linear-gradient(to bottom, #5bc0de 0%, #31b0d5 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff31b0d5', GradientType=0);
|
||||
}
|
||||
.wpdevelop .progress-bar-warning {
|
||||
background-image: -webkit-linear-gradient(top, #f0ad4e 0%, #ec971f 100%);
|
||||
background-image: -o-linear-gradient(top, #f0ad4e 0%, #ec971f 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f0ad4e), to(#ec971f));
|
||||
background-image: linear-gradient(to bottom, #f0ad4e 0%, #ec971f 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffec971f', GradientType=0);
|
||||
}
|
||||
.wpdevelop .progress-bar-danger {
|
||||
background-image: -webkit-linear-gradient(top, #d9534f 0%, #c9302c 100%);
|
||||
background-image: -o-linear-gradient(top, #d9534f 0%, #c9302c 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9534f), to(#c9302c));
|
||||
background-image: linear-gradient(to bottom, #d9534f 0%, #c9302c 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc9302c', GradientType=0);
|
||||
}
|
||||
.wpdevelop .progress-bar-striped {
|
||||
background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
|
||||
background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
|
||||
background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent);
|
||||
}
|
||||
.wpdevelop .list-group {
|
||||
border-radius: 4px;
|
||||
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.075);
|
||||
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.075);
|
||||
}
|
||||
.wpdevelop .list-group-item.active,
|
||||
.wpdevelop .list-group-item.active:hover,
|
||||
.wpdevelop .list-group-item.active:focus {
|
||||
text-shadow: 0 -1px 0 #286090;
|
||||
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2b669a 100%);
|
||||
background-image: -o-linear-gradient(top, #337ab7 0%, #2b669a 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2b669a));
|
||||
background-image: linear-gradient(to bottom, #337ab7 0%, #2b669a 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2b669a', GradientType=0);
|
||||
border-color: #2b669a;
|
||||
}
|
||||
.wpdevelop .list-group-item.active .badge,
|
||||
.wpdevelop .list-group-item.active:hover .badge,
|
||||
.wpdevelop .list-group-item.active:focus .badge {
|
||||
text-shadow: none;
|
||||
}
|
||||
.wpdevelop .panel {
|
||||
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
|
||||
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
|
||||
}
|
||||
.wpdevelop .panel-default > .panel-heading {
|
||||
background-image: -webkit-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
|
||||
background-image: -o-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f5f5f5), to(#e8e8e8));
|
||||
background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);
|
||||
}
|
||||
.wpdevelop .panel-primary > .panel-heading {
|
||||
background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
|
||||
background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4));
|
||||
background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);
|
||||
}
|
||||
.wpdevelop .panel-success > .panel-heading {
|
||||
background-image: -webkit-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%);
|
||||
background-image: -o-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#dff0d8), to(#d0e9c6));
|
||||
background-image: linear-gradient(to bottom, #dff0d8 0%, #d0e9c6 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffd0e9c6', GradientType=0);
|
||||
}
|
||||
.wpdevelop .panel-info > .panel-heading {
|
||||
background-image: -webkit-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%);
|
||||
background-image: -o-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#d9edf7), to(#c4e3f3));
|
||||
background-image: linear-gradient(to bottom, #d9edf7 0%, #c4e3f3 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffc4e3f3', GradientType=0);
|
||||
}
|
||||
.wpdevelop .panel-warning > .panel-heading {
|
||||
background-image: -webkit-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%);
|
||||
background-image: -o-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#fcf8e3), to(#faf2cc));
|
||||
background-image: linear-gradient(to bottom, #fcf8e3 0%, #faf2cc 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fffaf2cc', GradientType=0);
|
||||
}
|
||||
.wpdevelop .panel-danger > .panel-heading {
|
||||
background-image: -webkit-linear-gradient(top, #f2dede 0%, #ebcccc 100%);
|
||||
background-image: -o-linear-gradient(top, #f2dede 0%, #ebcccc 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f2dede), to(#ebcccc));
|
||||
background-image: linear-gradient(to bottom, #f2dede 0%, #ebcccc 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffebcccc', GradientType=0);
|
||||
}
|
||||
.wpdevelop .well {
|
||||
background-image: -webkit-linear-gradient(top, #e8e8e8 0%, #f5f5f5 100%);
|
||||
background-image: -o-linear-gradient(top, #e8e8e8 0%, #f5f5f5 100%);
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#e8e8e8), to(#f5f5f5));
|
||||
background-image: linear-gradient(to bottom, #e8e8e8 0%, #f5f5f5 100%);
|
||||
background-repeat: repeat-x;
|
||||
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffe8e8e8', endColorstr='#fff5f5f5', GradientType=0);
|
||||
border-color: #dcdcdc;
|
||||
-webkit-box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 0 rgba(255, 255, 255, 0.1);
|
||||
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 0 rgba(255, 255, 255, 0.1);
|
||||
}
|
||||
12
wp-content/plugins/secure-downloads/assets/libs/bootstrap/css/bootstrap-theme.min.css
vendored
Normal file
12
wp-content/plugins/secure-downloads/assets/libs/bootstrap/css/bootstrap-theme.min.css
vendored
Normal file
File diff suppressed because one or more lines are too long
6795
wp-content/plugins/secure-downloads/assets/libs/bootstrap/css/bootstrap.css
vendored
Normal file
6795
wp-content/plugins/secure-downloads/assets/libs/bootstrap/css/bootstrap.css
vendored
Normal file
File diff suppressed because it is too large
Load Diff
12
wp-content/plugins/secure-downloads/assets/libs/bootstrap/css/bootstrap.min.css
vendored
Normal file
12
wp-content/plugins/secure-downloads/assets/libs/bootstrap/css/bootstrap.min.css
vendored
Normal file
File diff suppressed because one or more lines are too long
@@ -0,0 +1,2 @@
|
||||
<?php
|
||||
// Silence is golden.
|
||||
Binary file not shown.
@@ -0,0 +1,288 @@
|
||||
<?xml version="1.0" standalone="no"?>
|
||||
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" >
|
||||
<svg xmlns="http://www.w3.org/2000/svg">
|
||||
<metadata></metadata>
|
||||
<defs>
|
||||
<font id="glyphicons_halflingsregular" horiz-adv-x="1200" >
|
||||
<font-face units-per-em="1200" ascent="960" descent="-240" />
|
||||
<missing-glyph horiz-adv-x="500" />
|
||||
<glyph horiz-adv-x="0" />
|
||||
<glyph horiz-adv-x="400" />
|
||||
<glyph unicode=" " />
|
||||
<glyph unicode="*" d="M600 1100q15 0 34 -1.5t30 -3.5l11 -1q10 -2 17.5 -10.5t7.5 -18.5v-224l158 158q7 7 18 8t19 -6l106 -106q7 -8 6 -19t-8 -18l-158 -158h224q10 0 18.5 -7.5t10.5 -17.5q6 -41 6 -75q0 -15 -1.5 -34t-3.5 -30l-1 -11q-2 -10 -10.5 -17.5t-18.5 -7.5h-224l158 -158 q7 -7 8 -18t-6 -19l-106 -106q-8 -7 -19 -6t-18 8l-158 158v-224q0 -10 -7.5 -18.5t-17.5 -10.5q-41 -6 -75 -6q-15 0 -34 1.5t-30 3.5l-11 1q-10 2 -17.5 10.5t-7.5 18.5v224l-158 -158q-7 -7 -18 -8t-19 6l-106 106q-7 8 -6 19t8 18l158 158h-224q-10 0 -18.5 7.5 t-10.5 17.5q-6 41 -6 75q0 15 1.5 34t3.5 30l1 11q2 10 10.5 17.5t18.5 7.5h224l-158 158q-7 7 -8 18t6 19l106 106q8 7 19 6t18 -8l158 -158v224q0 10 7.5 18.5t17.5 10.5q41 6 75 6z" />
|
||||
<glyph unicode="+" d="M450 1100h200q21 0 35.5 -14.5t14.5 -35.5v-350h350q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-350v-350q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v350h-350q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5 h350v350q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode=" " />
|
||||
<glyph unicode="¥" d="M825 1100h250q10 0 12.5 -5t-5.5 -13l-364 -364q-6 -6 -11 -18h268q10 0 13 -6t-3 -14l-120 -160q-6 -8 -18 -14t-22 -6h-125v-100h275q10 0 13 -6t-3 -14l-120 -160q-6 -8 -18 -14t-22 -6h-125v-174q0 -11 -7.5 -18.5t-18.5 -7.5h-148q-11 0 -18.5 7.5t-7.5 18.5v174 h-275q-10 0 -13 6t3 14l120 160q6 8 18 14t22 6h125v100h-275q-10 0 -13 6t3 14l120 160q6 8 18 14t22 6h118q-5 12 -11 18l-364 364q-8 8 -5.5 13t12.5 5h250q25 0 43 -18l164 -164q8 -8 18 -8t18 8l164 164q18 18 43 18z" />
|
||||
<glyph unicode=" " horiz-adv-x="650" />
|
||||
<glyph unicode=" " horiz-adv-x="1300" />
|
||||
<glyph unicode=" " horiz-adv-x="650" />
|
||||
<glyph unicode=" " horiz-adv-x="1300" />
|
||||
<glyph unicode=" " horiz-adv-x="433" />
|
||||
<glyph unicode=" " horiz-adv-x="325" />
|
||||
<glyph unicode=" " horiz-adv-x="216" />
|
||||
<glyph unicode=" " horiz-adv-x="216" />
|
||||
<glyph unicode=" " horiz-adv-x="162" />
|
||||
<glyph unicode=" " horiz-adv-x="260" />
|
||||
<glyph unicode=" " horiz-adv-x="72" />
|
||||
<glyph unicode=" " horiz-adv-x="260" />
|
||||
<glyph unicode=" " horiz-adv-x="325" />
|
||||
<glyph unicode="€" d="M744 1198q242 0 354 -189q60 -104 66 -209h-181q0 45 -17.5 82.5t-43.5 61.5t-58 40.5t-60.5 24t-51.5 7.5q-19 0 -40.5 -5.5t-49.5 -20.5t-53 -38t-49 -62.5t-39 -89.5h379l-100 -100h-300q-6 -50 -6 -100h406l-100 -100h-300q9 -74 33 -132t52.5 -91t61.5 -54.5t59 -29 t47 -7.5q22 0 50.5 7.5t60.5 24.5t58 41t43.5 61t17.5 80h174q-30 -171 -128 -278q-107 -117 -274 -117q-206 0 -324 158q-36 48 -69 133t-45 204h-217l100 100h112q1 47 6 100h-218l100 100h134q20 87 51 153.5t62 103.5q117 141 297 141z" />
|
||||
<glyph unicode="₽" d="M428 1200h350q67 0 120 -13t86 -31t57 -49.5t35 -56.5t17 -64.5t6.5 -60.5t0.5 -57v-16.5v-16.5q0 -36 -0.5 -57t-6.5 -61t-17 -65t-35 -57t-57 -50.5t-86 -31.5t-120 -13h-178l-2 -100h288q10 0 13 -6t-3 -14l-120 -160q-6 -8 -18 -14t-22 -6h-138v-175q0 -11 -5.5 -18 t-15.5 -7h-149q-10 0 -17.5 7.5t-7.5 17.5v175h-267q-10 0 -13 6t3 14l120 160q6 8 18 14t22 6h117v100h-267q-10 0 -13 6t3 14l120 160q6 8 18 14t22 6h117v475q0 10 7.5 17.5t17.5 7.5zM600 1000v-300h203q64 0 86.5 33t22.5 119q0 84 -22.5 116t-86.5 32h-203z" />
|
||||
<glyph unicode="−" d="M250 700h800q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="⌛" d="M1000 1200v-150q0 -21 -14.5 -35.5t-35.5 -14.5h-50v-100q0 -91 -49.5 -165.5t-130.5 -109.5q81 -35 130.5 -109.5t49.5 -165.5v-150h50q21 0 35.5 -14.5t14.5 -35.5v-150h-800v150q0 21 14.5 35.5t35.5 14.5h50v150q0 91 49.5 165.5t130.5 109.5q-81 35 -130.5 109.5 t-49.5 165.5v100h-50q-21 0 -35.5 14.5t-14.5 35.5v150h800zM400 1000v-100q0 -60 32.5 -109.5t87.5 -73.5q28 -12 44 -37t16 -55t-16 -55t-44 -37q-55 -24 -87.5 -73.5t-32.5 -109.5v-150h400v150q0 60 -32.5 109.5t-87.5 73.5q-28 12 -44 37t-16 55t16 55t44 37 q55 24 87.5 73.5t32.5 109.5v100h-400z" />
|
||||
<glyph unicode="◼" horiz-adv-x="500" d="M0 0z" />
|
||||
<glyph unicode="☁" d="M503 1089q110 0 200.5 -59.5t134.5 -156.5q44 14 90 14q120 0 205 -86.5t85 -206.5q0 -121 -85 -207.5t-205 -86.5h-750q-79 0 -135.5 57t-56.5 137q0 69 42.5 122.5t108.5 67.5q-2 12 -2 37q0 153 108 260.5t260 107.5z" />
|
||||
<glyph unicode="⛺" d="M774 1193.5q16 -9.5 20.5 -27t-5.5 -33.5l-136 -187l467 -746h30q20 0 35 -18.5t15 -39.5v-42h-1200v42q0 21 15 39.5t35 18.5h30l468 746l-135 183q-10 16 -5.5 34t20.5 28t34 5.5t28 -20.5l111 -148l112 150q9 16 27 20.5t34 -5zM600 200h377l-182 112l-195 534v-646z " />
|
||||
<glyph unicode="✉" d="M25 1100h1150q10 0 12.5 -5t-5.5 -13l-564 -567q-8 -8 -18 -8t-18 8l-564 567q-8 8 -5.5 13t12.5 5zM18 882l264 -264q8 -8 8 -18t-8 -18l-264 -264q-8 -8 -13 -5.5t-5 12.5v550q0 10 5 12.5t13 -5.5zM918 618l264 264q8 8 13 5.5t5 -12.5v-550q0 -10 -5 -12.5t-13 5.5 l-264 264q-8 8 -8 18t8 18zM818 482l364 -364q8 -8 5.5 -13t-12.5 -5h-1150q-10 0 -12.5 5t5.5 13l364 364q8 8 18 8t18 -8l164 -164q8 -8 18 -8t18 8l164 164q8 8 18 8t18 -8z" />
|
||||
<glyph unicode="✏" d="M1011 1210q19 0 33 -13l153 -153q13 -14 13 -33t-13 -33l-99 -92l-214 214l95 96q13 14 32 14zM1013 800l-615 -614l-214 214l614 614zM317 96l-333 -112l110 335z" />
|
||||
<glyph unicode="" d="M700 650v-550h250q21 0 35.5 -14.5t14.5 -35.5v-50h-800v50q0 21 14.5 35.5t35.5 14.5h250v550l-500 550h1200z" />
|
||||
<glyph unicode="" d="M368 1017l645 163q39 15 63 0t24 -49v-831q0 -55 -41.5 -95.5t-111.5 -63.5q-79 -25 -147 -4.5t-86 75t25.5 111.5t122.5 82q72 24 138 8v521l-600 -155v-606q0 -42 -44 -90t-109 -69q-79 -26 -147 -5.5t-86 75.5t25.5 111.5t122.5 82.5q72 24 138 7v639q0 38 14.5 59 t53.5 34z" />
|
||||
<glyph unicode="" d="M500 1191q100 0 191 -39t156.5 -104.5t104.5 -156.5t39 -191l-1 -2l1 -5q0 -141 -78 -262l275 -274q23 -26 22.5 -44.5t-22.5 -42.5l-59 -58q-26 -20 -46.5 -20t-39.5 20l-275 274q-119 -77 -261 -77l-5 1l-2 -1q-100 0 -191 39t-156.5 104.5t-104.5 156.5t-39 191 t39 191t104.5 156.5t156.5 104.5t191 39zM500 1022q-88 0 -162 -43t-117 -117t-43 -162t43 -162t117 -117t162 -43t162 43t117 117t43 162t-43 162t-117 117t-162 43z" />
|
||||
<glyph unicode="" d="M649 949q48 68 109.5 104t121.5 38.5t118.5 -20t102.5 -64t71 -100.5t27 -123q0 -57 -33.5 -117.5t-94 -124.5t-126.5 -127.5t-150 -152.5t-146 -174q-62 85 -145.5 174t-150 152.5t-126.5 127.5t-93.5 124.5t-33.5 117.5q0 64 28 123t73 100.5t104 64t119 20 t120.5 -38.5t104.5 -104z" />
|
||||
<glyph unicode="" d="M407 800l131 353q7 19 17.5 19t17.5 -19l129 -353h421q21 0 24 -8.5t-14 -20.5l-342 -249l130 -401q7 -20 -0.5 -25.5t-24.5 6.5l-343 246l-342 -247q-17 -12 -24.5 -6.5t-0.5 25.5l130 400l-347 251q-17 12 -14 20.5t23 8.5h429z" />
|
||||
<glyph unicode="" d="M407 800l131 353q7 19 17.5 19t17.5 -19l129 -353h421q21 0 24 -8.5t-14 -20.5l-342 -249l130 -401q7 -20 -0.5 -25.5t-24.5 6.5l-343 246l-342 -247q-17 -12 -24.5 -6.5t-0.5 25.5l130 400l-347 251q-17 12 -14 20.5t23 8.5h429zM477 700h-240l197 -142l-74 -226 l193 139l195 -140l-74 229l192 140h-234l-78 211z" />
|
||||
<glyph unicode="" d="M600 1200q124 0 212 -88t88 -212v-250q0 -46 -31 -98t-69 -52v-75q0 -10 6 -21.5t15 -17.5l358 -230q9 -5 15 -16.5t6 -21.5v-93q0 -10 -7.5 -17.5t-17.5 -7.5h-1150q-10 0 -17.5 7.5t-7.5 17.5v93q0 10 6 21.5t15 16.5l358 230q9 6 15 17.5t6 21.5v75q-38 0 -69 52 t-31 98v250q0 124 88 212t212 88z" />
|
||||
<glyph unicode="" d="M25 1100h1150q10 0 17.5 -7.5t7.5 -17.5v-1050q0 -10 -7.5 -17.5t-17.5 -7.5h-1150q-10 0 -17.5 7.5t-7.5 17.5v1050q0 10 7.5 17.5t17.5 7.5zM100 1000v-100h100v100h-100zM875 1000h-550q-10 0 -17.5 -7.5t-7.5 -17.5v-350q0 -10 7.5 -17.5t17.5 -7.5h550 q10 0 17.5 7.5t7.5 17.5v350q0 10 -7.5 17.5t-17.5 7.5zM1000 1000v-100h100v100h-100zM100 800v-100h100v100h-100zM1000 800v-100h100v100h-100zM100 600v-100h100v100h-100zM1000 600v-100h100v100h-100zM875 500h-550q-10 0 -17.5 -7.5t-7.5 -17.5v-350q0 -10 7.5 -17.5 t17.5 -7.5h550q10 0 17.5 7.5t7.5 17.5v350q0 10 -7.5 17.5t-17.5 7.5zM100 400v-100h100v100h-100zM1000 400v-100h100v100h-100zM100 200v-100h100v100h-100zM1000 200v-100h100v100h-100z" />
|
||||
<glyph unicode="" d="M50 1100h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5zM650 1100h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v400 q0 21 14.5 35.5t35.5 14.5zM50 500h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5zM650 500h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400 q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M50 1100h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM450 1100h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200 q0 21 14.5 35.5t35.5 14.5zM850 1100h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM50 700h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200 q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM450 700h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM850 700h200q21 0 35.5 -14.5t14.5 -35.5v-200 q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM50 300h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM450 300h200 q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM850 300h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5 t35.5 14.5z" />
|
||||
<glyph unicode="" d="M50 1100h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM450 1100h700q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-700q-21 0 -35.5 14.5t-14.5 35.5v200 q0 21 14.5 35.5t35.5 14.5zM50 700h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM450 700h700q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-700 q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM50 300h200q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5zM450 300h700q21 0 35.5 -14.5t14.5 -35.5v-200 q0 -21 -14.5 -35.5t-35.5 -14.5h-700q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M465 477l571 571q8 8 18 8t17 -8l177 -177q8 -7 8 -17t-8 -18l-783 -784q-7 -8 -17.5 -8t-17.5 8l-384 384q-8 8 -8 18t8 17l177 177q7 8 17 8t18 -8l171 -171q7 -7 18 -7t18 7z" />
|
||||
<glyph unicode="" d="M904 1083l178 -179q8 -8 8 -18.5t-8 -17.5l-267 -268l267 -268q8 -7 8 -17.5t-8 -18.5l-178 -178q-8 -8 -18.5 -8t-17.5 8l-268 267l-268 -267q-7 -8 -17.5 -8t-18.5 8l-178 178q-8 8 -8 18.5t8 17.5l267 268l-267 268q-8 7 -8 17.5t8 18.5l178 178q8 8 18.5 8t17.5 -8 l268 -267l268 268q7 7 17.5 7t18.5 -7z" />
|
||||
<glyph unicode="" d="M507 1177q98 0 187.5 -38.5t154.5 -103.5t103.5 -154.5t38.5 -187.5q0 -141 -78 -262l300 -299q8 -8 8 -18.5t-8 -18.5l-109 -108q-7 -8 -17.5 -8t-18.5 8l-300 299q-119 -77 -261 -77q-98 0 -188 38.5t-154.5 103t-103 154.5t-38.5 188t38.5 187.5t103 154.5 t154.5 103.5t188 38.5zM506.5 1023q-89.5 0 -165.5 -44t-120 -120.5t-44 -166t44 -165.5t120 -120t165.5 -44t166 44t120.5 120t44 165.5t-44 166t-120.5 120.5t-166 44zM425 900h150q10 0 17.5 -7.5t7.5 -17.5v-75h75q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5 t-17.5 -7.5h-75v-75q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v75h-75q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5h75v75q0 10 7.5 17.5t17.5 7.5z" />
|
||||
<glyph unicode="" d="M507 1177q98 0 187.5 -38.5t154.5 -103.5t103.5 -154.5t38.5 -187.5q0 -141 -78 -262l300 -299q8 -8 8 -18.5t-8 -18.5l-109 -108q-7 -8 -17.5 -8t-18.5 8l-300 299q-119 -77 -261 -77q-98 0 -188 38.5t-154.5 103t-103 154.5t-38.5 188t38.5 187.5t103 154.5 t154.5 103.5t188 38.5zM506.5 1023q-89.5 0 -165.5 -44t-120 -120.5t-44 -166t44 -165.5t120 -120t165.5 -44t166 44t120.5 120t44 165.5t-44 166t-120.5 120.5t-166 44zM325 800h350q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-350q-10 0 -17.5 7.5 t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5z" />
|
||||
<glyph unicode="" d="M550 1200h100q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5zM800 975v166q167 -62 272 -209.5t105 -331.5q0 -117 -45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5 t-184.5 123t-123 184.5t-45.5 224q0 184 105 331.5t272 209.5v-166q-103 -55 -165 -155t-62 -220q0 -116 57 -214.5t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5q0 120 -62 220t-165 155z" />
|
||||
<glyph unicode="" d="M1025 1200h150q10 0 17.5 -7.5t7.5 -17.5v-1150q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v1150q0 10 7.5 17.5t17.5 7.5zM725 800h150q10 0 17.5 -7.5t7.5 -17.5v-750q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v750 q0 10 7.5 17.5t17.5 7.5zM425 500h150q10 0 17.5 -7.5t7.5 -17.5v-450q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v450q0 10 7.5 17.5t17.5 7.5zM125 300h150q10 0 17.5 -7.5t7.5 -17.5v-250q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5 v250q0 10 7.5 17.5t17.5 7.5z" />
|
||||
<glyph unicode="" d="M600 1174q33 0 74 -5l38 -152l5 -1q49 -14 94 -39l5 -2l134 80q61 -48 104 -105l-80 -134l3 -5q25 -44 39 -93l1 -6l152 -38q5 -43 5 -73q0 -34 -5 -74l-152 -38l-1 -6q-15 -49 -39 -93l-3 -5l80 -134q-48 -61 -104 -105l-134 81l-5 -3q-44 -25 -94 -39l-5 -2l-38 -151 q-43 -5 -74 -5q-33 0 -74 5l-38 151l-5 2q-49 14 -94 39l-5 3l-134 -81q-60 48 -104 105l80 134l-3 5q-25 45 -38 93l-2 6l-151 38q-6 42 -6 74q0 33 6 73l151 38l2 6q13 48 38 93l3 5l-80 134q47 61 105 105l133 -80l5 2q45 25 94 39l5 1l38 152q43 5 74 5zM600 815 q-89 0 -152 -63t-63 -151.5t63 -151.5t152 -63t152 63t63 151.5t-63 151.5t-152 63z" />
|
||||
<glyph unicode="" d="M500 1300h300q41 0 70.5 -29.5t29.5 -70.5v-100h275q10 0 17.5 -7.5t7.5 -17.5v-75h-1100v75q0 10 7.5 17.5t17.5 7.5h275v100q0 41 29.5 70.5t70.5 29.5zM500 1200v-100h300v100h-300zM1100 900v-800q0 -41 -29.5 -70.5t-70.5 -29.5h-700q-41 0 -70.5 29.5t-29.5 70.5 v800h900zM300 800v-700h100v700h-100zM500 800v-700h100v700h-100zM700 800v-700h100v700h-100zM900 800v-700h100v700h-100z" />
|
||||
<glyph unicode="" d="M18 618l620 608q8 7 18.5 7t17.5 -7l608 -608q8 -8 5.5 -13t-12.5 -5h-175v-575q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v375h-300v-375q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v575h-175q-10 0 -12.5 5t5.5 13z" />
|
||||
<glyph unicode="" d="M600 1200v-400q0 -41 29.5 -70.5t70.5 -29.5h300v-650q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5v1100q0 21 14.5 35.5t35.5 14.5h450zM1000 800h-250q-21 0 -35.5 14.5t-14.5 35.5v250z" />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 1027q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5 t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5t-57 214.5t-155.5 155.5t-214.5 57zM525 900h50q10 0 17.5 -7.5t7.5 -17.5v-275h175q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v350q0 10 7.5 17.5t17.5 7.5z" />
|
||||
<glyph unicode="" d="M1300 0h-538l-41 400h-242l-41 -400h-538l431 1200h209l-21 -300h162l-20 300h208zM515 800l-27 -300h224l-27 300h-170z" />
|
||||
<glyph unicode="" d="M550 1200h200q21 0 35.5 -14.5t14.5 -35.5v-450h191q20 0 25.5 -11.5t-7.5 -27.5l-327 -400q-13 -16 -32 -16t-32 16l-327 400q-13 16 -7.5 27.5t25.5 11.5h191v450q0 21 14.5 35.5t35.5 14.5zM1125 400h50q10 0 17.5 -7.5t7.5 -17.5v-350q0 -10 -7.5 -17.5t-17.5 -7.5 h-1050q-10 0 -17.5 7.5t-7.5 17.5v350q0 10 7.5 17.5t17.5 7.5h50q10 0 17.5 -7.5t7.5 -17.5v-175h900v175q0 10 7.5 17.5t17.5 7.5z" />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 1027q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5 t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5t-57 214.5t-155.5 155.5t-214.5 57zM525 900h150q10 0 17.5 -7.5t7.5 -17.5v-275h137q21 0 26 -11.5t-8 -27.5l-223 -275q-13 -16 -32 -16t-32 16l-223 275q-13 16 -8 27.5t26 11.5h137v275q0 10 7.5 17.5t17.5 7.5z " />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 1027q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5 t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5t-57 214.5t-155.5 155.5t-214.5 57zM632 914l223 -275q13 -16 8 -27.5t-26 -11.5h-137v-275q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v275h-137q-21 0 -26 11.5t8 27.5l223 275q13 16 32 16 t32 -16z" />
|
||||
<glyph unicode="" d="M225 1200h750q10 0 19.5 -7t12.5 -17l186 -652q7 -24 7 -49v-425q0 -12 -4 -27t-9 -17q-12 -6 -37 -6h-1100q-12 0 -27 4t-17 8q-6 13 -6 38l1 425q0 25 7 49l185 652q3 10 12.5 17t19.5 7zM878 1000h-556q-10 0 -19 -7t-11 -18l-87 -450q-2 -11 4 -18t16 -7h150 q10 0 19.5 -7t11.5 -17l38 -152q2 -10 11.5 -17t19.5 -7h250q10 0 19.5 7t11.5 17l38 152q2 10 11.5 17t19.5 7h150q10 0 16 7t4 18l-87 450q-2 11 -11 18t-19 7z" />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 1027q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5 t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5t-57 214.5t-155.5 155.5t-214.5 57zM540 820l253 -190q17 -12 17 -30t-17 -30l-253 -190q-16 -12 -28 -6.5t-12 26.5v400q0 21 12 26.5t28 -6.5z" />
|
||||
<glyph unicode="" d="M947 1060l135 135q7 7 12.5 5t5.5 -13v-362q0 -10 -7.5 -17.5t-17.5 -7.5h-362q-11 0 -13 5.5t5 12.5l133 133q-109 76 -238 76q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5h150q0 -117 -45.5 -224 t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5q192 0 347 -117z" />
|
||||
<glyph unicode="" d="M947 1060l135 135q7 7 12.5 5t5.5 -13v-361q0 -11 -7.5 -18.5t-18.5 -7.5h-361q-11 0 -13 5.5t5 12.5l134 134q-110 75 -239 75q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5h-150q0 117 45.5 224t123 184.5t184.5 123t224 45.5q192 0 347 -117zM1027 600h150 q0 -117 -45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5q-192 0 -348 118l-134 -134q-7 -8 -12.5 -5.5t-5.5 12.5v360q0 11 7.5 18.5t18.5 7.5h360q10 0 12.5 -5.5t-5.5 -12.5l-133 -133q110 -76 240 -76q116 0 214.5 57t155.5 155.5t57 214.5z" />
|
||||
<glyph unicode="" d="M125 1200h1050q10 0 17.5 -7.5t7.5 -17.5v-1150q0 -10 -7.5 -17.5t-17.5 -7.5h-1050q-10 0 -17.5 7.5t-7.5 17.5v1150q0 10 7.5 17.5t17.5 7.5zM1075 1000h-850q-10 0 -17.5 -7.5t-7.5 -17.5v-850q0 -10 7.5 -17.5t17.5 -7.5h850q10 0 17.5 7.5t7.5 17.5v850 q0 10 -7.5 17.5t-17.5 7.5zM325 900h50q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-50q-10 0 -17.5 7.5t-7.5 17.5v50q0 10 7.5 17.5t17.5 7.5zM525 900h450q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-450q-10 0 -17.5 7.5t-7.5 17.5v50 q0 10 7.5 17.5t17.5 7.5zM325 700h50q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-50q-10 0 -17.5 7.5t-7.5 17.5v50q0 10 7.5 17.5t17.5 7.5zM525 700h450q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-450q-10 0 -17.5 7.5t-7.5 17.5v50 q0 10 7.5 17.5t17.5 7.5zM325 500h50q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-50q-10 0 -17.5 7.5t-7.5 17.5v50q0 10 7.5 17.5t17.5 7.5zM525 500h450q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-450q-10 0 -17.5 7.5t-7.5 17.5v50 q0 10 7.5 17.5t17.5 7.5zM325 300h50q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-50q-10 0 -17.5 7.5t-7.5 17.5v50q0 10 7.5 17.5t17.5 7.5zM525 300h450q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-450q-10 0 -17.5 7.5t-7.5 17.5v50 q0 10 7.5 17.5t17.5 7.5z" />
|
||||
<glyph unicode="" d="M900 800v200q0 83 -58.5 141.5t-141.5 58.5h-300q-82 0 -141 -59t-59 -141v-200h-100q-41 0 -70.5 -29.5t-29.5 -70.5v-600q0 -41 29.5 -70.5t70.5 -29.5h900q41 0 70.5 29.5t29.5 70.5v600q0 41 -29.5 70.5t-70.5 29.5h-100zM400 800v150q0 21 15 35.5t35 14.5h200 q20 0 35 -14.5t15 -35.5v-150h-300z" />
|
||||
<glyph unicode="" d="M125 1100h50q10 0 17.5 -7.5t7.5 -17.5v-1075h-100v1075q0 10 7.5 17.5t17.5 7.5zM1075 1052q4 0 9 -2q16 -6 16 -23v-421q0 -6 -3 -12q-33 -59 -66.5 -99t-65.5 -58t-56.5 -24.5t-52.5 -6.5q-26 0 -57.5 6.5t-52.5 13.5t-60 21q-41 15 -63 22.5t-57.5 15t-65.5 7.5 q-85 0 -160 -57q-7 -5 -15 -5q-6 0 -11 3q-14 7 -14 22v438q22 55 82 98.5t119 46.5q23 2 43 0.5t43 -7t32.5 -8.5t38 -13t32.5 -11q41 -14 63.5 -21t57 -14t63.5 -7q103 0 183 87q7 8 18 8z" />
|
||||
<glyph unicode="" d="M600 1175q116 0 227 -49.5t192.5 -131t131 -192.5t49.5 -227v-300q0 -10 -7.5 -17.5t-17.5 -7.5h-50q-10 0 -17.5 7.5t-7.5 17.5v300q0 127 -70.5 231.5t-184.5 161.5t-245 57t-245 -57t-184.5 -161.5t-70.5 -231.5v-300q0 -10 -7.5 -17.5t-17.5 -7.5h-50 q-10 0 -17.5 7.5t-7.5 17.5v300q0 116 49.5 227t131 192.5t192.5 131t227 49.5zM220 500h160q8 0 14 -6t6 -14v-460q0 -8 -6 -14t-14 -6h-160q-8 0 -14 6t-6 14v460q0 8 6 14t14 6zM820 500h160q8 0 14 -6t6 -14v-460q0 -8 -6 -14t-14 -6h-160q-8 0 -14 6t-6 14v460 q0 8 6 14t14 6z" />
|
||||
<glyph unicode="" d="M321 814l258 172q9 6 15 2.5t6 -13.5v-750q0 -10 -6 -13.5t-15 2.5l-258 172q-21 14 -46 14h-250q-10 0 -17.5 7.5t-7.5 17.5v350q0 10 7.5 17.5t17.5 7.5h250q25 0 46 14zM900 668l120 120q7 7 17 7t17 -7l34 -34q7 -7 7 -17t-7 -17l-120 -120l120 -120q7 -7 7 -17 t-7 -17l-34 -34q-7 -7 -17 -7t-17 7l-120 119l-120 -119q-7 -7 -17 -7t-17 7l-34 34q-7 7 -7 17t7 17l119 120l-119 120q-7 7 -7 17t7 17l34 34q7 8 17 8t17 -8z" />
|
||||
<glyph unicode="" d="M321 814l258 172q9 6 15 2.5t6 -13.5v-750q0 -10 -6 -13.5t-15 2.5l-258 172q-21 14 -46 14h-250q-10 0 -17.5 7.5t-7.5 17.5v350q0 10 7.5 17.5t17.5 7.5h250q25 0 46 14zM766 900h4q10 -1 16 -10q96 -129 96 -290q0 -154 -90 -281q-6 -9 -17 -10l-3 -1q-9 0 -16 6 l-29 23q-7 7 -8.5 16.5t4.5 17.5q72 103 72 229q0 132 -78 238q-6 8 -4.5 18t9.5 17l29 22q7 5 15 5z" />
|
||||
<glyph unicode="" d="M967 1004h3q11 -1 17 -10q135 -179 135 -396q0 -105 -34 -206.5t-98 -185.5q-7 -9 -17 -10h-3q-9 0 -16 6l-42 34q-8 6 -9 16t5 18q111 150 111 328q0 90 -29.5 176t-84.5 157q-6 9 -5 19t10 16l42 33q7 5 15 5zM321 814l258 172q9 6 15 2.5t6 -13.5v-750q0 -10 -6 -13.5 t-15 2.5l-258 172q-21 14 -46 14h-250q-10 0 -17.5 7.5t-7.5 17.5v350q0 10 7.5 17.5t17.5 7.5h250q25 0 46 14zM766 900h4q10 -1 16 -10q96 -129 96 -290q0 -154 -90 -281q-6 -9 -17 -10l-3 -1q-9 0 -16 6l-29 23q-7 7 -8.5 16.5t4.5 17.5q72 103 72 229q0 132 -78 238 q-6 8 -4.5 18.5t9.5 16.5l29 22q7 5 15 5z" />
|
||||
<glyph unicode="" d="M500 900h100v-100h-100v-100h-400v-100h-100v600h500v-300zM1200 700h-200v-100h200v-200h-300v300h-200v300h-100v200h600v-500zM100 1100v-300h300v300h-300zM800 1100v-300h300v300h-300zM300 900h-100v100h100v-100zM1000 900h-100v100h100v-100zM300 500h200v-500 h-500v500h200v100h100v-100zM800 300h200v-100h-100v-100h-200v100h-100v100h100v200h-200v100h300v-300zM100 400v-300h300v300h-300zM300 200h-100v100h100v-100zM1200 200h-100v100h100v-100zM700 0h-100v100h100v-100zM1200 0h-300v100h300v-100z" />
|
||||
<glyph unicode="" d="M100 200h-100v1000h100v-1000zM300 200h-100v1000h100v-1000zM700 200h-200v1000h200v-1000zM900 200h-100v1000h100v-1000zM1200 200h-200v1000h200v-1000zM400 0h-300v100h300v-100zM600 0h-100v91h100v-91zM800 0h-100v91h100v-91zM1100 0h-200v91h200v-91z" />
|
||||
<glyph unicode="" d="M500 1200l682 -682q8 -8 8 -18t-8 -18l-464 -464q-8 -8 -18 -8t-18 8l-682 682l1 475q0 10 7.5 17.5t17.5 7.5h474zM319.5 1024.5q-29.5 29.5 -71 29.5t-71 -29.5t-29.5 -71.5t29.5 -71.5t71 -29.5t71 29.5t29.5 71.5t-29.5 71.5z" />
|
||||
<glyph unicode="" d="M500 1200l682 -682q8 -8 8 -18t-8 -18l-464 -464q-8 -8 -18 -8t-18 8l-682 682l1 475q0 10 7.5 17.5t17.5 7.5h474zM800 1200l682 -682q8 -8 8 -18t-8 -18l-464 -464q-8 -8 -18 -8t-18 8l-56 56l424 426l-700 700h150zM319.5 1024.5q-29.5 29.5 -71 29.5t-71 -29.5 t-29.5 -71.5t29.5 -71.5t71 -29.5t71 29.5t29.5 71.5t-29.5 71.5z" />
|
||||
<glyph unicode="" d="M300 1200h825q75 0 75 -75v-900q0 -25 -18 -43l-64 -64q-8 -8 -13 -5.5t-5 12.5v950q0 10 -7.5 17.5t-17.5 7.5h-700q-25 0 -43 -18l-64 -64q-8 -8 -5.5 -13t12.5 -5h700q10 0 17.5 -7.5t7.5 -17.5v-950q0 -10 -7.5 -17.5t-17.5 -7.5h-850q-10 0 -17.5 7.5t-7.5 17.5v975 q0 25 18 43l139 139q18 18 43 18z" />
|
||||
<glyph unicode="" d="M250 1200h800q21 0 35.5 -14.5t14.5 -35.5v-1150l-450 444l-450 -445v1151q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M822 1200h-444q-11 0 -19 -7.5t-9 -17.5l-78 -301q-7 -24 7 -45l57 -108q6 -9 17.5 -15t21.5 -6h450q10 0 21.5 6t17.5 15l62 108q14 21 7 45l-83 301q-1 10 -9 17.5t-19 7.5zM1175 800h-150q-10 0 -21 -6.5t-15 -15.5l-78 -156q-4 -9 -15 -15.5t-21 -6.5h-550 q-10 0 -21 6.5t-15 15.5l-78 156q-4 9 -15 15.5t-21 6.5h-150q-10 0 -17.5 -7.5t-7.5 -17.5v-650q0 -10 7.5 -17.5t17.5 -7.5h150q10 0 17.5 7.5t7.5 17.5v150q0 10 7.5 17.5t17.5 7.5h750q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 7.5 -17.5t17.5 -7.5h150q10 0 17.5 7.5 t7.5 17.5v650q0 10 -7.5 17.5t-17.5 7.5zM850 200h-500q-10 0 -19.5 -7t-11.5 -17l-38 -152q-2 -10 3.5 -17t15.5 -7h600q10 0 15.5 7t3.5 17l-38 152q-2 10 -11.5 17t-19.5 7z" />
|
||||
<glyph unicode="" d="M500 1100h200q56 0 102.5 -20.5t72.5 -50t44 -59t25 -50.5l6 -20h150q41 0 70.5 -29.5t29.5 -70.5v-600q0 -41 -29.5 -70.5t-70.5 -29.5h-1000q-41 0 -70.5 29.5t-29.5 70.5v600q0 41 29.5 70.5t70.5 29.5h150q2 8 6.5 21.5t24 48t45 61t72 48t102.5 21.5zM900 800v-100 h100v100h-100zM600 730q-95 0 -162.5 -67.5t-67.5 -162.5t67.5 -162.5t162.5 -67.5t162.5 67.5t67.5 162.5t-67.5 162.5t-162.5 67.5zM600 603q43 0 73 -30t30 -73t-30 -73t-73 -30t-73 30t-30 73t30 73t73 30z" />
|
||||
<glyph unicode="" d="M681 1199l385 -998q20 -50 60 -92q18 -19 36.5 -29.5t27.5 -11.5l10 -2v-66h-417v66q53 0 75 43.5t5 88.5l-82 222h-391q-58 -145 -92 -234q-11 -34 -6.5 -57t25.5 -37t46 -20t55 -6v-66h-365v66q56 24 84 52q12 12 25 30.5t20 31.5l7 13l399 1006h93zM416 521h340 l-162 457z" />
|
||||
<glyph unicode="" d="M753 641q5 -1 14.5 -4.5t36 -15.5t50.5 -26.5t53.5 -40t50.5 -54.5t35.5 -70t14.5 -87q0 -67 -27.5 -125.5t-71.5 -97.5t-98.5 -66.5t-108.5 -40.5t-102 -13h-500v89q41 7 70.5 32.5t29.5 65.5v827q0 24 -0.5 34t-3.5 24t-8.5 19.5t-17 13.5t-28 12.5t-42.5 11.5v71 l471 -1q57 0 115.5 -20.5t108 -57t80.5 -94t31 -124.5q0 -51 -15.5 -96.5t-38 -74.5t-45 -50.5t-38.5 -30.5zM400 700h139q78 0 130.5 48.5t52.5 122.5q0 41 -8.5 70.5t-29.5 55.5t-62.5 39.5t-103.5 13.5h-118v-350zM400 200h216q80 0 121 50.5t41 130.5q0 90 -62.5 154.5 t-156.5 64.5h-159v-400z" />
|
||||
<glyph unicode="" d="M877 1200l2 -57q-83 -19 -116 -45.5t-40 -66.5l-132 -839q-9 -49 13 -69t96 -26v-97h-500v97q186 16 200 98l173 832q3 17 3 30t-1.5 22.5t-9 17.5t-13.5 12.5t-21.5 10t-26 8.5t-33.5 10q-13 3 -19 5v57h425z" />
|
||||
<glyph unicode="" d="M1300 900h-50q0 21 -4 37t-9.5 26.5t-18 17.5t-22 11t-28.5 5.5t-31 2t-37 0.5h-200v-850q0 -22 25 -34.5t50 -13.5l25 -2v-100h-400v100q4 0 11 0.5t24 3t30 7t24 15t11 24.5v850h-200q-25 0 -37 -0.5t-31 -2t-28.5 -5.5t-22 -11t-18 -17.5t-9.5 -26.5t-4 -37h-50v300 h1000v-300zM175 1000h-75v-800h75l-125 -167l-125 167h75v800h-75l125 167z" />
|
||||
<glyph unicode="" d="M1100 900h-50q0 21 -4 37t-9.5 26.5t-18 17.5t-22 11t-28.5 5.5t-31 2t-37 0.5h-200v-650q0 -22 25 -34.5t50 -13.5l25 -2v-100h-400v100q4 0 11 0.5t24 3t30 7t24 15t11 24.5v650h-200q-25 0 -37 -0.5t-31 -2t-28.5 -5.5t-22 -11t-18 -17.5t-9.5 -26.5t-4 -37h-50v300 h1000v-300zM1167 50l-167 -125v75h-800v-75l-167 125l167 125v-75h800v75z" />
|
||||
<glyph unicode="" d="M50 1100h600q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-600q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 800h1000q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1000q-21 0 -35.5 14.5t-14.5 35.5v100 q0 21 14.5 35.5t35.5 14.5zM50 500h800q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 200h1100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100 q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M250 1100h700q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-700q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 800h1100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5v100 q0 21 14.5 35.5t35.5 14.5zM250 500h700q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-700q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 200h1100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100 q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M500 950v100q0 21 14.5 35.5t35.5 14.5h600q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-600q-21 0 -35.5 14.5t-14.5 35.5zM100 650v100q0 21 14.5 35.5t35.5 14.5h1000q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1000 q-21 0 -35.5 14.5t-14.5 35.5zM300 350v100q0 21 14.5 35.5t35.5 14.5h800q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5zM0 50v100q0 21 14.5 35.5t35.5 14.5h1100q21 0 35.5 -14.5t14.5 -35.5v-100 q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5z" />
|
||||
<glyph unicode="" d="M50 1100h1100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 800h1100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5v100 q0 21 14.5 35.5t35.5 14.5zM50 500h1100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 200h1100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100 q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M50 1100h100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM350 1100h800q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5v100 q0 21 14.5 35.5t35.5 14.5zM50 800h100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM350 800h800q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-800 q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 500h100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM350 500h800q21 0 35.5 -14.5t14.5 -35.5v-100 q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 200h100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM350 200h800 q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M400 0h-100v1100h100v-1100zM550 1100h100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM550 800h500q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-500 q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM267 550l-167 -125v75h-200v100h200v75zM550 500h300q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-300q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM550 200h600 q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-600q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M50 1100h100q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM900 0h-100v1100h100v-1100zM50 800h500q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-500 q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM1100 600h200v-100h-200v-75l-167 125l167 125v-75zM50 500h300q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-300q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5zM50 200h600 q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-600q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M75 1000h750q31 0 53 -22t22 -53v-650q0 -31 -22 -53t-53 -22h-750q-31 0 -53 22t-22 53v650q0 31 22 53t53 22zM1200 300l-300 300l300 300v-600z" />
|
||||
<glyph unicode="" d="M44 1100h1112q18 0 31 -13t13 -31v-1012q0 -18 -13 -31t-31 -13h-1112q-18 0 -31 13t-13 31v1012q0 18 13 31t31 13zM100 1000v-737l247 182l298 -131l-74 156l293 318l236 -288v500h-1000zM342 884q56 0 95 -39t39 -94.5t-39 -95t-95 -39.5t-95 39.5t-39 95t39 94.5 t95 39z" />
|
||||
<glyph unicode="" d="M648 1169q117 0 216 -60t156.5 -161t57.5 -218q0 -115 -70 -258q-69 -109 -158 -225.5t-143 -179.5l-54 -62q-9 8 -25.5 24.5t-63.5 67.5t-91 103t-98.5 128t-95.5 148q-60 132 -60 249q0 88 34 169.5t91.5 142t137 96.5t166.5 36zM652.5 974q-91.5 0 -156.5 -65 t-65 -157t65 -156.5t156.5 -64.5t156.5 64.5t65 156.5t-65 157t-156.5 65z" />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 173v854q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5 t155.5 -155.5t214.5 -57z" />
|
||||
<glyph unicode="" d="M554 1295q21 -72 57.5 -143.5t76 -130t83 -118t82.5 -117t70 -116t49.5 -126t18.5 -136.5q0 -71 -25.5 -135t-68.5 -111t-99 -82t-118.5 -54t-125.5 -23q-84 5 -161.5 34t-139.5 78.5t-99 125t-37 164.5q0 69 18 136.5t49.5 126.5t69.5 116.5t81.5 117.5t83.5 119 t76.5 131t58.5 143zM344 710q-23 -33 -43.5 -70.5t-40.5 -102.5t-17 -123q1 -37 14.5 -69.5t30 -52t41 -37t38.5 -24.5t33 -15q21 -7 32 -1t13 22l6 34q2 10 -2.5 22t-13.5 19q-5 4 -14 12t-29.5 40.5t-32.5 73.5q-26 89 6 271q2 11 -6 11q-8 1 -15 -10z" />
|
||||
<glyph unicode="" d="M1000 1013l108 115q2 1 5 2t13 2t20.5 -1t25 -9.5t28.5 -21.5q22 -22 27 -43t0 -32l-6 -10l-108 -115zM350 1100h400q50 0 105 -13l-187 -187h-368q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5v182l200 200v-332 q0 -165 -93.5 -257.5t-256.5 -92.5h-400q-165 0 -257.5 92.5t-92.5 257.5v400q0 165 92.5 257.5t257.5 92.5zM1009 803l-362 -362l-161 -50l55 170l355 355z" />
|
||||
<glyph unicode="" d="M350 1100h361q-164 -146 -216 -200h-195q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5l200 153v-103q0 -165 -92.5 -257.5t-257.5 -92.5h-400q-165 0 -257.5 92.5t-92.5 257.5v400q0 165 92.5 257.5t257.5 92.5z M824 1073l339 -301q8 -7 8 -17.5t-8 -17.5l-340 -306q-7 -6 -12.5 -4t-6.5 11v203q-26 1 -54.5 0t-78.5 -7.5t-92 -17.5t-86 -35t-70 -57q10 59 33 108t51.5 81.5t65 58.5t68.5 40.5t67 24.5t56 13.5t40 4.5v210q1 10 6.5 12.5t13.5 -4.5z" />
|
||||
<glyph unicode="" d="M350 1100h350q60 0 127 -23l-178 -177h-349q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5v69l200 200v-219q0 -165 -92.5 -257.5t-257.5 -92.5h-400q-165 0 -257.5 92.5t-92.5 257.5v400q0 165 92.5 257.5t257.5 92.5z M643 639l395 395q7 7 17.5 7t17.5 -7l101 -101q7 -7 7 -17.5t-7 -17.5l-531 -532q-7 -7 -17.5 -7t-17.5 7l-248 248q-7 7 -7 17.5t7 17.5l101 101q7 7 17.5 7t17.5 -7l111 -111q8 -7 18 -7t18 7z" />
|
||||
<glyph unicode="" d="M318 918l264 264q8 8 18 8t18 -8l260 -264q7 -8 4.5 -13t-12.5 -5h-170v-200h200v173q0 10 5 12t13 -5l264 -260q8 -7 8 -17.5t-8 -17.5l-264 -265q-8 -7 -13 -5t-5 12v173h-200v-200h170q10 0 12.5 -5t-4.5 -13l-260 -264q-8 -8 -18 -8t-18 8l-264 264q-8 8 -5.5 13 t12.5 5h175v200h-200v-173q0 -10 -5 -12t-13 5l-264 265q-8 7 -8 17.5t8 17.5l264 260q8 7 13 5t5 -12v-173h200v200h-175q-10 0 -12.5 5t5.5 13z" />
|
||||
<glyph unicode="" d="M250 1100h100q21 0 35.5 -14.5t14.5 -35.5v-438l464 453q15 14 25.5 10t10.5 -25v-1000q0 -21 -10.5 -25t-25.5 10l-464 453v-438q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v1000q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M50 1100h100q21 0 35.5 -14.5t14.5 -35.5v-438l464 453q15 14 25.5 10t10.5 -25v-438l464 453q15 14 25.5 10t10.5 -25v-1000q0 -21 -10.5 -25t-25.5 10l-464 453v-438q0 -21 -10.5 -25t-25.5 10l-464 453v-438q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5 t-14.5 35.5v1000q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M1200 1050v-1000q0 -21 -10.5 -25t-25.5 10l-464 453v-438q0 -21 -10.5 -25t-25.5 10l-492 480q-15 14 -15 35t15 35l492 480q15 14 25.5 10t10.5 -25v-438l464 453q15 14 25.5 10t10.5 -25z" />
|
||||
<glyph unicode="" d="M243 1074l814 -498q18 -11 18 -26t-18 -26l-814 -498q-18 -11 -30.5 -4t-12.5 28v1000q0 21 12.5 28t30.5 -4z" />
|
||||
<glyph unicode="" d="M250 1000h200q21 0 35.5 -14.5t14.5 -35.5v-800q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v800q0 21 14.5 35.5t35.5 14.5zM650 1000h200q21 0 35.5 -14.5t14.5 -35.5v-800q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v800 q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M1100 950v-800q0 -21 -14.5 -35.5t-35.5 -14.5h-800q-21 0 -35.5 14.5t-14.5 35.5v800q0 21 14.5 35.5t35.5 14.5h800q21 0 35.5 -14.5t14.5 -35.5z" />
|
||||
<glyph unicode="" d="M500 612v438q0 21 10.5 25t25.5 -10l492 -480q15 -14 15 -35t-15 -35l-492 -480q-15 -14 -25.5 -10t-10.5 25v438l-464 -453q-15 -14 -25.5 -10t-10.5 25v1000q0 21 10.5 25t25.5 -10z" />
|
||||
<glyph unicode="" d="M1048 1102l100 1q20 0 35 -14.5t15 -35.5l5 -1000q0 -21 -14.5 -35.5t-35.5 -14.5l-100 -1q-21 0 -35.5 14.5t-14.5 35.5l-2 437l-463 -454q-14 -15 -24.5 -10.5t-10.5 25.5l-2 437l-462 -455q-15 -14 -25.5 -9.5t-10.5 24.5l-5 1000q0 21 10.5 25.5t25.5 -10.5l466 -450 l-2 438q0 20 10.5 24.5t25.5 -9.5l466 -451l-2 438q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M850 1100h100q21 0 35.5 -14.5t14.5 -35.5v-1000q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v438l-464 -453q-15 -14 -25.5 -10t-10.5 25v1000q0 21 10.5 25t25.5 -10l464 -453v438q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M686 1081l501 -540q15 -15 10.5 -26t-26.5 -11h-1042q-22 0 -26.5 11t10.5 26l501 540q15 15 36 15t36 -15zM150 400h1000q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1000q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M885 900l-352 -353l352 -353l-197 -198l-552 552l552 550z" />
|
||||
<glyph unicode="" d="M1064 547l-551 -551l-198 198l353 353l-353 353l198 198z" />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM650 900h-100q-21 0 -35.5 -14.5t-14.5 -35.5v-150h-150 q-21 0 -35.5 -14.5t-14.5 -35.5v-100q0 -21 14.5 -35.5t35.5 -14.5h150v-150q0 -21 14.5 -35.5t35.5 -14.5h100q21 0 35.5 14.5t14.5 35.5v150h150q21 0 35.5 14.5t14.5 35.5v100q0 21 -14.5 35.5t-35.5 14.5h-150v150q0 21 -14.5 35.5t-35.5 14.5z" />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM850 700h-500q-21 0 -35.5 -14.5t-14.5 -35.5v-100q0 -21 14.5 -35.5 t35.5 -14.5h500q21 0 35.5 14.5t14.5 35.5v100q0 21 -14.5 35.5t-35.5 14.5z" />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM741.5 913q-12.5 0 -21.5 -9l-120 -120l-120 120q-9 9 -21.5 9 t-21.5 -9l-141 -141q-9 -9 -9 -21.5t9 -21.5l120 -120l-120 -120q-9 -9 -9 -21.5t9 -21.5l141 -141q9 -9 21.5 -9t21.5 9l120 120l120 -120q9 -9 21.5 -9t21.5 9l141 141q9 9 9 21.5t-9 21.5l-120 120l120 120q9 9 9 21.5t-9 21.5l-141 141q-9 9 -21.5 9z" />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM546 623l-84 85q-7 7 -17.5 7t-18.5 -7l-139 -139q-7 -8 -7 -18t7 -18 l242 -241q7 -8 17.5 -8t17.5 8l375 375q7 7 7 17.5t-7 18.5l-139 139q-7 7 -17.5 7t-17.5 -7z" />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM588 941q-29 0 -59 -5.5t-63 -20.5t-58 -38.5t-41.5 -63t-16.5 -89.5 q0 -25 20 -25h131q30 -5 35 11q6 20 20.5 28t45.5 8q20 0 31.5 -10.5t11.5 -28.5q0 -23 -7 -34t-26 -18q-1 0 -13.5 -4t-19.5 -7.5t-20 -10.5t-22 -17t-18.5 -24t-15.5 -35t-8 -46q-1 -8 5.5 -16.5t20.5 -8.5h173q7 0 22 8t35 28t37.5 48t29.5 74t12 100q0 47 -17 83 t-42.5 57t-59.5 34.5t-64 18t-59 4.5zM675 400h-150q-10 0 -17.5 -7.5t-7.5 -17.5v-150q0 -10 7.5 -17.5t17.5 -7.5h150q10 0 17.5 7.5t7.5 17.5v150q0 10 -7.5 17.5t-17.5 7.5z" />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM675 1000h-150q-10 0 -17.5 -7.5t-7.5 -17.5v-150q0 -10 7.5 -17.5 t17.5 -7.5h150q10 0 17.5 7.5t7.5 17.5v150q0 10 -7.5 17.5t-17.5 7.5zM675 700h-250q-10 0 -17.5 -7.5t-7.5 -17.5v-50q0 -10 7.5 -17.5t17.5 -7.5h75v-200h-75q-10 0 -17.5 -7.5t-7.5 -17.5v-50q0 -10 7.5 -17.5t17.5 -7.5h350q10 0 17.5 7.5t7.5 17.5v50q0 10 -7.5 17.5 t-17.5 7.5h-75v275q0 10 -7.5 17.5t-17.5 7.5z" />
|
||||
<glyph unicode="" d="M525 1200h150q10 0 17.5 -7.5t7.5 -17.5v-194q103 -27 178.5 -102.5t102.5 -178.5h194q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-194q-27 -103 -102.5 -178.5t-178.5 -102.5v-194q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v194 q-103 27 -178.5 102.5t-102.5 178.5h-194q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5h194q27 103 102.5 178.5t178.5 102.5v194q0 10 7.5 17.5t17.5 7.5zM700 893v-168q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v168q-68 -23 -119 -74 t-74 -119h168q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-168q23 -68 74 -119t119 -74v168q0 10 7.5 17.5t17.5 7.5h150q10 0 17.5 -7.5t7.5 -17.5v-168q68 23 119 74t74 119h-168q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5h168 q-23 68 -74 119t-119 74z" />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 1027q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5 t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5t-57 214.5t-155.5 155.5t-214.5 57zM759 823l64 -64q7 -7 7 -17.5t-7 -17.5l-124 -124l124 -124q7 -7 7 -17.5t-7 -17.5l-64 -64q-7 -7 -17.5 -7t-17.5 7l-124 124l-124 -124q-7 -7 -17.5 -7t-17.5 7l-64 64 q-7 7 -7 17.5t7 17.5l124 124l-124 124q-7 7 -7 17.5t7 17.5l64 64q7 7 17.5 7t17.5 -7l124 -124l124 124q7 7 17.5 7t17.5 -7z" />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 1027q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5t57 -214.5 t155.5 -155.5t214.5 -57t214.5 57t155.5 155.5t57 214.5t-57 214.5t-155.5 155.5t-214.5 57zM782 788l106 -106q7 -7 7 -17.5t-7 -17.5l-320 -321q-8 -7 -18 -7t-18 7l-202 203q-8 7 -8 17.5t8 17.5l106 106q7 8 17.5 8t17.5 -8l79 -79l197 197q7 7 17.5 7t17.5 -7z" />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM600 1027q-116 0 -214.5 -57t-155.5 -155.5t-57 -214.5q0 -120 65 -225 l587 587q-105 65 -225 65zM965 819l-584 -584q104 -62 219 -62q116 0 214.5 57t155.5 155.5t57 214.5q0 115 -62 219z" />
|
||||
<glyph unicode="" d="M39 582l522 427q16 13 27.5 8t11.5 -26v-291h550q21 0 35.5 -14.5t14.5 -35.5v-200q0 -21 -14.5 -35.5t-35.5 -14.5h-550v-291q0 -21 -11.5 -26t-27.5 8l-522 427q-16 13 -16 32t16 32z" />
|
||||
<glyph unicode="" d="M639 1009l522 -427q16 -13 16 -32t-16 -32l-522 -427q-16 -13 -27.5 -8t-11.5 26v291h-550q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5h550v291q0 21 11.5 26t27.5 -8z" />
|
||||
<glyph unicode="" d="M682 1161l427 -522q13 -16 8 -27.5t-26 -11.5h-291v-550q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v550h-291q-21 0 -26 11.5t8 27.5l427 522q13 16 32 16t32 -16z" />
|
||||
<glyph unicode="" d="M550 1200h200q21 0 35.5 -14.5t14.5 -35.5v-550h291q21 0 26 -11.5t-8 -27.5l-427 -522q-13 -16 -32 -16t-32 16l-427 522q-13 16 -8 27.5t26 11.5h291v550q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M639 1109l522 -427q16 -13 16 -32t-16 -32l-522 -427q-16 -13 -27.5 -8t-11.5 26v291q-94 -2 -182 -20t-170.5 -52t-147 -92.5t-100.5 -135.5q5 105 27 193.5t67.5 167t113 135t167 91.5t225.5 42v262q0 21 11.5 26t27.5 -8z" />
|
||||
<glyph unicode="" d="M850 1200h300q21 0 35.5 -14.5t14.5 -35.5v-300q0 -21 -10.5 -25t-24.5 10l-94 94l-249 -249q-8 -7 -18 -7t-18 7l-106 106q-7 8 -7 18t7 18l249 249l-94 94q-14 14 -10 24.5t25 10.5zM350 0h-300q-21 0 -35.5 14.5t-14.5 35.5v300q0 21 10.5 25t24.5 -10l94 -94l249 249 q8 7 18 7t18 -7l106 -106q7 -8 7 -18t-7 -18l-249 -249l94 -94q14 -14 10 -24.5t-25 -10.5z" />
|
||||
<glyph unicode="" d="M1014 1120l106 -106q7 -8 7 -18t-7 -18l-249 -249l94 -94q14 -14 10 -24.5t-25 -10.5h-300q-21 0 -35.5 14.5t-14.5 35.5v300q0 21 10.5 25t24.5 -10l94 -94l249 249q8 7 18 7t18 -7zM250 600h300q21 0 35.5 -14.5t14.5 -35.5v-300q0 -21 -10.5 -25t-24.5 10l-94 94 l-249 -249q-8 -7 -18 -7t-18 7l-106 106q-7 8 -7 18t7 18l249 249l-94 94q-14 14 -10 24.5t25 10.5z" />
|
||||
<glyph unicode="" d="M600 1177q117 0 224 -45.5t184.5 -123t123 -184.5t45.5 -224t-45.5 -224t-123 -184.5t-184.5 -123t-224 -45.5t-224 45.5t-184.5 123t-123 184.5t-45.5 224t45.5 224t123 184.5t184.5 123t224 45.5zM704 900h-208q-20 0 -32 -14.5t-8 -34.5l58 -302q4 -20 21.5 -34.5 t37.5 -14.5h54q20 0 37.5 14.5t21.5 34.5l58 302q4 20 -8 34.5t-32 14.5zM675 400h-150q-10 0 -17.5 -7.5t-7.5 -17.5v-150q0 -10 7.5 -17.5t17.5 -7.5h150q10 0 17.5 7.5t7.5 17.5v150q0 10 -7.5 17.5t-17.5 7.5z" />
|
||||
<glyph unicode="" d="M260 1200q9 0 19 -2t15 -4l5 -2q22 -10 44 -23l196 -118q21 -13 36 -24q29 -21 37 -12q11 13 49 35l196 118q22 13 45 23q17 7 38 7q23 0 47 -16.5t37 -33.5l13 -16q14 -21 18 -45l25 -123l8 -44q1 -9 8.5 -14.5t17.5 -5.5h61q10 0 17.5 -7.5t7.5 -17.5v-50 q0 -10 -7.5 -17.5t-17.5 -7.5h-50q-10 0 -17.5 -7.5t-7.5 -17.5v-175h-400v300h-200v-300h-400v175q0 10 -7.5 17.5t-17.5 7.5h-50q-10 0 -17.5 7.5t-7.5 17.5v50q0 10 7.5 17.5t17.5 7.5h61q11 0 18 3t7 8q0 4 9 52l25 128q5 25 19 45q2 3 5 7t13.5 15t21.5 19.5t26.5 15.5 t29.5 7zM915 1079l-166 -162q-7 -7 -5 -12t12 -5h219q10 0 15 7t2 17l-51 149q-3 10 -11 12t-15 -6zM463 917l-177 157q-8 7 -16 5t-11 -12l-51 -143q-3 -10 2 -17t15 -7h231q11 0 12.5 5t-5.5 12zM500 0h-375q-10 0 -17.5 7.5t-7.5 17.5v375h400v-400zM1100 400v-375 q0 -10 -7.5 -17.5t-17.5 -7.5h-375v400h400z" />
|
||||
<glyph unicode="" d="M1165 1190q8 3 21 -6.5t13 -17.5q-2 -178 -24.5 -323.5t-55.5 -245.5t-87 -174.5t-102.5 -118.5t-118 -68.5t-118.5 -33t-120 -4.5t-105 9.5t-90 16.5q-61 12 -78 11q-4 1 -12.5 0t-34 -14.5t-52.5 -40.5l-153 -153q-26 -24 -37 -14.5t-11 43.5q0 64 42 102q8 8 50.5 45 t66.5 58q19 17 35 47t13 61q-9 55 -10 102.5t7 111t37 130t78 129.5q39 51 80 88t89.5 63.5t94.5 45t113.5 36t129 31t157.5 37t182 47.5zM1116 1098q-8 9 -22.5 -3t-45.5 -50q-38 -47 -119 -103.5t-142 -89.5l-62 -33q-56 -30 -102 -57t-104 -68t-102.5 -80.5t-85.5 -91 t-64 -104.5q-24 -56 -31 -86t2 -32t31.5 17.5t55.5 59.5q25 30 94 75.5t125.5 77.5t147.5 81q70 37 118.5 69t102 79.5t99 111t86.5 148.5q22 50 24 60t-6 19z" />
|
||||
<glyph unicode="" d="M653 1231q-39 -67 -54.5 -131t-10.5 -114.5t24.5 -96.5t47.5 -80t63.5 -62.5t68.5 -46.5t65 -30q-4 7 -17.5 35t-18.5 39.5t-17 39.5t-17 43t-13 42t-9.5 44.5t-2 42t4 43t13.5 39t23 38.5q96 -42 165 -107.5t105 -138t52 -156t13 -159t-19 -149.5q-13 -55 -44 -106.5 t-68 -87t-78.5 -64.5t-72.5 -45t-53 -22q-72 -22 -127 -11q-31 6 -13 19q6 3 17 7q13 5 32.5 21t41 44t38.5 63.5t21.5 81.5t-6.5 94.5t-50 107t-104 115.5q10 -104 -0.5 -189t-37 -140.5t-65 -93t-84 -52t-93.5 -11t-95 24.5q-80 36 -131.5 114t-53.5 171q-2 23 0 49.5 t4.5 52.5t13.5 56t27.5 60t46 64.5t69.5 68.5q-8 -53 -5 -102.5t17.5 -90t34 -68.5t44.5 -39t49 -2q31 13 38.5 36t-4.5 55t-29 64.5t-36 75t-26 75.5q-15 85 2 161.5t53.5 128.5t85.5 92.5t93.5 61t81.5 25.5z" />
|
||||
<glyph unicode="" d="M600 1094q82 0 160.5 -22.5t140 -59t116.5 -82.5t94.5 -95t68 -95t42.5 -82.5t14 -57.5t-14 -57.5t-43 -82.5t-68.5 -95t-94.5 -95t-116.5 -82.5t-140 -59t-159.5 -22.5t-159.5 22.5t-140 59t-116.5 82.5t-94.5 95t-68.5 95t-43 82.5t-14 57.5t14 57.5t42.5 82.5t68 95 t94.5 95t116.5 82.5t140 59t160.5 22.5zM888 829q-15 15 -18 12t5 -22q25 -57 25 -119q0 -124 -88 -212t-212 -88t-212 88t-88 212q0 59 23 114q8 19 4.5 22t-17.5 -12q-70 -69 -160 -184q-13 -16 -15 -40.5t9 -42.5q22 -36 47 -71t70 -82t92.5 -81t113 -58.5t133.5 -24.5 t133.5 24t113 58.5t92.5 81.5t70 81.5t47 70.5q11 18 9 42.5t-14 41.5q-90 117 -163 189zM448 727l-35 -36q-15 -15 -19.5 -38.5t4.5 -41.5q37 -68 93 -116q16 -13 38.5 -11t36.5 17l35 34q14 15 12.5 33.5t-16.5 33.5q-44 44 -89 117q-11 18 -28 20t-32 -12z" />
|
||||
<glyph unicode="" d="M592 0h-148l31 120q-91 20 -175.5 68.5t-143.5 106.5t-103.5 119t-66.5 110t-22 76q0 21 14 57.5t42.5 82.5t68 95t94.5 95t116.5 82.5t140 59t160.5 22.5q61 0 126 -15l32 121h148zM944 770l47 181q108 -85 176.5 -192t68.5 -159q0 -26 -19.5 -71t-59.5 -102t-93 -112 t-129 -104.5t-158 -75.5l46 173q77 49 136 117t97 131q11 18 9 42.5t-14 41.5q-54 70 -107 130zM310 824q-70 -69 -160 -184q-13 -16 -15 -40.5t9 -42.5q18 -30 39 -60t57 -70.5t74 -73t90 -61t105 -41.5l41 154q-107 18 -178.5 101.5t-71.5 193.5q0 59 23 114q8 19 4.5 22 t-17.5 -12zM448 727l-35 -36q-15 -15 -19.5 -38.5t4.5 -41.5q37 -68 93 -116q16 -13 38.5 -11t36.5 17l12 11l22 86l-3 4q-44 44 -89 117q-11 18 -28 20t-32 -12z" />
|
||||
<glyph unicode="" d="M-90 100l642 1066q20 31 48 28.5t48 -35.5l642 -1056q21 -32 7.5 -67.5t-50.5 -35.5h-1294q-37 0 -50.5 34t7.5 66zM155 200h345v75q0 10 7.5 17.5t17.5 7.5h150q10 0 17.5 -7.5t7.5 -17.5v-75h345l-445 723zM496 700h208q20 0 32 -14.5t8 -34.5l-58 -252 q-4 -20 -21.5 -34.5t-37.5 -14.5h-54q-20 0 -37.5 14.5t-21.5 34.5l-58 252q-4 20 8 34.5t32 14.5z" />
|
||||
<glyph unicode="" d="M650 1200q62 0 106 -44t44 -106v-339l363 -325q15 -14 26 -38.5t11 -44.5v-41q0 -20 -12 -26.5t-29 5.5l-359 249v-263q100 -93 100 -113v-64q0 -21 -13 -29t-32 1l-205 128l-205 -128q-19 -9 -32 -1t-13 29v64q0 20 100 113v263l-359 -249q-17 -12 -29 -5.5t-12 26.5v41 q0 20 11 44.5t26 38.5l363 325v339q0 62 44 106t106 44z" />
|
||||
<glyph unicode="" d="M850 1200h100q21 0 35.5 -14.5t14.5 -35.5v-50h50q21 0 35.5 -14.5t14.5 -35.5v-150h-1100v150q0 21 14.5 35.5t35.5 14.5h50v50q0 21 14.5 35.5t35.5 14.5h100q21 0 35.5 -14.5t14.5 -35.5v-50h500v50q0 21 14.5 35.5t35.5 14.5zM1100 800v-750q0 -21 -14.5 -35.5 t-35.5 -14.5h-1000q-21 0 -35.5 14.5t-14.5 35.5v750h1100zM100 600v-100h100v100h-100zM300 600v-100h100v100h-100zM500 600v-100h100v100h-100zM700 600v-100h100v100h-100zM900 600v-100h100v100h-100zM100 400v-100h100v100h-100zM300 400v-100h100v100h-100zM500 400 v-100h100v100h-100zM700 400v-100h100v100h-100zM900 400v-100h100v100h-100zM100 200v-100h100v100h-100zM300 200v-100h100v100h-100zM500 200v-100h100v100h-100zM700 200v-100h100v100h-100zM900 200v-100h100v100h-100z" />
|
||||
<glyph unicode="" d="M1135 1165l249 -230q15 -14 15 -35t-15 -35l-249 -230q-14 -14 -24.5 -10t-10.5 25v150h-159l-600 -600h-291q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5h209l600 600h241v150q0 21 10.5 25t24.5 -10zM522 819l-141 -141l-122 122h-209q-21 0 -35.5 14.5 t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5h291zM1135 565l249 -230q15 -14 15 -35t-15 -35l-249 -230q-14 -14 -24.5 -10t-10.5 25v150h-241l-181 181l141 141l122 -122h159v150q0 21 10.5 25t24.5 -10z" />
|
||||
<glyph unicode="" d="M100 1100h1000q41 0 70.5 -29.5t29.5 -70.5v-600q0 -41 -29.5 -70.5t-70.5 -29.5h-596l-304 -300v300h-100q-41 0 -70.5 29.5t-29.5 70.5v600q0 41 29.5 70.5t70.5 29.5z" />
|
||||
<glyph unicode="" d="M150 1200h200q21 0 35.5 -14.5t14.5 -35.5v-250h-300v250q0 21 14.5 35.5t35.5 14.5zM850 1200h200q21 0 35.5 -14.5t14.5 -35.5v-250h-300v250q0 21 14.5 35.5t35.5 14.5zM1100 800v-300q0 -41 -3 -77.5t-15 -89.5t-32 -96t-58 -89t-89 -77t-129 -51t-174 -20t-174 20 t-129 51t-89 77t-58 89t-32 96t-15 89.5t-3 77.5v300h300v-250v-27v-42.5t1.5 -41t5 -38t10 -35t16.5 -30t25.5 -24.5t35 -19t46.5 -12t60 -4t60 4.5t46.5 12.5t35 19.5t25 25.5t17 30.5t10 35t5 38t2 40.5t-0.5 42v25v250h300z" />
|
||||
<glyph unicode="" d="M1100 411l-198 -199l-353 353l-353 -353l-197 199l551 551z" />
|
||||
<glyph unicode="" d="M1101 789l-550 -551l-551 551l198 199l353 -353l353 353z" />
|
||||
<glyph unicode="" d="M404 1000h746q21 0 35.5 -14.5t14.5 -35.5v-551h150q21 0 25 -10.5t-10 -24.5l-230 -249q-14 -15 -35 -15t-35 15l-230 249q-14 14 -10 24.5t25 10.5h150v401h-381zM135 984l230 -249q14 -14 10 -24.5t-25 -10.5h-150v-400h385l215 -200h-750q-21 0 -35.5 14.5 t-14.5 35.5v550h-150q-21 0 -25 10.5t10 24.5l230 249q14 15 35 15t35 -15z" />
|
||||
<glyph unicode="" d="M56 1200h94q17 0 31 -11t18 -27l38 -162h896q24 0 39 -18.5t10 -42.5l-100 -475q-5 -21 -27 -42.5t-55 -21.5h-633l48 -200h535q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-50v-50q0 -21 -14.5 -35.5t-35.5 -14.5t-35.5 14.5t-14.5 35.5v50h-300v-50 q0 -21 -14.5 -35.5t-35.5 -14.5t-35.5 14.5t-14.5 35.5v50h-31q-18 0 -32.5 10t-20.5 19l-5 10l-201 961h-54q-20 0 -35 14.5t-15 35.5t15 35.5t35 14.5z" />
|
||||
<glyph unicode="" d="M1200 1000v-100h-1200v100h200q0 41 29.5 70.5t70.5 29.5h300q41 0 70.5 -29.5t29.5 -70.5h500zM0 800h1200v-800h-1200v800z" />
|
||||
<glyph unicode="" d="M200 800l-200 -400v600h200q0 41 29.5 70.5t70.5 29.5h300q42 0 71 -29.5t29 -70.5h500v-200h-1000zM1500 700l-300 -700h-1200l300 700h1200z" />
|
||||
<glyph unicode="" d="M635 1184l230 -249q14 -14 10 -24.5t-25 -10.5h-150v-601h150q21 0 25 -10.5t-10 -24.5l-230 -249q-14 -15 -35 -15t-35 15l-230 249q-14 14 -10 24.5t25 10.5h150v601h-150q-21 0 -25 10.5t10 24.5l230 249q14 15 35 15t35 -15z" />
|
||||
<glyph unicode="" d="M936 864l249 -229q14 -15 14 -35.5t-14 -35.5l-249 -229q-15 -15 -25.5 -10.5t-10.5 24.5v151h-600v-151q0 -20 -10.5 -24.5t-25.5 10.5l-249 229q-14 15 -14 35.5t14 35.5l249 229q15 15 25.5 10.5t10.5 -25.5v-149h600v149q0 21 10.5 25.5t25.5 -10.5z" />
|
||||
<glyph unicode="" d="M1169 400l-172 732q-5 23 -23 45.5t-38 22.5h-672q-20 0 -38 -20t-23 -41l-172 -739h1138zM1100 300h-1000q-41 0 -70.5 -29.5t-29.5 -70.5v-100q0 -41 29.5 -70.5t70.5 -29.5h1000q41 0 70.5 29.5t29.5 70.5v100q0 41 -29.5 70.5t-70.5 29.5zM800 100v100h100v-100h-100 zM1000 100v100h100v-100h-100z" />
|
||||
<glyph unicode="" d="M1150 1100q21 0 35.5 -14.5t14.5 -35.5v-850q0 -21 -14.5 -35.5t-35.5 -14.5t-35.5 14.5t-14.5 35.5v850q0 21 14.5 35.5t35.5 14.5zM1000 200l-675 200h-38l47 -276q3 -16 -5.5 -20t-29.5 -4h-7h-84q-20 0 -34.5 14t-18.5 35q-55 337 -55 351v250v6q0 16 1 23.5t6.5 14 t17.5 6.5h200l675 250v-850zM0 750v-250q-4 0 -11 0.5t-24 6t-30 15t-24 30t-11 48.5v50q0 26 10.5 46t25 30t29 16t25.5 7z" />
|
||||
<glyph unicode="" d="M553 1200h94q20 0 29 -10.5t3 -29.5l-18 -37q83 -19 144 -82.5t76 -140.5l63 -327l118 -173h17q19 0 33 -14.5t14 -35t-13 -40.5t-31 -27q-8 -4 -23 -9.5t-65 -19.5t-103 -25t-132.5 -20t-158.5 -9q-57 0 -115 5t-104 12t-88.5 15.5t-73.5 17.5t-54.5 16t-35.5 12l-11 4 q-18 8 -31 28t-13 40.5t14 35t33 14.5h17l118 173l63 327q15 77 76 140t144 83l-18 32q-6 19 3.5 32t28.5 13zM498 110q50 -6 102 -6q53 0 102 6q-12 -49 -39.5 -79.5t-62.5 -30.5t-63 30.5t-39 79.5z" />
|
||||
<glyph unicode="" d="M800 946l224 78l-78 -224l234 -45l-180 -155l180 -155l-234 -45l78 -224l-224 78l-45 -234l-155 180l-155 -180l-45 234l-224 -78l78 224l-234 45l180 155l-180 155l234 45l-78 224l224 -78l45 234l155 -180l155 180z" />
|
||||
<glyph unicode="" d="M650 1200h50q40 0 70 -40.5t30 -84.5v-150l-28 -125h328q40 0 70 -40.5t30 -84.5v-100q0 -45 -29 -74l-238 -344q-16 -24 -38 -40.5t-45 -16.5h-250q-7 0 -42 25t-66 50l-31 25h-61q-45 0 -72.5 18t-27.5 57v400q0 36 20 63l145 196l96 198q13 28 37.5 48t51.5 20z M650 1100l-100 -212l-150 -213v-375h100l136 -100h214l250 375v125h-450l50 225v175h-50zM50 800h100q21 0 35.5 -14.5t14.5 -35.5v-500q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v500q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M600 1100h250q23 0 45 -16.5t38 -40.5l238 -344q29 -29 29 -74v-100q0 -44 -30 -84.5t-70 -40.5h-328q28 -118 28 -125v-150q0 -44 -30 -84.5t-70 -40.5h-50q-27 0 -51.5 20t-37.5 48l-96 198l-145 196q-20 27 -20 63v400q0 39 27.5 57t72.5 18h61q124 100 139 100z M50 1000h100q21 0 35.5 -14.5t14.5 -35.5v-500q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v500q0 21 14.5 35.5t35.5 14.5zM636 1000l-136 -100h-100v-375l150 -213l100 -212h50v175l-50 225h450v125l-250 375h-214z" />
|
||||
<glyph unicode="" d="M356 873l363 230q31 16 53 -6l110 -112q13 -13 13.5 -32t-11.5 -34l-84 -121h302q84 0 138 -38t54 -110t-55 -111t-139 -39h-106l-131 -339q-6 -21 -19.5 -41t-28.5 -20h-342q-7 0 -90 81t-83 94v525q0 17 14 35.5t28 28.5zM400 792v-503l100 -89h293l131 339 q6 21 19.5 41t28.5 20h203q21 0 30.5 25t0.5 50t-31 25h-456h-7h-6h-5.5t-6 0.5t-5 1.5t-5 2t-4 2.5t-4 4t-2.5 4.5q-12 25 5 47l146 183l-86 83zM50 800h100q21 0 35.5 -14.5t14.5 -35.5v-500q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v500 q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M475 1103l366 -230q2 -1 6 -3.5t14 -10.5t18 -16.5t14.5 -20t6.5 -22.5v-525q0 -13 -86 -94t-93 -81h-342q-15 0 -28.5 20t-19.5 41l-131 339h-106q-85 0 -139.5 39t-54.5 111t54 110t138 38h302l-85 121q-11 15 -10.5 34t13.5 32l110 112q22 22 53 6zM370 945l146 -183 q17 -22 5 -47q-2 -2 -3.5 -4.5t-4 -4t-4 -2.5t-5 -2t-5 -1.5t-6 -0.5h-6h-6.5h-6h-475v-100h221q15 0 29 -20t20 -41l130 -339h294l106 89v503l-342 236zM1050 800h100q21 0 35.5 -14.5t14.5 -35.5v-500q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5 v500q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M550 1294q72 0 111 -55t39 -139v-106l339 -131q21 -6 41 -19.5t20 -28.5v-342q0 -7 -81 -90t-94 -83h-525q-17 0 -35.5 14t-28.5 28l-9 14l-230 363q-16 31 6 53l112 110q13 13 32 13.5t34 -11.5l121 -84v302q0 84 38 138t110 54zM600 972v203q0 21 -25 30.5t-50 0.5 t-25 -31v-456v-7v-6v-5.5t-0.5 -6t-1.5 -5t-2 -5t-2.5 -4t-4 -4t-4.5 -2.5q-25 -12 -47 5l-183 146l-83 -86l236 -339h503l89 100v293l-339 131q-21 6 -41 19.5t-20 28.5zM450 200h500q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-500 q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M350 1100h500q21 0 35.5 14.5t14.5 35.5v100q0 21 -14.5 35.5t-35.5 14.5h-500q-21 0 -35.5 -14.5t-14.5 -35.5v-100q0 -21 14.5 -35.5t35.5 -14.5zM600 306v-106q0 -84 -39 -139t-111 -55t-110 54t-38 138v302l-121 -84q-15 -12 -34 -11.5t-32 13.5l-112 110 q-22 22 -6 53l230 363q1 2 3.5 6t10.5 13.5t16.5 17t20 13.5t22.5 6h525q13 0 94 -83t81 -90v-342q0 -15 -20 -28.5t-41 -19.5zM308 900l-236 -339l83 -86l183 146q22 17 47 5q2 -1 4.5 -2.5t4 -4t2.5 -4t2 -5t1.5 -5t0.5 -6v-5.5v-6v-7v-456q0 -22 25 -31t50 0.5t25 30.5 v203q0 15 20 28.5t41 19.5l339 131v293l-89 100h-503z" />
|
||||
<glyph unicode="" d="M600 1178q118 0 225 -45.5t184.5 -123t123 -184.5t45.5 -225t-45.5 -225t-123 -184.5t-184.5 -123t-225 -45.5t-225 45.5t-184.5 123t-123 184.5t-45.5 225t45.5 225t123 184.5t184.5 123t225 45.5zM914 632l-275 223q-16 13 -27.5 8t-11.5 -26v-137h-275 q-10 0 -17.5 -7.5t-7.5 -17.5v-150q0 -10 7.5 -17.5t17.5 -7.5h275v-137q0 -21 11.5 -26t27.5 8l275 223q16 13 16 32t-16 32z" />
|
||||
<glyph unicode="" d="M600 1178q118 0 225 -45.5t184.5 -123t123 -184.5t45.5 -225t-45.5 -225t-123 -184.5t-184.5 -123t-225 -45.5t-225 45.5t-184.5 123t-123 184.5t-45.5 225t45.5 225t123 184.5t184.5 123t225 45.5zM561 855l-275 -223q-16 -13 -16 -32t16 -32l275 -223q16 -13 27.5 -8 t11.5 26v137h275q10 0 17.5 7.5t7.5 17.5v150q0 10 -7.5 17.5t-17.5 7.5h-275v137q0 21 -11.5 26t-27.5 -8z" />
|
||||
<glyph unicode="" d="M600 1178q118 0 225 -45.5t184.5 -123t123 -184.5t45.5 -225t-45.5 -225t-123 -184.5t-184.5 -123t-225 -45.5t-225 45.5t-184.5 123t-123 184.5t-45.5 225t45.5 225t123 184.5t184.5 123t225 45.5zM855 639l-223 275q-13 16 -32 16t-32 -16l-223 -275q-13 -16 -8 -27.5 t26 -11.5h137v-275q0 -10 7.5 -17.5t17.5 -7.5h150q10 0 17.5 7.5t7.5 17.5v275h137q21 0 26 11.5t-8 27.5z" />
|
||||
<glyph unicode="" d="M600 1178q118 0 225 -45.5t184.5 -123t123 -184.5t45.5 -225t-45.5 -225t-123 -184.5t-184.5 -123t-225 -45.5t-225 45.5t-184.5 123t-123 184.5t-45.5 225t45.5 225t123 184.5t184.5 123t225 45.5zM675 900h-150q-10 0 -17.5 -7.5t-7.5 -17.5v-275h-137q-21 0 -26 -11.5 t8 -27.5l223 -275q13 -16 32 -16t32 16l223 275q13 16 8 27.5t-26 11.5h-137v275q0 10 -7.5 17.5t-17.5 7.5z" />
|
||||
<glyph unicode="" d="M600 1176q116 0 222.5 -46t184 -123.5t123.5 -184t46 -222.5t-46 -222.5t-123.5 -184t-184 -123.5t-222.5 -46t-222.5 46t-184 123.5t-123.5 184t-46 222.5t46 222.5t123.5 184t184 123.5t222.5 46zM627 1101q-15 -12 -36.5 -20.5t-35.5 -12t-43 -8t-39 -6.5 q-15 -3 -45.5 0t-45.5 -2q-20 -7 -51.5 -26.5t-34.5 -34.5q-3 -11 6.5 -22.5t8.5 -18.5q-3 -34 -27.5 -91t-29.5 -79q-9 -34 5 -93t8 -87q0 -9 17 -44.5t16 -59.5q12 0 23 -5t23.5 -15t19.5 -14q16 -8 33 -15t40.5 -15t34.5 -12q21 -9 52.5 -32t60 -38t57.5 -11 q7 -15 -3 -34t-22.5 -40t-9.5 -38q13 -21 23 -34.5t27.5 -27.5t36.5 -18q0 -7 -3.5 -16t-3.5 -14t5 -17q104 -2 221 112q30 29 46.5 47t34.5 49t21 63q-13 8 -37 8.5t-36 7.5q-15 7 -49.5 15t-51.5 19q-18 0 -41 -0.5t-43 -1.5t-42 -6.5t-38 -16.5q-51 -35 -66 -12 q-4 1 -3.5 25.5t0.5 25.5q-6 13 -26.5 17.5t-24.5 6.5q1 15 -0.5 30.5t-7 28t-18.5 11.5t-31 -21q-23 -25 -42 4q-19 28 -8 58q6 16 22 22q6 -1 26 -1.5t33.5 -4t19.5 -13.5q7 -12 18 -24t21.5 -20.5t20 -15t15.5 -10.5l5 -3q2 12 7.5 30.5t8 34.5t-0.5 32q-3 18 3.5 29 t18 22.5t15.5 24.5q6 14 10.5 35t8 31t15.5 22.5t34 22.5q-6 18 10 36q8 0 24 -1.5t24.5 -1.5t20 4.5t20.5 15.5q-10 23 -31 42.5t-37.5 29.5t-49 27t-43.5 23q0 1 2 8t3 11.5t1.5 10.5t-1 9.5t-4.5 4.5q31 -13 58.5 -14.5t38.5 2.5l12 5q5 28 -9.5 46t-36.5 24t-50 15 t-41 20q-18 -4 -37 0zM613 994q0 -17 8 -42t17 -45t9 -23q-8 1 -39.5 5.5t-52.5 10t-37 16.5q3 11 16 29.5t16 25.5q10 -10 19 -10t14 6t13.5 14.5t16.5 12.5z" />
|
||||
<glyph unicode="" d="M756 1157q164 92 306 -9l-259 -138l145 -232l251 126q6 -89 -34 -156.5t-117 -110.5q-60 -34 -127 -39.5t-126 16.5l-596 -596q-15 -16 -36.5 -16t-36.5 16l-111 110q-15 15 -15 36.5t15 37.5l600 599q-34 101 5.5 201.5t135.5 154.5z" />
|
||||
<glyph unicode="" horiz-adv-x="1220" d="M100 1196h1000q41 0 70.5 -29.5t29.5 -70.5v-100q0 -41 -29.5 -70.5t-70.5 -29.5h-1000q-41 0 -70.5 29.5t-29.5 70.5v100q0 41 29.5 70.5t70.5 29.5zM1100 1096h-200v-100h200v100zM100 796h1000q41 0 70.5 -29.5t29.5 -70.5v-100q0 -41 -29.5 -70.5t-70.5 -29.5h-1000 q-41 0 -70.5 29.5t-29.5 70.5v100q0 41 29.5 70.5t70.5 29.5zM1100 696h-500v-100h500v100zM100 396h1000q41 0 70.5 -29.5t29.5 -70.5v-100q0 -41 -29.5 -70.5t-70.5 -29.5h-1000q-41 0 -70.5 29.5t-29.5 70.5v100q0 41 29.5 70.5t70.5 29.5zM1100 296h-300v-100h300v100z " />
|
||||
<glyph unicode="" d="M150 1200h900q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-900q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5zM700 500v-300l-200 -200v500l-350 500h900z" />
|
||||
<glyph unicode="" d="M500 1200h200q41 0 70.5 -29.5t29.5 -70.5v-100h300q41 0 70.5 -29.5t29.5 -70.5v-400h-500v100h-200v-100h-500v400q0 41 29.5 70.5t70.5 29.5h300v100q0 41 29.5 70.5t70.5 29.5zM500 1100v-100h200v100h-200zM1200 400v-200q0 -41 -29.5 -70.5t-70.5 -29.5h-1000 q-41 0 -70.5 29.5t-29.5 70.5v200h1200z" />
|
||||
<glyph unicode="" d="M50 1200h300q21 0 25 -10.5t-10 -24.5l-94 -94l199 -199q7 -8 7 -18t-7 -18l-106 -106q-8 -7 -18 -7t-18 7l-199 199l-94 -94q-14 -14 -24.5 -10t-10.5 25v300q0 21 14.5 35.5t35.5 14.5zM850 1200h300q21 0 35.5 -14.5t14.5 -35.5v-300q0 -21 -10.5 -25t-24.5 10l-94 94 l-199 -199q-8 -7 -18 -7t-18 7l-106 106q-7 8 -7 18t7 18l199 199l-94 94q-14 14 -10 24.5t25 10.5zM364 470l106 -106q7 -8 7 -18t-7 -18l-199 -199l94 -94q14 -14 10 -24.5t-25 -10.5h-300q-21 0 -35.5 14.5t-14.5 35.5v300q0 21 10.5 25t24.5 -10l94 -94l199 199 q8 7 18 7t18 -7zM1071 271l94 94q14 14 24.5 10t10.5 -25v-300q0 -21 -14.5 -35.5t-35.5 -14.5h-300q-21 0 -25 10.5t10 24.5l94 94l-199 199q-7 8 -7 18t7 18l106 106q8 7 18 7t18 -7z" />
|
||||
<glyph unicode="" d="M596 1192q121 0 231.5 -47.5t190 -127t127 -190t47.5 -231.5t-47.5 -231.5t-127 -190.5t-190 -127t-231.5 -47t-231.5 47t-190.5 127t-127 190.5t-47 231.5t47 231.5t127 190t190.5 127t231.5 47.5zM596 1010q-112 0 -207.5 -55.5t-151 -151t-55.5 -207.5t55.5 -207.5 t151 -151t207.5 -55.5t207.5 55.5t151 151t55.5 207.5t-55.5 207.5t-151 151t-207.5 55.5zM454.5 905q22.5 0 38.5 -16t16 -38.5t-16 -39t-38.5 -16.5t-38.5 16.5t-16 39t16 38.5t38.5 16zM754.5 905q22.5 0 38.5 -16t16 -38.5t-16 -39t-38 -16.5q-14 0 -29 10l-55 -145 q17 -23 17 -51q0 -36 -25.5 -61.5t-61.5 -25.5t-61.5 25.5t-25.5 61.5q0 32 20.5 56.5t51.5 29.5l122 126l1 1q-9 14 -9 28q0 23 16 39t38.5 16zM345.5 709q22.5 0 38.5 -16t16 -38.5t-16 -38.5t-38.5 -16t-38.5 16t-16 38.5t16 38.5t38.5 16zM854.5 709q22.5 0 38.5 -16 t16 -38.5t-16 -38.5t-38.5 -16t-38.5 16t-16 38.5t16 38.5t38.5 16z" />
|
||||
<glyph unicode="" d="M546 173l469 470q91 91 99 192q7 98 -52 175.5t-154 94.5q-22 4 -47 4q-34 0 -66.5 -10t-56.5 -23t-55.5 -38t-48 -41.5t-48.5 -47.5q-376 -375 -391 -390q-30 -27 -45 -41.5t-37.5 -41t-32 -46.5t-16 -47.5t-1.5 -56.5q9 -62 53.5 -95t99.5 -33q74 0 125 51l548 548 q36 36 20 75q-7 16 -21.5 26t-32.5 10q-26 0 -50 -23q-13 -12 -39 -38l-341 -338q-15 -15 -35.5 -15.5t-34.5 13.5t-14 34.5t14 34.5q327 333 361 367q35 35 67.5 51.5t78.5 16.5q14 0 29 -1q44 -8 74.5 -35.5t43.5 -68.5q14 -47 2 -96.5t-47 -84.5q-12 -11 -32 -32 t-79.5 -81t-114.5 -115t-124.5 -123.5t-123 -119.5t-96.5 -89t-57 -45q-56 -27 -120 -27q-70 0 -129 32t-93 89q-48 78 -35 173t81 163l511 511q71 72 111 96q91 55 198 55q80 0 152 -33q78 -36 129.5 -103t66.5 -154q17 -93 -11 -183.5t-94 -156.5l-482 -476 q-15 -15 -36 -16t-37 14t-17.5 34t14.5 35z" />
|
||||
<glyph unicode="" d="M649 949q48 68 109.5 104t121.5 38.5t118.5 -20t102.5 -64t71 -100.5t27 -123q0 -57 -33.5 -117.5t-94 -124.5t-126.5 -127.5t-150 -152.5t-146 -174q-62 85 -145.5 174t-150 152.5t-126.5 127.5t-93.5 124.5t-33.5 117.5q0 64 28 123t73 100.5t104 64t119 20 t120.5 -38.5t104.5 -104zM896 972q-33 0 -64.5 -19t-56.5 -46t-47.5 -53.5t-43.5 -45.5t-37.5 -19t-36 19t-40 45.5t-43 53.5t-54 46t-65.5 19q-67 0 -122.5 -55.5t-55.5 -132.5q0 -23 13.5 -51t46 -65t57.5 -63t76 -75l22 -22q15 -14 44 -44t50.5 -51t46 -44t41 -35t23 -12 t23.5 12t42.5 36t46 44t52.5 52t44 43q4 4 12 13q43 41 63.5 62t52 55t46 55t26 46t11.5 44q0 79 -53 133.5t-120 54.5z" />
|
||||
<glyph unicode="" d="M776.5 1214q93.5 0 159.5 -66l141 -141q66 -66 66 -160q0 -42 -28 -95.5t-62 -87.5l-29 -29q-31 53 -77 99l-18 18l95 95l-247 248l-389 -389l212 -212l-105 -106l-19 18l-141 141q-66 66 -66 159t66 159l283 283q65 66 158.5 66zM600 706l105 105q10 -8 19 -17l141 -141 q66 -66 66 -159t-66 -159l-283 -283q-66 -66 -159 -66t-159 66l-141 141q-66 66 -66 159.5t66 159.5l55 55q29 -55 75 -102l18 -17l-95 -95l247 -248l389 389z" />
|
||||
<glyph unicode="" d="M603 1200q85 0 162 -15t127 -38t79 -48t29 -46v-953q0 -41 -29.5 -70.5t-70.5 -29.5h-600q-41 0 -70.5 29.5t-29.5 70.5v953q0 21 30 46.5t81 48t129 37.5t163 15zM300 1000v-700h600v700h-600zM600 254q-43 0 -73.5 -30.5t-30.5 -73.5t30.5 -73.5t73.5 -30.5t73.5 30.5 t30.5 73.5t-30.5 73.5t-73.5 30.5z" />
|
||||
<glyph unicode="" d="M902 1185l283 -282q15 -15 15 -36t-14.5 -35.5t-35.5 -14.5t-35 15l-36 35l-279 -267v-300l-212 210l-308 -307l-280 -203l203 280l307 308l-210 212h300l267 279l-35 36q-15 14 -15 35t14.5 35.5t35.5 14.5t35 -15z" />
|
||||
<glyph unicode="" d="M700 1248v-78q38 -5 72.5 -14.5t75.5 -31.5t71 -53.5t52 -84t24 -118.5h-159q-4 36 -10.5 59t-21 45t-40 35.5t-64.5 20.5v-307l64 -13q34 -7 64 -16.5t70 -32t67.5 -52.5t47.5 -80t20 -112q0 -139 -89 -224t-244 -97v-77h-100v79q-150 16 -237 103q-40 40 -52.5 93.5 t-15.5 139.5h139q5 -77 48.5 -126t117.5 -65v335l-27 8q-46 14 -79 26.5t-72 36t-63 52t-40 72.5t-16 98q0 70 25 126t67.5 92t94.5 57t110 27v77h100zM600 754v274q-29 -4 -50 -11t-42 -21.5t-31.5 -41.5t-10.5 -65q0 -29 7 -50.5t16.5 -34t28.5 -22.5t31.5 -14t37.5 -10 q9 -3 13 -4zM700 547v-310q22 2 42.5 6.5t45 15.5t41.5 27t29 42t12 59.5t-12.5 59.5t-38 44.5t-53 31t-66.5 24.5z" />
|
||||
<glyph unicode="" d="M561 1197q84 0 160.5 -40t123.5 -109.5t47 -147.5h-153q0 40 -19.5 71.5t-49.5 48.5t-59.5 26t-55.5 9q-37 0 -79 -14.5t-62 -35.5q-41 -44 -41 -101q0 -26 13.5 -63t26.5 -61t37 -66q6 -9 9 -14h241v-100h-197q8 -50 -2.5 -115t-31.5 -95q-45 -62 -99 -112 q34 10 83 17.5t71 7.5q32 1 102 -16t104 -17q83 0 136 30l50 -147q-31 -19 -58 -30.5t-55 -15.5t-42 -4.5t-46 -0.5q-23 0 -76 17t-111 32.5t-96 11.5q-39 -3 -82 -16t-67 -25l-23 -11l-55 145q4 3 16 11t15.5 10.5t13 9t15.5 12t14.5 14t17.5 18.5q48 55 54 126.5 t-30 142.5h-221v100h166q-23 47 -44 104q-7 20 -12 41.5t-6 55.5t6 66.5t29.5 70.5t58.5 71q97 88 263 88z" />
|
||||
<glyph unicode="" d="M400 300h150q21 0 25 -11t-10 -25l-230 -250q-14 -15 -35 -15t-35 15l-230 250q-14 14 -10 25t25 11h150v900h200v-900zM935 1184l230 -249q14 -14 10 -24.5t-25 -10.5h-150v-900h-200v900h-150q-21 0 -25 10.5t10 24.5l230 249q14 15 35 15t35 -15z" />
|
||||
<glyph unicode="" d="M1000 700h-100v100h-100v-100h-100v500h300v-500zM400 300h150q21 0 25 -11t-10 -25l-230 -250q-14 -15 -35 -15t-35 15l-230 250q-14 14 -10 25t25 11h150v900h200v-900zM801 1100v-200h100v200h-100zM1000 350l-200 -250h200v-100h-300v150l200 250h-200v100h300v-150z " />
|
||||
<glyph unicode="" d="M400 300h150q21 0 25 -11t-10 -25l-230 -250q-14 -15 -35 -15t-35 15l-230 250q-14 14 -10 25t25 11h150v900h200v-900zM1000 1050l-200 -250h200v-100h-300v150l200 250h-200v100h300v-150zM1000 0h-100v100h-100v-100h-100v500h300v-500zM801 400v-200h100v200h-100z " />
|
||||
<glyph unicode="" d="M400 300h150q21 0 25 -11t-10 -25l-230 -250q-14 -15 -35 -15t-35 15l-230 250q-14 14 -10 25t25 11h150v900h200v-900zM1000 700h-100v400h-100v100h200v-500zM1100 0h-100v100h-200v400h300v-500zM901 400v-200h100v200h-100z" />
|
||||
<glyph unicode="" d="M400 300h150q21 0 25 -11t-10 -25l-230 -250q-14 -15 -35 -15t-35 15l-230 250q-14 14 -10 25t25 11h150v900h200v-900zM1100 700h-100v100h-200v400h300v-500zM901 1100v-200h100v200h-100zM1000 0h-100v400h-100v100h200v-500z" />
|
||||
<glyph unicode="" d="M400 300h150q21 0 25 -11t-10 -25l-230 -250q-14 -15 -35 -15t-35 15l-230 250q-14 14 -10 25t25 11h150v900h200v-900zM900 1000h-200v200h200v-200zM1000 700h-300v200h300v-200zM1100 400h-400v200h400v-200zM1200 100h-500v200h500v-200z" />
|
||||
<glyph unicode="" d="M400 300h150q21 0 25 -11t-10 -25l-230 -250q-14 -15 -35 -15t-35 15l-230 250q-14 14 -10 25t25 11h150v900h200v-900zM1200 1000h-500v200h500v-200zM1100 700h-400v200h400v-200zM1000 400h-300v200h300v-200zM900 100h-200v200h200v-200z" />
|
||||
<glyph unicode="" d="M350 1100h400q162 0 256 -93.5t94 -256.5v-400q0 -165 -93.5 -257.5t-256.5 -92.5h-400q-165 0 -257.5 92.5t-92.5 257.5v400q0 165 92.5 257.5t257.5 92.5zM800 900h-500q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5 v500q0 41 -29.5 70.5t-70.5 29.5z" />
|
||||
<glyph unicode="" d="M350 1100h400q165 0 257.5 -92.5t92.5 -257.5v-400q0 -165 -92.5 -257.5t-257.5 -92.5h-400q-163 0 -256.5 92.5t-93.5 257.5v400q0 163 94 256.5t256 93.5zM800 900h-500q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5 v500q0 41 -29.5 70.5t-70.5 29.5zM440 770l253 -190q17 -12 17 -30t-17 -30l-253 -190q-16 -12 -28 -6.5t-12 26.5v400q0 21 12 26.5t28 -6.5z" />
|
||||
<glyph unicode="" d="M350 1100h400q163 0 256.5 -94t93.5 -256v-400q0 -165 -92.5 -257.5t-257.5 -92.5h-400q-165 0 -257.5 92.5t-92.5 257.5v400q0 163 92.5 256.5t257.5 93.5zM800 900h-500q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5 v500q0 41 -29.5 70.5t-70.5 29.5zM350 700h400q21 0 26.5 -12t-6.5 -28l-190 -253q-12 -17 -30 -17t-30 17l-190 253q-12 16 -6.5 28t26.5 12z" />
|
||||
<glyph unicode="" d="M350 1100h400q165 0 257.5 -92.5t92.5 -257.5v-400q0 -163 -92.5 -256.5t-257.5 -93.5h-400q-163 0 -256.5 94t-93.5 256v400q0 165 92.5 257.5t257.5 92.5zM800 900h-500q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5 v500q0 41 -29.5 70.5t-70.5 29.5zM580 693l190 -253q12 -16 6.5 -28t-26.5 -12h-400q-21 0 -26.5 12t6.5 28l190 253q12 17 30 17t30 -17z" />
|
||||
<glyph unicode="" d="M550 1100h400q165 0 257.5 -92.5t92.5 -257.5v-400q0 -165 -92.5 -257.5t-257.5 -92.5h-400q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5h450q41 0 70.5 29.5t29.5 70.5v500q0 41 -29.5 70.5t-70.5 29.5h-450q-21 0 -35.5 14.5t-14.5 35.5v100 q0 21 14.5 35.5t35.5 14.5zM338 867l324 -284q16 -14 16 -33t-16 -33l-324 -284q-16 -14 -27 -9t-11 26v150h-250q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5h250v150q0 21 11 26t27 -9z" />
|
||||
<glyph unicode="" d="M793 1182l9 -9q8 -10 5 -27q-3 -11 -79 -225.5t-78 -221.5l300 1q24 0 32.5 -17.5t-5.5 -35.5q-1 0 -133.5 -155t-267 -312.5t-138.5 -162.5q-12 -15 -26 -15h-9l-9 8q-9 11 -4 32q2 9 42 123.5t79 224.5l39 110h-302q-23 0 -31 19q-10 21 6 41q75 86 209.5 237.5 t228 257t98.5 111.5q9 16 25 16h9z" />
|
||||
<glyph unicode="" d="M350 1100h400q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-450q-41 0 -70.5 -29.5t-29.5 -70.5v-500q0 -41 29.5 -70.5t70.5 -29.5h450q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-165 0 -257.5 92.5t-92.5 257.5v400 q0 165 92.5 257.5t257.5 92.5zM938 867l324 -284q16 -14 16 -33t-16 -33l-324 -284q-16 -14 -27 -9t-11 26v150h-250q-21 0 -35.5 14.5t-14.5 35.5v200q0 21 14.5 35.5t35.5 14.5h250v150q0 21 11 26t27 -9z" />
|
||||
<glyph unicode="" d="M750 1200h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -10.5 -25t-24.5 10l-109 109l-312 -312q-15 -15 -35.5 -15t-35.5 15l-141 141q-15 15 -15 35.5t15 35.5l312 312l-109 109q-14 14 -10 24.5t25 10.5zM456 900h-156q-41 0 -70.5 -29.5t-29.5 -70.5v-500 q0 -41 29.5 -70.5t70.5 -29.5h500q41 0 70.5 29.5t29.5 70.5v148l200 200v-298q0 -165 -93.5 -257.5t-256.5 -92.5h-400q-165 0 -257.5 92.5t-92.5 257.5v400q0 165 92.5 257.5t257.5 92.5h300z" />
|
||||
<glyph unicode="" d="M600 1186q119 0 227.5 -46.5t187 -125t125 -187t46.5 -227.5t-46.5 -227.5t-125 -187t-187 -125t-227.5 -46.5t-227.5 46.5t-187 125t-125 187t-46.5 227.5t46.5 227.5t125 187t187 125t227.5 46.5zM600 1022q-115 0 -212 -56.5t-153.5 -153.5t-56.5 -212t56.5 -212 t153.5 -153.5t212 -56.5t212 56.5t153.5 153.5t56.5 212t-56.5 212t-153.5 153.5t-212 56.5zM600 794q80 0 137 -57t57 -137t-57 -137t-137 -57t-137 57t-57 137t57 137t137 57z" />
|
||||
<glyph unicode="" d="M450 1200h200q21 0 35.5 -14.5t14.5 -35.5v-350h245q20 0 25 -11t-9 -26l-383 -426q-14 -15 -33.5 -15t-32.5 15l-379 426q-13 15 -8.5 26t25.5 11h250v350q0 21 14.5 35.5t35.5 14.5zM50 300h1000q21 0 35.5 -14.5t14.5 -35.5v-250h-1100v250q0 21 14.5 35.5t35.5 14.5z M900 200v-50h100v50h-100z" />
|
||||
<glyph unicode="" d="M583 1182l378 -435q14 -15 9 -31t-26 -16h-244v-250q0 -20 -17 -35t-39 -15h-200q-20 0 -32 14.5t-12 35.5v250h-250q-20 0 -25.5 16.5t8.5 31.5l383 431q14 16 33.5 17t33.5 -14zM50 300h1000q21 0 35.5 -14.5t14.5 -35.5v-250h-1100v250q0 21 14.5 35.5t35.5 14.5z M900 200v-50h100v50h-100z" />
|
||||
<glyph unicode="" d="M396 723l369 369q7 7 17.5 7t17.5 -7l139 -139q7 -8 7 -18.5t-7 -17.5l-525 -525q-7 -8 -17.5 -8t-17.5 8l-292 291q-7 8 -7 18t7 18l139 139q8 7 18.5 7t17.5 -7zM50 300h1000q21 0 35.5 -14.5t14.5 -35.5v-250h-1100v250q0 21 14.5 35.5t35.5 14.5zM900 200v-50h100v50 h-100z" />
|
||||
<glyph unicode="" d="M135 1023l142 142q14 14 35 14t35 -14l77 -77l-212 -212l-77 76q-14 15 -14 36t14 35zM655 855l210 210q14 14 24.5 10t10.5 -25l-2 -599q-1 -20 -15.5 -35t-35.5 -15l-597 -1q-21 0 -25 10.5t10 24.5l208 208l-154 155l212 212zM50 300h1000q21 0 35.5 -14.5t14.5 -35.5 v-250h-1100v250q0 21 14.5 35.5t35.5 14.5zM900 200v-50h100v50h-100z" />
|
||||
<glyph unicode="" d="M350 1200l599 -2q20 -1 35 -15.5t15 -35.5l1 -597q0 -21 -10.5 -25t-24.5 10l-208 208l-155 -154l-212 212l155 154l-210 210q-14 14 -10 24.5t25 10.5zM524 512l-76 -77q-15 -14 -36 -14t-35 14l-142 142q-14 14 -14 35t14 35l77 77zM50 300h1000q21 0 35.5 -14.5 t14.5 -35.5v-250h-1100v250q0 21 14.5 35.5t35.5 14.5zM900 200v-50h100v50h-100z" />
|
||||
<glyph unicode="" d="M1200 103l-483 276l-314 -399v423h-399l1196 796v-1096zM483 424v-230l683 953z" />
|
||||
<glyph unicode="" d="M1100 1000v-850q0 -21 -14.5 -35.5t-35.5 -14.5h-150v400h-700v-400h-150q-21 0 -35.5 14.5t-14.5 35.5v1000q0 20 14.5 35t35.5 15h250v-300h500v300h100zM700 1000h-100v200h100v-200z" />
|
||||
<glyph unicode="" d="M1100 1000l-2 -149l-299 -299l-95 95q-9 9 -21.5 9t-21.5 -9l-149 -147h-312v-400h-150q-21 0 -35.5 14.5t-14.5 35.5v1000q0 20 14.5 35t35.5 15h250v-300h500v300h100zM700 1000h-100v200h100v-200zM1132 638l106 -106q7 -7 7 -17.5t-7 -17.5l-420 -421q-8 -7 -18 -7 t-18 7l-202 203q-8 7 -8 17.5t8 17.5l106 106q7 8 17.5 8t17.5 -8l79 -79l297 297q7 7 17.5 7t17.5 -7z" />
|
||||
<glyph unicode="" d="M1100 1000v-269l-103 -103l-134 134q-15 15 -33.5 16.5t-34.5 -12.5l-266 -266h-329v-400h-150q-21 0 -35.5 14.5t-14.5 35.5v1000q0 20 14.5 35t35.5 15h250v-300h500v300h100zM700 1000h-100v200h100v-200zM1202 572l70 -70q15 -15 15 -35.5t-15 -35.5l-131 -131 l131 -131q15 -15 15 -35.5t-15 -35.5l-70 -70q-15 -15 -35.5 -15t-35.5 15l-131 131l-131 -131q-15 -15 -35.5 -15t-35.5 15l-70 70q-15 15 -15 35.5t15 35.5l131 131l-131 131q-15 15 -15 35.5t15 35.5l70 70q15 15 35.5 15t35.5 -15l131 -131l131 131q15 15 35.5 15 t35.5 -15z" />
|
||||
<glyph unicode="" d="M1100 1000v-300h-350q-21 0 -35.5 -14.5t-14.5 -35.5v-150h-500v-400h-150q-21 0 -35.5 14.5t-14.5 35.5v1000q0 20 14.5 35t35.5 15h250v-300h500v300h100zM700 1000h-100v200h100v-200zM850 600h100q21 0 35.5 -14.5t14.5 -35.5v-250h150q21 0 25 -10.5t-10 -24.5 l-230 -230q-14 -14 -35 -14t-35 14l-230 230q-14 14 -10 24.5t25 10.5h150v250q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M1100 1000v-400l-165 165q-14 15 -35 15t-35 -15l-263 -265h-402v-400h-150q-21 0 -35.5 14.5t-14.5 35.5v1000q0 20 14.5 35t35.5 15h250v-300h500v300h100zM700 1000h-100v200h100v-200zM935 565l230 -229q14 -15 10 -25.5t-25 -10.5h-150v-250q0 -20 -14.5 -35 t-35.5 -15h-100q-21 0 -35.5 15t-14.5 35v250h-150q-21 0 -25 10.5t10 25.5l230 229q14 15 35 15t35 -15z" />
|
||||
<glyph unicode="" d="M50 1100h1100q21 0 35.5 -14.5t14.5 -35.5v-150h-1200v150q0 21 14.5 35.5t35.5 14.5zM1200 800v-550q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5v550h1200zM100 500v-200h400v200h-400z" />
|
||||
<glyph unicode="" d="M935 1165l248 -230q14 -14 14 -35t-14 -35l-248 -230q-14 -14 -24.5 -10t-10.5 25v150h-400v200h400v150q0 21 10.5 25t24.5 -10zM200 800h-50q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5h50v-200zM400 800h-100v200h100v-200zM18 435l247 230 q14 14 24.5 10t10.5 -25v-150h400v-200h-400v-150q0 -21 -10.5 -25t-24.5 10l-247 230q-15 14 -15 35t15 35zM900 300h-100v200h100v-200zM1000 500h51q20 0 34.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-34.5 -14.5h-51v200z" />
|
||||
<glyph unicode="" d="M862 1073l276 116q25 18 43.5 8t18.5 -41v-1106q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v397q-4 1 -11 5t-24 17.5t-30 29t-24 42t-11 56.5v359q0 31 18.5 65t43.5 52zM550 1200q22 0 34.5 -12.5t14.5 -24.5l1 -13v-450q0 -28 -10.5 -59.5 t-25 -56t-29 -45t-25.5 -31.5l-10 -11v-447q0 -21 -14.5 -35.5t-35.5 -14.5h-200q-21 0 -35.5 14.5t-14.5 35.5v447q-4 4 -11 11.5t-24 30.5t-30 46t-24 55t-11 60v450q0 2 0.5 5.5t4 12t8.5 15t14.5 12t22.5 5.5q20 0 32.5 -12.5t14.5 -24.5l3 -13v-350h100v350v5.5t2.5 12 t7 15t15 12t25.5 5.5q23 0 35.5 -12.5t13.5 -24.5l1 -13v-350h100v350q0 2 0.5 5.5t3 12t7 15t15 12t24.5 5.5z" />
|
||||
<glyph unicode="" d="M1200 1100v-56q-4 0 -11 -0.5t-24 -3t-30 -7.5t-24 -15t-11 -24v-888q0 -22 25 -34.5t50 -13.5l25 -2v-56h-400v56q75 0 87.5 6.5t12.5 43.5v394h-500v-394q0 -37 12.5 -43.5t87.5 -6.5v-56h-400v56q4 0 11 0.5t24 3t30 7.5t24 15t11 24v888q0 22 -25 34.5t-50 13.5 l-25 2v56h400v-56q-75 0 -87.5 -6.5t-12.5 -43.5v-394h500v394q0 37 -12.5 43.5t-87.5 6.5v56h400z" />
|
||||
<glyph unicode="" d="M675 1000h375q21 0 35.5 -14.5t14.5 -35.5v-150h-105l-295 -98v98l-200 200h-400l100 100h375zM100 900h300q41 0 70.5 -29.5t29.5 -70.5v-500q0 -41 -29.5 -70.5t-70.5 -29.5h-300q-41 0 -70.5 29.5t-29.5 70.5v500q0 41 29.5 70.5t70.5 29.5zM100 800v-200h300v200 h-300zM1100 535l-400 -133v163l400 133v-163zM100 500v-200h300v200h-300zM1100 398v-248q0 -21 -14.5 -35.5t-35.5 -14.5h-375l-100 -100h-375l-100 100h400l200 200h105z" />
|
||||
<glyph unicode="" d="M17 1007l162 162q17 17 40 14t37 -22l139 -194q14 -20 11 -44.5t-20 -41.5l-119 -118q102 -142 228 -268t267 -227l119 118q17 17 42.5 19t44.5 -12l192 -136q19 -14 22.5 -37.5t-13.5 -40.5l-163 -162q-3 -1 -9.5 -1t-29.5 2t-47.5 6t-62.5 14.5t-77.5 26.5t-90 42.5 t-101.5 60t-111 83t-119 108.5q-74 74 -133.5 150.5t-94.5 138.5t-60 119.5t-34.5 100t-15 74.5t-4.5 48z" />
|
||||
<glyph unicode="" d="M600 1100q92 0 175 -10.5t141.5 -27t108.5 -36.5t81.5 -40t53.5 -37t31 -27l9 -10v-200q0 -21 -14.5 -33t-34.5 -9l-202 34q-20 3 -34.5 20t-14.5 38v146q-141 24 -300 24t-300 -24v-146q0 -21 -14.5 -38t-34.5 -20l-202 -34q-20 -3 -34.5 9t-14.5 33v200q3 4 9.5 10.5 t31 26t54 37.5t80.5 39.5t109 37.5t141 26.5t175 10.5zM600 795q56 0 97 -9.5t60 -23.5t30 -28t12 -24l1 -10v-50l365 -303q14 -15 24.5 -40t10.5 -45v-212q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5v212q0 20 10.5 45t24.5 40l365 303v50 q0 4 1 10.5t12 23t30 29t60 22.5t97 10z" />
|
||||
<glyph unicode="" d="M1100 700l-200 -200h-600l-200 200v500h200v-200h200v200h200v-200h200v200h200v-500zM250 400h700q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-12l137 -100h-950l137 100h-12q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5zM50 100h1100q21 0 35.5 -14.5 t14.5 -35.5v-50h-1200v50q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M700 1100h-100q-41 0 -70.5 -29.5t-29.5 -70.5v-1000h300v1000q0 41 -29.5 70.5t-70.5 29.5zM1100 800h-100q-41 0 -70.5 -29.5t-29.5 -70.5v-700h300v700q0 41 -29.5 70.5t-70.5 29.5zM400 0h-300v400q0 41 29.5 70.5t70.5 29.5h100q41 0 70.5 -29.5t29.5 -70.5v-400z " />
|
||||
<glyph unicode="" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM500 700h-200v-100h200v-300h-300v100h200v100h-200v300h300v-100zM900 700v-300l-100 -100h-200v500h200z M700 700v-300h100v300h-100z" />
|
||||
<glyph unicode="" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM500 300h-100v200h-100v-200h-100v500h100v-200h100v200h100v-500zM900 700v-300l-100 -100h-200v500h200z M700 700v-300h100v300h-100z" />
|
||||
<glyph unicode="" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM500 700h-200v-300h200v-100h-300v500h300v-100zM900 700h-200v-300h200v-100h-300v500h300v-100z" />
|
||||
<glyph unicode="" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM500 400l-300 150l300 150v-300zM900 550l-300 -150v300z" />
|
||||
<glyph unicode="" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM900 300h-700v500h700v-500zM800 700h-130q-38 0 -66.5 -43t-28.5 -108t27 -107t68 -42h130v300zM300 700v-300 h130q41 0 68 42t27 107t-28.5 108t-66.5 43h-130z" />
|
||||
<glyph unicode="" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM500 700h-200v-100h200v-300h-300v100h200v100h-200v300h300v-100zM900 300h-100v400h-100v100h200v-500z M700 300h-100v100h100v-100z" />
|
||||
<glyph unicode="" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM300 700h200v-400h-300v500h100v-100zM900 300h-100v400h-100v100h200v-500zM300 600v-200h100v200h-100z M700 300h-100v100h100v-100z" />
|
||||
<glyph unicode="" d="M200 1100h700q124 0 212 -88t88 -212v-500q0 -124 -88 -212t-212 -88h-700q-124 0 -212 88t-88 212v500q0 124 88 212t212 88zM100 900v-700h900v700h-900zM500 500l-199 -200h-100v50l199 200v150h-200v100h300v-300zM900 300h-100v400h-100v100h200v-500zM701 300h-100 v100h100v-100z" />
|
||||
<glyph unicode="" d="M600 1191q120 0 229.5 -47t188.5 -126t126 -188.5t47 -229.5t-47 -229.5t-126 -188.5t-188.5 -126t-229.5 -47t-229.5 47t-188.5 126t-126 188.5t-47 229.5t47 229.5t126 188.5t188.5 126t229.5 47zM600 1021q-114 0 -211 -56.5t-153.5 -153.5t-56.5 -211t56.5 -211 t153.5 -153.5t211 -56.5t211 56.5t153.5 153.5t56.5 211t-56.5 211t-153.5 153.5t-211 56.5zM800 700h-300v-200h300v-100h-300l-100 100v200l100 100h300v-100z" />
|
||||
<glyph unicode="" d="M600 1191q120 0 229.5 -47t188.5 -126t126 -188.5t47 -229.5t-47 -229.5t-126 -188.5t-188.5 -126t-229.5 -47t-229.5 47t-188.5 126t-126 188.5t-47 229.5t47 229.5t126 188.5t188.5 126t229.5 47zM600 1021q-114 0 -211 -56.5t-153.5 -153.5t-56.5 -211t56.5 -211 t153.5 -153.5t211 -56.5t211 56.5t153.5 153.5t56.5 211t-56.5 211t-153.5 153.5t-211 56.5zM800 700v-100l-50 -50l100 -100v-50h-100l-100 100h-150v-100h-100v400h300zM500 700v-100h200v100h-200z" />
|
||||
<glyph unicode="" d="M503 1089q110 0 200.5 -59.5t134.5 -156.5q44 14 90 14q120 0 205 -86.5t85 -207t-85 -207t-205 -86.5h-128v250q0 21 -14.5 35.5t-35.5 14.5h-300q-21 0 -35.5 -14.5t-14.5 -35.5v-250h-222q-80 0 -136 57.5t-56 136.5q0 69 43 122.5t108 67.5q-2 19 -2 37q0 100 49 185 t134 134t185 49zM525 500h150q10 0 17.5 -7.5t7.5 -17.5v-275h137q21 0 26 -11.5t-8 -27.5l-223 -244q-13 -16 -32 -16t-32 16l-223 244q-13 16 -8 27.5t26 11.5h137v275q0 10 7.5 17.5t17.5 7.5z" />
|
||||
<glyph unicode="" d="M502 1089q110 0 201 -59.5t135 -156.5q43 15 89 15q121 0 206 -86.5t86 -206.5q0 -99 -60 -181t-150 -110l-378 360q-13 16 -31.5 16t-31.5 -16l-381 -365h-9q-79 0 -135.5 57.5t-56.5 136.5q0 69 43 122.5t108 67.5q-2 19 -2 38q0 100 49 184.5t133.5 134t184.5 49.5z M632 467l223 -228q13 -16 8 -27.5t-26 -11.5h-137v-275q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v275h-137q-21 0 -26 11.5t8 27.5q199 204 223 228q19 19 31.5 19t32.5 -19z" />
|
||||
<glyph unicode="" d="M700 100v100h400l-270 300h170l-270 300h170l-300 333l-300 -333h170l-270 -300h170l-270 -300h400v-100h-50q-21 0 -35.5 -14.5t-14.5 -35.5v-50h400v50q0 21 -14.5 35.5t-35.5 14.5h-50z" />
|
||||
<glyph unicode="" d="M600 1179q94 0 167.5 -56.5t99.5 -145.5q89 -6 150.5 -71.5t61.5 -155.5q0 -61 -29.5 -112.5t-79.5 -82.5q9 -29 9 -55q0 -74 -52.5 -126.5t-126.5 -52.5q-55 0 -100 30v-251q21 0 35.5 -14.5t14.5 -35.5v-50h-300v50q0 21 14.5 35.5t35.5 14.5v251q-45 -30 -100 -30 q-74 0 -126.5 52.5t-52.5 126.5q0 18 4 38q-47 21 -75.5 65t-28.5 97q0 74 52.5 126.5t126.5 52.5q5 0 23 -2q0 2 -1 10t-1 13q0 116 81.5 197.5t197.5 81.5z" />
|
||||
<glyph unicode="" d="M1010 1010q111 -111 150.5 -260.5t0 -299t-150.5 -260.5q-83 -83 -191.5 -126.5t-218.5 -43.5t-218.5 43.5t-191.5 126.5q-111 111 -150.5 260.5t0 299t150.5 260.5q83 83 191.5 126.5t218.5 43.5t218.5 -43.5t191.5 -126.5zM476 1065q-4 0 -8 -1q-121 -34 -209.5 -122.5 t-122.5 -209.5q-4 -12 2.5 -23t18.5 -14l36 -9q3 -1 7 -1q23 0 29 22q27 96 98 166q70 71 166 98q11 3 17.5 13.5t3.5 22.5l-9 35q-3 13 -14 19q-7 4 -15 4zM512 920q-4 0 -9 -2q-80 -24 -138.5 -82.5t-82.5 -138.5q-4 -13 2 -24t19 -14l34 -9q4 -1 8 -1q22 0 28 21 q18 58 58.5 98.5t97.5 58.5q12 3 18 13.5t3 21.5l-9 35q-3 12 -14 19q-7 4 -15 4zM719.5 719.5q-49.5 49.5 -119.5 49.5t-119.5 -49.5t-49.5 -119.5t49.5 -119.5t119.5 -49.5t119.5 49.5t49.5 119.5t-49.5 119.5zM855 551q-22 0 -28 -21q-18 -58 -58.5 -98.5t-98.5 -57.5 q-11 -4 -17 -14.5t-3 -21.5l9 -35q3 -12 14 -19q7 -4 15 -4q4 0 9 2q80 24 138.5 82.5t82.5 138.5q4 13 -2.5 24t-18.5 14l-34 9q-4 1 -8 1zM1000 515q-23 0 -29 -22q-27 -96 -98 -166q-70 -71 -166 -98q-11 -3 -17.5 -13.5t-3.5 -22.5l9 -35q3 -13 14 -19q7 -4 15 -4 q4 0 8 1q121 34 209.5 122.5t122.5 209.5q4 12 -2.5 23t-18.5 14l-36 9q-3 1 -7 1z" />
|
||||
<glyph unicode="" d="M700 800h300v-380h-180v200h-340v-200h-380v755q0 10 7.5 17.5t17.5 7.5h575v-400zM1000 900h-200v200zM700 300h162l-212 -212l-212 212h162v200h100v-200zM520 0h-395q-10 0 -17.5 7.5t-7.5 17.5v395zM1000 220v-195q0 -10 -7.5 -17.5t-17.5 -7.5h-195z" />
|
||||
<glyph unicode="" d="M700 800h300v-520l-350 350l-550 -550v1095q0 10 7.5 17.5t17.5 7.5h575v-400zM1000 900h-200v200zM862 200h-162v-200h-100v200h-162l212 212zM480 0h-355q-10 0 -17.5 7.5t-7.5 17.5v55h380v-80zM1000 80v-55q0 -10 -7.5 -17.5t-17.5 -7.5h-155v80h180z" />
|
||||
<glyph unicode="" d="M1162 800h-162v-200h100l100 -100h-300v300h-162l212 212zM200 800h200q27 0 40 -2t29.5 -10.5t23.5 -30t7 -57.5h300v-100h-600l-200 -350v450h100q0 36 7 57.5t23.5 30t29.5 10.5t40 2zM800 400h240l-240 -400h-800l300 500h500v-100z" />
|
||||
<glyph unicode="" d="M650 1100h100q21 0 35.5 -14.5t14.5 -35.5v-50h50q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-300q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5h50v50q0 21 14.5 35.5t35.5 14.5zM1000 850v150q41 0 70.5 -29.5t29.5 -70.5v-800 q0 -41 -29.5 -70.5t-70.5 -29.5h-600q-1 0 -20 4l246 246l-326 326v324q0 41 29.5 70.5t70.5 29.5v-150q0 -62 44 -106t106 -44h300q62 0 106 44t44 106zM412 250l-212 -212v162h-200v100h200v162z" />
|
||||
<glyph unicode="" d="M450 1100h100q21 0 35.5 -14.5t14.5 -35.5v-50h50q21 0 35.5 -14.5t14.5 -35.5v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-300q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5h50v50q0 21 14.5 35.5t35.5 14.5zM800 850v150q41 0 70.5 -29.5t29.5 -70.5v-500 h-200v-300h200q0 -36 -7 -57.5t-23.5 -30t-29.5 -10.5t-40 -2h-600q-41 0 -70.5 29.5t-29.5 70.5v800q0 41 29.5 70.5t70.5 29.5v-150q0 -62 44 -106t106 -44h300q62 0 106 44t44 106zM1212 250l-212 -212v162h-200v100h200v162z" />
|
||||
<glyph unicode="" d="M658 1197l637 -1104q23 -38 7 -65.5t-60 -27.5h-1276q-44 0 -60 27.5t7 65.5l637 1104q22 39 54 39t54 -39zM704 800h-208q-20 0 -32 -14.5t-8 -34.5l58 -302q4 -20 21.5 -34.5t37.5 -14.5h54q20 0 37.5 14.5t21.5 34.5l58 302q4 20 -8 34.5t-32 14.5zM500 300v-100h200 v100h-200z" />
|
||||
<glyph unicode="" d="M425 1100h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5zM425 800h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5 t17.5 7.5zM825 800h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5zM25 500h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v150 q0 10 7.5 17.5t17.5 7.5zM425 500h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5zM825 500h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5 v150q0 10 7.5 17.5t17.5 7.5zM25 200h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5zM425 200h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5 t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5zM825 200h250q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-250q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5z" />
|
||||
<glyph unicode="" d="M700 1200h100v-200h-100v-100h350q62 0 86.5 -39.5t-3.5 -94.5l-66 -132q-41 -83 -81 -134h-772q-40 51 -81 134l-66 132q-28 55 -3.5 94.5t86.5 39.5h350v100h-100v200h100v100h200v-100zM250 400h700q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-12l137 -100 h-950l138 100h-13q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5zM50 100h1100q21 0 35.5 -14.5t14.5 -35.5v-50h-1200v50q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M600 1300q40 0 68.5 -29.5t28.5 -70.5h-194q0 41 28.5 70.5t68.5 29.5zM443 1100h314q18 -37 18 -75q0 -8 -3 -25h328q41 0 44.5 -16.5t-30.5 -38.5l-175 -145h-678l-178 145q-34 22 -29 38.5t46 16.5h328q-3 17 -3 25q0 38 18 75zM250 700h700q21 0 35.5 -14.5 t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-150v-200l275 -200h-950l275 200v200h-150q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5zM50 100h1100q21 0 35.5 -14.5t14.5 -35.5v-50h-1200v50q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M600 1181q75 0 128 -53t53 -128t-53 -128t-128 -53t-128 53t-53 128t53 128t128 53zM602 798h46q34 0 55.5 -28.5t21.5 -86.5q0 -76 39 -183h-324q39 107 39 183q0 58 21.5 86.5t56.5 28.5h45zM250 400h700q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-13 l138 -100h-950l137 100h-12q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5zM50 100h1100q21 0 35.5 -14.5t14.5 -35.5v-50h-1200v50q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M600 1300q47 0 92.5 -53.5t71 -123t25.5 -123.5q0 -78 -55.5 -133.5t-133.5 -55.5t-133.5 55.5t-55.5 133.5q0 62 34 143l144 -143l111 111l-163 163q34 26 63 26zM602 798h46q34 0 55.5 -28.5t21.5 -86.5q0 -76 39 -183h-324q39 107 39 183q0 58 21.5 86.5t56.5 28.5h45 zM250 400h700q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-13l138 -100h-950l137 100h-12q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5zM50 100h1100q21 0 35.5 -14.5t14.5 -35.5v-50h-1200v50q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M600 1200l300 -161v-139h-300q0 -57 18.5 -108t50 -91.5t63 -72t70 -67.5t57.5 -61h-530q-60 83 -90.5 177.5t-30.5 178.5t33 164.5t87.5 139.5t126 96.5t145.5 41.5v-98zM250 400h700q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-13l138 -100h-950l137 100 h-12q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5zM50 100h1100q21 0 35.5 -14.5t14.5 -35.5v-50h-1200v50q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M600 1300q41 0 70.5 -29.5t29.5 -70.5v-78q46 -26 73 -72t27 -100v-50h-400v50q0 54 27 100t73 72v78q0 41 29.5 70.5t70.5 29.5zM400 800h400q54 0 100 -27t72 -73h-172v-100h200v-100h-200v-100h200v-100h-200v-100h200q0 -83 -58.5 -141.5t-141.5 -58.5h-400 q-83 0 -141.5 58.5t-58.5 141.5v400q0 83 58.5 141.5t141.5 58.5z" />
|
||||
<glyph unicode="" d="M150 1100h900q21 0 35.5 -14.5t14.5 -35.5v-500q0 -21 -14.5 -35.5t-35.5 -14.5h-900q-21 0 -35.5 14.5t-14.5 35.5v500q0 21 14.5 35.5t35.5 14.5zM125 400h950q10 0 17.5 -7.5t7.5 -17.5v-50q0 -10 -7.5 -17.5t-17.5 -7.5h-283l224 -224q13 -13 13 -31.5t-13 -32 t-31.5 -13.5t-31.5 13l-88 88h-524l-87 -88q-13 -13 -32 -13t-32 13.5t-13 32t13 31.5l224 224h-289q-10 0 -17.5 7.5t-7.5 17.5v50q0 10 7.5 17.5t17.5 7.5zM541 300l-100 -100h324l-100 100h-124z" />
|
||||
<glyph unicode="" d="M200 1100h800q83 0 141.5 -58.5t58.5 -141.5v-200h-100q0 41 -29.5 70.5t-70.5 29.5h-250q-41 0 -70.5 -29.5t-29.5 -70.5h-100q0 41 -29.5 70.5t-70.5 29.5h-250q-41 0 -70.5 -29.5t-29.5 -70.5h-100v200q0 83 58.5 141.5t141.5 58.5zM100 600h1000q41 0 70.5 -29.5 t29.5 -70.5v-300h-1200v300q0 41 29.5 70.5t70.5 29.5zM300 100v-50q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v50h200zM1100 100v-50q0 -21 -14.5 -35.5t-35.5 -14.5h-100q-21 0 -35.5 14.5t-14.5 35.5v50h200z" />
|
||||
<glyph unicode="" d="M480 1165l682 -683q31 -31 31 -75.5t-31 -75.5l-131 -131h-481l-517 518q-32 31 -32 75.5t32 75.5l295 296q31 31 75.5 31t76.5 -31zM108 794l342 -342l303 304l-341 341zM250 100h800q21 0 35.5 -14.5t14.5 -35.5v-50h-900v50q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M1057 647l-189 506q-8 19 -27.5 33t-40.5 14h-400q-21 0 -40.5 -14t-27.5 -33l-189 -506q-8 -19 1.5 -33t30.5 -14h625v-150q0 -21 14.5 -35.5t35.5 -14.5t35.5 14.5t14.5 35.5v150h125q21 0 30.5 14t1.5 33zM897 0h-595v50q0 21 14.5 35.5t35.5 14.5h50v50 q0 21 14.5 35.5t35.5 14.5h48v300h200v-300h47q21 0 35.5 -14.5t14.5 -35.5v-50h50q21 0 35.5 -14.5t14.5 -35.5v-50z" />
|
||||
<glyph unicode="" d="M900 800h300v-575q0 -10 -7.5 -17.5t-17.5 -7.5h-375v591l-300 300v84q0 10 7.5 17.5t17.5 7.5h375v-400zM1200 900h-200v200zM400 600h300v-575q0 -10 -7.5 -17.5t-17.5 -7.5h-650q-10 0 -17.5 7.5t-7.5 17.5v950q0 10 7.5 17.5t17.5 7.5h375v-400zM700 700h-200v200z " />
|
||||
<glyph unicode="" d="M484 1095h195q75 0 146 -32.5t124 -86t89.5 -122.5t48.5 -142q18 -14 35 -20q31 -10 64.5 6.5t43.5 48.5q10 34 -15 71q-19 27 -9 43q5 8 12.5 11t19 -1t23.5 -16q41 -44 39 -105q-3 -63 -46 -106.5t-104 -43.5h-62q-7 -55 -35 -117t-56 -100l-39 -234q-3 -20 -20 -34.5 t-38 -14.5h-100q-21 0 -33 14.5t-9 34.5l12 70q-49 -14 -91 -14h-195q-24 0 -65 8l-11 -64q-3 -20 -20 -34.5t-38 -14.5h-100q-21 0 -33 14.5t-9 34.5l26 157q-84 74 -128 175l-159 53q-19 7 -33 26t-14 40v50q0 21 14.5 35.5t35.5 14.5h124q11 87 56 166l-111 95 q-16 14 -12.5 23.5t24.5 9.5h203q116 101 250 101zM675 1000h-250q-10 0 -17.5 -7.5t-7.5 -17.5v-50q0 -10 7.5 -17.5t17.5 -7.5h250q10 0 17.5 7.5t7.5 17.5v50q0 10 -7.5 17.5t-17.5 7.5z" />
|
||||
<glyph unicode="" d="M641 900l423 247q19 8 42 2.5t37 -21.5l32 -38q14 -15 12.5 -36t-17.5 -34l-139 -120h-390zM50 1100h106q67 0 103 -17t66 -71l102 -212h823q21 0 35.5 -14.5t14.5 -35.5v-50q0 -21 -14 -40t-33 -26l-737 -132q-23 -4 -40 6t-26 25q-42 67 -100 67h-300q-62 0 -106 44 t-44 106v200q0 62 44 106t106 44zM173 928h-80q-19 0 -28 -14t-9 -35v-56q0 -51 42 -51h134q16 0 21.5 8t5.5 24q0 11 -16 45t-27 51q-18 28 -43 28zM550 727q-32 0 -54.5 -22.5t-22.5 -54.5t22.5 -54.5t54.5 -22.5t54.5 22.5t22.5 54.5t-22.5 54.5t-54.5 22.5zM130 389 l152 130q18 19 34 24t31 -3.5t24.5 -17.5t25.5 -28q28 -35 50.5 -51t48.5 -13l63 5l48 -179q13 -61 -3.5 -97.5t-67.5 -79.5l-80 -69q-47 -40 -109 -35.5t-103 51.5l-130 151q-40 47 -35.5 109.5t51.5 102.5zM380 377l-102 -88q-31 -27 2 -65l37 -43q13 -15 27.5 -19.5 t31.5 6.5l61 53q19 16 14 49q-2 20 -12 56t-17 45q-11 12 -19 14t-23 -8z" />
|
||||
<glyph unicode="" d="M625 1200h150q10 0 17.5 -7.5t7.5 -17.5v-109q79 -33 131 -87.5t53 -128.5q1 -46 -15 -84.5t-39 -61t-46 -38t-39 -21.5l-17 -6q6 0 15 -1.5t35 -9t50 -17.5t53 -30t50 -45t35.5 -64t14.5 -84q0 -59 -11.5 -105.5t-28.5 -76.5t-44 -51t-49.5 -31.5t-54.5 -16t-49.5 -6.5 t-43.5 -1v-75q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v75h-100v-75q0 -10 -7.5 -17.5t-17.5 -7.5h-150q-10 0 -17.5 7.5t-7.5 17.5v75h-175q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5h75v600h-75q-10 0 -17.5 7.5t-7.5 17.5v150 q0 10 7.5 17.5t17.5 7.5h175v75q0 10 7.5 17.5t17.5 7.5h150q10 0 17.5 -7.5t7.5 -17.5v-75h100v75q0 10 7.5 17.5t17.5 7.5zM400 900v-200h263q28 0 48.5 10.5t30 25t15 29t5.5 25.5l1 10q0 4 -0.5 11t-6 24t-15 30t-30 24t-48.5 11h-263zM400 500v-200h363q28 0 48.5 10.5 t30 25t15 29t5.5 25.5l1 10q0 4 -0.5 11t-6 24t-15 30t-30 24t-48.5 11h-363z" />
|
||||
<glyph unicode="" d="M212 1198h780q86 0 147 -61t61 -147v-416q0 -51 -18 -142.5t-36 -157.5l-18 -66q-29 -87 -93.5 -146.5t-146.5 -59.5h-572q-82 0 -147 59t-93 147q-8 28 -20 73t-32 143.5t-20 149.5v416q0 86 61 147t147 61zM600 1045q-70 0 -132.5 -11.5t-105.5 -30.5t-78.5 -41.5 t-57 -45t-36 -41t-20.5 -30.5l-6 -12l156 -243h560l156 243q-2 5 -6 12.5t-20 29.5t-36.5 42t-57 44.5t-79 42t-105 29.5t-132.5 12zM762 703h-157l195 261z" />
|
||||
<glyph unicode="" d="M475 1300h150q103 0 189 -86t86 -189v-500q0 -41 -42 -83t-83 -42h-450q-41 0 -83 42t-42 83v500q0 103 86 189t189 86zM700 300v-225q0 -21 -27 -48t-48 -27h-150q-21 0 -48 27t-27 48v225h300z" />
|
||||
<glyph unicode="" d="M475 1300h96q0 -150 89.5 -239.5t239.5 -89.5v-446q0 -41 -42 -83t-83 -42h-450q-41 0 -83 42t-42 83v500q0 103 86 189t189 86zM700 300v-225q0 -21 -27 -48t-48 -27h-150q-21 0 -48 27t-27 48v225h300z" />
|
||||
<glyph unicode="" d="M1294 767l-638 -283l-378 170l-78 -60v-224l100 -150v-199l-150 148l-150 -149v200l100 150v250q0 4 -0.5 10.5t0 9.5t1 8t3 8t6.5 6l47 40l-147 65l642 283zM1000 380l-350 -166l-350 166v147l350 -165l350 165v-147z" />
|
||||
<glyph unicode="" d="M250 800q62 0 106 -44t44 -106t-44 -106t-106 -44t-106 44t-44 106t44 106t106 44zM650 800q62 0 106 -44t44 -106t-44 -106t-106 -44t-106 44t-44 106t44 106t106 44zM1050 800q62 0 106 -44t44 -106t-44 -106t-106 -44t-106 44t-44 106t44 106t106 44z" />
|
||||
<glyph unicode="" d="M550 1100q62 0 106 -44t44 -106t-44 -106t-106 -44t-106 44t-44 106t44 106t106 44zM550 700q62 0 106 -44t44 -106t-44 -106t-106 -44t-106 44t-44 106t44 106t106 44zM550 300q62 0 106 -44t44 -106t-44 -106t-106 -44t-106 44t-44 106t44 106t106 44z" />
|
||||
<glyph unicode="" d="M125 1100h950q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-950q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5zM125 700h950q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-950q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5 t17.5 7.5zM125 300h950q10 0 17.5 -7.5t7.5 -17.5v-150q0 -10 -7.5 -17.5t-17.5 -7.5h-950q-10 0 -17.5 7.5t-7.5 17.5v150q0 10 7.5 17.5t17.5 7.5z" />
|
||||
<glyph unicode="" d="M350 1200h500q162 0 256 -93.5t94 -256.5v-500q0 -165 -93.5 -257.5t-256.5 -92.5h-500q-165 0 -257.5 92.5t-92.5 257.5v500q0 165 92.5 257.5t257.5 92.5zM900 1000h-600q-41 0 -70.5 -29.5t-29.5 -70.5v-600q0 -41 29.5 -70.5t70.5 -29.5h600q41 0 70.5 29.5 t29.5 70.5v600q0 41 -29.5 70.5t-70.5 29.5zM350 900h500q21 0 35.5 -14.5t14.5 -35.5v-300q0 -21 -14.5 -35.5t-35.5 -14.5h-500q-21 0 -35.5 14.5t-14.5 35.5v300q0 21 14.5 35.5t35.5 14.5zM400 800v-200h400v200h-400z" />
|
||||
<glyph unicode="" d="M150 1100h1000q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-50v-200h50q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-50v-200h50q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5t-35.5 -14.5h-50v-200h50q21 0 35.5 -14.5t14.5 -35.5t-14.5 -35.5 t-35.5 -14.5h-1000q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5h50v200h-50q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5h50v200h-50q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5h50v200h-50q-21 0 -35.5 14.5t-14.5 35.5t14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M650 1187q87 -67 118.5 -156t0 -178t-118.5 -155q-87 66 -118.5 155t0 178t118.5 156zM300 800q124 0 212 -88t88 -212q-124 0 -212 88t-88 212zM1000 800q0 -124 -88 -212t-212 -88q0 124 88 212t212 88zM300 500q124 0 212 -88t88 -212q-124 0 -212 88t-88 212z M1000 500q0 -124 -88 -212t-212 -88q0 124 88 212t212 88zM700 199v-144q0 -21 -14.5 -35.5t-35.5 -14.5t-35.5 14.5t-14.5 35.5v142q40 -4 43 -4q17 0 57 6z" />
|
||||
<glyph unicode="" d="M745 878l69 19q25 6 45 -12l298 -295q11 -11 15 -26.5t-2 -30.5q-5 -14 -18 -23.5t-28 -9.5h-8q1 0 1 -13q0 -29 -2 -56t-8.5 -62t-20 -63t-33 -53t-51 -39t-72.5 -14h-146q-184 0 -184 288q0 24 10 47q-20 4 -62 4t-63 -4q11 -24 11 -47q0 -288 -184 -288h-142 q-48 0 -84.5 21t-56 51t-32 71.5t-16 75t-3.5 68.5q0 13 2 13h-7q-15 0 -27.5 9.5t-18.5 23.5q-6 15 -2 30.5t15 25.5l298 296q20 18 46 11l76 -19q20 -5 30.5 -22.5t5.5 -37.5t-22.5 -31t-37.5 -5l-51 12l-182 -193h891l-182 193l-44 -12q-20 -5 -37.5 6t-22.5 31t6 37.5 t31 22.5z" />
|
||||
<glyph unicode="" d="M1200 900h-50q0 21 -4 37t-9.5 26.5t-18 17.5t-22 11t-28.5 5.5t-31 2t-37 0.5h-200v-850q0 -22 25 -34.5t50 -13.5l25 -2v-100h-400v100q4 0 11 0.5t24 3t30 7t24 15t11 24.5v850h-200q-25 0 -37 -0.5t-31 -2t-28.5 -5.5t-22 -11t-18 -17.5t-9.5 -26.5t-4 -37h-50v300 h1000v-300zM500 450h-25q0 15 -4 24.5t-9 14.5t-17 7.5t-20 3t-25 0.5h-100v-425q0 -11 12.5 -17.5t25.5 -7.5h12v-50h-200v50q50 0 50 25v425h-100q-17 0 -25 -0.5t-20 -3t-17 -7.5t-9 -14.5t-4 -24.5h-25v150h500v-150z" />
|
||||
<glyph unicode="" d="M1000 300v50q-25 0 -55 32q-14 14 -25 31t-16 27l-4 11l-289 747h-69l-300 -754q-18 -35 -39 -56q-9 -9 -24.5 -18.5t-26.5 -14.5l-11 -5v-50h273v50q-49 0 -78.5 21.5t-11.5 67.5l69 176h293l61 -166q13 -34 -3.5 -66.5t-55.5 -32.5v-50h312zM412 691l134 342l121 -342 h-255zM1100 150v-100q0 -21 -14.5 -35.5t-35.5 -14.5h-1000q-21 0 -35.5 14.5t-14.5 35.5v100q0 21 14.5 35.5t35.5 14.5h1000q21 0 35.5 -14.5t14.5 -35.5z" />
|
||||
<glyph unicode="" d="M50 1200h1100q21 0 35.5 -14.5t14.5 -35.5v-1100q0 -21 -14.5 -35.5t-35.5 -14.5h-1100q-21 0 -35.5 14.5t-14.5 35.5v1100q0 21 14.5 35.5t35.5 14.5zM611 1118h-70q-13 0 -18 -12l-299 -753q-17 -32 -35 -51q-18 -18 -56 -34q-12 -5 -12 -18v-50q0 -8 5.5 -14t14.5 -6 h273q8 0 14 6t6 14v50q0 8 -6 14t-14 6q-55 0 -71 23q-10 14 0 39l63 163h266l57 -153q11 -31 -6 -55q-12 -17 -36 -17q-8 0 -14 -6t-6 -14v-50q0 -8 6 -14t14 -6h313q8 0 14 6t6 14v50q0 7 -5.5 13t-13.5 7q-17 0 -42 25q-25 27 -40 63h-1l-288 748q-5 12 -19 12zM639 611 h-197l103 264z" />
|
||||
<glyph unicode="" d="M1200 1100h-1200v100h1200v-100zM50 1000h400q21 0 35.5 -14.5t14.5 -35.5v-900q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v900q0 21 14.5 35.5t35.5 14.5zM650 1000h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400 q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5zM700 900v-300h300v300h-300z" />
|
||||
<glyph unicode="" d="M50 1200h400q21 0 35.5 -14.5t14.5 -35.5v-900q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v900q0 21 14.5 35.5t35.5 14.5zM650 700h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v400 q0 21 14.5 35.5t35.5 14.5zM700 600v-300h300v300h-300zM1200 0h-1200v100h1200v-100z" />
|
||||
<glyph unicode="" d="M50 1000h400q21 0 35.5 -14.5t14.5 -35.5v-350h100v150q0 21 14.5 35.5t35.5 14.5h400q21 0 35.5 -14.5t14.5 -35.5v-150h100v-100h-100v-150q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v150h-100v-350q0 -21 -14.5 -35.5t-35.5 -14.5h-400 q-21 0 -35.5 14.5t-14.5 35.5v800q0 21 14.5 35.5t35.5 14.5zM700 700v-300h300v300h-300z" />
|
||||
<glyph unicode="" d="M100 0h-100v1200h100v-1200zM250 1100h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5zM300 1000v-300h300v300h-300zM250 500h900q21 0 35.5 -14.5t14.5 -35.5v-400 q0 -21 -14.5 -35.5t-35.5 -14.5h-900q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M600 1100h150q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-150v-100h450q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-900q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5h350v100h-150q-21 0 -35.5 14.5 t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5h150v100h100v-100zM400 1000v-300h300v300h-300z" />
|
||||
<glyph unicode="" d="M1200 0h-100v1200h100v-1200zM550 1100h400q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-400q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5zM600 1000v-300h300v300h-300zM50 500h900q21 0 35.5 -14.5t14.5 -35.5v-400 q0 -21 -14.5 -35.5t-35.5 -14.5h-900q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5z" />
|
||||
<glyph unicode="" d="M865 565l-494 -494q-23 -23 -41 -23q-14 0 -22 13.5t-8 38.5v1000q0 25 8 38.5t22 13.5q18 0 41 -23l494 -494q14 -14 14 -35t-14 -35z" />
|
||||
<glyph unicode="" d="M335 635l494 494q29 29 50 20.5t21 -49.5v-1000q0 -41 -21 -49.5t-50 20.5l-494 494q-14 14 -14 35t14 35z" />
|
||||
<glyph unicode="" d="M100 900h1000q41 0 49.5 -21t-20.5 -50l-494 -494q-14 -14 -35 -14t-35 14l-494 494q-29 29 -20.5 50t49.5 21z" />
|
||||
<glyph unicode="" d="M635 865l494 -494q29 -29 20.5 -50t-49.5 -21h-1000q-41 0 -49.5 21t20.5 50l494 494q14 14 35 14t35 -14z" />
|
||||
<glyph unicode="" d="M700 741v-182l-692 -323v221l413 193l-413 193v221zM1200 0h-800v200h800v-200z" />
|
||||
<glyph unicode="" d="M1200 900h-200v-100h200v-100h-300v300h200v100h-200v100h300v-300zM0 700h50q0 21 4 37t9.5 26.5t18 17.5t22 11t28.5 5.5t31 2t37 0.5h100v-550q0 -22 -25 -34.5t-50 -13.5l-25 -2v-100h400v100q-4 0 -11 0.5t-24 3t-30 7t-24 15t-11 24.5v550h100q25 0 37 -0.5t31 -2 t28.5 -5.5t22 -11t18 -17.5t9.5 -26.5t4 -37h50v300h-800v-300z" />
|
||||
<glyph unicode="" d="M800 700h-50q0 21 -4 37t-9.5 26.5t-18 17.5t-22 11t-28.5 5.5t-31 2t-37 0.5h-100v-550q0 -22 25 -34.5t50 -14.5l25 -1v-100h-400v100q4 0 11 0.5t24 3t30 7t24 15t11 24.5v550h-100q-25 0 -37 -0.5t-31 -2t-28.5 -5.5t-22 -11t-18 -17.5t-9.5 -26.5t-4 -37h-50v300 h800v-300zM1100 200h-200v-100h200v-100h-300v300h200v100h-200v100h300v-300z" />
|
||||
<glyph unicode="" d="M701 1098h160q16 0 21 -11t-7 -23l-464 -464l464 -464q12 -12 7 -23t-21 -11h-160q-13 0 -23 9l-471 471q-7 8 -7 18t7 18l471 471q10 9 23 9z" />
|
||||
<glyph unicode="" d="M339 1098h160q13 0 23 -9l471 -471q7 -8 7 -18t-7 -18l-471 -471q-10 -9 -23 -9h-160q-16 0 -21 11t7 23l464 464l-464 464q-12 12 -7 23t21 11z" />
|
||||
<glyph unicode="" d="M1087 882q11 -5 11 -21v-160q0 -13 -9 -23l-471 -471q-8 -7 -18 -7t-18 7l-471 471q-9 10 -9 23v160q0 16 11 21t23 -7l464 -464l464 464q12 12 23 7z" />
|
||||
<glyph unicode="" d="M618 993l471 -471q9 -10 9 -23v-160q0 -16 -11 -21t-23 7l-464 464l-464 -464q-12 -12 -23 -7t-11 21v160q0 13 9 23l471 471q8 7 18 7t18 -7z" />
|
||||
<glyph unicode="" d="M1000 1200q0 -124 -88 -212t-212 -88q0 124 88 212t212 88zM450 1000h100q21 0 40 -14t26 -33l79 -194q5 1 16 3q34 6 54 9.5t60 7t65.5 1t61 -10t56.5 -23t42.5 -42t29 -64t5 -92t-19.5 -121.5q-1 -7 -3 -19.5t-11 -50t-20.5 -73t-32.5 -81.5t-46.5 -83t-64 -70 t-82.5 -50q-13 -5 -42 -5t-65.5 2.5t-47.5 2.5q-14 0 -49.5 -3.5t-63 -3.5t-43.5 7q-57 25 -104.5 78.5t-75 111.5t-46.5 112t-26 90l-7 35q-15 63 -18 115t4.5 88.5t26 64t39.5 43.5t52 25.5t58.5 13t62.5 2t59.5 -4.5t55.5 -8l-147 192q-12 18 -5.5 30t27.5 12z" />
|
||||
<glyph unicode="🔑" d="M250 1200h600q21 0 35.5 -14.5t14.5 -35.5v-400q0 -21 -14.5 -35.5t-35.5 -14.5h-150v-500l-255 -178q-19 -9 -32 -1t-13 29v650h-150q-21 0 -35.5 14.5t-14.5 35.5v400q0 21 14.5 35.5t35.5 14.5zM400 1100v-100h300v100h-300z" />
|
||||
<glyph unicode="🚪" d="M250 1200h750q39 0 69.5 -40.5t30.5 -84.5v-933l-700 -117v950l600 125h-700v-1000h-100v1025q0 23 15.5 49t34.5 26zM500 525v-100l100 20v100z" />
|
||||
</font>
|
||||
</defs></svg>
|
||||
|
After Width: | Height: | Size: 106 KiB |
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,2 @@
|
||||
<?php
|
||||
// Silence is golden.
|
||||
@@ -0,0 +1,2 @@
|
||||
<?php
|
||||
// Silence is golden.
|
||||
2366
wp-content/plugins/secure-downloads/assets/libs/bootstrap/js/bootstrap.js
vendored
Normal file
2366
wp-content/plugins/secure-downloads/assets/libs/bootstrap/js/bootstrap.js
vendored
Normal file
File diff suppressed because it is too large
Load Diff
12
wp-content/plugins/secure-downloads/assets/libs/bootstrap/js/bootstrap.min.js
vendored
Normal file
12
wp-content/plugins/secure-downloads/assets/libs/bootstrap/js/bootstrap.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
@@ -0,0 +1,2 @@
|
||||
<?php
|
||||
// Silence is golden.
|
||||
@@ -0,0 +1,2 @@
|
||||
<?php
|
||||
// Silence is golden.
|
||||
950
wp-content/plugins/secure-downloads/core/admin/api-settings.php
Normal file
950
wp-content/plugins/secure-downloads/core/admin/api-settings.php
Normal file
@@ -0,0 +1,950 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package General Settings API - Saving different options
|
||||
* @category Settings API
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
* @modified 2016-02-24
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
// General Settings API - Saving different options
|
||||
class OPSD_Settings_API_General extends OPSD_Settings_API {
|
||||
|
||||
|
||||
/** Override Settings API Constructor
|
||||
* During creation, system try to load values from DB, if exist.
|
||||
*
|
||||
* @param type $id - of Settings
|
||||
*/
|
||||
public function __construct( $id = '' ){
|
||||
|
||||
$options = array(
|
||||
'db_prefix_option' => '' // 'opsd_'
|
||||
, 'db_saving_type' => 'separate'
|
||||
, 'id' => 'set_gen'
|
||||
);
|
||||
|
||||
$id = empty($id) ? $options['id'] : $id;
|
||||
|
||||
parent::__construct( $id, $options ); // Define ID of Setting page and options
|
||||
|
||||
add_action( 'opsd_after_settings_content', array($this, 'enqueue_js'), 10, 3 );
|
||||
}
|
||||
|
||||
|
||||
/** Init all fields rows for settings page */
|
||||
public function init_settings_fields() {
|
||||
|
||||
$this->fields = array();
|
||||
|
||||
$default_options_values = opsd_get_default_options();
|
||||
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" G e n e r a l " >
|
||||
/*
|
||||
wp_redirect:
|
||||
/wrong-hash
|
||||
/download-expired
|
||||
/ip-not-valied
|
||||
/no-such-product
|
||||
/product-not-exist
|
||||
*/
|
||||
|
||||
// Redirection Path
|
||||
$this->fields['opsd_download_url_path'] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => ''
|
||||
, 'group' => 'general'
|
||||
, 'placeholder' => '/file-download/'
|
||||
, 'css' => 'width:100%;'
|
||||
, 'title' => __('URL Path', 'secure-downloads')
|
||||
, 'description' => '(' . __('Optional' , 'secure-downloads') . ') ' . __('Enter URL path, that will exist in secret URL' , 'secure-downloads')
|
||||
, 'description_tag' => ''
|
||||
|
||||
);
|
||||
|
||||
// Redirection Path
|
||||
$this->fields['opsd_protected_directory_name_level1'] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => ''
|
||||
, 'group' => 'general'
|
||||
, 'placeholder' => 'opsd_XXXXXXXXXX'
|
||||
, 'css' => 'width:100%;'
|
||||
, 'title' => __('Upload Folder', 'secure-downloads')
|
||||
, 'description' => __('Path to upload folder' , 'secure-downloads')
|
||||
, 'description_tag' => ''
|
||||
|
||||
);
|
||||
|
||||
// Secret Key
|
||||
$this->fields['opsd_secret_key'] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => wp_generate_password( 30, false, false )
|
||||
, 'group' => 'general'
|
||||
, 'placeholder' => wp_generate_password( 30, false, false )
|
||||
, 'css' => 'width:100%;'
|
||||
, 'title' => __('Secret Key', 'secure-downloads')
|
||||
, 'description' => __('Enter your secret key. Secure link hash will be generated from it. Please keep it secure.' , 'secure-downloads')
|
||||
, 'description_tag' => ''
|
||||
|
||||
);
|
||||
|
||||
|
||||
// Default Expiration
|
||||
|
||||
$options = array(
|
||||
'+5 minutes' => '5 ' . __('minutes', 'secure-downloads')
|
||||
, '+15 minutes' => '15 ' . __('minutes', 'secure-downloads')
|
||||
, '+30 minutes' => '30 ' . __('minutes', 'secure-downloads')
|
||||
, '+45 minutes' => '45 ' . __('minutes', 'secure-downloads')
|
||||
, '+1 hour' => '1 ' . __('hour', 'secure-downloads')
|
||||
, '+6 hours' => '6 ' . __('hours', 'secure-downloads')
|
||||
, '+12 hours' => '12 ' . __('hours', 'secure-downloads')
|
||||
, '+24 hours' => '24 ' . __('hours', 'secure-downloads')
|
||||
, '+3 days' => '3 ' . __('days', 'secure-downloads')
|
||||
, '+5 days' => '5 ' . __('days', 'secure-downloads')
|
||||
, '+7 days' => '7 ' . __('days', 'secure-downloads')
|
||||
, '+30 days' => '30 ' . __('days', 'secure-downloads')
|
||||
, '+90 days' => '90 ' . __('days', 'secure-downloads')
|
||||
, '+365 days' => '1 ' . __('year', 'secure-downloads')
|
||||
, '0' => __('Never', 'secure-downloads') //FixIn: 1.2.2.2
|
||||
);
|
||||
$this->fields['opsd_defualt_expiration'] = array(
|
||||
'type' => 'select'
|
||||
, 'default' => '+24 hours'
|
||||
//, 'value' => '/css/skins/standard.css' //This will override value loaded from DB
|
||||
, 'title' => __('Default Expiration', 'secure-downloads')
|
||||
, 'description' => __('Select default expiration time of link' , 'secure-downloads')
|
||||
, 'options' => $options
|
||||
, 'group' => 'general'
|
||||
);
|
||||
|
||||
// Default IP Lock
|
||||
$this->fields['opsd_defualt_iplock'] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => ''
|
||||
, 'group' => 'general'
|
||||
, 'placeholder' => '0.0.0.0'
|
||||
, 'css' => 'width:17em;'
|
||||
, 'title' => __('Default IP address loc', 'secure-downloads')
|
||||
, 'description' => __('Enter default IP address for grant access to download file only for specific IP. Or leave empty for having no lock.' , 'secure-downloads')
|
||||
. '<div class="opsd-settings-notice notice-info" style="text-align:left">'
|
||||
. '<strong>'. __('Note', '') . '!</strong> '
|
||||
. __('To specify an IP range for grant access, use configuration like', 'secure-downloads') . ' '
|
||||
. '<br/>' . __('Example', 'secure-downloads') . ' 1: <strong>195.47.89</strong>'
|
||||
. '<br/>' . __('Example', 'secure-downloads') . ' 2: <strong>195.47</strong>'
|
||||
. '<br/>' . __('Example', 'secure-downloads') . ' 3: <strong>195</strong>'
|
||||
. '</div>'
|
||||
|
||||
);
|
||||
|
||||
// </editor-fold>
|
||||
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" E r r o r U R L s " >
|
||||
|
||||
// get_opsd_option( 'opsd_url_wrong_hash' )
|
||||
// get_opsd_option( 'opsd_url_download_expired' )
|
||||
// get_opsd_option( 'opsd_url_ip_not_valied' )
|
||||
// get_opsd_option( 'opsd_url_file_not_exist' )
|
||||
// get_opsd_option( 'opsd_url_error_opening_file' )
|
||||
|
||||
$name_of_field = 'opsd_url_wrong_hash';
|
||||
$this->fields[ $name_of_field . '_prefix' ] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'warning_url'
|
||||
, 'html' => '<tr valign="top" class="opsd_sub_settings_grayed0 opsd_tr_set_gen_' . $name_of_field . ' ">
|
||||
<th scope="row">'
|
||||
. OPSD_Settings_API::label_static( 'set_gen_' . $name_of_field
|
||||
, array( 'title' => __( 'Wrong hash', 'secure-downloads' ), 'label_css' => '' )
|
||||
)
|
||||
. '</th>
|
||||
<td><fieldset>' . '<code style="font-size:14px;">' . site_url() . '</code>'
|
||||
);
|
||||
$this->fields[ $name_of_field ] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => ( isset( $default_options_values[ $name_of_field ] ) ) ? $default_options_values[ $name_of_field ] : ''
|
||||
, 'placeholder' => '/error-download'
|
||||
, 'css' => 'width:75%'
|
||||
, 'group' => 'warning_url'
|
||||
, 'only_field' => true
|
||||
);
|
||||
$this->fields[ $name_of_field . '_sufix' ] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'warning_url'
|
||||
, 'html' => '<p class="description" style="line-height: 1.7em;margin: 0;">'
|
||||
. __( 'Type URL of page with warning about wrong hash in link', 'secure-downloads' )
|
||||
. '</p>
|
||||
</fieldset>
|
||||
</td>
|
||||
</tr>'
|
||||
);
|
||||
|
||||
$name_of_field = 'opsd_url_download_expired';
|
||||
$this->fields[ $name_of_field . '_prefix' ] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'warning_url'
|
||||
, 'html' => '<tr valign="top" class="opsd_sub_settings_grayed0 opsd_tr_set_gen_' . $name_of_field . ' ">
|
||||
<th scope="row">'
|
||||
. OPSD_Settings_API::label_static( 'set_gen_' . $name_of_field
|
||||
, array( 'title' => __( 'Link Expired', 'secure-downloads' ), 'label_css' => '' )
|
||||
)
|
||||
. '</th>
|
||||
<td><fieldset>' . '<code style="font-size:14px;">' . site_url() . '</code>'
|
||||
);
|
||||
$this->fields[ $name_of_field ] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => ( isset( $default_options_values[ $name_of_field ] ) ) ? $default_options_values[ $name_of_field ] : ''
|
||||
, 'placeholder' => '/download-expired'
|
||||
, 'css' => 'width:75%'
|
||||
, 'group' => 'warning_url'
|
||||
, 'only_field' => true
|
||||
);
|
||||
$this->fields[ $name_of_field . '_sufix' ] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'warning_url'
|
||||
, 'html' => '<p class="description" style="line-height: 1.7em;margin: 0;">'
|
||||
. __( 'Type URL of page with warning about expiration of download link', 'secure-downloads' )
|
||||
. '</p>
|
||||
</fieldset>
|
||||
</td>
|
||||
</tr>'
|
||||
);
|
||||
|
||||
$name_of_field = 'opsd_url_ip_not_valied';
|
||||
$this->fields[ $name_of_field . '_prefix' ] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'warning_url'
|
||||
, 'html' => '<tr valign="top" class="opsd_sub_settings_grayed0 opsd_tr_set_gen_' . $name_of_field . ' ">
|
||||
<th scope="row">'
|
||||
. OPSD_Settings_API::label_static( 'set_gen_' . $name_of_field
|
||||
, array( 'title' => __( 'IP Not Valid', 'secure-downloads' ), 'label_css' => '' )
|
||||
)
|
||||
. '</th>
|
||||
<td><fieldset>' . '<code style="font-size:14px;">' . site_url() . '</code>'
|
||||
);
|
||||
$this->fields[ $name_of_field ] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => ( isset( $default_options_values[ $name_of_field ] ) ) ? $default_options_values[ $name_of_field ] : ''
|
||||
, 'placeholder' => '/error-download'
|
||||
, 'css' => 'width:75%'
|
||||
, 'group' => 'warning_url'
|
||||
, 'only_field' => true
|
||||
);
|
||||
$this->fields[ $name_of_field . '_sufix' ] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'warning_url'
|
||||
, 'html' => '<p class="description" style="line-height: 1.7em;margin: 0;">'
|
||||
. __( 'Type URL of page with warning about not valid IP for downloading', 'secure-downloads' )
|
||||
. '</p>
|
||||
</fieldset>
|
||||
</td>
|
||||
</tr>'
|
||||
);
|
||||
|
||||
$name_of_field = 'opsd_url_file_not_exist';
|
||||
$this->fields[ $name_of_field . '_prefix' ] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'warning_url'
|
||||
, 'html' => '<tr valign="top" class="opsd_sub_settings_grayed0 opsd_tr_set_gen_' . $name_of_field . ' ">
|
||||
<th scope="row">'
|
||||
. OPSD_Settings_API::label_static( 'set_gen_' . $name_of_field
|
||||
, array( 'title' => __( 'File not exist', 'secure-downloads' ), 'label_css' => '' )
|
||||
)
|
||||
. '</th>
|
||||
<td><fieldset>' . '<code style="font-size:14px;">' . site_url() . '</code>'
|
||||
);
|
||||
$this->fields[ $name_of_field ] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => ( isset( $default_options_values[ $name_of_field ] ) ) ? $default_options_values[ $name_of_field ] : ''
|
||||
, 'placeholder' => '/error-download'
|
||||
, 'css' => 'width:75%'
|
||||
, 'group' => 'warning_url'
|
||||
, 'only_field' => true
|
||||
);
|
||||
$this->fields[ $name_of_field . '_sufix' ] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'warning_url'
|
||||
, 'html' => '<p class="description" style="line-height: 1.7em;margin: 0;">'
|
||||
. __( 'Type URL of page with warning that requested file not exist', 'secure-downloads' )
|
||||
. '</p>
|
||||
</fieldset>
|
||||
</td>
|
||||
</tr>'
|
||||
);
|
||||
|
||||
$name_of_field = 'opsd_url_error_opening_file';
|
||||
$this->fields[ $name_of_field . '_prefix' ] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'warning_url'
|
||||
, 'html' => '<tr valign="top" class="opsd_sub_settings_grayed0 opsd_tr_set_gen_' . $name_of_field . ' ">
|
||||
<th scope="row">'
|
||||
. OPSD_Settings_API::label_static( 'set_gen_' . $name_of_field
|
||||
, array( 'title' => __( 'Error File Opening', 'secure-downloads' ), 'label_css' => '' )
|
||||
)
|
||||
. '</th>
|
||||
<td><fieldset>' . '<code style="font-size:14px;">' . site_url() . '</code>'
|
||||
);
|
||||
$this->fields[ $name_of_field ] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => ( isset( $default_options_values[ $name_of_field ] ) ) ? $default_options_values[ $name_of_field ] : ''
|
||||
, 'placeholder' => '/error-download'
|
||||
, 'css' => 'width:75%'
|
||||
, 'group' => 'warning_url'
|
||||
, 'only_field' => true
|
||||
);
|
||||
$this->fields[ $name_of_field . '_sufix' ] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'warning_url'
|
||||
, 'html' => '<p class="description" style="line-height: 1.7em;margin: 0;">'
|
||||
. __( 'Type URL of page with warning about error of file opening', 'secure-downloads' )
|
||||
. '</p>
|
||||
</fieldset>
|
||||
</td>
|
||||
</tr>'
|
||||
);
|
||||
|
||||
|
||||
|
||||
// </editor-fold>
|
||||
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" Miscellaneous " >
|
||||
|
||||
|
||||
|
||||
|
||||
// CSV Separator ////////////////////////////////////////////////////////
|
||||
$field_options = array(
|
||||
',' => ', - ' . __( 'comma', 'secure-downloads' )
|
||||
, ';' => '; - ' . __( 'semicolon', 'secure-downloads' )
|
||||
, '|' => '| - ' . __( 'vertical bar', 'secure-downloads' )
|
||||
, '^' => '^ - ' . __( 'caret', 'secure-downloads' )
|
||||
);
|
||||
$this->fields['opsd_csv_separator'] = array(
|
||||
'type' => 'select'
|
||||
, 'default' => $default_options_values['opsd_csv_separator'] //';'
|
||||
, 'title' => __('CSV field separator', 'secure-downloads')
|
||||
, 'description' => sprintf(__('Select CSV separator of data field.' ,'secure-downloads'),'<b>','</b>')
|
||||
, 'options' => $field_options
|
||||
, 'group' => 'opsd_listing'
|
||||
);
|
||||
// Divider ///////////////////////////////////////////////////////////////
|
||||
$this->fields['hr_opsd_csv_separator_separator'] = array( 'type' => 'hr', 'group' => 'opsd_listing' );
|
||||
|
||||
|
||||
// Dates Format ////////////////////////////////////////////////////////
|
||||
$this->fields['opsd_date_format_html_prefix'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'opsd_listing'
|
||||
, 'html' => '<tr valign="top" class="opsd_tr_set_gen_opsd_date_format">
|
||||
<th scope="row">'.
|
||||
OPSD_Settings_API::label_static( 'set_gen_opsd_date_format'
|
||||
, array( 'title'=> __('Date Format' , 'secure-downloads'), 'label_css' => 'margin: 0.25em 0 !important;vertical-align: middle;' ) )
|
||||
.'</th>
|
||||
<td><fieldset>'
|
||||
);
|
||||
$field_options = array();
|
||||
foreach ( array( __('F j, Y'), 'Y/m/d', 'm/d/Y', 'd/m/Y' ) as $format ) {
|
||||
$field_options[ esc_attr($format) ] = array( 'title' => date_i18n( $format ) );
|
||||
}
|
||||
$field_options['custom'] = array( 'title' => __('Custom' , 'secure-downloads') . ':', 'attr' => array( 'id' => 'date_format_selection_custom' ) );
|
||||
|
||||
$this->fields['opsd_date_format_selection'] = array(
|
||||
'type' => 'radio'
|
||||
, 'default' => get_option('date_format')
|
||||
, 'options' => $field_options
|
||||
, 'group' => 'opsd_listing'
|
||||
, 'only_field' => true
|
||||
);
|
||||
|
||||
$opsd_date_format = get_opsd_option( 'opsd_date_format');
|
||||
$this->fields['opsd_date_format'] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => $default_options_values['opsd_date_format'] //get_option('date_format')
|
||||
, 'value' => htmlentities( $opsd_date_format ) // Display value of this field in specific way
|
||||
, 'group' => 'opsd_listing'
|
||||
, 'placeholder' => get_option('date_format')
|
||||
, 'css' => 'width:10em;'
|
||||
, 'only_field' => true
|
||||
);
|
||||
|
||||
$this->fields['opsd_date_format_html_sufix'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'opsd_listing'
|
||||
, 'html' => ' <span class="description"><code>' . date_i18n( $opsd_date_format ) . '</code></span>'
|
||||
. '<p class="description">'
|
||||
. sprintf(__('Type your date format for emails and the item table. %sDocumentation on date formatting%s' , 'secure-downloads'),'<br/><a href="http://codex.wordpress.org/Formatting_Date_and_Time" target="_blank">','</a>')
|
||||
. ' </p>
|
||||
</fieldset>
|
||||
</td>
|
||||
</tr>'
|
||||
);
|
||||
|
||||
// Time Format
|
||||
// $this->fields = apply_filters( 'opsd_settings_opsd_time_format', $this->fields, $default_options_values );
|
||||
|
||||
// Time Format /////////////////////////////////////////////////////////////
|
||||
$this->fields['opsd_time_format_html_prefix'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'opsd_listing'
|
||||
, 'html' => '<tr valign="top" class="wpbc_tr_set_gen_opsd_time_format">
|
||||
<th scope="row">'.
|
||||
OPSD_Settings_API::label_static( 'set_gen_opsd_time_format'
|
||||
, array( 'title'=> __('Time Format' ,'secure-downloads'), 'label_css' => 'margin: 0.25em 0 !important;vertical-align: middle;' ) )
|
||||
.'</th>
|
||||
<td><fieldset>'
|
||||
);
|
||||
$field_options = array();
|
||||
foreach ( array( 'g:i a', 'g:i A', 'H:i' ) as $format ) {
|
||||
$field_options[ esc_attr($format) ] = array( 'title' => date_i18n( $format ) );
|
||||
}
|
||||
$field_options['custom'] = array( 'title' => __('Custom' ,'secure-downloads') . ':', 'attr' => array( 'id' => 'time_format_selection_custom' ) );
|
||||
|
||||
$this->fields['opsd_time_format_selection'] = array(
|
||||
'type' => 'radio'
|
||||
, 'default' => 'H:i'
|
||||
, 'options' => $field_options
|
||||
, 'group' => 'opsd_listing'
|
||||
, 'only_field' => true
|
||||
);
|
||||
|
||||
$opsd_time_format = get_opsd_option( 'opsd_time_format');
|
||||
$this->fields['opsd_time_format'] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => $default_options_values['opsd_time_format'] //'H:i'
|
||||
, 'value' => htmlentities( $opsd_time_format ) // Display value of this field in specific way
|
||||
, 'group' => 'opsd_listing'
|
||||
, 'placeholder' => 'H:i'
|
||||
, 'css' => 'width:5em;'
|
||||
, 'only_field' => true
|
||||
);
|
||||
|
||||
$this->fields['opsd_time_format_html_sufix'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'opsd_listing'
|
||||
, 'html' => ' <span class="description"><code>' . date_i18n( $opsd_time_format ) . '</code></span>'
|
||||
. '<p class="description">'
|
||||
. sprintf(__('Type your time format for emails and the opsd table. %sDocumentation on time formatting%s' ,'secure-downloads'),'<br/><a href="http://php.net/manual/en/function.date.php" target="_blank">','</a>')
|
||||
. ' </p>
|
||||
</fieldset>
|
||||
</td>
|
||||
</tr>'
|
||||
);
|
||||
|
||||
// </editor-fold>
|
||||
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" Advanced " >
|
||||
|
||||
|
||||
//Show | Hide links for Advanced JavaScript section
|
||||
$this->fields['opsd_advanced_js_loading_settings'] = array(
|
||||
'type' => 'html'
|
||||
, 'html' =>
|
||||
'<a id="opsd_show_advanced_section_link_show" class="opsd_expand_section_link" href="javascript:void(0)">+ ' . __('Show advanced settings of JavaScript loading' , 'secure-downloads') . '</a>'
|
||||
. '<a id="opsd_show_advanced_section_link_hide" class="opsd_expand_section_link" href="javascript:void(0)" style="display:none;">- ' . __('Hide advanced settings of JavaScript loading' , 'secure-downloads') . '</a>'
|
||||
, 'cols' => 2
|
||||
, 'group' => 'advanced'
|
||||
);
|
||||
/*
|
||||
$this->fields['opsd_is_not_load_bs_script_in_client'] = array(
|
||||
'type' => 'checkbox'
|
||||
, 'default' => $default_options_values['opsd_is_not_load_bs_script_in_client'] //'Off'
|
||||
, 'title' => __('Disable Bootstrap loading on Front-End' , 'secure-downloads')
|
||||
, 'label' => __(' If your theme or some other plugin is load the BootStrap JavaScripts, you can disable loading of this script by this plugin.' , 'secure-downloads')
|
||||
, 'description' => ''
|
||||
, 'group' => 'advanced'
|
||||
, 'tr_class' => 'opsd_advanced_js_loading_settings opsd_sub_settings_grayed hidden_items'
|
||||
);
|
||||
*/
|
||||
$this->fields['opsd_is_not_load_bs_script_in_admin'] = array(
|
||||
'type' => 'checkbox'
|
||||
, 'default' => $default_options_values['opsd_is_not_load_bs_script_in_admin'] //'Off'
|
||||
, 'title' => __('Disable Bootstrap loading on Back-End' , 'secure-downloads')
|
||||
, 'label' => __(' If your theme or some other plugin is load the BootStrap JavaScripts, you can disable loading of this script by this plugin.' , 'secure-downloads')
|
||||
, 'description' => ''
|
||||
, 'group' => 'advanced'
|
||||
, 'tr_class' => 'opsd_advanced_js_loading_settings opsd_sub_settings_grayed hidden_items'
|
||||
);
|
||||
/*
|
||||
$this->fields['hr_calendar_before_is_load_js_css_on_specific_pages'] = array( 'type' => 'hr', 'group' => 'advanced', 'tr_class' => 'opsd_advanced_js_loading_settings opsd_sub_settings_grayed hidden_items' );
|
||||
$this->fields['opsd_is_load_js_css_on_specific_pages'] = array(
|
||||
'type' => 'checkbox'
|
||||
, 'default' => $default_options_values['opsd_is_load_js_css_on_specific_pages'] //'Off'
|
||||
, 'title' => __('Load JS and CSS files only on specific pages' , 'secure-downloads')
|
||||
, 'label' => __('Activate loading of CSS and JavaScript files of plugin only at specific pages.' , 'secure-downloads')
|
||||
, 'description' => ''
|
||||
, 'group' => 'advanced'
|
||||
, 'tr_class' => 'opsd_advanced_js_loading_settings opsd_sub_settings_grayed hidden_items'
|
||||
, 'is_demo_safe' => opsd_is_this_demo()
|
||||
);
|
||||
$this->fields['opsd_pages_for_load_js_css'] = array(
|
||||
'type' => 'textarea'
|
||||
, 'default' => $default_options_values['opsd_pages_for_load_js_css'] //''
|
||||
, 'placeholder' => '/opsd-form/'
|
||||
, 'title' => __('Relative URLs of pages, where to load plugin CSS and JS files' , 'secure-downloads')
|
||||
, 'description' => sprintf(__('Enter relative URLs of pages, where you have Secure Downloads elements (item forms or availability calendars). Please enter one URL per line. Example: %s' , 'secure-downloads'),'<code>/opsd-form/</code>')
|
||||
,'description_tag' => 'p'
|
||||
, 'css' => 'width:100%'
|
||||
, 'rows' => 5
|
||||
, 'group' => 'advanced'
|
||||
, 'tr_class' => 'opsd_advanced_js_loading_settings opsd_is_load_js_css_on_specific_pages opsd_sub_settings_grayed hidden_items'
|
||||
, 'is_demo_safe' => opsd_is_this_demo()
|
||||
);
|
||||
*/
|
||||
if ( opsd_is_this_demo() )
|
||||
$this->fields['opsd_pages_for_load_js_css_demo'] = array( 'group' => 'advanced', 'type' => 'html', 'html' => opsd_get_warning_text_in_demo_mode(), 'cols' => 2 , 'tr_class' => 'opsd_advanced_js_loading_settings opsd_sub_settings_grayed hidden_items' );
|
||||
|
||||
|
||||
/*
|
||||
// Show settings of powered by notice
|
||||
$this->fields['opsd_advanced_powered_by_notice_settings'] = array(
|
||||
'type' => 'html'
|
||||
, 'html' =>
|
||||
'<a id="opsd_powered_by_link_show" class="opsd_expand_section_link" href="javascript:void(0)">+ ' . __('Show settings of powered by notice' , 'secure-downloads') . '</a>'
|
||||
. '<a id="opsd_powered_by_link_hide" class="opsd_expand_section_link" href="javascript:void(0)" style="display:none;">- ' . __('Hide settings of powered by notice' , 'secure-downloads') . '</a>'
|
||||
, 'cols' => 2
|
||||
, 'group' => 'advanced'
|
||||
);
|
||||
|
||||
$this->fields['opsd_is_show_powered_by_notice'] = array(
|
||||
'type' => 'checkbox'
|
||||
, 'default' => $default_options_values['opsd_is_show_powered_by_notice'] //'On'
|
||||
, 'title' => __('Powered by notice' , 'secure-downloads')
|
||||
, 'label' => sprintf(__(' Turn On/Off powered by "Item Calendar" notice under the calendar.' , 'secure-downloads'),'oplugins.com')
|
||||
, 'description' => ''
|
||||
, 'group' => 'advanced'
|
||||
, 'tr_class' => 'opsd_is_show_powered_by_notice opsd_sub_settings_grayed hidden_items'
|
||||
);
|
||||
|
||||
|
||||
$this->fields['opsd_opsd_copyright_adminpanel'] = array(
|
||||
'type' => 'checkbox'
|
||||
, 'default' => $default_options_values['opsd_opsd_copyright_adminpanel'] //'On'
|
||||
, 'title' => __('Help and info notices' , 'secure-downloads')
|
||||
, 'label' => sprintf(__(' Turn On/Off version notice and help link to rate plugin at admin panel.' , 'secure-downloads'),'oplugins.com')
|
||||
, 'description' => ''
|
||||
, 'group' => 'advanced'
|
||||
, 'tr_class' => 'opsd_is_show_powered_by_notice opsd_sub_settings_grayed hidden_items'
|
||||
);
|
||||
*/
|
||||
if ( ( ! opsd_is_this_demo() ) && ( current_user_can( 'activate_plugins' ) ) ) {
|
||||
|
||||
|
||||
$this->fields['help_plugin_system_info'] = array(
|
||||
'type' => 'help'
|
||||
, 'value' => array() //opsd_get_help_rows_about_config_in_several_languges() //FixIn: 1.1.3
|
||||
, 'class' => ''
|
||||
, 'css' => 'margin:0;padding:0;border:0;'
|
||||
, 'description' => ''
|
||||
, 'cols' => 2
|
||||
, 'group' => 'advanced'
|
||||
, 'tr_class' => ''
|
||||
, 'description_tag' => 'p'
|
||||
);
|
||||
|
||||
$this->fields['help_plugin_system_info']['value'][] =
|
||||
'<div class="clear"></div><hr/><center><a class="button button" href="'
|
||||
. opsd_get_settings_url()
|
||||
. '&system_info=show#opsd_general_settings_system_info_metabox">'
|
||||
. __('Plugin System Info' , 'secure-downloads')
|
||||
. '</a></center>';
|
||||
}
|
||||
|
||||
// </editor-fold>
|
||||
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" Information " >
|
||||
if ( function_exists( 'opsd_get_dashboard_info' ) ) {
|
||||
$this->fields['opsd_information'] = array(
|
||||
'type' => 'html'
|
||||
, 'html' => opsd_get_dashboard_info()
|
||||
, 'cols' => 2
|
||||
, 'group' => 'information'
|
||||
);
|
||||
}
|
||||
// </editor-fold>
|
||||
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" User permissions for plugin menu pages " >
|
||||
|
||||
|
||||
$this->fields['opsd_menu_position'] = array(
|
||||
'type' => 'select'
|
||||
, 'default' => 'top'
|
||||
, 'title' => __('Plugin menu position', 'secure-downloads')
|
||||
, 'description' => ''
|
||||
, 'options' => array(
|
||||
'top' => __('Top', 'secure-downloads')
|
||||
, 'middle' => __('Middle', 'secure-downloads')
|
||||
, 'bottom' => __('Bottom', 'secure-downloads')
|
||||
)
|
||||
, 'group' => 'permissions'
|
||||
, 'is_demo_safe' => opsd_is_this_demo()
|
||||
);
|
||||
|
||||
$this->fields['opsd_user_role_opsd_header'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'permissions'
|
||||
, 'html' => '<tr valign="top">
|
||||
<th scope="row" colspan="2">
|
||||
<hr/><p><strong>' . wp_kses_post( __('User permissions for plugin menu pages' , 'secure-downloads') ) . ':</strong></p>
|
||||
</th>
|
||||
</tr'
|
||||
);
|
||||
|
||||
$field_options = array();
|
||||
$field_options['subscriber'] = translate_user_role('Subscriber');
|
||||
$field_options['contributor'] = translate_user_role('Contributor');
|
||||
$field_options['author'] = translate_user_role('Author');
|
||||
$field_options['editor'] = translate_user_role('Editor');
|
||||
$field_options['administrator'] = translate_user_role('Administrator');
|
||||
|
||||
$this->fields['opsd_user_role_master'] = array(
|
||||
'type' => 'select'
|
||||
, 'default' => $default_options_values['opsd_user_role_master'] //'editor'
|
||||
, 'title' => __('Secure Links', 'secure-downloads')
|
||||
, 'description' => ''
|
||||
, 'options' => $field_options
|
||||
, 'group' => 'permissions'
|
||||
, 'is_demo_safe' => opsd_is_this_demo()
|
||||
);
|
||||
$this->fields['opsd_user_role_addnew'] = array(
|
||||
'type' => 'select'
|
||||
, 'default' => $default_options_values['opsd_user_role_addnew'] //'editor'
|
||||
, 'title' => __('Files', 'secure-downloads')
|
||||
, 'description' => ''
|
||||
, 'options' => $field_options
|
||||
, 'group' => 'permissions'
|
||||
, 'is_demo_safe' => opsd_is_this_demo()
|
||||
);
|
||||
$this->fields['opsd_user_role_settings'] = array(
|
||||
'type' => 'select'
|
||||
, 'default' => $default_options_values['opsd_user_role_settings'] //'administrator'
|
||||
, 'title' => __('Settings', 'secure-downloads')
|
||||
, 'description' => __('Select user access level for the menu pages of plugin' , 'secure-downloads')
|
||||
, 'description_tag' => 'p'
|
||||
, 'options' => $field_options
|
||||
, 'group' => 'permissions'
|
||||
, 'is_demo_safe' => opsd_is_this_demo()
|
||||
);
|
||||
|
||||
if ( opsd_is_this_demo() )
|
||||
$this->fields['opsd_user_role_settings_demo'] = array( 'group' => 'permissions', 'type' => 'html', 'html' => opsd_get_warning_text_in_demo_mode(), 'cols' => 2 );
|
||||
|
||||
|
||||
// </editor-fold>
|
||||
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" Uninstall " >
|
||||
$this->fields['opsd_is_delete_if_deactive'] = array(
|
||||
'type' => 'checkbox'
|
||||
, 'default' => $default_options_values['opsd_is_delete_if_deactive'] //'Off'
|
||||
, 'title' => __('Delete plugin settings, when plugin deactivated' , 'secure-downloads')
|
||||
, 'label' => __('Check this box to delete plugin settings options, when you uninstal this plugin.' , 'secure-downloads')
|
||||
, 'description' => ''
|
||||
, 'group' => 'uninstall'
|
||||
);
|
||||
// </editor-fold>
|
||||
|
||||
|
||||
//debuge($this->fields);die;
|
||||
}
|
||||
|
||||
|
||||
/** Add Custon JavaScript - for some specific settings options
|
||||
* Need to executes after showing of entire settings page (on hook: opsd_after_settings_content).
|
||||
* After initial definition of settings, and possible definition after POST request.
|
||||
*
|
||||
* @param type $menu_slug
|
||||
*
|
||||
*/
|
||||
public function enqueue_js( $menu_slug, $active_page_tab, $active_page_subtab ) {
|
||||
|
||||
$js_script = '';
|
||||
|
||||
// Hide Legend items
|
||||
$js_script .= "
|
||||
if ( ! jQuery('#set_gen_opsd_is_show_legend').is(':checked') ) {
|
||||
jQuery('.opsd_calendar_legend_items').addClass('hidden_items');
|
||||
}
|
||||
";
|
||||
// Hide or Show Legend items on click checkbox
|
||||
$js_script .= " jQuery('#set_gen_opsd_is_show_legend').on( 'change', function(){
|
||||
if ( this.checked ) {
|
||||
jQuery('.opsd_calendar_legend_items').removeClass('hidden_items');
|
||||
} else {
|
||||
jQuery('.opsd_calendar_legend_items').addClass('hidden_items');
|
||||
}
|
||||
} ); ";
|
||||
// Thank you Message or Page
|
||||
$js_script .= "
|
||||
if ( jQuery('#type_of_thank_you_message_message').is(':checked') ) {
|
||||
jQuery('.opsd_calendar_thank_you_page').addClass('hidden_items');
|
||||
}
|
||||
if ( jQuery('#type_of_thank_you_message_page').is(':checked') ) {
|
||||
jQuery('.opsd_calendar_thank_you_message').addClass('hidden_items');
|
||||
}
|
||||
";
|
||||
$js_script .= " jQuery('input[name=\"set_gen_opsd_type_of_thank_you_message\"]').on( 'change', function(){
|
||||
if ( jQuery('#type_of_thank_you_message_message').is(':checked') ) {
|
||||
jQuery('.opsd_calendar_thank_you_message').removeClass('hidden_items');
|
||||
jQuery('.opsd_calendar_thank_you_page').addClass('hidden_items');
|
||||
} else {
|
||||
jQuery('.opsd_calendar_thank_you_message').addClass('hidden_items');
|
||||
jQuery('.opsd_calendar_thank_you_page').removeClass('hidden_items');
|
||||
}
|
||||
} ); ";
|
||||
|
||||
// Default calendar view mode (Item Listing) - set active / inctive options depend from resource selection.
|
||||
$js_script .= " jQuery('#set_gen_opsd_view_days_num').on( 'focus', function(){
|
||||
if ( jQuery('#set_gen_opsd_default_opsd_resource').length > 0 ) {
|
||||
jQuery('#set_gen_opsd_default_opsd_resource').on( 'change', function() {
|
||||
jQuery('#set_gen_opsd_view_days_num option:eq(2)').prop('selected', true);
|
||||
});
|
||||
if ( jQuery('#set_gen_opsd_default_opsd_resource').val() == '' ) {
|
||||
jQuery('#set_gen_opsd_view_days_num option:eq(0)').prop('disabled', false);
|
||||
jQuery('#set_gen_opsd_view_days_num option:eq(1)').prop('disabled', false);
|
||||
jQuery('#set_gen_opsd_view_days_num option:eq(2)').prop('disabled', false);
|
||||
jQuery('#set_gen_opsd_view_days_num option:eq(3)').prop('disabled', false);
|
||||
jQuery('#set_gen_opsd_view_days_num option:eq(4)').prop('disabled', true);
|
||||
jQuery('#set_gen_opsd_view_days_num option:eq(5)').prop('disabled', true);
|
||||
} else {
|
||||
jQuery('#set_gen_opsd_view_days_num option:eq(0)').prop('disabled', true);
|
||||
jQuery('#set_gen_opsd_view_days_num option:eq(1)').prop('disabled', true);
|
||||
jQuery('#set_gen_opsd_view_days_num option:eq(2)').prop('disabled', false);
|
||||
jQuery('#set_gen_opsd_view_days_num option:eq(3)').prop('disabled', true);
|
||||
jQuery('#set_gen_opsd_view_days_num option:eq(4)').prop('disabled', false);
|
||||
jQuery('#set_gen_opsd_view_days_num option:eq(5)').prop('disabled', false);
|
||||
}
|
||||
}
|
||||
} ); ";
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Set correct value for dates format, depend from selection of radio buttons
|
||||
$opsd_date_format = get_opsd_option( 'opsd_date_format');
|
||||
// On initial Load set correct text value and correct radio button
|
||||
$js_script .= "
|
||||
// Select by default Custom value, later check all other predefined values
|
||||
jQuery( '#date_format_selection_custom' ).prop('checked', true);
|
||||
|
||||
jQuery('input[name=\"set_gen_opsd_date_format_selection\"]').each(function() {
|
||||
var radio_button_value = jQuery( this ).val()
|
||||
var encodedStr = radio_button_value.replace(/[\u00A0-\u9999<>\&]/gim, function(i) {
|
||||
return '&#'+i.charCodeAt(0)+';';
|
||||
});
|
||||
if ( encodedStr == '". $opsd_date_format ."' ) {
|
||||
jQuery( this ).prop('checked', true);
|
||||
}
|
||||
});
|
||||
|
||||
jQuery('#set_gen_opsd_date_format').val('". $opsd_date_format ."');
|
||||
";
|
||||
// On click Radio button "Date Format", - set value in custom Text field
|
||||
$js_script .= " jQuery('input[name=\"set_gen_opsd_date_format_selection\"]').on( 'change', function(){
|
||||
if ( ( this.checked ) && ( jQuery(this).val() != 'custom' ) ){
|
||||
|
||||
jQuery('#set_gen_opsd_date_format').val( jQuery(this).val().replace(/[\u00A0-\u9999<>\&]/gim,
|
||||
function(i) {
|
||||
return '&#'+i.charCodeAt(0)+';';
|
||||
})
|
||||
);
|
||||
}
|
||||
} ); ";
|
||||
// If we edit custom "Date Format" Text field - select Custom Radio button.
|
||||
$js_script .= " jQuery('#set_gen_opsd_date_format').on( 'change', function(){
|
||||
jQuery( '#date_format_selection_custom' ).prop('checked', true);
|
||||
} ); ";
|
||||
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Set correct value for Time Format, depend from selection of radio buttons
|
||||
$opsd_time_format = get_opsd_option( 'opsd_time_format');
|
||||
// Function to load on initial stage of page loading, set correct value of text and select correct radio button.
|
||||
$js_script .= "
|
||||
// Select by default Custom value, later check all other predefined values
|
||||
jQuery( '#time_format_selection_custom' ).prop('checked', true);
|
||||
|
||||
jQuery('input[name=\"set_gen_opsd_time_format_selection\"]').each(function() {
|
||||
var radio_button_value = jQuery( this ).val()
|
||||
var encodedStr = radio_button_value.replace(/[\u00A0-\u9999<>\&]/gim, function(i) {
|
||||
return '&#'+i.charCodeAt(0)+';';
|
||||
});
|
||||
if ( encodedStr == '". $opsd_time_format ."' ) {
|
||||
jQuery( this ).prop('checked', true);
|
||||
}
|
||||
});
|
||||
|
||||
jQuery('#set_gen_opsd_time_format').val('". $opsd_time_format ."');
|
||||
";
|
||||
// On click Radio button "Time Format", - set value in custom Text field
|
||||
$js_script .= " jQuery('input[name=\"set_gen_opsd_time_format_selection\"]').on( 'change', function(){
|
||||
if ( ( this.checked ) && ( jQuery(this).val() != 'custom' ) ){
|
||||
|
||||
jQuery('#set_gen_opsd_time_format').val( jQuery(this).val().replace(/[\u00A0-\u9999<>\&]/gim,
|
||||
function(i) {
|
||||
return '&#'+i.charCodeAt(0)+';';
|
||||
})
|
||||
);
|
||||
}
|
||||
} ); ";
|
||||
// If we edit custom "Time Format" Text field - select Custom Radio button.
|
||||
$js_script .= " jQuery('#set_gen_opsd_time_format').on( 'change', function(){
|
||||
jQuery( '#time_format_selection_custom' ).prop('checked', true);
|
||||
} ); ";
|
||||
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Advanced section
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
// Click on "Allow unlimited items per same day(s)"
|
||||
$js_script .= " jQuery('#set_gen_opsd_is_days_always_available').on( 'change', function(){
|
||||
if ( this.checked ) {
|
||||
var answer = confirm('"
|
||||
. esc_js( __( 'Warning', 'secure-downloads') ) . '! '
|
||||
. esc_js( __( 'You allow unlimited number of items per same dates, its can be a reason of double items on the same date. Do you really want to do this?', 'secure-downloads') )
|
||||
. "' );
|
||||
if ( answer) {
|
||||
this.checked = true;
|
||||
jQuery('#set_gen_opsd_check_on_server_if_dates_free').prop('checked', false );
|
||||
jQuery('#set_gen_opsd_is_show_pending_days_as_available').prop('checked', false );
|
||||
jQuery('.opsd_pending_days_as_available_sub_settings').addClass('hidden_items');
|
||||
} else {
|
||||
this.checked = false;
|
||||
}
|
||||
}
|
||||
} ); ";
|
||||
// Click on "Checking to prevent double item, during submitting item"
|
||||
$js_script .= " jQuery('#set_gen_opsd_check_on_server_if_dates_free').on( 'change', function(){
|
||||
if ( this.checked ) {
|
||||
var answer = confirm('"
|
||||
. esc_js( __( 'Warning', 'secure-downloads') ) . '! '
|
||||
. esc_js( __( 'This feature can impact to speed of submitting item. Do you really want to do this?', 'secure-downloads') )
|
||||
. "' );
|
||||
if ( answer) {
|
||||
this.checked = true;
|
||||
jQuery('#set_gen_opsd_is_days_always_available').prop('checked', false );
|
||||
} else {
|
||||
this.checked = false;
|
||||
}
|
||||
}
|
||||
} ); ";
|
||||
|
||||
// Click on Show Advanced JavaScript section link
|
||||
$js_script .= " jQuery('#opsd_show_advanced_section_link_show').on( 'click', function(){
|
||||
jQuery('#opsd_show_advanced_section_link_show').slideToggle(200);
|
||||
jQuery('#opsd_show_advanced_section_link_hide').animate( {opacity: 1}, 200 ).slideToggle(200);
|
||||
jQuery('.opsd_advanced_js_loading_settings').removeClass('hidden_items');
|
||||
|
||||
if ( ! jQuery('#set_gen_opsd_is_load_js_css_on_specific_pages').is(':checked') ) {
|
||||
jQuery('.opsd_is_load_js_css_on_specific_pages').addClass('hidden_items');
|
||||
}
|
||||
} ); ";
|
||||
$js_script .= " jQuery('#opsd_show_advanced_section_link_hide').on( 'click', function(){
|
||||
jQuery('#opsd_show_advanced_section_link_hide').slideToggle(200);
|
||||
jQuery('#opsd_show_advanced_section_link_show').animate( {opacity: 1}, 200 ).slideToggle(200);
|
||||
jQuery('.opsd_advanced_js_loading_settings').addClass('hidden_items');
|
||||
} ); ";
|
||||
// Click on "is_not_load_bs_script_in_client"
|
||||
$js_script .= " jQuery('#set_gen_opsd_is_not_load_bs_script_in_client, #set_gen_opsd_is_not_load_bs_script_in_admin').on( 'change', function(){
|
||||
if ( this.checked ) {
|
||||
var answer = confirm('"
|
||||
. esc_js( __( 'Warning', 'secure-downloads') ) . '! '
|
||||
. esc_js( __( 'You are need to be sure what you are doing. You are disable of loading some JavaScripts Do you really want to do this?', 'secure-downloads') )
|
||||
. "' );
|
||||
if ( answer) {
|
||||
this.checked = true;
|
||||
} else {
|
||||
this.checked = false;
|
||||
}
|
||||
}
|
||||
} ); ";
|
||||
$js_script .= " jQuery('#set_gen_opsd_is_load_js_css_on_specific_pages').on( 'change', function(){
|
||||
if ( this.checked ) {
|
||||
var answer = confirm('"
|
||||
. esc_js( __( 'Warning', 'secure-downloads') ) . '! '
|
||||
. esc_js( __( 'You are need to be sure what you are doing. You are disable of loading some JavaScripts Do you really want to do this?', 'secure-downloads') )
|
||||
. "' );
|
||||
if ( answer) {
|
||||
this.checked = true;
|
||||
jQuery('.opsd_is_load_js_css_on_specific_pages').removeClass('hidden_items');
|
||||
} else {
|
||||
this.checked = false;
|
||||
}
|
||||
} else {
|
||||
jQuery('.opsd_is_load_js_css_on_specific_pages').addClass('hidden_items');
|
||||
}
|
||||
} );
|
||||
";
|
||||
|
||||
|
||||
// Click on Powered by links
|
||||
$js_script .= " jQuery('#opsd_powered_by_link_show').on( 'click', function(){
|
||||
jQuery('#opsd_powered_by_link_show').slideToggle(200);
|
||||
jQuery('#opsd_powered_by_link_hide').animate( {opacity: 1}, 200 ).slideToggle(200);
|
||||
jQuery('.opsd_is_show_powered_by_notice').removeClass('hidden_items');
|
||||
} ); ";
|
||||
$js_script .= " jQuery('#opsd_powered_by_link_hide').on( 'click', function(){
|
||||
jQuery('#opsd_powered_by_link_hide').slideToggle(200);
|
||||
jQuery('#opsd_powered_by_link_show').animate( {opacity: 1}, 200 ).slideToggle(200);
|
||||
jQuery('.opsd_is_show_powered_by_notice').addClass('hidden_items');
|
||||
} ); ";
|
||||
|
||||
|
||||
// Show confirmation window, if user activate this checkbox
|
||||
$js_script .= " jQuery('#set_gen_opsd_is_delete_if_deactive').on( 'change', function(){
|
||||
if ( this.checked ) {
|
||||
var answer = confirm('"
|
||||
. esc_js( __( 'Warning', 'secure-downloads') ) . '! '
|
||||
. esc_js( __( 'If you check this option, all data will be deleted when you uninstall this plugin. Do you really want to do this?', 'secure-downloads') )
|
||||
. "' );
|
||||
if ( answer) {
|
||||
this.checked = true;
|
||||
} else {
|
||||
this.checked = false;
|
||||
}
|
||||
}
|
||||
} );
|
||||
";
|
||||
|
||||
|
||||
// Eneque JS to the footer of the page
|
||||
opsd_enqueue_js( $js_script );
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
/** Override VALIDATED fields BEFORE saving to DB
|
||||
* Description:
|
||||
* Check "Thank you page" URL
|
||||
*
|
||||
* @param array $validated_fields
|
||||
*/
|
||||
function opsd_settings_validate_fields_before_saving__all( $validated_fields ) {
|
||||
|
||||
|
||||
$validated_fields['opsd_url_wrong_hash'] = opsd_make_link_relative( $validated_fields['opsd_url_wrong_hash'] );
|
||||
$validated_fields['opsd_url_download_expired'] = opsd_make_link_relative( $validated_fields['opsd_url_download_expired'] );
|
||||
$validated_fields['opsd_url_ip_not_valied'] = opsd_make_link_relative( $validated_fields['opsd_url_ip_not_valied'] );
|
||||
$validated_fields['opsd_url_file_not_exist'] = opsd_make_link_relative( $validated_fields['opsd_url_file_not_exist'] );
|
||||
$validated_fields['opsd_url_error_opening_file'] = opsd_make_link_relative( $validated_fields['opsd_url_error_opening_file'] );
|
||||
|
||||
unset( $validated_fields[ 'opsd_date_format_selection' ] ); // We do not need to this field, because saving to DB only: "date_format" field
|
||||
unset( $validated_fields[ 'opsd_time_format_selection' ] ); // We do not need to this field, because saving to DB only: "time_format" field
|
||||
|
||||
return $validated_fields;
|
||||
}
|
||||
add_filter( 'opsd_settings_validate_fields_before_saving', 'opsd_settings_validate_fields_before_saving__all', 10, 1 ); // Hook for validated fields.
|
||||
@@ -0,0 +1,462 @@
|
||||
<?php /**
|
||||
* @version 1.1
|
||||
* @package Secure Downloads
|
||||
* @category item Listing Table in Admin Panel
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-12-28
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
class OPSD_OPSD_Listing_Table {
|
||||
|
||||
public $items;
|
||||
public $opsd_types;
|
||||
|
||||
private $url; // URL for differnt Menus
|
||||
private $user_id; // ID of logged in users
|
||||
private $is_free; // Version type
|
||||
private $days_column_style; // CSS Styles for days columns
|
||||
private $date_view_type; // Initial Days View mode
|
||||
|
||||
|
||||
public function __construct( $items, $opsd_types ) {
|
||||
|
||||
$this->items = $items;
|
||||
$this->opsd_types = $opsd_types;
|
||||
|
||||
$this->url = array();
|
||||
$this->days_column_style = array( 'wide' => 'color:#333;', 'short' => 'color:#333;' );
|
||||
$this->init_params();
|
||||
}
|
||||
|
||||
|
||||
/** Get URL for specific menu
|
||||
*
|
||||
* @param sting $url - 'master' | 'add' | 'settings' | 'request'
|
||||
* @return string - url
|
||||
*/
|
||||
public function get_url( $url = 'listing') {
|
||||
if ( isset( $this->url[ $url ] ) )
|
||||
return $this->url[ $url ];
|
||||
else
|
||||
$this->url[ 'master' ];
|
||||
}
|
||||
|
||||
|
||||
/** Check if items exist or no */
|
||||
public function is_items_exist() {
|
||||
if ( count( $this->items ) > 0 )
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
/** Init Paramteres */
|
||||
private function init_params() {
|
||||
|
||||
$user = wp_get_current_user();
|
||||
$this->user_id = $user->ID;
|
||||
|
||||
$this->url['master'] = 'admin.php?page=' . opsd_get_master_url( false );
|
||||
$this->url['add'] = 'admin.php?page=' . opsd_get_new_opsd_url( false );
|
||||
$this->url['settings'] = 'admin.php?page=' . opsd_get_settings_url( false );
|
||||
|
||||
// Transform the REQESTS parameters (GET and POST) into URL
|
||||
$this->url['request'] = opsd_get_params_in_url( opsd_get_master_url( false ), array('page_num', 'wh_opsd_type') );
|
||||
|
||||
|
||||
$this->date_view_type = get_opsd_option( 'opsd_date_view_type');
|
||||
if ( $this->date_view_type == 'short' ) $this->days_column_style['wide'] .= 'display:none;';
|
||||
else $this->days_column_style['short'] .= 'display:none;';
|
||||
|
||||
$version = get_opsd_version();
|
||||
if ( $version == 'free' ) $this->is_free = true;
|
||||
else $this->is_free = false;
|
||||
}
|
||||
|
||||
|
||||
/** Show Listing Table */
|
||||
public function show() {
|
||||
|
||||
?><div id="listing_visible_opsd" class="container-fluid table table-striped opsd_selectable_table"><?php
|
||||
|
||||
if ( $this->is_items_exist() ) {
|
||||
|
||||
$this->header( $this->is_free );
|
||||
|
||||
?><span class="opsd_selectable_body"><?php
|
||||
|
||||
$this->rows( $this->is_free );
|
||||
|
||||
?></span><?php
|
||||
|
||||
} else {
|
||||
?><center>
|
||||
<h4><?php _e('Nothing Found', 'secure-downloads'); ?>.</h4>
|
||||
</center><?php
|
||||
}
|
||||
|
||||
?></div><?php
|
||||
}
|
||||
|
||||
|
||||
/** Show Header */
|
||||
public function header( $is_free ) {
|
||||
|
||||
?>
|
||||
<div class="row opsd-listing-header opsd_selectable_head">
|
||||
<div class="opsd-listing-collumn col-sm-<?php echo $is_free ? '2' : '3'; ?> col-xs-4">
|
||||
<div class="row">
|
||||
<div class="opsd-no-margin col-sm-1 col-xs-1 opsd_column_1 check-column" >
|
||||
<input type="checkbox" onclick="javascript:opsd_set_checkbox_in_table( this.checked, 'opsd_list_item_checkbox' );" class="opsd-no-margin" style="vertical-align: middle;"/>
|
||||
</div>
|
||||
<div class="opsd-no-margin col-sm-1 col-xs-5 text-center opsd_column_2">
|
||||
<?php _e('ID', 'secure-downloads'); ?>
|
||||
</div>
|
||||
<div class="opsd-no-margin col-sm-<?php echo $is_free ? '6' : '7'; ?> text-left hide-sm opsd_column_3">
|
||||
<?php _e('Labels' , 'secure-downloads'); if ( ! $is_free ) { echo ' / '; _e('Actions' , 'secure-downloads'); } ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="opsd-listing-collumn col-sm-6 col-xs-6 text-center opsd_column_4"><?php _e('Item Data', 'secure-downloads'); ?></div>
|
||||
<div class="opsd-listing-collumn col-sm-3 hide-sm text-center opsd_column_5"><?php _e('Item Dates', 'secure-downloads'); ?>
|
||||
<a id="opsd_dates_full"
|
||||
onclick="javascript:jQuery('#opsd_dates_full,.opsd_dates_small').hide();jQuery('#opsd_dates_small,.opsd_dates_full').show();" href="javascript:void(0)"
|
||||
title="<?php _e('Show ALL dates of item' , 'secure-downloads'); ?>"
|
||||
style="<?php echo $this->days_column_style['short']; ?>"
|
||||
class="tooltip_top"
|
||||
><i class="glyphicon glyphicon-resize-full" style=" margin-top: 2px;"></i></a>
|
||||
<a id="opsd_dates_small"
|
||||
onclick="javascript:jQuery('#opsd_dates_small,.opsd_dates_full').hide();jQuery('#opsd_dates_full,.opsd_dates_small').show();" href="javascript:void(0)"
|
||||
title="<?php _e('Show only check in/out dates' , 'secure-downloads'); ?>"
|
||||
style="<?php echo $this->days_column_style['wide']; ?>"
|
||||
class="tooltip_top"
|
||||
><i class="glyphicon glyphicon-resize-small" style=" margin-top: 2px;"></i></a>
|
||||
</div>
|
||||
<?php if ( $is_free ) { ?>
|
||||
<div class="opsd-listing-collumn col-sm-1 hide-sm text-center opsd_column_6"><?php _e('Actions', 'secure-downloads'); ?></div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
|
||||
|
||||
/** Show Listing Rows
|
||||
*
|
||||
* @param boolean $is_free
|
||||
*/
|
||||
public function rows( $is_free ) {
|
||||
|
||||
$availbale_locales_in_system = get_available_languages();
|
||||
$print_data = apply_opsd_filter( 'opsd_print_get_header', array( array() ) ); // P
|
||||
$bk_key = 0;
|
||||
|
||||
//TODO: blank data
|
||||
$this->items = 'a:1:{i:121;O:8:"stdClass":19:{s:10:"booking_id";s:3:"121";s:5:"trash";s:1:"0";s:8:"sync_gid";s:0:"";s:6:"is_new";s:1:"1";s:6:"status";s:0:"";s:9:"sort_date";s:19:"2017-11-22 00:00:00";s:17:"modification_date";s:19:"2017-05-14 10:25:15";s:4:"form";s:261:"text^name4^William~text^secondname4^Wilyson~text^email4^Wilyson.example@wpbookingcalendar.com~text^address4^200 Lincoln Ave~text^city4^Glasgow~text^postcode4^92073~text^country4^UK~text^phone4^927-80-51~select-one^visitors4^1~textarea^details4^~coupon^coupon4^ ";s:4:"hash";s:32:"0020d451b4bf5a34a3e65928128d2c85";s:12:"booking_type";s:1:"4";s:6:"remark";N;s:4:"cost";s:6:"960.00";s:10:"pay_status";s:0:"";s:11:"pay_request";s:1:"0";s:5:"dates";a:5:{i:0;O:8:"stdClass":4:{s:10:"booking_id";s:3:"121";s:12:"booking_date";s:19:"2017-11-22 00:00:00";s:8:"approved";s:1:"0";s:7:"type_id";N;}i:1;O:8:"stdClass":4:{s:10:"booking_id";s:3:"121";s:12:"booking_date";s:19:"2017-11-23 00:00:00";s:8:"approved";s:1:"0";s:7:"type_id";N;}i:2;O:8:"stdClass":4:{s:10:"booking_id";s:3:"121";s:12:"booking_date";s:19:"2017-11-24 00:00:00";s:8:"approved";s:1:"0";s:7:"type_id";N;}i:3;O:8:"stdClass":4:{s:10:"booking_id";s:3:"121";s:12:"booking_date";s:19:"2017-11-25 00:00:00";s:8:"approved";s:1:"0";s:7:"type_id";N;}i:4;O:8:"stdClass":4:{s:10:"booking_id";s:3:"121";s:12:"booking_date";s:19:"2017-11-26 00:00:00";s:8:"approved";s:1:"0";s:7:"type_id";N;}}s:11:"dates_short";a:3:{i:0;s:19:"2017-11-22 00:00:00";i:1;s:1:"-";i:2;s:19:"2017-11-26 00:00:00";}s:9:"form_show";s:7:" Times:";s:9:"form_data";a:7:{s:5:"email";s:37:"Wilyson.example@wpbookingcalendar.com";s:4:"name";s:7:"William";s:10:"secondname";s:7:"Wilyson";s:8:"visitors";s:1:"1";s:6:"coupon";s:1:" ";s:5:"_all_";a:11:{s:5:"name4";s:7:"William";s:11:"secondname4";s:7:"Wilyson";s:6:"email4";s:37:"Wilyson.example@wpbookingcalendar.com";s:8:"address4";s:15:"200 Lincoln Ave";s:5:"city4";s:7:"Glasgow";s:9:"postcode4";s:5:"92073";s:8:"country4";s:2:"UK";s:6:"phone4";s:9:"927-80-51";s:9:"visitors4";s:1:"1";s:8:"details4";s:0:"";s:7:"coupon4";s:1:" ";}s:12:"_all_fields_";a:18:{s:4:"name";s:7:"William";s:10:"secondname";s:7:"Wilyson";s:5:"email";s:37:"Wilyson.example@wpbookingcalendar.com";s:7:"address";s:15:"200 Lincoln Ave";s:4:"city";s:7:"Glasgow";s:8:"postcode";s:5:"92073";s:7:"country";s:2:"UK";s:5:"phone";s:9:"927-80-51";s:8:"visitors";s:1:"1";s:7:"details";s:0:"";s:6:"coupon";s:1:" ";s:19:"booking_resource_id";s:1:"4";s:11:"resource_id";s:1:"4";s:7:"type_id";s:1:"4";s:4:"type";s:1:"4";s:8:"resource";s:1:"4";s:10:"booking_id";s:3:"121";s:14:"resource_title";O:8:"stdClass":12:{s:15:"booking_type_id";s:1:"4";s:5:"title";s:11:"Apartment#3";s:5:"users";s:1:"1";s:6:"import";N;s:4:"cost";s:2:"25";s:12:"default_form";s:8:"standard";s:9:"prioritet";s:1:"0";s:6:"parent";s:1:"0";s:8:"visitors";s:1:"1";s:2:"id";s:1:"4";s:5:"count";i:1;s:2:"ID";s:1:"4";}}}s:14:"dates_short_id";a:3:{i:0;s:0:"";i:1;s:0:"";i:2;s:0:"";}}}';
|
||||
$this->items = maybe_unserialize( $this->items );
|
||||
$this->items[]=$this->items[121];
|
||||
$this->items[]=$this->items[121];
|
||||
$this->items[]=$this->items[121];
|
||||
foreach ( $this->items as $bk ) {
|
||||
|
||||
$bk_key++;
|
||||
//TODO: blank data
|
||||
$bk->form_show = '<div class="standard-content-form">
|
||||
<strong>First Name</strong>:<span class="fieldvalue">William</span>
|
||||
<strong>Last Name</strong>:<span class="fieldvalue">Wilyson</span>
|
||||
<strong>Email</strong>:<span class="fieldvalue">Wilyson.example@test.com</span>
|
||||
<strong>Phone</strong>:<span class="fieldvalue">927-80-51</span>
|
||||
<strong>Adults</strong>:<span class="fieldvalue"> 1</span>
|
||||
<strong>Children</strong>:<span class="fieldvalue"></span>
|
||||
<strong>Details</strong>: <span class="fieldvalue"> </span>
|
||||
</div>';
|
||||
$bk->opsd_id = $bk->booking_id;
|
||||
|
||||
|
||||
$row_data = array();
|
||||
$row_data[ 'availbale_locales' ] = $availbale_locales_in_system;
|
||||
$row_data[ 'css' ] = '';
|
||||
$row_data[ 'css' ] .= $bk_key % 2 ? '' : ' row_alternative_color';
|
||||
$row_data[ 'css' ] .= ( $bk_key == ( count( $this->items ) ) ) ? ' opsd-listing-last_row' : '';
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
||||
$date_format = get_opsd_option( 'opsd_date_format' );
|
||||
if ( empty( $date_format ) ) $date_format = 'm / d / Y, D';
|
||||
$time_format = get_opsd_option( 'opsd_time_format' );
|
||||
if ( empty( $time_format ) ) $time_format = 'h:i a';
|
||||
|
||||
$row_data['cr_date'] = date_i18n( $date_format , mysql2date( 'U', $bk->modification_date ) );
|
||||
$row_data['cr_time'] = date_i18n( $time_format , mysql2date( 'U', $bk->modification_date ) );
|
||||
$row_data['id'] = $bk->opsd_id; // 100
|
||||
$row_data['is_new'] = (isset( $bk->is_new )) ? $bk->is_new : '0';
|
||||
$row_data['modification_date'] = (isset( $bk->modification_date )) ? $bk->modification_date : ''; // 2012-02-29 16:01:58
|
||||
$row_data['form'] = $bk->form; // select-one^rangetime5^10:00 - 12:00~text^name5^Jonny~text^secondname5^Smith~email^ ....
|
||||
$row_data['form_show'] = $bk->form_show; // First Name:Jonny Last Name:Smith Email:email@server.com Country:GB ....
|
||||
$row_data['form_data'] = $bk->form_data; // Array ([name] => Jonny... [_all_] => Array ( [rangetime5] => 10:00 - 12:00 [name5] => Jonny ... ) .... )
|
||||
$row_data['dates'] = $bk->dates; // Array ( [0] => stdClass Object ( [opsd_id] => 8 [opsd_date] => 2012-04-16 10:00:01 [approved] => 0 [type_id] => )
|
||||
$row_data['dates_short'] = $bk->dates_short; // Array ( [0] => 2012-04-16 10:00:01 [1] => - [2] => 2012-04-20 12:00:02 [3] => , [4] => 2012-04-16 10:00:01 ....
|
||||
$row_data['is_approved'] = ( count( $bk->dates ) > 0 ) ? $bk->dates[0]->approved : 0;
|
||||
|
||||
//Is item in Trash.
|
||||
$row_data['is_trash'] = $bk->trash ; //FixIn: 6.1.1.10
|
||||
|
||||
// BL **************************************************************
|
||||
$row_data['dates_short_id'] = ( ( count( $bk->dates ) > 0 ) && ( isset( $bk->dates_short_id ) ) ) ? $bk->dates_short_id : array(); // Array ([0] => [1] => .... [4] => 6... [11] => [12] => 8 )
|
||||
|
||||
// Get SHORT Dates showing data ////////////////////////////////////
|
||||
//$row_data['short_dates_content'] = opsd_get_short_dates_formated_to_show( $row_data['dates_short'], $row_data['is_approved'], $row_data['dates_short_id'], $this->opsd_types );
|
||||
//TODO: blank data
|
||||
$row_data['short_dates_content'] = '<div class="securedownloads_dates_small" style="color: rgb(51, 51, 51); display: block;"><a href="javascript:void(0)" class="field-securedownloads-date label ">November 22, 2017<sup class="field-securedownloads-time"></sup></a><span class="date_tire"> - </span><a href="javascript:void(0)" class="field-securedownloads-date label ">November 26, 2017<sup class="field-securedownloads-time"></sup></a></div>';
|
||||
// Get WIDE Dates showing data /////////////////////////////////////
|
||||
//$row_data['wide_dates_content'] = opsd_get_wide_dates_formated_to_show( $row_data['dates'], $row_data['is_approved'], $this->opsd_types );
|
||||
//TODO: blank data
|
||||
$row_data['wide_dates_content'] = '<div class="securedownloads_dates_full" style="color: rgb(51, 51, 51); display: block;"><a href="javascript:void(0)" class="field-securedownloads-date label approved ">September 14, 2017<sup class="field-securedownloads-time"></sup></a><span class="date_tire">, </span><a href="javascript:void(0)" class="field-securedownloads-date label approved ">September 15, 2017<sup class="field-securedownloads-time"></sup></a><span class="date_tire">, </span><a href="javascript:void(0)" class="field-securedownloads-date label approved ">September 16, 2017<sup class="field-securedownloads-time"></sup></a></div>';
|
||||
// P ***************************************************************
|
||||
$row_data['resource'] = ( isset( $bk->opsd_type ) ) ? $bk->opsd_type : '1';
|
||||
$row_data['resource_name'] = '<span class="label_resource_not_exist">' . __( 'Default', 'secure-downloads') . '</span>';
|
||||
|
||||
if ( class_exists( 'opsd_personal' ) ) {
|
||||
|
||||
if ( isset( $this->opsd_types[ $row_data['resource'] ] ) ) {
|
||||
|
||||
$row_data['resource_name'] = $this->opsd_types[$row_data['resource']]->title;
|
||||
$row_data['resource_name'] = apply_opsd_filter('opsd_check_for_active_language', $row_data['resource_name'] );
|
||||
if ( strlen( $row_data['resource_name'] ) > 19 ) {
|
||||
$row_data['resource_name'] = '<span style="cursor:pointer;" class="tooltip_top" title="' . $row_data['resource_name'] . '">'
|
||||
. substr( $row_data['resource_name'], 0, 13 )
|
||||
. ' ... ' . substr( $row_data['resource_name'], -3 )
|
||||
. '</span>';
|
||||
}
|
||||
} else
|
||||
$row_data['resource_name'] = '<span class="label_resource_not_exist">' . __( 'Resource not exist', 'secure-downloads') . '</span>';
|
||||
}
|
||||
|
||||
$row_data['hash'] = (isset( $bk->hash )) ? $bk->hash : ''; // 99c9c2bd4fd0207e4376bdbf5ee473bc
|
||||
$row_data['remark'] = (isset( $bk->remark )) ? $bk->remark : '';
|
||||
|
||||
// BS **************************************************************
|
||||
$row_data['cost'] = (isset( $bk->cost )) ? $bk->cost : ''; // 150.00
|
||||
$row_data['pay_status'] = (isset( $bk->pay_status )) ? $bk->pay_status : ''; // 30800
|
||||
$row_data['pay_request'] = (isset( $bk->pay_request )) ? $bk->pay_request : ''; // 0
|
||||
$row_data['status'] = (isset( $bk->status )) ? $bk->status : '';
|
||||
$row_data['is_paid'] = 0;
|
||||
$row_data['current_payment_status_titles'] = '';
|
||||
$row_data['pay_print_status'] = '';
|
||||
|
||||
if ( class_exists( 'opsd_biz_s' ) ) {
|
||||
|
||||
if ( opsd_is_payment_status_ok( trim( $row_data['pay_status'] ) ) ) $row_data['is_paid'] = 1;
|
||||
|
||||
$payment_status_titles = get_payment_status_titles();
|
||||
$row_data['current_payment_status_titles'] = array_search( $row_data['pay_status'], $payment_status_titles );
|
||||
if ( $row_data['current_payment_status_titles'] === false )
|
||||
$row_data['current_payment_status_titles'] = $row_data['pay_status'];
|
||||
|
||||
|
||||
if ( $row_data['is_paid'] ) {
|
||||
$row_data['pay_print_status'] = __( 'Paid OK', 'secure-downloads');
|
||||
if ( $row_data['current_payment_status_titles'] == 'Completed' )
|
||||
$row_data['pay_print_status'] = $row_data['current_payment_status_titles'];
|
||||
} else if ( ( is_numeric( $row_data['pay_status'] ) ) || ( $row_data['pay_status'] == '' ) ) {
|
||||
$row_data['pay_print_status'] = __( 'Unknown', 'secure-downloads');
|
||||
} else {
|
||||
$row_data['pay_print_status'] = $row_data['current_payment_status_titles'];
|
||||
}
|
||||
}
|
||||
|
||||
// Print data /////////////////////////////////////////////////////
|
||||
$print_data[] = apply_opsd_filter( 'opsd_print_get_row'
|
||||
, array()
|
||||
, $row_data['id']
|
||||
, $row_data['is_approved']
|
||||
, $row_data['form_show']
|
||||
, $row_data['resource_name']
|
||||
, $row_data['is_paid']
|
||||
, $row_data['pay_print_status']
|
||||
, ( $this->date_view_type == 'short' ) ? '<div class="opsd_dates_small">'
|
||||
. $row_data['short_dates_content']
|
||||
. '</div>'
|
||||
: '<div class="opsd_dates_full">'
|
||||
. $row_data['wide_dates_content']
|
||||
. '</div>'
|
||||
, $row_data['cost']
|
||||
, $row_data['resource']
|
||||
);
|
||||
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
||||
$this->show_row( $row_data, $is_free );
|
||||
}
|
||||
|
||||
make_opsd_action( 'opsd_listing_show_change_opsd_resources', $this->opsd_types );
|
||||
|
||||
make_opsd_action( 'opsd_print_loyout', $print_data );
|
||||
}
|
||||
|
||||
|
||||
/** Show 1 Listing Row
|
||||
*
|
||||
* @param array $row_data - Array of data to show
|
||||
* @param boolean $is_free
|
||||
*/
|
||||
public function show_row( $row_data, $is_free ) {
|
||||
|
||||
// is New
|
||||
?><div id="opsd_mark_<?php echo $row_data[ 'id' ]; ?>"
|
||||
class="<?php if ( $row_data[ 'is_new'] != '1') echo ' hidden_items '; ?> opsd-listing-collumn new-label clearfix-height">
|
||||
<a href="javascript:void(0)"
|
||||
onclick="javascript:console.log( '<?php echo $row_data[ 'id' ]; ?>', 0, <?php echo $this->user_id; ?>, '<?php echo opsd_get_locale(); ?>' );"
|
||||
class="tooltip_right approve_opsd_link"
|
||||
title="<?php _e('New item' , 'secure-downloads'); ?>"
|
||||
><i class="glyphicon glyphicon-flash"></i></a>
|
||||
</div><?php
|
||||
|
||||
// Row start
|
||||
?><div id="opsd_row_<?php echo $row_data[ 'id' ]; ?>" class="row opsd_row clearfix-height opsd-listing-row <?php echo $row_data[ 'css' ]; ?><?php echo $is_free ? ' opsd_free' : ''; ?>"><?php
|
||||
|
||||
?><div class="opsd-listing-collumn col-sm-<?php echo $is_free ? '2' : '3'; ?> col-xs-12">
|
||||
<div class="row"><?php
|
||||
|
||||
// Checkbox
|
||||
?><div class="opsd-no-margin col-sm-1 col-xs-1 field-checkbox opsd_column_1 check-column">
|
||||
<input type="checkbox" class="opsd-no-margin opsd_list_item_checkbox opsd_list_item_checkbox"
|
||||
onclick="javascript: if (jQuery(this).attr('checked') !== undefined ) { jQuery(this).parent().parent().parent().parent().addClass('row_selected_color'); } else {jQuery(this).parent().parent().parent().parent().removeClass('row_selected_color');}"
|
||||
id="opsd_id_selected_<?php echo $row_data[ 'id' ]; ?>"
|
||||
name="opsd_appr_<?php $row_data[ 'id' ]; ?>"
|
||||
/>
|
||||
</div><?php
|
||||
|
||||
// ID
|
||||
?><div class="opsd-no-margin col-sm-1 col-xs-1 field-id text-center opsd_column_2">
|
||||
<span class="label"><?php echo $row_data[ 'id' ]; ?></span>
|
||||
</div><?php
|
||||
|
||||
// Labels
|
||||
?><div class="opsd-no-margin col-sm-<?php echo $is_free ? '6' : '7'; ?> col-xs-10 text-left field-labels opsd-labels opsd_column_3" >
|
||||
<?php make_opsd_action('opsd_listing_show_label_resource', $row_data['resource_name'], $this->url['request'] .'&wh_opsd_type='. $row_data['resource'] ); ?>
|
||||
<span class="label label-default label-pending <?php if ($row_data['is_approved']) echo ' hidden_items '; ?> "><?php _e('Pending' , 'secure-downloads'); ?></span>
|
||||
<span class="label label-default label-approved <?php if (! $row_data['is_approved']) echo ' hidden_items '; ?>"><?php _e('Approved' , 'secure-downloads'); ?></span>
|
||||
<?php make_opsd_action('opsd_listing_show_payment_label', $row_data['is_paid'], $row_data['pay_print_status'], $row_data['current_payment_status_titles']); ?>
|
||||
<span class="label label-trash label-danger <?php if (! $row_data['is_trash']) echo ' hidden_items '; ?> "><?php _e('Trash' , 'secure-downloads'); ?></span><?php //FixIn: 6.1.1.10 ?>
|
||||
</div><?php
|
||||
?></div>
|
||||
</div><?php
|
||||
|
||||
// Data
|
||||
?><div class="opsd-listing-collumn col-sm-6 col-xs-12 opsd-text-justify field-content opsd_column_4">
|
||||
<?php echo $row_data['form_show']; ?>
|
||||
</div><?php
|
||||
|
||||
//Dates
|
||||
?><div class="opsd-listing-collumn col-sm-3 col-xs-12 text-center field-dates opsd-dates opsd_column_5">
|
||||
<div class="opsd_dates_small" style="<?php echo $this->days_column_style['short']; ?>"><?php echo $row_data['short_dates_content']; ?></div>
|
||||
<div class="opsd_dates_full" style="<?php echo $this->days_column_style['wide']; ?>"><?php echo $row_data['wide_dates_content']; ?></div>
|
||||
</div><?php
|
||||
|
||||
if ( ! $is_free ) {
|
||||
?><div class="clear"></div><?php
|
||||
}
|
||||
|
||||
// Actions
|
||||
?><div class="opsd-listing-collumn col-sm-<?php echo $is_free ? '1' : '10'; ?> col-xs-12 text-left field-action-buttons opsd-actions opsd_column_6"><?php
|
||||
|
||||
// Cost
|
||||
make_opsd_action( 'opsd_listing_button_cost_edit', $row_data );
|
||||
|
||||
|
||||
?><div class="actions-fields-group control-group"><?php
|
||||
|
||||
// Payment Status
|
||||
make_opsd_action('opsd_listing_button_payment_status', $row_data );
|
||||
|
||||
?><span class="opsd-buttons-separator"></span><?php
|
||||
|
||||
// Edit
|
||||
$row_data['edit_opsd_url'] = $this->url['add'] . '&opsd_type=' . $row_data['resource'] . '&opsd_hash=' . $row_data['hash'] . '&parent_res=1' ;
|
||||
make_opsd_action( 'opsd_listing_button_edit', $row_data );
|
||||
|
||||
// Change item resource
|
||||
make_opsd_action( 'opsd_listing_button_change_resource', $row_data );
|
||||
|
||||
// Duplicate
|
||||
make_opsd_action( 'opsd_listing_button_duplicate', $row_data );
|
||||
|
||||
// Print
|
||||
make_opsd_action( 'opsd_listing_button_print', $row_data );
|
||||
|
||||
// Notes
|
||||
make_opsd_action( 'opsd_listing_button_notes', $row_data );
|
||||
|
||||
// Change Locale
|
||||
make_opsd_action( 'opsd_listing_button_locale', $row_data );
|
||||
|
||||
|
||||
?><span class="opsd-buttons-separator"></span><?php
|
||||
|
||||
//FixIn: 6.1.1.10
|
||||
// Trash
|
||||
?><a href="javascript:void(0)"
|
||||
onclick="javascript:if ( opsd_are_you_sure('<?php echo esc_js(__('Do you really want to do this ?' , 'secure-downloads')); ?>') ) console.log( 1, <?php echo $row_data[ 'id' ]; ?>, <?php echo $this->user_id; ?>, '<?php echo opsd_get_locale(); ?>' , 1 );"
|
||||
class="tooltip_top button-secondary button trash_opsd_link <?php if ( $row_data['is_trash'] ) echo ' hidden_items '; ?>"
|
||||
title="<?php _e('Move to trash' , 'secure-downloads'); ?>"
|
||||
><i class="glyphicon glyphicon-trash"></i></a><?php
|
||||
// Restore
|
||||
?><a href="javascript:void(0)"
|
||||
onclick="javascript:if ( opsd_are_you_sure('<?php echo esc_js(__('Do you really want to do this ?' , 'secure-downloads')); ?>') ) console.log( 0, <?php echo $row_data[ 'id' ]; ?>, <?php echo $this->user_id; ?>, '<?php echo opsd_get_locale(); ?>' , 1 );"
|
||||
class="tooltip_top button-secondary button restore_opsd_link <?php if ( ! $row_data['is_trash'] ) echo ' hidden_items '; ?>"
|
||||
title="<?php _e('Restore' , 'secure-downloads'); ?>"
|
||||
><i class="glyphicon glyphicon-repeat"></i></a><?php
|
||||
// Delete
|
||||
?><a href="javascript:void(0)"
|
||||
onclick="javascript:if ( opsd_are_you_sure('<?php echo esc_js(__('Do you really want to delete this item ?' , 'secure-downloads')); ?>') ) console.log(<?php echo $row_data[ 'id' ]; ?>, <?php echo $this->user_id; ?>, '<?php echo opsd_get_locale(); ?>' , 1 );"
|
||||
class="tooltip_top button-secondary button delete_opsd_link <?php if ( ! $row_data['is_trash'] ) echo ' hidden_items '; ?>"
|
||||
title="<?php _e('Completely Delete' , 'secure-downloads'); ?>"
|
||||
><i class="glyphicon glyphicon-remove"></i></a><?php
|
||||
//End FixIn: 6.1.1.10
|
||||
|
||||
|
||||
// Approve
|
||||
?><a href="javascript:void(0)"
|
||||
onclick="javascript:console.log(<?php echo $row_data[ 'id' ]; ?>,1,<?php echo $this->user_id; ?>,'<?php echo opsd_get_locale(); ?>',1);"
|
||||
class="tooltip_top approve_opsd_link button-secondary button <?php if ($row_data['is_approved']) echo ' hidden_items '; ?> "
|
||||
title="<?php _e('Approve' , 'secure-downloads'); ?>"
|
||||
><i class="glyphicon glyphicon-ok-circle"></i></a><?php
|
||||
|
||||
// Reject
|
||||
?><a href="javascript:void(0)"
|
||||
onclick="javascript:if ( opsd_are_you_sure('<?php echo esc_js(__('Do you really want to set item as pending ?' , 'secure-downloads')); ?>') ) console.log(<?php echo $row_data[ 'id' ]; ?>,0, <?php echo $this->user_id; ?>, '<?php echo opsd_get_locale(); ?>' , 1 );"
|
||||
class="tooltip_top pending_opsd_link button-secondary button <?php if (! $row_data['is_approved']) echo ' hidden_items '; ?> "
|
||||
title="<?php _e('Reject' , 'secure-downloads'); ?>"
|
||||
><i class="glyphicon glyphicon-ban-circle"></i></a><?php
|
||||
|
||||
?></div><?php
|
||||
|
||||
?></div><?php
|
||||
|
||||
// Created Date
|
||||
?><div class="opsd-listing-collumn col-sm-<?php echo $is_free ? '12' : '2'; ?> col-xs-12 text-left field-system-info opsd_column_7"><?php
|
||||
?><span><?php _e('Created' , 'secure-downloads'); ?>:</span> <span class="field-creation-date"><?php echo $row_data['cr_date'], ' ', $row_data['cr_time']; ?></span><?php
|
||||
?></div><?php
|
||||
|
||||
|
||||
// Notes Section
|
||||
make_opsd_action( 'opsd_listing_section_notes', $row_data );
|
||||
|
||||
// Change Resources section
|
||||
make_opsd_action( 'opsd_listing_section_change_resource', $row_data );
|
||||
|
||||
// Payment Status Section
|
||||
make_opsd_action( 'opsd_listing_section_payment_status', $row_data );
|
||||
|
||||
|
||||
?></div><?php
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,200 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @category Content of Settings page
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-11-02
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
|
||||
class OPSD_Page_SettingsFields extends OPSD_Page_Structure {
|
||||
|
||||
public function in_page() {
|
||||
return 'opsd-settings';
|
||||
}
|
||||
|
||||
public function tabs() {
|
||||
|
||||
$tabs = array();
|
||||
$tabs[ 'sub-toolbar' ] = array(
|
||||
'title' => 'Sub Toolbar Elements' // Title of TAB
|
||||
, 'hint' => 'Customizaton of Form Fields' // Hint
|
||||
, 'page_title' => 'Form fields' // Title of Page
|
||||
//, 'link' => '' // Can be skiped, then generated link based on Page and Tab tags. Or can be extenral link
|
||||
//, 'position' => '' // 'left' || 'right' || ''
|
||||
//, 'css_classes' => '' // CSS class(es)
|
||||
//, 'icon' => '' // Icon - link to the real PNG img
|
||||
, 'font_icon' => 'glyphicon glyphicon-edit' // CSS definition of forn Icon
|
||||
, 'default' => false // Is this tab activated by default or not: true || false.
|
||||
, 'subtabs' => array()
|
||||
|
||||
);
|
||||
// $tabs[ 'upgrade' ] = array(
|
||||
// 'title' => 'Upgrade' // Title of TAB
|
||||
// , 'hint' => 'Upgrade to higher version' // Hint
|
||||
// //, 'page_title' => 'Upgrade' // Title of Page
|
||||
// , 'link' => 'http://server.com/' // Can be skiped, then generated link based on Page and Tab tags. Or can be extenral link
|
||||
// , 'position' => 'right' // 'left' || 'right' || ''
|
||||
// //, 'css_classes' => '' // CSS class(es)
|
||||
// //, 'icon' => '' // Icon - link to the real PNG img
|
||||
// , 'font_icon' => 'glyphicon glyphicon-shopping-cart'// CSS definition of forn Icon
|
||||
// //, 'default' => false // Is this tab activated by default or not: true || false.
|
||||
// //, 'subtabs' => array()
|
||||
//
|
||||
// );
|
||||
|
||||
$subtabs = array();
|
||||
|
||||
$subtabs['form-html-section-1'] = array( 'type' => 'html' , 'html' => '<div style="float:left;">' );
|
||||
|
||||
$subtabs['sub-toolbar'] = array(
|
||||
'type' => 'subtab' // Required| Possible values: 'subtab' | 'separator' | 'button' | 'goto-link'
|
||||
, 'title' => 'Form' // Title of TAB
|
||||
, 'page_title' => 'Form Settings' // Title of Page
|
||||
, 'hint' => 'Customization of Form Settings' // Hint
|
||||
, 'link' => '' // link
|
||||
, 'position' => '' // 'left' || 'right' || ''
|
||||
, 'css_classes' => '' // CSS class(es)
|
||||
//, 'icon' => 'https://www.paypalobjects.com/webstatic/icon/pp258.png' // Icon - link to the real PNG img
|
||||
//, 'font_icon' => 'glyphicon glyphicon-credit-card' // CSS definition of Font Icon
|
||||
, 'default' => true // Is this sub tab activated by default or not: true || false.
|
||||
, 'disabled' => false // Is this sub tab deactivated: true || false.
|
||||
, 'checkbox' => false // or definition array for specific checkbox: array( 'checked' => true, 'name' => 'feature1_active_status' )
|
||||
, 'content' => 'content' // Function to load as conten of this TAB
|
||||
);
|
||||
|
||||
$subtabs['form-separator'] = array(
|
||||
'type' => 'separator' // Required| Possible values: 'subtab' | 'separator' | 'button' | 'goto-link'
|
||||
);
|
||||
$subtabs['form-goto'] = array(
|
||||
'type' => 'goto-link' // Required| Possible values: 'subtab' | 'separator' | 'button' | 'goto-link'
|
||||
, 'title' =>ucwords( 'Form fields' ) // Title of TAB
|
||||
, 'hint' => '' // Hint
|
||||
, 'show_section' => 'id_of_show_section' // ID of HTML element, for scroll to.
|
||||
);
|
||||
|
||||
$subtabs['form-html-section-2'] = array( 'type' => 'html' , 'html' => '</div>' );
|
||||
|
||||
ob_start();
|
||||
$params = array(
|
||||
'label_for' => 'deny_reason1' // "For" parameter of label element
|
||||
//, 'label' => 'Reason:' // Label above the input group
|
||||
, 'style' => '' // CSS Style of entire div element
|
||||
, 'items' => array(
|
||||
array(
|
||||
'type' => 'addon'
|
||||
, 'element' => 'radio' // text | radio | checkbox
|
||||
, 'text' => 'Reason of cancelation' // Simple plain text showing
|
||||
, 'id' => 'radios' // ID, if this radio | checkbox element
|
||||
, 'name' => 'radioss' // Name, if this radio | checkbox element
|
||||
, 'value' => '' // value, if this radio | checkbox element
|
||||
, 'selected' => false // Selected, if this radio | checkbox element
|
||||
, 'legend' => '' // aria-label parameter , if this radio | checkbox element
|
||||
, 'class' => '' // Any CSS class here
|
||||
, 'attr' => array() // Any additional attributes, if this radio | checkbox element
|
||||
)
|
||||
, array(
|
||||
'type' => 'text'
|
||||
, 'id' => 'deny_reason' // HTML ID of element
|
||||
, 'value' => '' // Value of Text field
|
||||
, 'placeholder' => 'Reason of Cancelation'
|
||||
, 'style' => '' // CSS of select element
|
||||
, 'class' => '' // CSS Class of select element
|
||||
, 'attr' => array() // Any additional attributes, if this radio | checkbox element
|
||||
|
||||
)
|
||||
, array(
|
||||
'type' => 'button'
|
||||
, 'title' => 'Delete'
|
||||
, 'class' => 'button-secondary'
|
||||
, 'font_icon' => 'glyphicon glyphicon-trash'
|
||||
, 'icon_position' => 'right'
|
||||
, 'action' => "jQuery('#opsd_filters_formID').trigger( 'submit' );" )
|
||||
)
|
||||
);
|
||||
?><span style="float:left;margin:0 5px;"><div class="control-group opsd-no-padding"><?php // col-sm-2 col-xs-12 " ><?php
|
||||
opsd_bs_input_group( $params );
|
||||
?></div></span><?php
|
||||
|
||||
$html_element_data = ob_get_clean();
|
||||
|
||||
$subtabs['form-selection'] = array(
|
||||
'type' => 'html' // Required| Possible values: 'subtab' | 'separator' | 'button' | 'goto-link'
|
||||
, 'html' => $html_element_data
|
||||
);
|
||||
/**/
|
||||
$subtabs['form-save'] = array(
|
||||
'type' => 'button' // Required| Possible values: 'subtab' | 'separator' | 'button' | 'goto-link'
|
||||
, 'title' => 'Save Changes' // Title of TAB
|
||||
, 'form' => 'opsd_form' // Required for 'button'! Name of Form to submit
|
||||
);
|
||||
|
||||
$tabs[ 'sub-toolbar' ][ 'subtabs' ] = $subtabs;
|
||||
|
||||
return $tabs;
|
||||
}
|
||||
|
||||
|
||||
public function content() {
|
||||
debuge( 'Content <strong>' . basename(__FILE__ ) . '</strong> <span style="font-size:9px;">' . __FILE__ . '</span>');
|
||||
|
||||
|
||||
|
||||
opsd_bs_toolbar_sub_html_container_start();
|
||||
$params = array(
|
||||
'label_for' => 'deny_reason1' // "For" parameter of label element
|
||||
, 'label' => 'Reason:' // Label above the input group
|
||||
, 'style' => '' // CSS Style of entire div element
|
||||
, 'items' => array(
|
||||
array(
|
||||
'type' => 'addon'
|
||||
, 'element' => 'radio' // text | radio | checkbox
|
||||
, 'text' => 'Reason of cancelation' // Simple plain text showing
|
||||
, 'id' => 'radios' // ID, if this radio | checkbox element
|
||||
, 'name' => 'radioss' // Name, if this radio | checkbox element
|
||||
, 'value' => '' // value, if this radio | checkbox element
|
||||
, 'selected' => false // Selected, if this radio | checkbox element
|
||||
, 'legend' => '' // aria-label parameter , if this radio | checkbox element
|
||||
, 'class' => '' // Any CSS class here
|
||||
, 'attr' => array() // Any additional attributes, if this radio | checkbox element
|
||||
)
|
||||
, array(
|
||||
'type' => 'text'
|
||||
, 'id' => 'deny_reason' // HTML ID of element
|
||||
, 'value' => '' // Value of Text field
|
||||
, 'placeholder' => 'Reason of Cancelation'
|
||||
, 'style' => '' // CSS of select element
|
||||
, 'class' => '' // CSS Class of select element
|
||||
, 'attr' => array() // Any additional attributes, if this radio | checkbox element
|
||||
|
||||
)
|
||||
, array(
|
||||
'type' => 'button'
|
||||
, 'title' => 'Delete'
|
||||
, 'class' => 'button-secondary'
|
||||
, 'font_icon' => 'glyphicon glyphicon-trash'
|
||||
, 'icon_position' => 'right'
|
||||
, 'action' => "jQuery('#opsd_filters_formID').trigger( 'submit' );" )
|
||||
)
|
||||
);
|
||||
?><span class="wpdevelop"><div class="control-group opsd-no-padding"><?php // col-sm-2 col-xs-12 " ><?php
|
||||
opsd_bs_input_group( $params );
|
||||
?></div></span><?php
|
||||
opsd_bs_toolbar_sub_html_container_end();
|
||||
|
||||
}
|
||||
|
||||
|
||||
public function update() {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
add_action('opsd_menu_created', array( new OPSD_Page_SettingsFields() , '__construct') ); // Executed after creation of Menu
|
||||
@@ -0,0 +1,124 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @category Content of item Listing page
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-11-13
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
|
||||
/** Show Content
|
||||
* Update Content
|
||||
* Define Slug
|
||||
* Define where to show
|
||||
*/
|
||||
class OPSD_Page_Main extends OPSD_Page_Structure {
|
||||
|
||||
private $listing_table;
|
||||
|
||||
public function in_page() {
|
||||
return 'opsd-files';
|
||||
}
|
||||
|
||||
public function tabs() {
|
||||
|
||||
$tabs = array();
|
||||
$tabs[ 'vm_toolbar' ] = array(
|
||||
'title' => __('Item Listing', 'secure-downloads') // Title of TAB
|
||||
, 'hint' => __('Item Listing', 'secure-downloads') // Hint
|
||||
, 'page_title' => __('Item Listing', 'secure-downloads') // Title of Page
|
||||
, 'link' => '' // Can be skiped, then generated link based on Page and Tab tags. Or can be extenral link
|
||||
, 'position' => '' // 'left' || 'right' || ''
|
||||
, 'css_classes' => '' // CSS class(es)
|
||||
, 'icon' => '' // Icon - link to the real PNG img
|
||||
, 'font_icon' => 'glyphicon glyphicon-tasks' // CSS definition of forn Icon
|
||||
, 'default' => ! true // Is this tab activated by default or not: true || false.
|
||||
, 'disabled' => false // Is this tab disbaled: true || false.
|
||||
, 'hided' => !true // Is this tab hided: true || false.
|
||||
, 'subtabs' => array()
|
||||
|
||||
);
|
||||
|
||||
// $subtabs = array();
|
||||
// $tabs[ 'items' ][ 'subtabs' ] = $subtabs;
|
||||
|
||||
return $tabs;
|
||||
}
|
||||
|
||||
|
||||
public function content() {
|
||||
|
||||
opsd_check_request_paramters(); //Cleanup REQUEST parameters //FixIn:6.2.1.4
|
||||
|
||||
do_action( 'opsd_hook_opsd_page_header', array( 'page' => $this->in_page() ) ); // Define Notices Section and show some static messages, if needed.
|
||||
|
||||
?><span class="wpdevelop"><?php // BS UI CSS Class
|
||||
|
||||
make_opsd_action( 'opsd_write_content_for_modals' ); // Content for modal windows
|
||||
|
||||
opsd_js_for_items_page(); // JavaScript functions
|
||||
|
||||
make_opsd_action( 'opsd_check_request_param__wh_opsd_type' ); // Setting $_REQUEST['wh_opsd_type'] - remove empty and duplicates ID of item resources in this list
|
||||
|
||||
make_opsd_action( 'check_for_resources_of_notsuperadmin_in_opsd_listing' ); // If "Regular User", then filter resources in $_REQUEST['wh_opsd_type'] to show only resources of this user
|
||||
|
||||
|
||||
// T o o l b a r s /////////////////////////////////////////////////
|
||||
opsd_items_toolbar();
|
||||
|
||||
|
||||
?><div class="clear" style="height:40px;"></div><?php
|
||||
|
||||
$args = array( 'wh_opsd_type' => (isset( $_REQUEST[ 'wh_opsd_type' ] )) ? opsd_clean_parameter( $_REQUEST[ 'wh_opsd_type' ] ) : '' );
|
||||
echo '<textarea id="bk_request_params" style="display:none;">', serialize( $args ), '</textarea>';
|
||||
|
||||
$items = array(
|
||||
array(), array()
|
||||
);
|
||||
$opsd_types = array();
|
||||
$items_count = 100;
|
||||
$page_num = 1;
|
||||
$page_items_count= 10;
|
||||
|
||||
$this->listing_table = new OPSD_OPSD_Listing_Table( $items, $opsd_types );
|
||||
$this->listing_table->show();
|
||||
|
||||
|
||||
opsd_show_pagination($items_count, $page_num, $page_items_count); // Show Pagination
|
||||
|
||||
opsd_show_opsd_footer();
|
||||
|
||||
?></span><!-- wpdevelop class --><?php
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
add_action('opsd_menu_created', array( new OPSD_Page_Main() , '__construct') ); // Executed after creation of Menu
|
||||
|
||||
|
||||
|
||||
/** Trick here to overload default REQUST parameters before page is loading */
|
||||
function opsd_define_listing_page_parameters( $page_tag ) {
|
||||
|
||||
// $page_tag - here can be all defined in plugin menu pages
|
||||
// So we need to check activated page. By default its inside of $_GET['page'],
|
||||
|
||||
// Execute it only for item Listing admin pages.
|
||||
//if ( ( isset( $_GET[ 'page' ] ) ) && ( $_GET[ 'page' ] == 'opsd' ) ) {
|
||||
|
||||
if ( opsd_is_master_page() ) { // We are inside of this page. Menu item selected.
|
||||
// Get saved filters set, (if its not set in request yet), like "tab" & "view_mode" and overload $_REQUEST
|
||||
//$_REQUEST['view_mode'] = $opsd_default_view_mode; // Set to REQUEST
|
||||
}
|
||||
}
|
||||
// We are set 9 to execute early than hook in OPSD_Admin_Menus
|
||||
//add_action('opsd_define_nav_tabs', 'opsd_define_listing_page_parameters', 1 ); // This Hook fire in the class OPSD_Admin_Menus for showing page content of specific menu
|
||||
2
wp-content/plugins/secure-downloads/core/admin/index.php
Normal file
2
wp-content/plugins/secure-downloads/core/admin/index.php
Normal file
@@ -0,0 +1,2 @@
|
||||
<?php
|
||||
// Silence is golden.
|
||||
@@ -0,0 +1,255 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @category Admin Panel - Dashboard functions
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2016-03-16
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit, if accessed directly
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// D a s h b o a r d W i d g e t
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/** Setup Widget for Dashboard */
|
||||
function opsd_dashboard_widget_setup(){
|
||||
|
||||
// Check, if we have permission to show Widget ///////////////////////////
|
||||
$is_user_activated = apply_opsd_filter('multiuser_is_current_user_active', true ); //FixIn: 6.0.1.17
|
||||
if ( ! $is_user_activated )
|
||||
return false;
|
||||
|
||||
$user_role = get_opsd_option( 'opsd_user_role_master' );
|
||||
if ( ! opsd_is_current_user_have_this_role( $user_role ) )
|
||||
return false;
|
||||
|
||||
|
||||
// Add Secure Downloads Widget to Dashboard ///////////////////////////////
|
||||
$bk_dashboard_widget_id = 'opsd_dashboard_widget';
|
||||
wp_add_dashboard_widget( $bk_dashboard_widget_id, sprintf( __( 'Item Calendar', 'secure-downloads') ), 'opsd_dashboard_widget_show', null );
|
||||
|
||||
|
||||
// Sort Dashboard. Add Secure Downloads widget to top ///////////////////////
|
||||
global $wp_meta_boxes;
|
||||
$normal_dashboard = $wp_meta_boxes['dashboard']['normal']['core'];
|
||||
if ( isset( $normal_dashboard[$bk_dashboard_widget_id] ) ) {
|
||||
// Backup and delete our new dashbaord widget from the end of the array
|
||||
$example_widget_backup = array( $bk_dashboard_widget_id => $normal_dashboard[$bk_dashboard_widget_id] );
|
||||
unset( $normal_dashboard[$bk_dashboard_widget_id] );
|
||||
} else
|
||||
$example_widget_backup = array();
|
||||
|
||||
// Sometimes, some other plugins can modify this item, so its can be not a array
|
||||
if ( is_array( $normal_dashboard ) ) {
|
||||
// Merge the two arrays together so our widget is at the beginning
|
||||
if ( is_array( $normal_dashboard ) )
|
||||
$sorted_dashboard = array_merge( $example_widget_backup, $normal_dashboard );
|
||||
else
|
||||
$sorted_dashboard = $example_widget_backup;
|
||||
// Save the sorted array back into the original metaboxes
|
||||
$wp_meta_boxes['dashboard']['normal']['core'] = $sorted_dashboard;
|
||||
}
|
||||
}
|
||||
//add_action( 'wp_dashboard_setup', 'opsd_dashboard_widget_setup' );
|
||||
|
||||
|
||||
|
||||
/** Show item Dashboard Widget content */
|
||||
function opsd_dashboard_widget_show() {
|
||||
|
||||
opsd_dashboard_widget_css();
|
||||
|
||||
?>
|
||||
<div id="opsd_dashboard_widget_container" >
|
||||
<?php
|
||||
|
||||
opsd_dashboard_section_version();
|
||||
|
||||
opsd_dashboard_section_support();
|
||||
|
||||
?>
|
||||
</div>
|
||||
<div style="clear:both;"></div>
|
||||
<?php
|
||||
}
|
||||
|
||||
|
||||
/** Get Info for Dashboard */
|
||||
function opsd_get_dashboard_info() {
|
||||
|
||||
ob_start();
|
||||
|
||||
opsd_dashboard_widget_show();
|
||||
|
||||
return ob_get_clean();
|
||||
}
|
||||
|
||||
|
||||
/** CSS for Dashboard Widget */
|
||||
function opsd_dashboard_widget_css() {
|
||||
|
||||
?><style type="text/css">
|
||||
#opsd_dashboard_widget_container {
|
||||
width:100%;
|
||||
}
|
||||
#opsd_dashboard_widget_container .opsd_dashboard_section {
|
||||
float:left;
|
||||
margin:0px;
|
||||
padding:0px;
|
||||
width:100%;
|
||||
}
|
||||
#opsd_dashboard_widget_container .opsd_dashboard_section h4 {
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
margin: 5px 0 15px;
|
||||
}
|
||||
#bk_upgrade_section p {
|
||||
font-size: 13px;
|
||||
line-height: 1.5em;
|
||||
margin: 15px 0 0;
|
||||
padding: 0;
|
||||
}
|
||||
#dashboard-widgets-wrap #opsd_dashboard_widget_container .opsd_dashboard_section {
|
||||
width:49%;
|
||||
}
|
||||
#dashboard-widgets-wrap #opsd_dashboard_widget_container .bk_right {
|
||||
float:right
|
||||
}
|
||||
#dashboard-widgets-wrap #opsd_dashboard_widget_container .border_orrange,
|
||||
#opsd_dashboard_widget_container .border_orrange {
|
||||
background: #fffaf1 none repeat scroll 0 0;
|
||||
border-left: 3px solid #eeab26;
|
||||
clear: both;
|
||||
margin: 5px 5px 20px;
|
||||
padding: 10px 0;
|
||||
width: 99%;
|
||||
}
|
||||
#opsd_dashboard_widget_container .bk_header {
|
||||
color: #555555;
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
line-height: 1em;
|
||||
}
|
||||
#opsd_dashboard_widget_container .bk_table {
|
||||
background:transparent;
|
||||
border-bottom:none;
|
||||
border-top:1px solid #ECECEC;
|
||||
margin:6px 0 10px 6px;
|
||||
padding:2px 10px;
|
||||
width:95%;
|
||||
-border-radius:4px;
|
||||
-moz-border-radius:4px;
|
||||
-webkit-border-radius:4px;
|
||||
-moz-box-shadow:0 0 2px #C5C3C3;
|
||||
-webkit-box-shadow:0 0 2px #C5C3C3;
|
||||
-box-shadow:0 0 2px #C5C3C3;
|
||||
}
|
||||
#opsd_dashboard_widget_container .bk_table td{
|
||||
border-bottom:1px solid #DDDDDD;
|
||||
line-height:19px;
|
||||
padding:4px 0px 4px 10px;
|
||||
font-size:13px;
|
||||
}
|
||||
#opsd_dashboard_widget_container .bk_table tr td.first{
|
||||
text-align:center;
|
||||
padding:4px 0px;
|
||||
}
|
||||
#opsd_dashboard_widget_container .bk_table tr td a {
|
||||
text-decoration: none;
|
||||
}
|
||||
#opsd_dashboard_widget_container .bk_table tr td a span{
|
||||
font-size:18px;
|
||||
font-family: Georgia,"Times New Roman","Bitstream Charter",Times,serif;
|
||||
}
|
||||
#opsd_dashboard_widget_container .bk_table td.bk_spec_font a{
|
||||
font-family: Georgia,"Times New Roman","Bitstream Charter",Times,serif;
|
||||
font-size:14px;
|
||||
}
|
||||
#opsd_dashboard_widget_container .bk_table td.bk_spec_font {
|
||||
font-family: Georgia,"Times New Roman","Bitstream Charter",Times,serif;
|
||||
font-size:13px;
|
||||
}
|
||||
#opsd_dashboard_widget_container .bk_table td.pending a{
|
||||
color:#E66F00;
|
||||
}
|
||||
#opsd_dashboard_widget_container .bk_table td.new-items a{
|
||||
color:red;
|
||||
}
|
||||
#opsd_dashboard_widget_container .bk_table td.actual-items a{
|
||||
color:green;
|
||||
}
|
||||
#bk_errror_loading {
|
||||
text-align: center;
|
||||
font-style: italic;
|
||||
font-size:11px;
|
||||
}
|
||||
</style><?php
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// S e c t i o n s
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/** Dashboard Support Section */
|
||||
function opsd_dashboard_section_support() {
|
||||
?>
|
||||
<div class="opsd_dashboard_section bk_right">
|
||||
<span class="bk_header"><?php _e('Support' , 'secure-downloads');?>:</span>
|
||||
<table class="bk_table">
|
||||
<tr>
|
||||
<td style="text-align:center;" class="bk_spec_font"><a target="_blank" href="https://oplugins.com/plugins/secure-downloads/"><?php _e('Help Info' , 'secure-downloads');?></a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align:center;" class="bk_spec_font"><a href="mailto:support@oplugins.com"><?php _e('Contact Support' , 'secure-downloads');?></a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align:center;" class="bk_spec_font"><?php
|
||||
printf( __( '%sNew feature suggestion%s', 'secure-downloads'),
|
||||
'<a href="mailto:newfeature@oplugins.com?Subject=Secure%20Downloads" target="_blank">',
|
||||
'</a>' ); ?></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
|
||||
|
||||
/** Dashboard Version Section */
|
||||
function opsd_dashboard_section_version() {
|
||||
|
||||
$version = 'free';
|
||||
|
||||
?>
|
||||
<div class="opsd_dashboard_section" >
|
||||
<span class="bk_header"><?php _e('Current version' , 'secure-downloads');?>:</span>
|
||||
<table class="bk_table">
|
||||
<tr class="first">
|
||||
<td style="width:35%;text-align: right;;" class=""><?php _e('Version' , 'secure-downloads');?>:</td>
|
||||
<td style="color: #e50;font-size: 13px;font-weight: 600;text-align: left;text-shadow: 0 -1px 0 #eee;;"
|
||||
class="bk_spec_font"><?php
|
||||
if ( substr( OPSD_VERSION, 0, 2 ) == '9.' ) {
|
||||
$show_version = substr( OPSD_VERSION , 2 ) ;
|
||||
if ( substr($show_version, ( -1 * ( strlen( OPSD_VERSION_NUM ) ) ) ) === OPSD_VERSION_NUM ) {
|
||||
$show_version = substr($show_version, 0, ( -1 * ( strlen( OPSD_VERSION_NUM ) ) - 1 ) );
|
||||
$show_version = str_replace('.', ' ', $show_version) . " <sup><strong style='font-size:12px;'>" . OPSD_VERSION_NUM . "</strong></sup>" ;
|
||||
}
|
||||
echo $show_version ;
|
||||
} else
|
||||
echo OPSD_VERSION;
|
||||
?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="width:35%;text-align: right;" class="first b"><?php _e('Release date' , 'secure-downloads');?>:</td>
|
||||
<td style="text-align: left; font-weight: 600;" class="bk_spec_font"><?php echo date ("d.m.Y", filemtime(OPSD_FILE)); ?></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
1583
wp-content/plugins/secure-downloads/core/admin/opsd-toolbars.php
Normal file
1583
wp-content/plugins/secure-downloads/core/admin/opsd-toolbars.php
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,963 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package Content
|
||||
* @category Menu
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-04-09
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
/** Replace:
|
||||
1. DownloadNotification -> DownloadNotification
|
||||
2. DOWNLOAD_NOTIFICATION -> DOWNLOAD_NOTIFICATION
|
||||
3. download_notification -> download_notification
|
||||
4. Check in api-emails.php 'db_prefix_option' => '...' option, have to be the same as OPSD_EMAIL_DOWNLOAD_NOTIFICATION_PREFIX here
|
||||
5. Configure Fields in init_settings_fields.
|
||||
*/
|
||||
|
||||
if ( ! defined( 'OPSD_EMAIL_DOWNLOAD_NOTIFICATION_PREFIX' ) ) define( 'OPSD_EMAIL_DOWNLOAD_NOTIFICATION_PREFIX', 'opsd_email_' ); // Its defined in api-emails.php file & its same for all emails, here its used only for easy coding...
|
||||
|
||||
if ( ! defined( 'OPSD_EMAIL_DOWNLOAD_NOTIFICATION_ID' ) ) define( 'OPSD_EMAIL_DOWNLOAD_NOTIFICATION_ID', 'download_notification' ); /* Define Name of Email Template.
|
||||
Note. Prefix "opsd_email_" defined in api-emails.php file.
|
||||
Full name of option is - "opsd_email_download_notification"
|
||||
Other email templates names:
|
||||
- 'download_notification' - send email with download link to user
|
||||
- 'link_admin' - send copy of email to admin with download link
|
||||
- 'download_admin' - send email about downloads happend
|
||||
*/
|
||||
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/any/api-emails.php' ); // API
|
||||
|
||||
|
||||
/** Email F i e l d s */
|
||||
class OPSD_Emails_API_DownloadNotification extends OPSD_Emails_API { // O v e r r i d i n g "OPSD_Emails_API" ClASS
|
||||
|
||||
/** Overrided functions - define Email Fields & Values */
|
||||
public function init_settings_fields() {
|
||||
|
||||
$this->fields = array();
|
||||
|
||||
$this->fields['enabled'] = array(
|
||||
'type' => 'checkbox'
|
||||
, 'default' => 'On'
|
||||
, 'title' => __('Enable / Disable', 'secure-downloads')
|
||||
, 'label' => __('Enable this email notification', 'secure-downloads')
|
||||
, 'description' => ''
|
||||
, 'group' => 'general'
|
||||
|
||||
);
|
||||
/*
|
||||
$this->fields['copy_to_admin'] = array(
|
||||
'type' => 'checkbox'
|
||||
, 'default' => 'On'
|
||||
, 'title' => __('Copy to admin', 'secure-downloads')
|
||||
, 'label' => __('Enable / disable sending copy of this email notification to admin', 'secure-downloads')
|
||||
, 'description' => ''
|
||||
, 'group' => 'general'
|
||||
|
||||
);
|
||||
*/
|
||||
$this->fields['enabled_hr'] = array( 'type' => 'hr' );
|
||||
|
||||
$this->fields['to_html_prefix'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'general'
|
||||
, 'html' => '<tr valign="top">
|
||||
<th scope="row">
|
||||
<label class="opsd-form-email" for="'
|
||||
. esc_attr( 'download_notification_to' )
|
||||
. '">' . wp_kses_post( __('To' , 'secure-downloads') )
|
||||
. '</label>
|
||||
</th>
|
||||
<td><fieldset style="float:left;width:50%;margin-right:5%;">'
|
||||
);
|
||||
$this->fields['to'] = array(
|
||||
'type' => 'text' // We are using here 'text' and not 'email', for ability to save several comma seperated emails.
|
||||
, 'default' => get_option( 'admin_email' )
|
||||
//, 'placeholder' => ''
|
||||
, 'title' => ''
|
||||
, 'description' => __('Email Address', 'secure-downloads') . '. ' . __('Required', 'secure-downloads') . '.'
|
||||
, 'description_tag' => ''
|
||||
, 'css' => 'width:100%'
|
||||
, 'group' => 'general'
|
||||
, 'tr_class' => ''
|
||||
, 'only_field' => true
|
||||
, 'validate_as' => array( 'required' )
|
||||
);
|
||||
$this->fields['to_html_middle'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'general'
|
||||
, 'html' => '</fieldset><fieldset style="float:left;width:45%;">'
|
||||
);
|
||||
|
||||
$user_info = array( 'name' => '' );
|
||||
if ( is_user_logged_in() ) {
|
||||
$user_data = get_userdata( get_current_user_id() );
|
||||
$user_info['name'] = ( $user_data ) ? $user_data->display_name : '';
|
||||
}
|
||||
|
||||
$this->fields['to_name'] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => $user_info['name']
|
||||
//, 'placeholder' => ''
|
||||
, 'title' => ''
|
||||
, 'description' => __('Title', 'secure-downloads') . ' (' . __('optional', 'secure-downloads') . ').' //. ' ' . __('If empty then title defined as WordPress', 'secure-downloads')
|
||||
, 'description_tag' => ''
|
||||
, 'css' => 'width:100%'
|
||||
, 'group' => 'general'
|
||||
, 'tr_class' => ''
|
||||
, 'only_field' => true
|
||||
);
|
||||
$this->fields['to_html_sufix'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'general'
|
||||
, 'html' => ' </fieldset>
|
||||
</td>
|
||||
</tr>'
|
||||
);
|
||||
|
||||
|
||||
|
||||
$this->fields['from_html_prefix'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'general'
|
||||
, 'html' => '<tr valign="top">
|
||||
<th scope="row">
|
||||
<label class="opsd-form-email" for="'
|
||||
. esc_attr( 'download_notification_from' )
|
||||
. '">' . wp_kses_post( __('From' , 'secure-downloads') )
|
||||
. '</label>
|
||||
</th>
|
||||
<td><fieldset style="float:left;width:50%;margin-right:5%;">'
|
||||
);
|
||||
$this->fields['from'] = array(
|
||||
'type' => 'email' // Its can be only 1 email, so check it as Email field.
|
||||
, 'default' => get_option( 'admin_email' )
|
||||
//, 'placeholder' => ''
|
||||
, 'title' => ''
|
||||
, 'description' => __('Email Address', 'secure-downloads') . '. ' . __('Required', 'secure-downloads') . '.'
|
||||
, 'description_tag' => ''
|
||||
, 'css' => 'width:100%'
|
||||
, 'group' => 'general'
|
||||
, 'tr_class' => ''
|
||||
, 'only_field' => true
|
||||
, 'validate_as' => array( 'required' )
|
||||
);
|
||||
$this->fields['from_html_middle'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'general'
|
||||
, 'html' => '</fieldset><fieldset style="float:left;width:45%;">'
|
||||
);
|
||||
$this->fields['from_name'] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => $user_info['name']
|
||||
//, 'placeholder' => ''
|
||||
, 'title' => ''
|
||||
, 'description' => __('Title', 'secure-downloads') . ' (' . __('optional', 'secure-downloads') . ').' //. ' ' . __('If empty then title defined as WordPress', 'secure-downloads')
|
||||
, 'description_tag' => ''
|
||||
, 'css' => 'width:100%'
|
||||
, 'group' => 'general'
|
||||
, 'tr_class' => ''
|
||||
, 'only_field' => true
|
||||
);
|
||||
$this->fields['from_html_sufix'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'general'
|
||||
, 'html' => ' </fieldset>
|
||||
</td>
|
||||
</tr>'
|
||||
);
|
||||
|
||||
$this->fields['from_hr'] = array( 'type' => 'hr' );
|
||||
|
||||
|
||||
$this->fields['subject'] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => sprintf( __( 'Download notification of %s', 'secure-downloads'), '[product_title] [ [product_id] ]' )
|
||||
//, 'placeholder' => ''
|
||||
, 'title' => __('Subject', 'secure-downloads')
|
||||
, 'description' => sprintf(__('Type your email %ssubject%s.' , 'secure-downloads'),'<b>','</b>') . ' ' . __('Required', 'secure-downloads') . '.'
|
||||
, 'description_tag' => ''
|
||||
, 'css' => 'width:100%'
|
||||
, 'group' => 'general'
|
||||
, 'tr_class' => ''
|
||||
, 'validate_as' => array( 'required' )
|
||||
);
|
||||
|
||||
$blg_title = get_option( 'blogname' );
|
||||
$blg_title = str_replace( array( '"', "'" ), '', $blg_title );
|
||||
|
||||
$this->fields['content'] = array(
|
||||
'type' => 'wp_textarea'
|
||||
, 'default' =>
|
||||
// sprintf( __( 'Hello.%sThe %s have been downloaded at %s from IP: %s~ Download link of %s will expire in %s === User info ===%s User agent: %s IP: %s Request url: %s ======================%s === Product Summary ===%s %s ======================%s Thank you, %s', 'secure-downloads' )
|
||||
// , '<br/><br/>'
|
||||
// , '[product_title] [ [product_id] ]'
|
||||
// , '[current_date] [current_time]'
|
||||
// , '[remote_ip]' . '<br/><br/>'
|
||||
// , '[product_filename] ([product_size])'
|
||||
// , '[product_expire_after] - [product_expire_date]' . '<br/><br/>'
|
||||
// , '<br/>'
|
||||
// , '[user_agent]' . '<br/>', '[remote_ip]' . '<br/>', '[request_url]' . '<br/>'
|
||||
// , '<br/><br/>'
|
||||
// , '<br/>'
|
||||
// , '[product_summary]<br/>[product_description]<br/>[product_link]<br/>'
|
||||
// , '<br/><br/>'
|
||||
// , $blg_title . '<br/>' . '[siteurl]'
|
||||
// )
|
||||
sprintf( __( 'Hi. %s The %s have been downloaded. %s ===== User Info ===== %s To: %s IP: %s User agent: %s Request url: %s ====================== %s ===== Product Summary ===== %s Expire at %s ====================== %s', 'secure-downloads' )
|
||||
, '<br/><br/>'
|
||||
, '<strong>[product_title] [product_version]</strong> [ID=[product_id]]'
|
||||
, '<br/><br/>'
|
||||
, '<br/>'
|
||||
, '[link_sent_to]' . '<br/>'
|
||||
, '[remote_ip]' . '<br/>'
|
||||
, '[user_agent]' . '<br/>'
|
||||
, '[request_url]' . '<br/>'
|
||||
, '<br/><br/>'
|
||||
, '<br/>[product_summary] <br/>[product_description] <br/>'
|
||||
, '<strong>[product_expire_date]</strong> '. '<br/>'
|
||||
, '<br/> <br/><strong>[current_date] [current_time]</strong>'
|
||||
)
|
||||
//, 'placeholder' => ''
|
||||
, 'title' => __('Content', 'secure-downloads')
|
||||
, 'description' => __('Type your email message content.', 'secure-downloads')
|
||||
, 'description_tag' => ''
|
||||
, 'css' => ''
|
||||
, 'group' => 'general'
|
||||
, 'tr_class' => ''
|
||||
, 'rows' => 10
|
||||
, 'show_in_2_cols' => true
|
||||
);
|
||||
// $this->fields['content'] = htmlspecialchars( $this->fields['content'] );// Convert > to >
|
||||
// $this->fields['content'] = html_entity_decode( $this->fields['content'] );// Convert > to >
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////
|
||||
// Style
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
$this->fields['header_content'] = array(
|
||||
'type' => 'textarea'
|
||||
, 'default' => ''
|
||||
, 'title' => __('Email Heading', 'secure-downloads')
|
||||
, 'description' => __('Enter main heading contained within the email notification.', 'secure-downloads')
|
||||
//, 'placeholder' => ''
|
||||
, 'rows' => 2
|
||||
, 'css' => "width:100%;"
|
||||
, 'group' => 'parts'
|
||||
);
|
||||
$this->fields['footer_content'] = array(
|
||||
'type' => 'textarea'
|
||||
, 'default' => ''
|
||||
, 'title' => __('Email Footer Text', 'secure-downloads')
|
||||
, 'description' => __('Enter text contained within footer of the email notification', 'secure-downloads')
|
||||
//, 'placeholder' => ''
|
||||
, 'rows' => 2
|
||||
, 'css' => 'width:100%;'
|
||||
, 'group' => 'parts'
|
||||
);
|
||||
|
||||
$this->fields['template_file'] = array(
|
||||
'type' => 'select'
|
||||
, 'default' => 'plain'
|
||||
, 'title' => __('Email template', 'secure-downloads')
|
||||
, 'description' => __('Choose email template.', 'secure-downloads')
|
||||
, 'description_tag' => 'span'
|
||||
, 'css' => ''
|
||||
, 'options' => array(
|
||||
'plain' => __('Plain (without styles)', 'secure-downloads')
|
||||
, 'standard' => __('Standard 1 column', 'secure-downloads')
|
||||
)
|
||||
, 'group' => 'style'
|
||||
);
|
||||
|
||||
$this->fields['template_file_help'] = array(
|
||||
'type' => 'help'
|
||||
, 'value' => array( sprintf( __('You can override this email template in this folder %s', 'secure-downloads')
|
||||
, '<code>' . realpath( dirname(__FILE__) . '/../any/emails_tpl/' ) . '</code>' )
|
||||
)
|
||||
, 'cols' => 2
|
||||
, 'group' => 'style'
|
||||
);
|
||||
|
||||
$this->fields['base_color'] = array(
|
||||
'type' => 'color'
|
||||
, 'default' => '#557da1'
|
||||
, 'title' => __('Base Color', 'secure-downloads')
|
||||
, 'description' => __('The base color for email templates.', 'secure-downloads')
|
||||
. ' ' . __('Default color', 'secure-downloads') .': <code>#557da1</code>.'
|
||||
, 'group' => 'style'
|
||||
, 'tr_class' => 'template_colors'
|
||||
);
|
||||
$this->fields['background_color'] = array(
|
||||
'type' => 'color'
|
||||
, 'default' => '#f5f5f5'
|
||||
, 'title' => __('Background Color', 'secure-downloads')
|
||||
, 'description' => __('The background color for email templates.', 'secure-downloads')
|
||||
. ' ' . __('Default color', 'secure-downloads') .': <code>#f5f5f5</code>.'
|
||||
, 'group' => 'style'
|
||||
, 'tr_class' => 'template_colors'
|
||||
);
|
||||
$this->fields['body_color'] = array(
|
||||
'type' => 'color'
|
||||
, 'default' => '#fdfdfd'
|
||||
, 'title' => __('Email Body Background Color', 'secure-downloads')
|
||||
, 'description' => __('The main body background color for email templates.', 'secure-downloads')
|
||||
. ' ' . __('Default color', 'secure-downloads') .': <code>#fdfdfd</code>.'
|
||||
, 'group' => 'style'
|
||||
, 'tr_class' => 'template_colors'
|
||||
);
|
||||
$this->fields['text_color'] = array(
|
||||
'type' => 'color'
|
||||
, 'default' => '#505050'
|
||||
, 'title' => __('Email Body Text Colour', 'secure-downloads')
|
||||
, 'description' => __('The main body text color for email templates.', 'secure-downloads')
|
||||
. ' ' . __('Default color', 'secure-downloads') .': <code>#505050</code>.'
|
||||
, 'group' => 'style'
|
||||
, 'tr_class' => 'template_colors'
|
||||
);
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////
|
||||
// Email format: Plain, HTML, MultiPart
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
$this->fields['email_content_type'] = array(
|
||||
'type' => 'select'
|
||||
, 'default' => 'plain'
|
||||
, 'title' => __('Email format', 'secure-downloads')
|
||||
, 'description' => __('Choose which format of email to send.', 'secure-downloads')
|
||||
, 'description_tag' => 'p'
|
||||
, 'css' => 'width:100%;'
|
||||
, 'options' => array(
|
||||
'plain' => __('Plain text', 'secure-downloads')
|
||||
// , 'html' => __('HTML', 'secure-downloads')
|
||||
// , 'multipart' => __('Multipart', 'secure-downloads')
|
||||
)
|
||||
, 'group' => 'email_content_type'
|
||||
);
|
||||
if ( class_exists( 'DOMDocument' ) ) {
|
||||
$this->fields['email_content_type']['options']['html'] = __('HTML', 'secure-downloads');
|
||||
$this->fields['email_content_type']['options']['multipart'] = __('Multipart', 'secure-downloads');
|
||||
|
||||
$this->fields['email_content_type']['default'] = 'html';
|
||||
}
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////
|
||||
// Help
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
||||
$this->fields['content_help'] = array(
|
||||
'type' => 'help'
|
||||
, 'value' => array()
|
||||
, 'cols' => 2
|
||||
, 'group' => 'help'
|
||||
);
|
||||
|
||||
$skip_shortcodes = array(
|
||||
'denyreason'
|
||||
, 'paymentreason'
|
||||
, 'visitorediturl'
|
||||
, 'visitorcancelurl'
|
||||
, 'visitorpayurl'
|
||||
);
|
||||
$email_example = sprintf(__('For example: "You have a new reservation %s on the following date(s): %s Contact information: %s You can approve or cancel this item at: %s Thank you, Reservation service."' , 'secure-downloads'),'','[dates]<br/><br/>','<br/> [content]<br/><br/>', htmlentities( ' <a href="[moderatelink]">'.__('here' , 'secure-downloads').'</a> ') . '<br/><br/> ');
|
||||
|
||||
$help_fields = opsd_get_email_help_shortcodes( $skip_shortcodes, $email_example );
|
||||
|
||||
foreach ( $help_fields as $help_fields_key => $help_fields_value ) {
|
||||
$this->fields['content_help']['value'][] = $help_fields_value;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** Settings Emails P a g e */
|
||||
class OPSD_Settings_Page_Email_DownloadNotification extends OPSD_Page_Structure {
|
||||
|
||||
public $email_settings_api = false;
|
||||
|
||||
|
||||
/** Define interface for Email API
|
||||
*
|
||||
* @param string $selected_email_name - name of Email template
|
||||
* @param array $init_fields_values - array of init form fields data
|
||||
* @return object Email API
|
||||
*/
|
||||
public function mail_api( $selected_email_name ='', $init_fields_values = array() ){
|
||||
|
||||
if ( $this->email_settings_api === false ) {
|
||||
$this->email_settings_api = new OPSD_Emails_API_DownloadNotification( $selected_email_name , $init_fields_values );
|
||||
}
|
||||
|
||||
return $this->email_settings_api;
|
||||
}
|
||||
|
||||
|
||||
public function in_page() { // P a g e t a g
|
||||
return 'opsd-settings';
|
||||
}
|
||||
|
||||
|
||||
public function tabs() { // T a b s A r r a y
|
||||
|
||||
$tabs = array();
|
||||
|
||||
$tabs[ 'email' ] = array(
|
||||
'title' => __( 'Emails', 'secure-downloads') // Title of TAB
|
||||
, 'page_title'=> __( 'Emails Settings', 'secure-downloads') // Title of Page
|
||||
, 'hint' => __( 'Emails Settings', 'secure-downloads') // Hint
|
||||
//, 'link' => '' // Can be skiped, then generated link based on Page and Tab tags. Or can be extenral link
|
||||
//, 'position' => '' // 'left' || 'right' || ''
|
||||
//, 'css_classes'=> '' // CSS class(es)
|
||||
//, 'icon' => '' // Icon - link to the real PNG img
|
||||
, 'font_icon' => 'glyphicon glyphicon-envelope' // CSS definition of forn Icon
|
||||
//, 'default' => false // Is this tab activated by default or not: true || false.
|
||||
//, 'disabled' => false // Is this tab disbaled: true || false.
|
||||
//, 'hided' => false // Is this tab hided: true || false.
|
||||
, 'subtabs' => array()
|
||||
);
|
||||
|
||||
$subtabs = array();
|
||||
|
||||
|
||||
$is_data_exist = get_opsd_option( OPSD_EMAIL_DOWNLOAD_NOTIFICATION_PREFIX . OPSD_EMAIL_DOWNLOAD_NOTIFICATION_ID ); // ''opsd_email_' - defined in api-emails.php file.
|
||||
if ( ( ! empty( $is_data_exist ) ) && ( isset( $is_data_exist['enabled'] ) ) && ( $is_data_exist['enabled'] == 'On' ) )
|
||||
$icon = '<i class="menu_icon icon-1x glyphicon glyphicon-check"></i> ';
|
||||
else
|
||||
$icon = '<i class="menu_icon icon-1x glyphicon glyphicon-unchecked"></i> ';
|
||||
|
||||
$subtabs['download-notification'] = array(
|
||||
'type' => 'subtab' // Required| Possible values: 'subtab' | 'separator' | 'button' | 'goto-link' | 'html'
|
||||
, 'title' => $icon . __('Download Notification' , 'secure-downloads') // Title of TAB
|
||||
, 'page_title' => __('Emails Settings', 'secure-downloads') // Title of Page
|
||||
, 'hint' => __('Email about download notification, which is sending to admin' , 'secure-downloads') // Hint
|
||||
, 'link' => '' // link
|
||||
, 'position' => '' // 'left' || 'right' || ''
|
||||
, 'css_classes' => '' // CSS class(es)
|
||||
//, 'icon' => 'http://.../icon.png' // Icon - link to the real PNG img
|
||||
//, 'font_icon' => 'glyphicon glyphicon-envelope' // CSS definition of Font Icon
|
||||
, 'default' => ! true // Is this sub tab activated by default or not: true || false.
|
||||
, 'disabled' => false // Is this sub tab deactivated: true || false.
|
||||
, 'checkbox' => false // or definition array for specific checkbox: array( 'checked' => true, 'name' => 'feature1_active_status' ) //, 'checkbox' => array( 'checked' => $is_checked, 'name' => 'enabled_active_status' )
|
||||
, 'content' => 'content' // Function to load as conten of this TAB
|
||||
);
|
||||
|
||||
$tabs[ 'email' ]['subtabs'] = $subtabs;
|
||||
|
||||
return $tabs;
|
||||
}
|
||||
|
||||
|
||||
/** Show Content of Settings page */
|
||||
public function content() {
|
||||
//debuge( 'OPSD_EMAIL_DOWNLOAD_NOTIFICATION_PREFIX . OPSD_EMAIL_DOWNLOAD_NOTIFICATION_ID, get_opsd_option( OPSD_EMAIL_DOWNLOAD_NOTIFICATION_PREFIX . OPSD_EMAIL_DOWNLOAD_NOTIFICATION_ID )', OPSD_EMAIL_DOWNLOAD_NOTIFICATION_PREFIX . OPSD_EMAIL_DOWNLOAD_NOTIFICATION_ID, get_opsd_option( OPSD_EMAIL_DOWNLOAD_NOTIFICATION_PREFIX . OPSD_EMAIL_DOWNLOAD_NOTIFICATION_ID ) );
|
||||
|
||||
$this->css();
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Checking
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
do_action( 'opsd_hook_settings_page_header', array( 'page' => $this->in_page(), 'subpage' => 'emails_settings' ) ); // Define Notices Section and show some static messages, if needed.
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Load Data
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/** Its will load DATA from DB, during creattion mail_api CLASS
|
||||
* during initial activation of the API its try to get option from DB
|
||||
* We need to define this API before checking POST, to know all available fields
|
||||
* Define Email Name & define field values from DB, if not exist, then default values.
|
||||
Array (
|
||||
[opsd_email_download_notification] => Array
|
||||
(
|
||||
[enabled] => On
|
||||
[to] => beta@oplugins.com
|
||||
[to_name] => Some Name
|
||||
[from] => admin@oplugins.com
|
||||
[from_name] =>
|
||||
[subject] => New item
|
||||
[content] => You need to approve [shortcodetype] for: ...
|
||||
[header_content] =>
|
||||
[footer_content] =>
|
||||
[template_file] => plain
|
||||
[base_color] => #557da1
|
||||
[background_color] => #f5f5f5
|
||||
[body_color] => #fdfdfd
|
||||
[text_color] => #505050
|
||||
[email_content_type] => html
|
||||
)
|
||||
)
|
||||
|
||||
// $mail_api->save_to_db( $fields_values );
|
||||
*/
|
||||
$init_fields_values = array();
|
||||
|
||||
$this->mail_api( OPSD_EMAIL_DOWNLOAD_NOTIFICATION_ID, $init_fields_values );
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// S u b m i t Actions - S e n d
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
$submit_form_name_action = 'opsd_form_action'; // Define form name
|
||||
if ( isset( $_POST['is_form_sbmitted_'. $submit_form_name_action ] ) ) {
|
||||
|
||||
// Nonce checking {Return false if invalid, 1 if generated between, 0-12 hours ago, 2 if generated between 12-24 hours ago. }
|
||||
$nonce_gen_time = check_admin_referer( 'opsd_settings_page_' . $submit_form_name_action ); // Its stop show anything on submiting, if its not refear to the original page
|
||||
|
||||
// Save Changes
|
||||
$this->update_actions();
|
||||
}
|
||||
?>
|
||||
<form name="<?php echo $submit_form_name_action; ?>" id="<?php echo $submit_form_name_action; ?>" action="" method="post" autocomplete="off">
|
||||
<?php
|
||||
// N o n c e field, and key for checking S u b m i t
|
||||
wp_nonce_field( 'opsd_settings_page_' . $submit_form_name_action );
|
||||
?><input type="hidden" name="is_form_sbmitted_<?php echo $submit_form_name_action; ?>" id="is_form_sbmitted_<?php echo $submit_form_name_action; ?>" value="1" />
|
||||
<input type="hidden" name="form_action" id="form_action" value="" />
|
||||
</form>
|
||||
<?php
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// S u b m i t Main Form
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
$submit_form_name = 'opsd_emails_template'; // Define form name
|
||||
|
||||
$this->mail_api()->validated_form_id = $submit_form_name; // Define ID of Form for ability to validate fields before submit.
|
||||
|
||||
if ( isset( $_POST['is_form_sbmitted_'. $submit_form_name ] ) ) {
|
||||
|
||||
// Nonce checking {Return false if invalid, 1 if generated between, 0-12 hours ago, 2 if generated between 12-24 hours ago. }
|
||||
$nonce_gen_time = check_admin_referer( 'opsd_settings_page_' . $submit_form_name ); // Its stop show anything on submiting, if its not refear to the original page
|
||||
|
||||
// Save Changes
|
||||
$this->update();
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// JavaScript: Tooltips, Popover, Datepick (js & css)
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
echo '<span class="wpdevelop">';
|
||||
|
||||
opsd_js_for_items_page();
|
||||
|
||||
echo '</span>';
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Content
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
?>
|
||||
<div class="clear" style="margin-bottom:10px;"></div>
|
||||
|
||||
<span class="metabox-holder">
|
||||
|
||||
<form name="<?php echo $submit_form_name; ?>" id="<?php echo $submit_form_name; ?>" action="" method="post" autocomplete="off">
|
||||
<?php
|
||||
// N o n c e field, and key for checking S u b m i t
|
||||
wp_nonce_field( 'opsd_settings_page_' . $submit_form_name );
|
||||
?><input type="hidden" name="is_form_sbmitted_<?php echo $submit_form_name; ?>" id="is_form_sbmitted_<?php echo $submit_form_name; ?>" value="1" />
|
||||
|
||||
|
||||
<div class="clear"></div>
|
||||
<div class="metabox-holder">
|
||||
|
||||
<div class="opsd_settings_row opsd_settings_row_left" >
|
||||
<?php
|
||||
|
||||
opsd_open_meta_box_section( $submit_form_name . 'general', __('Email about download notification, which is sending to admin', 'secure-downloads') );
|
||||
|
||||
$this->mail_api()->show( 'general' );
|
||||
|
||||
opsd_close_meta_box_section();
|
||||
|
||||
|
||||
opsd_open_meta_box_section( $submit_form_name . 'parts' , __('Header / Footer', 'secure-downloads') );
|
||||
|
||||
$this->mail_api()->show( 'parts' );
|
||||
|
||||
opsd_close_meta_box_section();
|
||||
|
||||
|
||||
opsd_open_meta_box_section( $submit_form_name . 'style' , __('Email Styles', 'secure-downloads') );
|
||||
|
||||
$this->mail_api()->show( 'style' );
|
||||
|
||||
opsd_close_meta_box_section();
|
||||
|
||||
?>
|
||||
</div>
|
||||
|
||||
<div class="opsd_settings_row opsd_settings_row_right">
|
||||
<?php
|
||||
|
||||
opsd_open_meta_box_section( $submit_form_name . 'actions', __('Actions', 'secure-downloads') );
|
||||
|
||||
?><a class="button button-secondary" style="margin:0 0 5px;" href="javascript:void(0)"
|
||||
onclick="javascript: jQuery('#form_action').val('test_send'); jQuery('form#<?php echo $submit_form_name_action; ?>').trigger( 'submit' );"
|
||||
><?php _e('Send Test Email', 'secure-downloads'); ?></a><?php
|
||||
|
||||
?><input type="submit" value="<?php _e('Save Changes', 'secure-downloads'); ?>" class="button button-primary right" style="margin:0 0 5px 5px;" /><?php
|
||||
|
||||
/* ?>
|
||||
<a class="button button-secondary" href="javascript:void(0)" ><?php _e('Preview Email', 'secure-downloads'); ?></a>
|
||||
<hr />
|
||||
<a class="button button-secondary right"
|
||||
href="javascript:void(0)"
|
||||
onclick="javascript: if ( opsd_are_you_sure('<?php echo esc_js(__('Do you really want to delete this item?', 'secure-downloads')); ?>') ){
|
||||
jQuery('#form_action').val('delete');
|
||||
jQuery('form#<?php echo $submit_form_name_action; ?>').trigger( 'submit' );
|
||||
}"
|
||||
><?php _e('Delete Email', 'secure-downloads'); ?></a>
|
||||
<?php */
|
||||
|
||||
?><div class="clear"></div><?php
|
||||
|
||||
opsd_close_meta_box_section();
|
||||
|
||||
opsd_open_meta_box_section( $submit_form_name . 'email_content_type', __('Type', 'secure-downloads') );
|
||||
|
||||
$this->mail_api()->show( 'email_content_type' );
|
||||
|
||||
opsd_close_meta_box_section();
|
||||
|
||||
|
||||
opsd_open_meta_box_section( $submit_form_name . 'help', __('Help', 'secure-downloads') );
|
||||
|
||||
$this->mail_api()->show( 'help' );
|
||||
|
||||
opsd_close_meta_box_section();
|
||||
|
||||
?>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</div>
|
||||
|
||||
<input type="submit" value="<?php _e('Save Changes', 'secure-downloads'); ?>" class="button button-primary" />
|
||||
</form>
|
||||
</span>
|
||||
<?php
|
||||
|
||||
$this->enqueue_js();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Update form from Toolbar - create / delete/ load email templates
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function update_actions( ) {
|
||||
|
||||
|
||||
if ( $_POST['form_action'] == 'test_send' ) { // Sending test email
|
||||
|
||||
/*
|
||||
$this->email_settings_api = false;
|
||||
$selected_email_name = 'standard';
|
||||
$email_fields = get_opsd_option( 'opsd_email_' . $selected_email_name );
|
||||
$this->mail_api( $selected_email_name, $email_fields );
|
||||
*/
|
||||
|
||||
|
||||
//$to = sanitize_email( $this->mail_api()->fields_values['to'] );
|
||||
$replace = array ();
|
||||
$replace[ 'product_id' ] = '<strong>99</strong>';
|
||||
$replace[ 'product_title' ] = '<strong>Product ZZZ</strong>';
|
||||
$replace[ 'product_version' ] = '<strong>1.0</strong>';
|
||||
$replace[ 'product_description' ] = 'Product ZZZ Info';
|
||||
$replace[ 'product_filename' ] = 'zzz_product.zip';
|
||||
$replace[ 'product_link' ] = home_url();
|
||||
$replace[ 'product_size' ] = '3 Mb';
|
||||
$replace[ 'product_expire_after' ] = '1 day';
|
||||
$replace[ 'product_expire_date' ] = date_i18n( get_opsd_option( 'opsd_date_format' ) . ' ' . get_opsd_option( 'opsd_time_format' ), strtotime( '+1 day' ) );
|
||||
$replace[ 'product_summary' ] = '<a href="">' . $replace[ 'product_filename' ] . '</a> (' . $replace[ 'product_size' ] . ') ~ expire in ' . $replace[ 'product_expire_after' ];
|
||||
|
||||
$replace[ 'link_sent_to' ] = $this->mail_api()->get_from__email_address();
|
||||
|
||||
$replace[ 'siteurl' ] = htmlspecialchars_decode( '<a href="' . home_url() . '">' . home_url() . '</a>' );
|
||||
$replace[ 'remote_ip' ] = opsd_get_user_ip(); // The IP address from which the user is viewing the current page.
|
||||
$replace[ 'user_agent' ] = $_SERVER[ 'HTTP_USER_AGENT' ]; // Contents of the User-Agent: header from the current request, if there is one.
|
||||
$replace[ 'request_url' ] = $_SERVER[ 'HTTP_REFERER' ]; // The address of the page (if any) where action was occured. Because we are sending it in Ajax request, we need to use the REFERER HTTP
|
||||
$replace[ 'current_date' ] = date_i18n( get_opsd_option( 'opsd_date_format' ) );
|
||||
$replace[ 'current_time' ] = date_i18n( get_opsd_option( 'opsd_time_format' ) );
|
||||
|
||||
|
||||
$to = $this->mail_api()->get_from__email_address();
|
||||
$to_name = $this->mail_api()->get_from__name();
|
||||
$to = trim( $to_name ) . ' <' . $to . '> ';
|
||||
|
||||
$email_result = $this->mail_api()->send( $to , $replace );
|
||||
|
||||
if ( $email_result )
|
||||
opsd_show_message ( __('Email sent to ', 'secure-downloads') . ' ' . $this->mail_api()->get_from__email_address() , 5 );
|
||||
else
|
||||
opsd_show_message ( __('Email had not sent. Some error occuered.', 'secure-downloads'), 5 ,'error' );
|
||||
}
|
||||
|
||||
/*
|
||||
if ( $_POST['form_action'] == 'create' ) { // Create
|
||||
|
||||
$email_title = esc_attr( $_POST['create_email_template'] );
|
||||
$email_name = opsd_get_slug_format_4_option_name( $email_title );
|
||||
|
||||
$opsd_email_tpl_names = get_opsd_option( 'opsd_email_tpl_names' );
|
||||
if ( empty( $opsd_email_tpl_names ) ) $opsd_email_tpl_names = array();
|
||||
|
||||
|
||||
if ( empty($email_name) || isset( $opsd_email_tpl_names[ $email_name ] ) ) { // Error
|
||||
opsd_show_message ( __('Email template has not added.', 'secure-downloads'), 5 , 'error' );
|
||||
return false;
|
||||
}
|
||||
|
||||
$opsd_email_tpl_names[ $email_name ]= stripslashes( $email_title );
|
||||
|
||||
update_opsd_option( 'opsd_email_tpl_names', $opsd_email_tpl_names );
|
||||
|
||||
opsd_show_message ( __('Email template added successfully', 'secure-downloads'), 5 ); // Show Save message
|
||||
|
||||
$redir = esc_url( add_query_arg( array('email_template' => $email_name ), html_entity_decode( $this->getUrl() ) ) );
|
||||
|
||||
opsd_reload_page_by_js( $redir );
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
if ( $_POST['form_action'] == 'delete' ) { // Delete
|
||||
$email_name = esc_attr( $_POST['select_email_template'] );
|
||||
|
||||
$opsd_email_tpl_names = get_opsd_option( 'opsd_email_tpl_names' );
|
||||
if ( empty( $opsd_email_tpl_names ) ) $opsd_email_tpl_names = array();
|
||||
|
||||
if ( ! isset( $opsd_email_tpl_names[ $email_name ] ) ) { // Error
|
||||
opsd_show_message ( __('Email template does not exist.', 'secure-downloads'), 5 , 'error' );
|
||||
return false;
|
||||
}
|
||||
|
||||
unset($opsd_email_tpl_names[ $email_name ]); // Remove Email name from list of email names
|
||||
update_opsd_option( 'opsd_email_tpl_names', $opsd_email_tpl_names );
|
||||
|
||||
delete_opsd_option( 'opsd_email_' . $email_name ); // Delete Email Template
|
||||
|
||||
opsd_show_message ( __('Email template deleted successfully', 'secure-downloads'), 5 ); // Show Save message
|
||||
|
||||
|
||||
$redir = esc_url( remove_query_arg( array( 'email_template' ), html_entity_decode( $this->getUrl() ) ) ); // Load standard email template
|
||||
|
||||
opsd_reload_page_by_js( $redir );
|
||||
|
||||
return true;
|
||||
|
||||
}
|
||||
|
||||
if ( $_POST['form_action'] == 'load' ) { // Load
|
||||
$email_name = $_POST['select_email_template'];
|
||||
|
||||
$opsd_email_tpl_names = get_opsd_option( 'opsd_email_tpl_names' );
|
||||
if ( empty( $opsd_email_tpl_names ) ) $opsd_email_tpl_names = array();
|
||||
|
||||
if ( ! isset( $opsd_email_tpl_names[ $email_name ] ) ) { // Error
|
||||
opsd_show_message ( __('Email template does not exist.', 'secure-downloads'), 5 , 'error' );
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
|
||||
/** Update Email template to DB */
|
||||
public function update() {
|
||||
|
||||
// Get Validated Email fields
|
||||
$validated_fields = $this->mail_api()->validate_post();
|
||||
|
||||
//debuge($validated_fields);
|
||||
// Remove <p> at begining and </p> at END of email template.
|
||||
if (
|
||||
( substr( $validated_fields['content'], 0, 3) === '<p>' )
|
||||
&& ( substr( $validated_fields['content'], -4 ) === '</p>' )
|
||||
) {
|
||||
$validated_fields['content'] = substr ( $validated_fields['content'], 3, ( strlen ( $validated_fields['content'] ) - 7 ) );
|
||||
}
|
||||
|
||||
$this->mail_api()->save_to_db( $validated_fields );
|
||||
|
||||
opsd_show_message ( __('Settings saved.', 'secure-downloads'), 5 ); // Show Save message
|
||||
}
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" CSS & JS " >
|
||||
|
||||
/** CSS for this page */
|
||||
private function css() {
|
||||
?>
|
||||
<style type="text/css">
|
||||
.opsd-help-message {
|
||||
border:none;
|
||||
margin:0 !important;
|
||||
padding:0 !important;
|
||||
}
|
||||
|
||||
@media (max-width: 399px) {
|
||||
}
|
||||
</style>
|
||||
<?php
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** Add Custon JavaScript - for some specific settings options
|
||||
* Executed After post content, after initial definition of settings, and possible definition after POST request.
|
||||
*
|
||||
* @param type $menu_slug
|
||||
*
|
||||
*/
|
||||
private function enqueue_js(){ // $page_tag, $active_page_tab, $active_page_subtab ) {
|
||||
|
||||
|
||||
|
||||
// Check if this correct page /////////////////////////////////////////////
|
||||
|
||||
// if ( !(
|
||||
// ( $page_tag == 'opsd-settings') // Load only at 'opsd-settings' menu
|
||||
// && ( $_GET['tab'] == 'email' ) // At ''general' tab
|
||||
// && ( ( ! isset( $_GET['subtab'] ) ) || ( $_GET['subtab'] == 'new-admin' ) )
|
||||
// )
|
||||
// ) return;
|
||||
|
||||
// JavaScript //////////////////////////////////////////////////////////////
|
||||
|
||||
$js_script = '';
|
||||
//Show or hide colors section in settings page depend form selected email template.
|
||||
$js_script .= " jQuery('select[name=\"download_notification_template_file\"]').on( 'change', function(){
|
||||
if ( jQuery('select[name=\"download_notification_template_file\"] option:selected').val() == 'plain' ) {
|
||||
jQuery('.template_colors').hide();
|
||||
} else {
|
||||
jQuery('.template_colors').show();
|
||||
}
|
||||
} ); ";
|
||||
$js_script .= "\n"; //New Line
|
||||
$js_script .= " if ( jQuery('select[name=\"download_notification_template_file\"] option:selected').val() == 'plain' ) {
|
||||
jQuery('.template_colors').hide();
|
||||
} ";
|
||||
|
||||
// Show Warning messages if Title (optional) is empty - title of email will be "WordPress
|
||||
$js_script .= " jQuery(document).ready(function(){ ";
|
||||
$js_script .= " if ( jQuery('#download_notification_to_name').val() == '' ) {";
|
||||
$js_script .= " jQuery('#download_notification_to_name').parent().append('<div class=\'updated\' style=\'border-left-color:#ffb900;padding:5px 10px;\'>". esc_js(__('If empty then title defined as WordPress', 'secure-downloads'))."</div>')";
|
||||
$js_script .= " }";
|
||||
$js_script .= " if ( jQuery('#download_notification_from_name').val() == '' ) {";
|
||||
$js_script .= " jQuery('#download_notification_from_name').parent().append('<div class=\'updated\' style=\'border-left-color:#ffb900;padding:5px 10px;\'>". esc_js(__('If empty then title defined as WordPress', 'secure-downloads'))."</div>')";
|
||||
$js_script .= " }";
|
||||
$js_script .= " }); ";
|
||||
// Show Warning messages if "From" Email DNS different from current website DNS
|
||||
$js_script .= " jQuery(document).ready(function(){ ";
|
||||
|
||||
$js_script .= " var opsd_email_from = jQuery('#download_notification_from').val();"; // from@oplugins.com
|
||||
$js_script .= " opsd_email_from = opsd_email_from.split('@');"; // ['from', 'oplugins.com']
|
||||
$js_script .= " opsd_email_from.shift();"; // ['oplugins.com']
|
||||
$js_script .= " opsd_email_from = opsd_email_from.join('');"; // 'oplugins.com'
|
||||
|
||||
$js_script .= " var opsd_website_dns = jQuery(location).attr('hostname');"; // server.com
|
||||
$js_script .= " if ( opsd_email_from != opsd_website_dns ) {";
|
||||
$js_script .= " jQuery('#download_notification_from').parent().append('<div class=\'updated\' style=\'border-left-color:#ffb900;padding:5px 10px;\'>". esc_js(__('Email different from website DNS, its can be a reason of not delivery emails. Please use the email withing the same domain as your website!', 'secure-downloads'))."</div>')";
|
||||
$js_script .= " }";
|
||||
|
||||
$js_script .= " }); ";
|
||||
|
||||
|
||||
|
||||
// Eneque JS to the footer of the page
|
||||
opsd_enqueue_js( $js_script );
|
||||
}
|
||||
|
||||
|
||||
// </editor-fold>
|
||||
}
|
||||
add_action('opsd_menu_created', array( new OPSD_Settings_Page_Email_DownloadNotification() , '__construct') ); // Executed after creation of Menu
|
||||
|
||||
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" Emails Sending After Download action " >
|
||||
|
||||
function opsd_send_email_download_notification( $replace = array(), $email_to = '' ) {
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Load Data
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/* Check if New Email Template Exist or NOT
|
||||
* Exist - return empty array in format: array( OPTION_NAME => array() )
|
||||
* Its will load DATA from DB, during creattion mail_api CLASS
|
||||
* during initial activation of the API its try to get option from DB
|
||||
* We need to define this API before checking POST, to know all available fields
|
||||
* Define Email Name & define field values from DB, if not exist, then default values.
|
||||
* Not Exist - import Old Data from DB
|
||||
* or get "default" data from settings and return array with this data
|
||||
* This data its initial parameters for definition fields in mail_api CLASS
|
||||
*
|
||||
*/
|
||||
|
||||
$init_fields_values = array();//opsd_import6_email__download_notification__get_fields_array_for_activation();
|
||||
|
||||
// Get Value of first element - array of default or imported OLD data, because need only array of values without key - name of options for wp_options table
|
||||
//$init_fields_values = array_shift( array_values( $init_fields_values ) );
|
||||
|
||||
$mail_api = new OPSD_Emails_API_DownloadNotification( OPSD_EMAIL_DOWNLOAD_NOTIFICATION_ID, $init_fields_values );
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
if ( $mail_api->fields_values['enabled'] == 'Off' ) return false; // Email template deactivated - exit.
|
||||
|
||||
add_filter( 'opsd_email_api_is_allow_send_copy' , 'opsd_email_api_is_allow_send_copy_block' , 10, 3);
|
||||
|
||||
// Email
|
||||
if ( ! empty( $mail_api->fields_values['to'] ) ) // Admin email from Settings > Emails page
|
||||
$valid_email = sanitize_email( $mail_api->fields_values['to'] );
|
||||
// Overwrite email, if passed to function
|
||||
if ( ! empty( $to_email ) )
|
||||
$valid_email = sanitize_email( $to_email );
|
||||
|
||||
if ( empty( $valid_email ) ) return $mail_api; //return false;
|
||||
|
||||
// Name
|
||||
if ( ! empty( $mail_api->fields_values['to_name'] ) )
|
||||
$email_to_name = trim( wp_specialchars_decode( esc_html( stripslashes( $mail_api->fields_values['to_name'] ) ), ENT_QUOTES ) );
|
||||
else
|
||||
$email_to_name = '';
|
||||
|
||||
|
||||
$to = $email_to_name . ' <' . $valid_email . '> ';
|
||||
$email_result = $mail_api->send( $to , $replace );
|
||||
|
||||
//debuge( (int) $email_result, $to , $replace);
|
||||
|
||||
return $mail_api;
|
||||
|
||||
}
|
||||
|
||||
// </editor-fold>
|
||||
@@ -0,0 +1,990 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package Content
|
||||
* @category Menu
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-04-09
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
/** Replace:
|
||||
1. LinkUser -> LinkUser
|
||||
2. LINK_USER -> LINK_USER
|
||||
3. link_user -> link_user
|
||||
4. Check in api-emails.php 'db_prefix_option' => '...' option, have to be the same as OPSD_EMAIL_LINK_USER_PREFIX here
|
||||
5. Configure Fields in init_settings_fields.
|
||||
*/
|
||||
|
||||
if ( ! defined( 'OPSD_EMAIL_LINK_USER_PREFIX' ) ) define( 'OPSD_EMAIL_LINK_USER_PREFIX', 'opsd_email_' ); // Its defined in api-emails.php file & its same for all emails, here its used only for easy coding...
|
||||
|
||||
if ( ! defined( 'OPSD_EMAIL_LINK_USER_ID' ) ) define( 'OPSD_EMAIL_LINK_USER_ID', 'link_user' ); /* Define Name of Email Template.
|
||||
Note. Prefix "opsd_email_" defined in api-emails.php file.
|
||||
Full name of option is - "opsd_email_link_user"
|
||||
Other email templates names:
|
||||
- 'link_user' - send email with download link to user
|
||||
- 'link_admin' - send copy of email to admin with download link
|
||||
- 'download_admin' - send email about downloads happend
|
||||
*/
|
||||
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/any/api-emails.php' ); // API
|
||||
|
||||
|
||||
/** Email F i e l d s */
|
||||
class OPSD_Emails_API_LinkUser extends OPSD_Emails_API { // O v e r r i d i n g "OPSD_Emails_API" ClASS
|
||||
|
||||
/** Overrided functions - define Email Fields & Values */
|
||||
public function init_settings_fields() {
|
||||
|
||||
$this->fields = array();
|
||||
|
||||
$this->fields['enabled'] = array(
|
||||
'type' => 'checkbox'
|
||||
, 'default' => 'On'
|
||||
, 'title' => __('Enable / Disable', 'secure-downloads')
|
||||
, 'label' => __('Enable this email notification', 'secure-downloads')
|
||||
, 'description' => ''
|
||||
, 'group' => 'general'
|
||||
|
||||
);
|
||||
|
||||
$this->fields['copy_to_admin'] = array(
|
||||
'type' => 'checkbox'
|
||||
, 'default' => 'On'
|
||||
, 'title' => __('Copy to admin', 'secure-downloads')
|
||||
, 'label' => __('Enable / disable sending copy of this email notification to admin', 'secure-downloads')
|
||||
, 'description' => ''
|
||||
, 'group' => 'general'
|
||||
|
||||
);
|
||||
|
||||
$this->fields['enabled_hr'] = array( 'type' => 'hr' );
|
||||
|
||||
$user_info = array( 'name' => '' );
|
||||
if ( is_user_logged_in() ) {
|
||||
$user_data = get_userdata( get_current_user_id() );
|
||||
$user_info['name'] = ( $user_data ) ? $user_data->display_name : '';
|
||||
}
|
||||
|
||||
/*
|
||||
$this->fields['to_html_prefix'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'general'
|
||||
, 'html' => '<tr valign="top">
|
||||
<th scope="row">
|
||||
<label class="opsd-form-email" for="'
|
||||
. esc_attr( 'link_user_to' )
|
||||
. '">' . wp_kses_post( __('To' , 'secure-downloads') )
|
||||
. '</label>
|
||||
</th>
|
||||
<td><fieldset style="float:left;width:50%;margin-right:5%;">'
|
||||
);
|
||||
$this->fields['to'] = array(
|
||||
'type' => 'text' // We are using here 'text' and not 'email', for ability to save several comma seperated emails.
|
||||
, 'default' => get_option( 'admin_email' )
|
||||
//, 'placeholder' => ''
|
||||
, 'title' => ''
|
||||
, 'description' => __('Email Address', 'secure-downloads') . '. ' . __('Required', 'secure-downloads') . '.'
|
||||
, 'description_tag' => ''
|
||||
, 'css' => 'width:100%'
|
||||
, 'group' => 'general'
|
||||
, 'tr_class' => ''
|
||||
, 'only_field' => true
|
||||
, 'validate_as' => array( 'required' )
|
||||
);
|
||||
$this->fields['to_html_middle'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'general'
|
||||
, 'html' => '</fieldset><fieldset style="float:left;width:45%;">'
|
||||
);
|
||||
$this->fields['to_name'] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => '' // $user_info['name']
|
||||
//, 'placeholder' => ''
|
||||
, 'title' => ''
|
||||
, 'description' => __('Title', 'secure-downloads') . ' (' . __('optional', 'secure-downloads') . ').' //. ' ' . __('If empty then title defined as WordPress', 'secure-downloads')
|
||||
, 'description_tag' => ''
|
||||
, 'css' => 'width:100%'
|
||||
, 'group' => 'general'
|
||||
, 'tr_class' => ''
|
||||
, 'only_field' => true
|
||||
);
|
||||
$this->fields['to_html_sufix'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'general'
|
||||
, 'html' => ' </fieldset>
|
||||
</td>
|
||||
</tr>'
|
||||
);
|
||||
*/
|
||||
|
||||
|
||||
$this->fields['from_html_prefix'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'general'
|
||||
, 'html' => '<tr valign="top">
|
||||
<th scope="row">
|
||||
<label class="opsd-form-email" for="'
|
||||
. esc_attr( 'link_user_from' )
|
||||
. '">' . wp_kses_post( __('From' , 'secure-downloads') )
|
||||
. '</label>
|
||||
</th>
|
||||
<td><fieldset style="float:left;width:50%;margin-right:5%;">'
|
||||
);
|
||||
$this->fields['from'] = array(
|
||||
'type' => 'email' // Its can be only 1 email, so check it as Email field.
|
||||
, 'default' => get_option( 'admin_email' )
|
||||
//, 'placeholder' => ''
|
||||
, 'title' => ''
|
||||
, 'description' => __('Email Address', 'secure-downloads') . '. ' . __('Required', 'secure-downloads') . '.'
|
||||
, 'description_tag' => ''
|
||||
, 'css' => 'width:100%'
|
||||
, 'group' => 'general'
|
||||
, 'tr_class' => ''
|
||||
, 'only_field' => true
|
||||
, 'validate_as' => array( 'required' )
|
||||
);
|
||||
$this->fields['from_html_middle'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'general'
|
||||
, 'html' => '</fieldset><fieldset style="float:left;width:45%;">'
|
||||
);
|
||||
$this->fields['from_name'] = array(
|
||||
'type' => 'text'
|
||||
, 'default' => $user_info['name']
|
||||
//, 'placeholder' => ''
|
||||
, 'title' => ''
|
||||
, 'description' => __('Title', 'secure-downloads') . ' (' . __('optional', 'secure-downloads') . ').' //. ' ' . __('If empty then title defined as WordPress', 'secure-downloads')
|
||||
, 'description_tag' => ''
|
||||
, 'css' => 'width:100%'
|
||||
, 'group' => 'general'
|
||||
, 'tr_class' => ''
|
||||
, 'only_field' => true
|
||||
);
|
||||
$this->fields['from_html_sufix'] = array(
|
||||
'type' => 'pure_html'
|
||||
, 'group' => 'general'
|
||||
, 'html' => ' </fieldset>
|
||||
</td>
|
||||
</tr>'
|
||||
);
|
||||
|
||||
$this->fields['from_hr'] = array( 'type' => 'hr' );
|
||||
|
||||
|
||||
$this->fields['subject'] = array(
|
||||
'type' => 'text'
|
||||
// , 'default' => sprintf( __( 'Update of %s', 'secure-downloads'), '[product_title]' )
|
||||
, 'default' => sprintf( __( 'Delivery of %s', 'secure-downloads'), '[product_title] [product_version]' )
|
||||
//, 'placeholder' => ''
|
||||
, 'title' => __('Subject', 'secure-downloads')
|
||||
, 'description' => sprintf(__('Type your email %ssubject%s.' , 'secure-downloads'),'<b>','</b>') . ' ' . __('Required', 'secure-downloads') . '.'
|
||||
, 'description_tag' => ''
|
||||
, 'css' => 'width:100%'
|
||||
, 'group' => 'general'
|
||||
, 'tr_class' => ''
|
||||
, 'validate_as' => array( 'required' )
|
||||
);
|
||||
|
||||
$blg_title = get_option( 'blogname' );
|
||||
$blg_title = str_replace( array( '"', "'" ), '', $blg_title );
|
||||
|
||||
$this->fields['content'] = array(
|
||||
'type' => 'wp_textarea'
|
||||
// , 'default' => sprintf( __( 'Hello.%sTo download %s click the link below:%s (%s) ~ Download link will expire in %sThank you, %s', 'secure-downloads')
|
||||
// , '<br/><br/>', '[product_title]', '<br/>[product_link]', '[product_size]', '[product_expire_after]<br/><br/>', '[site_title]<br>[siteurl]' )
|
||||
, 'default' => sprintf( __( 'Hello. %sThank you for requesting %s To download %s click the link below: %s Thank you, %s', 'secure-downloads' )
|
||||
, '<br/>'
|
||||
, '[product_title] [product_version]<br/><br/>'
|
||||
, '<strong>[product_description]</strong>'
|
||||
, '<br/> --- <br/> [product_summary] - [product_expire_date] <br/> --- <br/> <br/> '
|
||||
, '[siteurl]<br/> [current_date] [current_time]' )
|
||||
//, 'placeholder' => ''
|
||||
, 'title' => __('Content', 'secure-downloads')
|
||||
, 'description' => __('Type your email message content.', 'secure-downloads')
|
||||
, 'description_tag' => ''
|
||||
, 'css' => ''
|
||||
, 'group' => 'general'
|
||||
, 'tr_class' => ''
|
||||
, 'rows' => 10
|
||||
, 'show_in_2_cols' => true
|
||||
);
|
||||
// $this->fields['content'] = htmlspecialchars( $this->fields['content'] );// Convert > to >
|
||||
// $this->fields['content'] = html_entity_decode( $this->fields['content'] );// Convert > to >
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////
|
||||
// Style
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
$this->fields['header_content'] = array(
|
||||
'type' => 'textarea'
|
||||
, 'default' => ''
|
||||
, 'title' => __('Email Heading', 'secure-downloads')
|
||||
, 'description' => __('Enter main heading contained within the email notification.', 'secure-downloads')
|
||||
//, 'placeholder' => ''
|
||||
, 'rows' => 2
|
||||
, 'css' => "width:100%;"
|
||||
, 'group' => 'parts'
|
||||
);
|
||||
$this->fields['footer_content'] = array(
|
||||
'type' => 'textarea'
|
||||
, 'default' => ''
|
||||
, 'title' => __('Email Footer Text', 'secure-downloads')
|
||||
, 'description' => __('Enter text contained within footer of the email notification', 'secure-downloads')
|
||||
//, 'placeholder' => ''
|
||||
, 'rows' => 2
|
||||
, 'css' => 'width:100%;'
|
||||
, 'group' => 'parts'
|
||||
);
|
||||
|
||||
$this->fields['template_file'] = array(
|
||||
'type' => 'select'
|
||||
, 'default' => 'plain'
|
||||
, 'title' => __('Email template', 'secure-downloads')
|
||||
, 'description' => __('Choose email template.', 'secure-downloads')
|
||||
, 'description_tag' => 'span'
|
||||
, 'css' => ''
|
||||
, 'options' => array(
|
||||
'plain' => __('Plain (without styles)', 'secure-downloads')
|
||||
, 'standard' => __('Standard 1 column', 'secure-downloads')
|
||||
)
|
||||
, 'group' => 'style'
|
||||
);
|
||||
|
||||
$this->fields['template_file_help'] = array(
|
||||
'type' => 'help'
|
||||
, 'value' => array( sprintf( __('You can override this email template in this folder %s', 'secure-downloads')
|
||||
, '<code>' . realpath( dirname(__FILE__) . '/../any/emails_tpl/' ) . '</code>' )
|
||||
)
|
||||
, 'cols' => 2
|
||||
, 'group' => 'style'
|
||||
);
|
||||
|
||||
$this->fields['base_color'] = array(
|
||||
'type' => 'color'
|
||||
, 'default' => '#557da1'
|
||||
, 'title' => __('Base Color', 'secure-downloads')
|
||||
, 'description' => __('The base color for email templates.', 'secure-downloads')
|
||||
. ' ' . __('Default color', 'secure-downloads') .': <code>#557da1</code>.'
|
||||
, 'group' => 'style'
|
||||
, 'tr_class' => 'template_colors'
|
||||
);
|
||||
$this->fields['background_color'] = array(
|
||||
'type' => 'color'
|
||||
, 'default' => '#f5f5f5'
|
||||
, 'title' => __('Background Color', 'secure-downloads')
|
||||
, 'description' => __('The background color for email templates.', 'secure-downloads')
|
||||
. ' ' . __('Default color', 'secure-downloads') .': <code>#f5f5f5</code>.'
|
||||
, 'group' => 'style'
|
||||
, 'tr_class' => 'template_colors'
|
||||
);
|
||||
$this->fields['body_color'] = array(
|
||||
'type' => 'color'
|
||||
, 'default' => '#fdfdfd'
|
||||
, 'title' => __('Email Body Background Color', 'secure-downloads')
|
||||
, 'description' => __('The main body background color for email templates.', 'secure-downloads')
|
||||
. ' ' . __('Default color', 'secure-downloads') .': <code>#fdfdfd</code>.'
|
||||
, 'group' => 'style'
|
||||
, 'tr_class' => 'template_colors'
|
||||
);
|
||||
$this->fields['text_color'] = array(
|
||||
'type' => 'color'
|
||||
, 'default' => '#505050'
|
||||
, 'title' => __('Email Body Text Colour', 'secure-downloads')
|
||||
, 'description' => __('The main body text color for email templates.', 'secure-downloads')
|
||||
. ' ' . __('Default color', 'secure-downloads') .': <code>#505050</code>.'
|
||||
, 'group' => 'style'
|
||||
, 'tr_class' => 'template_colors'
|
||||
);
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////
|
||||
// Email format: Plain, HTML, MultiPart
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
$this->fields['email_content_type'] = array(
|
||||
'type' => 'select'
|
||||
, 'default' => 'plain'
|
||||
, 'title' => __('Email format', 'secure-downloads')
|
||||
, 'description' => __('Choose which format of email to send.', 'secure-downloads')
|
||||
, 'description_tag' => 'p'
|
||||
, 'css' => 'width:100%;'
|
||||
, 'options' => array(
|
||||
'plain' => __('Plain text', 'secure-downloads')
|
||||
// , 'html' => __('HTML', 'secure-downloads')
|
||||
// , 'multipart' => __('Multipart', 'secure-downloads')
|
||||
)
|
||||
, 'group' => 'email_content_type'
|
||||
);
|
||||
if ( class_exists( 'DOMDocument' ) ) {
|
||||
$this->fields['email_content_type']['options']['html'] = __('HTML', 'secure-downloads');
|
||||
$this->fields['email_content_type']['options']['multipart'] = __('Multipart', 'secure-downloads');
|
||||
|
||||
$this->fields['email_content_type']['default'] = 'html';
|
||||
}
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////
|
||||
// Help
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
||||
$this->fields['content_help'] = array(
|
||||
'type' => 'help'
|
||||
, 'value' => array()
|
||||
, 'cols' => 2
|
||||
, 'group' => 'help'
|
||||
);
|
||||
|
||||
$skip_shortcodes = array(
|
||||
'denyreason'
|
||||
, 'paymentreason'
|
||||
, 'visitorediturl'
|
||||
, 'visitorcancelurl'
|
||||
, 'visitorpayurl'
|
||||
);
|
||||
$email_example = sprintf(__('For example: "You have a new reservation %s on the following date(s): %s Contact information: %s You can approve or cancel this item at: %s Thank you, Reservation service."' , 'secure-downloads'),'','[dates]<br/><br/>','<br/> [content]<br/><br/>', htmlentities( ' <a href="[moderatelink]">'.__('here' , 'secure-downloads').'</a> ') . '<br/><br/> ');
|
||||
|
||||
$help_fields = opsd_get_email_help_shortcodes( $skip_shortcodes, $email_example );
|
||||
|
||||
foreach ( $help_fields as $help_fields_key => $help_fields_value ) {
|
||||
$this->fields['content_help']['value'][] = $help_fields_value;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** Settings Emails P a g e */
|
||||
class OPSD_Settings_Page_Email_LinkUser extends OPSD_Page_Structure {
|
||||
|
||||
// Addon Fix
|
||||
public function __construct() {
|
||||
$is_show = true;
|
||||
$is_show = apply_filters( 'opsd_is_show_email_link_user_page', $is_show );
|
||||
if ( $is_show )
|
||||
parent::__construct();
|
||||
}
|
||||
|
||||
public $email_settings_api = false;
|
||||
|
||||
|
||||
/** Define interface for Email API
|
||||
*
|
||||
* @param string $selected_email_name - name of Email template
|
||||
* @param array $init_fields_values - array of init form fields data
|
||||
* @return object Email API
|
||||
*/
|
||||
public function mail_api( $selected_email_name ='', $init_fields_values = array() ){
|
||||
|
||||
if ( $this->email_settings_api === false ) {
|
||||
$this->email_settings_api = new OPSD_Emails_API_LinkUser( $selected_email_name , $init_fields_values );
|
||||
}
|
||||
|
||||
return $this->email_settings_api;
|
||||
}
|
||||
|
||||
|
||||
public function in_page() { // P a g e t a g
|
||||
return 'opsd-settings';
|
||||
}
|
||||
|
||||
|
||||
public function tabs() { // T a b s A r r a y
|
||||
|
||||
$tabs = array();
|
||||
|
||||
$tabs[ 'email' ] = array(
|
||||
'title' => __( 'Emails', 'secure-downloads') // Title of TAB
|
||||
, 'page_title'=> __( 'Emails Settings', 'secure-downloads') // Title of Page
|
||||
, 'hint' => __( 'Emails Settings', 'secure-downloads') // Hint
|
||||
//, 'link' => '' // Can be skiped, then generated link based on Page and Tab tags. Or can be extenral link
|
||||
//, 'position' => '' // 'left' || 'right' || ''
|
||||
//, 'css_classes'=> '' // CSS class(es)
|
||||
//, 'icon' => '' // Icon - link to the real PNG img
|
||||
, 'font_icon' => 'glyphicon glyphicon-envelope' // CSS definition of forn Icon
|
||||
//, 'default' => false // Is this tab activated by default or not: true || false.
|
||||
//, 'disabled' => false // Is this tab disbaled: true || false.
|
||||
//, 'hided' => false // Is this tab hided: true || false.
|
||||
, 'subtabs' => array()
|
||||
);
|
||||
|
||||
$subtabs = array();
|
||||
|
||||
|
||||
$is_data_exist = get_opsd_option( OPSD_EMAIL_LINK_USER_PREFIX . OPSD_EMAIL_LINK_USER_ID ); // ''opsd_email_' - defined in api-emails.php file.
|
||||
if ( ( ! empty( $is_data_exist ) ) && ( isset( $is_data_exist['enabled'] ) ) && ( $is_data_exist['enabled'] == 'On' ) )
|
||||
$icon = '<i class="menu_icon icon-1x glyphicon glyphicon-check"></i> ';
|
||||
else
|
||||
$icon = '<i class="menu_icon icon-1x glyphicon glyphicon-unchecked"></i> ';
|
||||
|
||||
if ( ( ! empty( $is_data_exist ) ) && ( isset( $is_data_exist['copy_to_admin'] ) ) && ( $is_data_exist['copy_to_admin'] == 'On' ) )
|
||||
$sufix = '<sup> 2</sup>';
|
||||
else
|
||||
$sufix = '';
|
||||
|
||||
$subtabs['link-user'] = array(
|
||||
'type' => 'subtab' // Required| Possible values: 'subtab' | 'separator' | 'button' | 'goto-link' | 'html'
|
||||
, 'title' => $icon . __('To User' , 'secure-downloads') . $sufix // Title of TAB
|
||||
, 'page_title' => __('Emails Settings', 'secure-downloads') // Title of Page
|
||||
, 'hint' => __('Email with download link, which is sending to user' , 'secure-downloads') // Hint
|
||||
, 'link' => '' // link
|
||||
, 'position' => '' // 'left' || 'right' || ''
|
||||
, 'css_classes' => '' // CSS class(es)
|
||||
//, 'icon' => 'http://.../icon.png' // Icon - link to the real PNG img
|
||||
//, 'font_icon' => 'glyphicon glyphicon-envelope' // CSS definition of Font Icon
|
||||
, 'default' => true // Is this sub tab activated by default or not: true || false.
|
||||
, 'disabled' => false // Is this sub tab deactivated: true || false.
|
||||
, 'checkbox' => false // or definition array for specific checkbox: array( 'checked' => true, 'name' => 'feature1_active_status' ) //, 'checkbox' => array( 'checked' => $is_checked, 'name' => 'enabled_active_status' )
|
||||
, 'content' => 'content' // Function to load as conten of this TAB
|
||||
);
|
||||
|
||||
$tabs[ 'email' ]['subtabs'] = $subtabs;
|
||||
|
||||
return $tabs;
|
||||
}
|
||||
|
||||
|
||||
/** Show Content of Settings page */
|
||||
public function content() {
|
||||
//debuge( 'OPSD_EMAIL_LINK_USER_PREFIX . OPSD_EMAIL_LINK_USER_ID, get_opsd_option( OPSD_EMAIL_LINK_USER_PREFIX . OPSD_EMAIL_LINK_USER_ID )', OPSD_EMAIL_LINK_USER_PREFIX . OPSD_EMAIL_LINK_USER_ID, get_opsd_option( OPSD_EMAIL_LINK_USER_PREFIX . OPSD_EMAIL_LINK_USER_ID ) );
|
||||
|
||||
$this->css();
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Checking
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
do_action( 'opsd_hook_settings_page_header', array( 'page' => $this->in_page(), 'subpage' => 'emails_settings' ) ); // Define Notices Section and show some static messages, if needed.
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Load Data
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/** Its will load DATA from DB, during creattion mail_api CLASS
|
||||
* during initial activation of the API its try to get option from DB
|
||||
* We need to define this API before checking POST, to know all available fields
|
||||
* Define Email Name & define field values from DB, if not exist, then default values.
|
||||
Array (
|
||||
[opsd_email_link_user] => Array
|
||||
(
|
||||
[enabled] => On
|
||||
[to] => beta@oplugins.com
|
||||
[to_name] => 'Some name'
|
||||
[from] => admin@oplugins.com
|
||||
[from_name] =>
|
||||
[subject] => New item
|
||||
[content] => You need to approve [shortcodetype] for: [dates]...
|
||||
[header_content] =>
|
||||
[footer_content] =>
|
||||
[template_file] => plain
|
||||
[base_color] => #557da1
|
||||
[background_color] => #f5f5f5
|
||||
[body_color] => #fdfdfd
|
||||
[text_color] => #505050
|
||||
[email_content_type] => html
|
||||
)
|
||||
)
|
||||
|
||||
// $mail_api->save_to_db( $fields_values );
|
||||
*/
|
||||
$init_fields_values = array();
|
||||
|
||||
$this->mail_api( OPSD_EMAIL_LINK_USER_ID, $init_fields_values );
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// S u b m i t Actions - S e n d
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
$submit_form_name_action = 'opsd_form_action'; // Define form name
|
||||
if ( isset( $_POST['is_form_sbmitted_'. $submit_form_name_action ] ) ) {
|
||||
|
||||
// Nonce checking {Return false if invalid, 1 if generated between, 0-12 hours ago, 2 if generated between 12-24 hours ago. }
|
||||
$nonce_gen_time = check_admin_referer( 'opsd_settings_page_' . $submit_form_name_action ); // Its stop show anything on submiting, if its not refear to the original page
|
||||
|
||||
// Save Changes
|
||||
$this->update_actions();
|
||||
}
|
||||
?>
|
||||
<form name="<?php echo $submit_form_name_action; ?>" id="<?php echo $submit_form_name_action; ?>" action="" method="post" autocomplete="off">
|
||||
<?php
|
||||
// N o n c e field, and key for checking S u b m i t
|
||||
wp_nonce_field( 'opsd_settings_page_' . $submit_form_name_action );
|
||||
?><input type="hidden" name="is_form_sbmitted_<?php echo $submit_form_name_action; ?>" id="is_form_sbmitted_<?php echo $submit_form_name_action; ?>" value="1" />
|
||||
<input type="hidden" name="form_action" id="form_action" value="" />
|
||||
</form>
|
||||
<?php
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// S u b m i t Main Form
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
$submit_form_name = 'opsd_emails_template'; // Define form name
|
||||
|
||||
$this->mail_api()->validated_form_id = $submit_form_name; // Define ID of Form for ability to validate fields before submit.
|
||||
|
||||
if ( isset( $_POST['is_form_sbmitted_'. $submit_form_name ] ) ) {
|
||||
|
||||
// Nonce checking {Return false if invalid, 1 if generated between, 0-12 hours ago, 2 if generated between 12-24 hours ago. }
|
||||
$nonce_gen_time = check_admin_referer( 'opsd_settings_page_' . $submit_form_name ); // Its stop show anything on submiting, if its not refear to the original page
|
||||
|
||||
// Save Changes
|
||||
$this->update();
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// JavaScript: Tooltips, Popover, Datepick (js & css)
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
echo '<span class="wpdevelop">';
|
||||
|
||||
opsd_js_for_items_page();
|
||||
|
||||
echo '</span>';
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Content
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
?>
|
||||
<div class="clear" style="margin-bottom:10px;"></div>
|
||||
|
||||
<span class="metabox-holder">
|
||||
|
||||
<form name="<?php echo $submit_form_name; ?>" id="<?php echo $submit_form_name; ?>" action="" method="post" autocomplete="off">
|
||||
<?php
|
||||
// N o n c e field, and key for checking S u b m i t
|
||||
wp_nonce_field( 'opsd_settings_page_' . $submit_form_name );
|
||||
?><input type="hidden" name="is_form_sbmitted_<?php echo $submit_form_name; ?>" id="is_form_sbmitted_<?php echo $submit_form_name; ?>" value="1" />
|
||||
|
||||
|
||||
<div class="clear"></div>
|
||||
<div class="metabox-holder">
|
||||
|
||||
<div class="opsd_settings_row opsd_settings_row_left" >
|
||||
<?php
|
||||
|
||||
opsd_open_meta_box_section( $submit_form_name . 'general', __('Email with download link, which is sending to user', 'secure-downloads') );
|
||||
|
||||
$this->mail_api()->show( 'general' );
|
||||
|
||||
opsd_close_meta_box_section();
|
||||
|
||||
|
||||
opsd_open_meta_box_section( $submit_form_name . 'parts' , __('Header / Footer', 'secure-downloads') );
|
||||
|
||||
$this->mail_api()->show( 'parts' );
|
||||
|
||||
opsd_close_meta_box_section();
|
||||
|
||||
|
||||
opsd_open_meta_box_section( $submit_form_name . 'style' , __('Email Styles', 'secure-downloads') );
|
||||
|
||||
$this->mail_api()->show( 'style' );
|
||||
|
||||
opsd_close_meta_box_section();
|
||||
|
||||
?>
|
||||
</div>
|
||||
|
||||
<div class="opsd_settings_row opsd_settings_row_right">
|
||||
<?php
|
||||
|
||||
opsd_open_meta_box_section( $submit_form_name . 'actions', __('Actions', 'secure-downloads') );
|
||||
|
||||
?><a class="button button-secondary" style="margin:0 0 5px;" href="javascript:void(0)"
|
||||
onclick="javascript: jQuery('#form_action').val('test_send'); jQuery('form#<?php echo $submit_form_name_action; ?>').trigger( 'submit' );"
|
||||
><?php _e('Send Test Email', 'secure-downloads'); ?></a><?php
|
||||
|
||||
?><input type="submit" value="<?php _e('Save Changes', 'secure-downloads'); ?>" class="button button-primary right" style="margin:0 0 5px 5px;" /><?php
|
||||
|
||||
/* ?>
|
||||
<a class="button button-secondary" href="javascript:void(0)" ><?php _e('Preview Email', 'secure-downloads'); ?></a>
|
||||
<hr />
|
||||
<a class="button button-secondary right"
|
||||
href="javascript:void(0)"
|
||||
onclick="javascript: if ( opsd_are_you_sure('<?php echo esc_js(__('Do you really want to delete this item?', 'secure-downloads')); ?>') ){
|
||||
jQuery('#form_action').val('delete');
|
||||
jQuery('form#<?php echo $submit_form_name_action; ?>').trigger( 'submit' );
|
||||
}"
|
||||
><?php _e('Delete Email', 'secure-downloads'); ?></a>
|
||||
<?php */
|
||||
|
||||
?><div class="clear"></div><?php
|
||||
|
||||
opsd_close_meta_box_section();
|
||||
|
||||
opsd_open_meta_box_section( $submit_form_name . 'email_content_type', __('Type', 'secure-downloads') );
|
||||
|
||||
$this->mail_api()->show( 'email_content_type' );
|
||||
|
||||
opsd_close_meta_box_section();
|
||||
|
||||
|
||||
opsd_open_meta_box_section( $submit_form_name . 'help', __('Help', 'secure-downloads') );
|
||||
|
||||
$this->mail_api()->show( 'help' );
|
||||
|
||||
opsd_close_meta_box_section();
|
||||
|
||||
?>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</div>
|
||||
|
||||
<input type="submit" value="<?php _e('Save Changes', 'secure-downloads'); ?>" class="button button-primary" />
|
||||
</form>
|
||||
</span>
|
||||
<?php
|
||||
|
||||
$this->enqueue_js();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Update form from Toolbar - create / delete/ load email templates
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function update_actions( ) {
|
||||
|
||||
|
||||
if ( $_POST['form_action'] == 'test_send' ) { // Sending test email
|
||||
|
||||
/*
|
||||
$this->email_settings_api = false;
|
||||
$selected_email_name = 'standard';
|
||||
$email_fields = get_opsd_option( 'opsd_email_' . $selected_email_name );
|
||||
$this->mail_api( $selected_email_name, $email_fields );
|
||||
*/
|
||||
|
||||
|
||||
//$to = sanitize_email( $this->mail_api()->fields_values['to'] );
|
||||
|
||||
$replace = array();
|
||||
$replace[ 'product_id' ] = '<strong>99</strong>';
|
||||
$replace[ 'product_title' ] = '<strong>Product ZZZ</strong>';
|
||||
$replace[ 'product_version' ] = '<strong>1.0</strong>';
|
||||
$replace[ 'product_description' ] = 'Product ZZZ Info';
|
||||
$replace[ 'product_filename' ] = 'zzz_product.zip';
|
||||
$replace[ 'product_link' ] = home_url();
|
||||
$replace[ 'product_size' ] = '3 Mb';
|
||||
$replace[ 'product_expire_after' ] = '1 day';
|
||||
$replace[ 'product_expire_date' ] = date_i18n( get_opsd_option( 'opsd_date_format' ) . ' ' . get_opsd_option( 'opsd_time_format' ), strtotime( '+1 day' ) );
|
||||
$replace[ 'product_summary' ] = '<a href="">' . $replace[ 'product_filename' ] . '</a> (' . $replace[ 'product_size' ] . ') ~ expire in ' . $replace[ 'product_expire_after' ];
|
||||
|
||||
$replace[ 'link_sent_to' ] = $this->mail_api()->get_from__email_address();
|
||||
|
||||
$replace[ 'siteurl' ] = htmlspecialchars_decode( '<a href="' . home_url() . '">' . home_url() . '</a>' );
|
||||
$replace[ 'remote_ip' ] = opsd_get_user_ip(); // The IP address from which the user is viewing the current page.
|
||||
$replace[ 'user_agent' ] = $_SERVER[ 'HTTP_USER_AGENT' ]; // Contents of the User-Agent: header from the current request, if there is one.
|
||||
$replace[ 'request_url' ] = $_SERVER[ 'HTTP_REFERER' ]; // The address of the page (if any) where action was occured. Because we are sending it in Ajax request, we need to use the REFERER HTTP
|
||||
$replace[ 'current_date' ] = date_i18n( get_opsd_option( 'opsd_date_format' ) );
|
||||
$replace[ 'current_time' ] = date_i18n( get_opsd_option( 'opsd_time_format' ) );
|
||||
|
||||
|
||||
|
||||
$to = $this->mail_api()->get_from__email_address();
|
||||
$to_name = $this->mail_api()->get_from__name();
|
||||
$to = trim( $to_name ) . ' <' . $to . '> ';
|
||||
|
||||
$email_result = $this->mail_api()->send( $to , $replace );
|
||||
|
||||
if ( $email_result )
|
||||
opsd_show_message ( __('Email sent to ', 'secure-downloads') . ' ' . $this->mail_api()->get_from__email_address() , 5 );
|
||||
else
|
||||
opsd_show_message ( __('Email had not sent. Some error occuered.', 'secure-downloads'), 5 ,'error' );
|
||||
}
|
||||
|
||||
/*
|
||||
if ( $_POST['form_action'] == 'create' ) { // Create
|
||||
|
||||
$email_title = esc_attr( $_POST['create_email_template'] );
|
||||
$email_name = opsd_get_slug_format_4_option_name( $email_title );
|
||||
|
||||
$opsd_email_tpl_names = get_opsd_option( 'opsd_email_tpl_names' );
|
||||
if ( empty( $opsd_email_tpl_names ) ) $opsd_email_tpl_names = array();
|
||||
|
||||
|
||||
if ( empty($email_name) || isset( $opsd_email_tpl_names[ $email_name ] ) ) { // Error
|
||||
opsd_show_message ( __('Email template has not added.', 'secure-downloads'), 5 , 'error' );
|
||||
return false;
|
||||
}
|
||||
|
||||
$opsd_email_tpl_names[ $email_name ]= stripslashes( $email_title );
|
||||
|
||||
update_opsd_option( 'opsd_email_tpl_names', $opsd_email_tpl_names );
|
||||
|
||||
opsd_show_message ( __('Email template added successfully', 'secure-downloads'), 5 ); // Show Save message
|
||||
|
||||
$redir = esc_url( add_query_arg( array('email_template' => $email_name ), html_entity_decode( $this->getUrl() ) ) );
|
||||
|
||||
opsd_reload_page_by_js( $redir );
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
if ( $_POST['form_action'] == 'delete' ) { // Delete
|
||||
$email_name = esc_attr( $_POST['select_email_template'] );
|
||||
|
||||
$opsd_email_tpl_names = get_opsd_option( 'opsd_email_tpl_names' );
|
||||
if ( empty( $opsd_email_tpl_names ) ) $opsd_email_tpl_names = array();
|
||||
|
||||
if ( ! isset( $opsd_email_tpl_names[ $email_name ] ) ) { // Error
|
||||
opsd_show_message ( __('Email template does not exist.', 'secure-downloads'), 5 , 'error' );
|
||||
return false;
|
||||
}
|
||||
|
||||
unset($opsd_email_tpl_names[ $email_name ]); // Remove Email name from list of email names
|
||||
update_opsd_option( 'opsd_email_tpl_names', $opsd_email_tpl_names );
|
||||
|
||||
delete_opsd_option( 'opsd_email_' . $email_name ); // Delete Email Template
|
||||
|
||||
opsd_show_message ( __('Email template deleted successfully', 'secure-downloads'), 5 ); // Show Save message
|
||||
|
||||
|
||||
$redir = esc_url( remove_query_arg( array( 'email_template' ), html_entity_decode( $this->getUrl() ) ) ); // Load standard email template
|
||||
|
||||
opsd_reload_page_by_js( $redir );
|
||||
|
||||
return true;
|
||||
|
||||
}
|
||||
|
||||
if ( $_POST['form_action'] == 'load' ) { // Load
|
||||
$email_name = $_POST['select_email_template'];
|
||||
|
||||
$opsd_email_tpl_names = get_opsd_option( 'opsd_email_tpl_names' );
|
||||
if ( empty( $opsd_email_tpl_names ) ) $opsd_email_tpl_names = array();
|
||||
|
||||
if ( ! isset( $opsd_email_tpl_names[ $email_name ] ) ) { // Error
|
||||
opsd_show_message ( __('Email template does not exist.', 'secure-downloads'), 5 , 'error' );
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
|
||||
/** Update Email template to DB */
|
||||
public function update() {
|
||||
|
||||
// Get Validated Email fields
|
||||
$validated_fields = $this->mail_api()->validate_post();
|
||||
|
||||
// Remove <p> at begining and </p> at END of email template.
|
||||
if (
|
||||
( substr( $validated_fields['content'], 0, 3) === '<p>' )
|
||||
&& ( substr( $validated_fields['content'], -4 ) === '</p>' )
|
||||
) {
|
||||
$validated_fields['content'] = substr ( $validated_fields['content'], 3, ( strlen ( $validated_fields['content'] ) - 7 ) );
|
||||
}
|
||||
|
||||
$this->mail_api()->save_to_db( $validated_fields );
|
||||
|
||||
opsd_show_message ( __('Settings saved.', 'secure-downloads'), 5 ); // Show Save message
|
||||
}
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" CSS & JS " >
|
||||
|
||||
/** CSS for this page */
|
||||
private function css() {
|
||||
?>
|
||||
<style type="text/css">
|
||||
.opsd-help-message {
|
||||
border:none;
|
||||
margin:0 !important;
|
||||
padding:0 !important;
|
||||
}
|
||||
|
||||
@media (max-width: 399px) {
|
||||
}
|
||||
</style>
|
||||
<?php
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** Add Custon JavaScript - for some specific settings options
|
||||
* Executed After post content, after initial definition of settings, and possible definition after POST request.
|
||||
*
|
||||
* @param type $menu_slug
|
||||
*
|
||||
*/
|
||||
private function enqueue_js(){ // $page_tag, $active_page_tab, $active_page_subtab ) {
|
||||
|
||||
|
||||
|
||||
// Check if this correct page /////////////////////////////////////////////
|
||||
|
||||
// if ( !(
|
||||
// ( $page_tag == 'opsd-settings') // Load only at 'opsd-settings' menu
|
||||
// && ( $_GET['tab'] == 'email' ) // At ''general' tab
|
||||
// && ( ( ! isset( $_GET['subtab'] ) ) || ( $_GET['subtab'] == 'new-admin' ) )
|
||||
// )
|
||||
// ) return;
|
||||
|
||||
// JavaScript //////////////////////////////////////////////////////////////
|
||||
|
||||
$js_script = '';
|
||||
//Show or hide colors section in settings page depend form selected email template.
|
||||
$js_script .= " jQuery('select[name=\"link_user_template_file\"]').on( 'change', function(){
|
||||
if ( jQuery('select[name=\"link_user_template_file\"] option:selected').val() == 'plain' ) {
|
||||
jQuery('.template_colors').hide();
|
||||
} else {
|
||||
jQuery('.template_colors').show();
|
||||
}
|
||||
} ); ";
|
||||
$js_script .= "\n"; //New Line
|
||||
$js_script .= " if ( jQuery('select[name=\"link_user_template_file\"] option:selected').val() == 'plain' ) {
|
||||
jQuery('.template_colors').hide();
|
||||
} ";
|
||||
|
||||
// Show Warning messages if Title (optional) is empty - title of email will be "WordPress
|
||||
$js_script .= " jQuery(document).ready(function(){ ";
|
||||
$js_script .= " if ( jQuery('#link_user_to_name').val() == '' ) {";
|
||||
$js_script .= " jQuery('#link_user_to_name').parent().append('<div class=\'updated\' style=\'border-left-color:#ffb900;padding:5px 10px;\'>". esc_js(__('If empty then title defined as WordPress', 'secure-downloads'))."</div>')";
|
||||
$js_script .= " }";
|
||||
$js_script .= " if ( jQuery('#link_user_from_name').val() == '' ) {";
|
||||
$js_script .= " jQuery('#link_user_from_name').parent().append('<div class=\'updated\' style=\'border-left-color:#ffb900;padding:5px 10px;\'>". esc_js(__('If empty then title defined as WordPress', 'secure-downloads'))."</div>')";
|
||||
$js_script .= " }";
|
||||
$js_script .= " }); ";
|
||||
// Show Warning messages if "From" Email DNS different from current website DNS
|
||||
$js_script .= " jQuery(document).ready(function(){ ";
|
||||
|
||||
$js_script .= " var opsd_email_from = jQuery('#link_user_from').val();"; // from@oplugins.com
|
||||
$js_script .= " opsd_email_from = opsd_email_from.split('@');"; // ['from', 'oplugins.com']
|
||||
$js_script .= " opsd_email_from.shift();"; // ['oplugins.com']
|
||||
$js_script .= " opsd_email_from = opsd_email_from.join('');"; // 'oplugins.com'
|
||||
|
||||
$js_script .= " var opsd_website_dns = jQuery(location).attr('hostname');"; // server.com
|
||||
$js_script .= " if ( opsd_email_from != opsd_website_dns ) {";
|
||||
$js_script .= " jQuery('#link_user_from').parent().append('<div class=\'updated\' style=\'border-left-color:#ffb900;padding:5px 10px;\'>". esc_js(__('Email different from website DNS, its can be a reason of not delivery emails. Please use the email withing the same domain as your website!', 'secure-downloads'))."</div>')";
|
||||
$js_script .= " }";
|
||||
|
||||
$js_script .= " }); ";
|
||||
|
||||
|
||||
|
||||
// Eneque JS to the footer of the page
|
||||
opsd_enqueue_js( $js_script );
|
||||
}
|
||||
|
||||
|
||||
// </editor-fold>
|
||||
}
|
||||
add_action('opsd_menu_created', array( new OPSD_Settings_Page_Email_LinkUser() , '__construct') ); // Executed after creation of Menu
|
||||
|
||||
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" Emails Sending After New item " >
|
||||
|
||||
/** Send email to customer with link for downloading file.
|
||||
*
|
||||
* @param array $replace - Array with replace parameters for email.
|
||||
* @param string $email_to - Email address
|
||||
* @param string $send_copy_to_admin - On|Off
|
||||
* @param array $other_params - Optional. Array of validated parameters from submit form at Send page
|
||||
* @return \OPSD_Emails_API_LinkUser|boolean
|
||||
*/
|
||||
function opsd_send_email_to_user_notification( $replace = array(), $email_to = '', $send_copy_to_admin = 'Off', $other_params = array() ) {
|
||||
|
||||
$is_continue = true;
|
||||
|
||||
$is_continue = apply_filters( 'opsd_send_email_to_user_notification_filter', $is_continue, $replace, $email_to, $send_copy_to_admin, $other_params);
|
||||
|
||||
if ( $is_continue !== true )
|
||||
return $is_continue;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// Load Data
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/* Check if New Email Template Exist or NOT
|
||||
* Exist - return empty array in format: array( OPTION_NAME => array() )
|
||||
* Its will load DATA from DB, during creattion mail_api CLASS
|
||||
* during initial activation of the API its try to get option from DB
|
||||
* We need to define this API before checking POST, to know all available fields
|
||||
* Define Email Name & define field values from DB, if not exist, then default values.
|
||||
* Not Exist - import Old Data from DB
|
||||
* or get "default" data from settings and return array with this data
|
||||
* This data its initial parameters for definition fields in mail_api CLASS
|
||||
*
|
||||
*/
|
||||
|
||||
$init_fields_values = array();//opsd_import6_email__link_user__get_fields_array_for_activation();
|
||||
|
||||
// Get Value of first element - array of default or imported OLD data, because need only array of values without key - name of options for wp_options table
|
||||
//$init_fields_values = array_shift( array_values( $init_fields_values ) );
|
||||
|
||||
$mail_api = new OPSD_Emails_API_LinkUser( OPSD_EMAIL_LINK_USER_ID, $init_fields_values );
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
if ( $mail_api->fields_values['enabled'] == 'Off' ) return false; // Email template deactivated - exit.
|
||||
|
||||
add_filter( 'opsd_email_api_is_allow_send_copy' , 'opsd_email_api_is_allow_send_copy_block' , 10, 3);
|
||||
|
||||
|
||||
if ( ! empty( $replace['to'] ) )
|
||||
$valid_email = sanitize_email( $replace['to'] );
|
||||
|
||||
if ( ! empty( $email_to ) )
|
||||
$valid_email = sanitize_email( $email_to );
|
||||
|
||||
if ( empty( $valid_email ) ) return $mail_api; //return false;
|
||||
|
||||
if ( ! empty( $replace['to_name'] ) )
|
||||
$email_to_name = trim( wp_specialchars_decode( esc_html( stripslashes( $replace['to_name'] ) ), ENT_QUOTES ) );
|
||||
else
|
||||
$email_to_name = '';
|
||||
|
||||
$to = $email_to_name . ' <' . $valid_email . '> ';
|
||||
|
||||
$email_result = $mail_api->send( $to , $replace );
|
||||
|
||||
// Send copy of email to admin also to "From" email address
|
||||
if ( $send_copy_to_admin == 'On') {
|
||||
$subject = $mail_api->get_field_value('subject');
|
||||
$mail_api->set_field_value('subject', __('Email copy to', 'secure-downloads') . ': ' . $valid_email . ' ' . $subject );
|
||||
$email_result = $mail_api->send( $mail_api->get_from__email_address() , $replace );
|
||||
$mail_api->set_field_value('subject', $subject );
|
||||
}
|
||||
|
||||
//debuge( (int) $email_result, $to , $replace);
|
||||
|
||||
return $mail_api;
|
||||
|
||||
}
|
||||
|
||||
|
||||
/** Block Sending copy of email to Admin, based on OPSD_Emails_API interface, instead of that we will sent it manually from opsd_send_email_to_user_notification function
|
||||
*
|
||||
* @param boolean $is_send_email
|
||||
* @param type $id
|
||||
* @param type $fields_values
|
||||
* @return boolean
|
||||
*/
|
||||
function opsd_email_api_is_allow_send_copy_block( $is_send_email, $id, $fields_values ) {
|
||||
$is_send_email = false;
|
||||
return $is_send_email;
|
||||
}
|
||||
// </editor-fold>
|
||||
@@ -0,0 +1,276 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @category Content of Add New Item
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-10-31
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
/** Show Content
|
||||
* Update Content
|
||||
* Define Slug
|
||||
* Define where to show
|
||||
*/
|
||||
class OPSD_Page_Files extends OPSD_Page_Structure {
|
||||
|
||||
|
||||
public function in_page() {
|
||||
return 'opsd-files';
|
||||
}
|
||||
|
||||
public function tabs() {
|
||||
|
||||
$tabs = array();
|
||||
$tabs[ 'add-files' ] = array(
|
||||
'title' => __('Add New', 'secure-downloads') // Title of TAB
|
||||
, 'hint' => __('Manage Files', 'secure-downloads') // Hint
|
||||
, 'page_title' => __('Manage Files', 'secure-downloads') // Title of Page
|
||||
, 'link' => '' // Can be skiped, then generated link based on Page and Tab tags. Or can be extenral link
|
||||
, 'position' => '' // 'left' || 'right' || ''
|
||||
, 'css_classes' => '' // CSS class(es)
|
||||
, 'icon' => '' // Icon - link to the real PNG img
|
||||
, 'font_icon' => 'glyphicon glyphicon-plus' // CSS definition of forn Icon
|
||||
, 'default' => true // Is this tab activated by default or not: true || false.
|
||||
, 'disabled' => false // Is this tab disbaled: true || false.
|
||||
, 'hided' => !true // Is this tab hided: true || false.
|
||||
, 'subtabs' => array()
|
||||
);
|
||||
|
||||
return $tabs;
|
||||
}
|
||||
|
||||
|
||||
public function content() {
|
||||
|
||||
// Checking ////////////////////////////////////////////////////////////
|
||||
|
||||
do_action( 'opsd_hook_settings_page_header', array( 'page' => $this->in_page() ) ); // Define Notices Section and show some static messages, if needed.
|
||||
|
||||
// Submit /////////////////////////////////////////////////////////////
|
||||
|
||||
$submit_form_name = 'opsd_products_csv_form'; // Define form name
|
||||
$updated_data = '';
|
||||
if ( isset( $_POST['is_form_sbmitted_'. $submit_form_name ] ) ) { // Check if was clicked on Saved
|
||||
|
||||
// Nonce checking {Return false if invalid, 1 if generated between, 0-12 hours ago, 2 if generated between 12-24 hours ago. }
|
||||
$nonce_gen_time = check_admin_referer( 'opsd_settings_page_' . $submit_form_name ); // Its stop show anything on submiting, if its not refear to the original page
|
||||
|
||||
// Save Changes
|
||||
$updated_data = $this->update();
|
||||
$updated_data = $updated_data['original_validated_data'];
|
||||
}
|
||||
|
||||
//$opsd_user_role_master = get_opsd_option( 'opsd_user_role_master' ); // O L D W A Y: Get Fields Data
|
||||
|
||||
|
||||
// JavaScript: Tooltips, Popover, Datepick (js & css) //////////////////
|
||||
echo '<span class="wpdevelop">';
|
||||
opsd_js_for_items_page();
|
||||
echo '</span>';
|
||||
|
||||
|
||||
// Content ////////////////////////////////////////////////////////////
|
||||
?>
|
||||
<div class="clear" style="margin-bottom:10px;"></div>
|
||||
<span class="metabox-holder">
|
||||
<form name="<?php echo $submit_form_name; ?>" id="<?php echo $submit_form_name; ?>" action="" method="post">
|
||||
<?php
|
||||
// N o n c e field, and key for checking S u b m i t
|
||||
wp_nonce_field( 'opsd_settings_page_' . $submit_form_name );
|
||||
?><input type="hidden" name="is_form_sbmitted_<?php echo $submit_form_name; ?>" id="is_form_sbmitted_<?php echo $submit_form_name; ?>" value="1" />
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_products_csv', __('Files List', 'secure-downloads') ); ?>
|
||||
|
||||
<table class="form-table">
|
||||
<tbody>
|
||||
<tr class="opsd_tr_opsd_products_csv_text " valign="top">
|
||||
<td scope="row" colspan="2">
|
||||
<?php
|
||||
|
||||
$field_name = 'opsd_products_csv_text';
|
||||
|
||||
$field_value = get_opsd_option('opsd_products_csv' );
|
||||
//$field_value = json_encode( $field_value ); // array('a' => 1, 'b' => 2 ... ) => {"a":1,"b":2 ...}
|
||||
|
||||
$place_holder = str_replace( '|', get_opsd_option( 'opsd_csv_separator' ), __( 'ID | Title | Version Number | Desciption | Path (URL)', 'secure-downloads' ) );
|
||||
$field = array(
|
||||
'title' => ''
|
||||
, 'description' => ''
|
||||
, 'type' => 'textarea'
|
||||
, 'value' => empty( $updated_data ) ? $field_value : $updated_data
|
||||
, 'class' => ''
|
||||
, 'css' => 'width:100%;'
|
||||
, 'placeholder' => $place_holder
|
||||
, 'disabled' => false
|
||||
, 'rows' => 8
|
||||
, 'show_in_2_cols' => true
|
||||
, 'only_field' => true
|
||||
);
|
||||
OPSD_Settings_API::field_textarea_row_static( $field_name, $field );
|
||||
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="opsd_tr_opsd_products_csv_text " valign="top">
|
||||
<td scope="row" colspan="2" style="font-style: italic;">
|
||||
<?php
|
||||
echo __( 'Please use one product per line.', 'secure-downloads' ) . '<br/>';
|
||||
echo __( 'CSV product configuration structure', 'secure-downloads' ) . ': <b>' . $place_holder . '</b>' . '<br/>';
|
||||
echo sprintf( __( 'Or just use simple text at row (without separators %s) for definition section.', 'secure-downloads' ), '<strong>' . get_opsd_option( 'opsd_csv_separator' ) . '</strong>' ) . '<br/>';
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
<div class="clear"></div>
|
||||
|
||||
<?php
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
// Add New Files button
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
?>
|
||||
<span class='wpdevelop' style="margin-right:15px;">
|
||||
<a class="button button-secondary opsd_btn_upload"
|
||||
style="font-weight: 600;"
|
||||
<?php echo 'data-' . esc_attr( 'modal_title' ) . '="' . esc_attr( __( 'Choose files', 'secure-downloads' ) ) . '" '; ?>
|
||||
<?php echo 'data-' . esc_attr( 'btn_title' ) . '="' . esc_attr( __( 'Insert', 'secure-downloads' ) ) . '" '; ?>
|
||||
href="javascript:void(0)" title="<?php _e('Add New Product' , 'secure-downloads') ?>"
|
||||
><span style="opsd_text_hide_mobile0"><?php echo __('Add New' , 'secure-downloads') . ' ' . __( 'Files', 'secure-downloads' ); ?> </span><span class="glyphicon glyphicon-plus" aria-hidden="true"></span></a>
|
||||
</span>
|
||||
<?php
|
||||
|
||||
// Get OPSD_Upload obj. instance
|
||||
$opsd_upload = opsd_upload();
|
||||
|
||||
$opsd_upload->set_upload_button( '.opsd_btn_upload' );
|
||||
|
||||
$opsd_upload->set_element_insert_url( '.opsd_file_urls' );
|
||||
|
||||
?><input type="submit" value="<?php _e('Save Changes', 'secure-downloads'); ?>" class="button button-primary opsd_submit_button" /><?php
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
// Help Notice
|
||||
/////////////////////////////////////////////////////////////////////////
|
||||
|
||||
?><div class="clear"style="margin-top:25px;"></div><?php
|
||||
|
||||
$notice_id = 'opsd_upload_help_section';
|
||||
if ( ! opsd_section_is_dismissed( $notice_id ) ) {
|
||||
|
||||
?><div id="<?php echo $notice_id; ?>"
|
||||
class="opsd_system_notice opsd_is_dismissible opsd_is_hideable notice-warning opsd_internal_notice"
|
||||
data-nonce="<?php echo wp_create_nonce( $nonce_name = $notice_id . '_opsdnonce' ); ?>"
|
||||
data-user-id="<?php echo get_current_user_id(); ?>"
|
||||
><?php
|
||||
|
||||
opsd_x_dismiss_button();
|
||||
|
||||
$field_options = array();
|
||||
$field_options[] = '<strong>' . __( 'How to add new product ?', 'secure-downloads' ) . '</strong>';
|
||||
$field_options[] = '1. ' . sprintf( __( 'Click on %s"Add New"%s button and upload your files', 'secure-downloads' ), '<strong>', '</strong>' );
|
||||
$field_options[] = '2. ' . sprintf( __( 'Enter Title, Version Number and Description at %s"Attachment details"%s section', 'secure-downloads' ), '<strong>', '</strong>' ) . ' <em>(' . __( 'at right side of page', 'secure-downloads' ) . ')</em>';
|
||||
$field_options[] = '3. ' . sprintf( __( 'Select one or multiple files and click on insert button', 'secure-downloads' ) );
|
||||
$field_options[] = '4. ' . sprintf( __( 'Save the changes.', 'secure-downloads' ) );
|
||||
|
||||
OPSD_Settings_API::field_help_row_static(
|
||||
'help_translation_section_after_legend_items'
|
||||
, array(
|
||||
'type' => 'help'
|
||||
, 'value' => $field_options
|
||||
, 'class' => ''
|
||||
, 'css' => 'margin:0;padding:0;border:0;'
|
||||
, 'description' => ''
|
||||
, 'cols' => 2
|
||||
, 'group' => 'help'
|
||||
, 'tr_class' => ''
|
||||
, 'description_tag' => 'p'
|
||||
)
|
||||
);
|
||||
?></div><?php
|
||||
}
|
||||
|
||||
?>
|
||||
</form>
|
||||
</span>
|
||||
<?php
|
||||
do_action( 'opsd_hook_settings_page_footer', 'csv_products' );
|
||||
}
|
||||
|
||||
|
||||
/** Save Settings
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function update() {
|
||||
|
||||
$validated_option = OPSD_Settings_API::validate_text_post_static( 'opsd_products_csv_text' );
|
||||
|
||||
update_opsd_option('opsd_products_csv', $validated_option );
|
||||
|
||||
opsd_show_changes_saved_message();
|
||||
|
||||
return array ( 'original_validated_data' => $validated_option );
|
||||
|
||||
|
||||
/** Standard Saving || Actions
|
||||
*
|
||||
$post_action_key = 'opsd_action';
|
||||
|
||||
$post_key = 'opsd_products_csv_text';
|
||||
|
||||
if ( isset( $_POST[ $post_action_key ] ) && ( $_POST[ $post_action_key ] == 'gogo2list' ) && ( isset( $_POST[ $post_key ] ) ) ) {
|
||||
|
||||
// Get Validated post
|
||||
$gogo_validated = OPSD_Settings_API::validate_text_post_static( $post_key );
|
||||
|
||||
|
||||
$show_debug_info_validated = OPSD_Settings_API::validate_checkbox_post_static( 'show_debug_info' );
|
||||
if ($show_debug_info_validated == 'On'){
|
||||
debuge( 'POST', $_POST );
|
||||
debuge('Validated data', $gogo_validated );
|
||||
}
|
||||
|
||||
|
||||
update_opsd_option('opsd_products_csv', $gogo_validated ); // Save to DB
|
||||
|
||||
opsd_show_changes_saved_message();
|
||||
|
||||
// opsd_show_message ( __('Done', 'secure-downloads'), 0 ); // Show Message
|
||||
|
||||
return array ( 'original_validated_data' => $gogo_validated ); // Exit, for do not parse
|
||||
}
|
||||
*/
|
||||
|
||||
/** Standard Bulk Saving of settings
|
||||
$validated_fields = $this->settings_api()->validate_post(); // Get Validated Settings fields in $_POST request.
|
||||
|
||||
$validated_fields = apply_filters( 'opsd_settings_validate_fields_before_saving', $validated_fields ); //Hook for validated fields.
|
||||
|
||||
unset($validated_fields['opsd_start_day_weeek']); // Skip saving specific option, for example in Demo mode.
|
||||
|
||||
$this->settings_api()->save_to_db( $validated_fields ); // Save fields to DB
|
||||
//opsd_show_changes_saved_message();
|
||||
opsd_show_message ( __('Done', 'secure-downloads'), 0 ); // Show Message
|
||||
*/
|
||||
|
||||
/** O L D W A Y: Saving Fields Data
|
||||
*
|
||||
update_opsd_option( 'opsd_is_delete_if_deactive'
|
||||
, OPSD_Settings_API::validate_checkbox_post('opsd_is_delete_if_deactive') );
|
||||
( (isset( $_POST['opsd_is_delete_if_deactive'] ))?'On':'Off') );
|
||||
*/
|
||||
}
|
||||
|
||||
}
|
||||
add_action('opsd_menu_created', array( new OPSD_Page_Files() , '__construct') ); // Executed after creation of Menu
|
||||
@@ -0,0 +1,479 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @category Content of Add New Item
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-10-31
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
|
||||
/** Show Content
|
||||
* Update Content
|
||||
* Define Slug
|
||||
* Define where to show
|
||||
*/
|
||||
class OPSD_Page_FilesSortable extends OPSD_Page_Structure {
|
||||
|
||||
|
||||
public function in_page() {
|
||||
return 'opsd-files';
|
||||
}
|
||||
|
||||
public function tabs() {
|
||||
|
||||
$tabs = array();
|
||||
$tabs[ 'files-sortable' ] = array(
|
||||
'title' => __('Sortable List', 'secure-downloads') // Title of TAB
|
||||
, 'hint' => __('Sortable List', 'secure-downloads') // Hint
|
||||
, 'page_title' => __('Manage List', 'secure-downloads') // Title of Page
|
||||
, 'link' => '' // Can be skiped, then generated link based on Page and Tab tags. Or can be extenral link
|
||||
, 'position' => '' // 'left' || 'right' || ''
|
||||
, 'css_classes' => '' // CSS class(es)
|
||||
, 'icon' => '' // Icon - link to the real PNG img
|
||||
, 'font_icon' => 'glyphicon glyphicon-sort' // CSS definition of forn Icon
|
||||
, 'default' => !true // Is this tab activated by default or not: true || false.
|
||||
, 'disabled' => false // Is this tab disbaled: true || false.
|
||||
, 'hided' => !true // Is this tab hided: true || false.
|
||||
, 'subtabs' => array()
|
||||
);
|
||||
|
||||
return $tabs;
|
||||
}
|
||||
|
||||
|
||||
public function content() {
|
||||
|
||||
// Checking ////////////////////////////////////////////////////////////
|
||||
|
||||
do_action( 'opsd_hook_settings_page_header', array( 'page' => $this->in_page() ) ); // Define Notices Section and show some static messages, if needed.
|
||||
|
||||
// Submit /////////////////////////////////////////////////////////////
|
||||
|
||||
$submit_form_name = 'opsd_sortable_products_form'; // Define form name
|
||||
$updated_data = '';
|
||||
if ( isset( $_POST['is_form_sbmitted_'. $submit_form_name ] ) ) { // Check if was clicked on Saved
|
||||
|
||||
// Nonce checking {Return false if invalid, 1 if generated between, 0-12 hours ago, 2 if generated between 12-24 hours ago. }
|
||||
$nonce_gen_time = check_admin_referer( 'opsd_settings_page_' . $submit_form_name ); // Its stop show anything on submiting, if its not refear to the original page
|
||||
|
||||
// Save Changes
|
||||
$updated_data = $this->update();
|
||||
//$updated_data = $updated_data['original_validated_data'];
|
||||
}
|
||||
|
||||
//$opsd_user_role_master = get_opsd_option( 'opsd_user_role_master' ); // O L D W A Y: Get Fields Data
|
||||
|
||||
|
||||
// JavaScript: Tooltips, Popover, Datepick (js & css) //////////////////
|
||||
echo '<span class="wpdevelop">';
|
||||
opsd_js_for_items_page();
|
||||
echo '</span>';
|
||||
|
||||
|
||||
// Content ////////////////////////////////////////////////////////////
|
||||
?>
|
||||
<div class="clear" style="margin-bottom:10px;"></div>
|
||||
<span class="metabox-holder">
|
||||
<form name="<?php echo $submit_form_name; ?>" id="<?php echo $submit_form_name; ?>" action="" method="post">
|
||||
<?php
|
||||
// N o n c e field, and key for checking S u b m i t
|
||||
wp_nonce_field( 'opsd_settings_page_' . $submit_form_name );
|
||||
?><input type="hidden" name="is_form_sbmitted_<?php echo $submit_form_name; ?>" id="is_form_sbmitted_<?php echo $submit_form_name; ?>" value="1" />
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_sortable_products_list', __('Products List', 'secure-downloads') ); ?>
|
||||
|
||||
<?php $this->show_soratble_table(); ?>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
<div class="clear"></div>
|
||||
<input type="submit" value="<?php _e('Save Changes', 'secure-downloads'); ?>" class="button button-primary opsd_submit_button" />
|
||||
|
||||
</form>
|
||||
</span>
|
||||
<?php
|
||||
do_action( 'opsd_hook_settings_page_footer', 'sortable_products' );
|
||||
}
|
||||
|
||||
|
||||
/** Save Settings
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function update() {
|
||||
|
||||
//debuge($_POST);
|
||||
|
||||
if ( isset( $_POST['pro'] ) ) {
|
||||
|
||||
// Get Exist List of products ////////////////////////////////////
|
||||
$products_csv = get_opsd_option('opsd_products_csv' );
|
||||
|
||||
$products_obj = new OPSD_Products();
|
||||
|
||||
$products_obj->define_products_from_csv( $products_csv );
|
||||
|
||||
$products = $products_obj->get_products(); /**
|
||||
[id] => 206
|
||||
[title] => product.developer
|
||||
[version_num] => 'gdfgd'
|
||||
[description] => 'gdfgdf'
|
||||
[path] => /wp-content/uploads/opsd_lSJacOT1yVLFnrkqt2xR/2017/04/product.developer.zip
|
||||
*/
|
||||
|
||||
// New products /////////////////////////////////////////////////
|
||||
$new_products_arr = array();
|
||||
//debuge($_POST);
|
||||
foreach ( $_POST['pro'] as $post_index => $pro_id ) {
|
||||
|
||||
$product_arr = array();
|
||||
|
||||
$exist_product = $products_obj->get_product( $pro_id );
|
||||
//debuge($pro_id, $exist_product) ;
|
||||
if ( ! empty( $exist_product ) ) {
|
||||
|
||||
$post_key = 'pro'; // ID
|
||||
if ( isset( $_POST[ $post_key ] ) && isset( $_POST[ $post_key ][ $post_index ] ) ) {
|
||||
$product_arr[ 'id' ] = OPSD_Settings_API::validate_text_post_static( $post_key , $post_index ); // Validate
|
||||
}
|
||||
$post_key = 'pro_title';
|
||||
if ( isset( $_POST[ $post_key ] ) && isset( $_POST[ $post_key ][ $post_index ] ) ) {
|
||||
$product_arr[ 'title' ] = OPSD_Settings_API::validate_text_post_static( $post_key , $post_index ); // Validate
|
||||
}
|
||||
$post_key = 'pro_version_num';
|
||||
if ( isset( $_POST[ $post_key ] ) && isset( $_POST[ $post_key ][ $post_index ] ) ) {
|
||||
$product_arr[ 'version_num' ] = OPSD_Settings_API::validate_text_post_static( $post_key , $post_index ); // Validate
|
||||
}
|
||||
|
||||
$post_key = 'pro_description';
|
||||
if ( isset( $_POST[ $post_key ] ) && isset( $_POST[ $post_key ][ $post_index ] ) ) {
|
||||
$product_arr[ 'description' ] = OPSD_Settings_API::validate_text_post_static( $post_key , $post_index ); // Validate
|
||||
}
|
||||
|
||||
//$product_arr[ 'description' ] = $exist_product['description'];
|
||||
|
||||
$post_key = 'pro_path';
|
||||
if ( isset( $_POST[ $post_key ] ) && isset( $_POST[ $post_key ][ $post_index ] ) ) {
|
||||
$product_arr[ 'path' ] = trim( str_replace(
|
||||
site_url()
|
||||
, ''
|
||||
, OPSD_Settings_API::validate_text_post_static( $post_key , $post_index )
|
||||
) ); // Get local relative path
|
||||
}
|
||||
} else {
|
||||
|
||||
// Product does not exist so probabaly its Group section title.
|
||||
$post_key = 'pro_title';
|
||||
if ( isset( $_POST[ $post_key ] ) && isset( $_POST[ $post_key ][ $post_index ] ) ) {
|
||||
$product_arr[ 'title' ] = OPSD_Settings_API::validate_text_post_static( $post_key , $post_index ); // Validate
|
||||
}
|
||||
|
||||
}
|
||||
$new_products_arr[] = $product_arr;
|
||||
}
|
||||
|
||||
// Create CSV
|
||||
//debuge($new_products_arr);
|
||||
$products_csv = $products_obj->save_products( $new_products_arr );
|
||||
opsd_show_changes_saved_message();
|
||||
|
||||
return array ( 'original_validated_data' => $products_csv );
|
||||
}
|
||||
|
||||
|
||||
|
||||
// $validated_option = OPSD_Settings_API::validate_text_post_static( 'opsd_sortable_products_text' );
|
||||
//
|
||||
// update_opsd_option('opsd_sortable_products', $validated_option );
|
||||
//
|
||||
// opsd_show_changes_saved_message();
|
||||
//
|
||||
// return array ( 'original_validated_data' => $validated_option );
|
||||
|
||||
|
||||
/** Standard Saving || Actions
|
||||
*
|
||||
$post_action_key = 'opsd_action';
|
||||
|
||||
$post_key = 'opsd_sortable_products_text';
|
||||
|
||||
if ( isset( $_POST[ $post_action_key ] ) && ( $_POST[ $post_action_key ] == 'gogo2list' ) && ( isset( $_POST[ $post_key ] ) ) ) {
|
||||
|
||||
// Get Validated post
|
||||
$gogo_validated = OPSD_Settings_API::validate_text_post_static( $post_key );
|
||||
|
||||
|
||||
$show_debug_info_validated = OPSD_Settings_API::validate_checkbox_post_static( 'show_debug_info' );
|
||||
if ($show_debug_info_validated == 'On'){
|
||||
debuge( 'POST', $_POST );
|
||||
debuge('Validated data', $gogo_validated );
|
||||
}
|
||||
|
||||
|
||||
update_opsd_option('opsd_sortable_products', $gogo_validated ); // Save to DB
|
||||
|
||||
opsd_show_changes_saved_message();
|
||||
|
||||
// opsd_show_message ( __('Done', 'secure-downloads'), 0 ); // Show Message
|
||||
|
||||
return array ( 'original_validated_data' => $gogo_validated ); // Exit, for do not parse
|
||||
}
|
||||
*/
|
||||
|
||||
/** Standard Bulk Saving of settings
|
||||
$validated_fields = $this->settings_api()->validate_post(); // Get Validated Settings fields in $_POST request.
|
||||
|
||||
$validated_fields = apply_filters( 'opsd_settings_validate_fields_before_saving', $validated_fields ); //Hook for validated fields.
|
||||
|
||||
unset($validated_fields['opsd_start_day_weeek']); // Skip saving specific option, for example in Demo mode.
|
||||
|
||||
$this->settings_api()->save_to_db( $validated_fields ); // Save fields to DB
|
||||
//opsd_show_changes_saved_message();
|
||||
opsd_show_message ( __('Done', 'secure-downloads'), 0 ); // Show Message
|
||||
*/
|
||||
|
||||
/** O L D W A Y: Saving Fields Data
|
||||
*
|
||||
update_opsd_option( 'opsd_is_delete_if_deactive'
|
||||
, OPSD_Settings_API::validate_checkbox_post('opsd_is_delete_if_deactive') );
|
||||
( (isset( $_POST['opsd_is_delete_if_deactive'] ))?'On':'Off') );
|
||||
*/
|
||||
}
|
||||
|
||||
|
||||
public function show_soratble_table() {
|
||||
|
||||
// Get List of products ////////////////////////////////////
|
||||
$products_csv = get_opsd_option('opsd_products_csv' );
|
||||
|
||||
$products_obj = new OPSD_Products();
|
||||
|
||||
$products_obj->define_products_from_csv( $products_csv ); /** Array
|
||||
(
|
||||
[id] => 0
|
||||
[order] => 0
|
||||
[ip] => 0.0.0.0
|
||||
[ipl] => 0
|
||||
[expire] => +1440 seconds
|
||||
[title] => Personal
|
||||
[size] => 3.45
|
||||
[path] => XXXXXXXXXX/wpbc/personal.zip
|
||||
), ...
|
||||
*/
|
||||
|
||||
$products = $products_obj->get_products();
|
||||
|
||||
//debuge($products);die;
|
||||
/**
|
||||
[id] => 207
|
||||
[order] => 0
|
||||
[ip] => 0.0.0.0
|
||||
[expire] => +1 day
|
||||
[title] => product.multisite
|
||||
[version_num] =>
|
||||
[description] =>
|
||||
[path] => /wp-content/uploads/opsd_lSJacOT1yVLFnrkqt2xR/2017/04/product.multisite.zip
|
||||
*/
|
||||
?>
|
||||
<div class="opsd_sortable_table wpdevelop" >
|
||||
<table class="widefat opsd_input_table sortable table table-striped" cellspacing="0" cellpadding="0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="sort"> </th>
|
||||
<th style="width:30px;"><?php _e('ID', 'secure-downloads' ) ?></th>
|
||||
<th style="width:15%"><?php _e('Title', 'secure-downloads' ) ?></th>
|
||||
<th style="width:10%"><?php _e('Version', 'secure-downloads' ) ?></th>
|
||||
<th style="width:22%"><?php _e('Desciption', 'secure-downloads' ) ?></th>
|
||||
<th><?php _e('Path', 'secure-downloads' ) ?></th>
|
||||
<th style="width:70px;"><?php _e('Actions', 'secure-downloads' ) ?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody class="accounts">
|
||||
<?php
|
||||
$i = -1;
|
||||
if ( ! empty( $products ) ) {
|
||||
|
||||
foreach ( $products as $product_id => $product ) {
|
||||
$i++;
|
||||
|
||||
if ( count($product) > 5 ) { //Skip emty rows.
|
||||
|
||||
$product_id = $product[ 'id' ];
|
||||
echo
|
||||
'<tr class="account" id="'. $product_id .'">'
|
||||
. '<td class="sort"><input type="hidden" value="' . esc_attr( wp_unslash( $product_id ) ) . '" name="pro[' . $i . ']" /></td>'
|
||||
. '<th style="vertical-align:middle;">' . wp_unslash( esc_js( $product_id ) ) . '</th>'
|
||||
. '<td><input style="font-weight:600;" type="text" value="' . wp_unslash( esc_js( $product['title'] ) ) . '" name="pro_title[' . $i . ']" /></td>'
|
||||
. '<td><input type="text" value="' . wp_unslash( esc_js( $product['version_num'] ) ) . '" name="pro_version_num[' . $i . ']" /></td>'
|
||||
. '<td><textarea name="pro_description[' . $i . ']" style="height:2em;width:100%;">'.wp_unslash( esc_js( $product['description'] ) ).'</textarea></td>'
|
||||
. '<td><input type="text" value="' . wp_unslash( esc_js( $product['path'] ) ) . '" name="pro_path[' . $i . ']" /></td>'
|
||||
. '<td style="text-align:center;">'
|
||||
. '<a href="javascript:void(0)"
|
||||
class="button-secondary button opsd_delete_row"
|
||||
title="'. esc_js( __( 'Delete', 'secure-downloads' ) ) .'"
|
||||
data-original-title="Completely "><i class="glyphicon glyphicon-remove"></i></a>'
|
||||
.'</td>'
|
||||
. '</tr>';
|
||||
} else {
|
||||
|
||||
$product_id = time() + wp_rand( 1000 );
|
||||
echo '<tr class="account" id="'. $product_id .'">'
|
||||
. '<td class="sort"><input type="hidden" value="' . esc_attr( wp_unslash( $product_id ) ) . '" name="pro[' . $i . ']" /></td>'
|
||||
. '<td style="vertical-align:middle;" colspan="5">'
|
||||
. '<input style="font-weight:600;" type="text" value="' . wp_unslash( esc_js( $product['title'] ) ) . '" name="pro_title[' . $i . ']" />'
|
||||
. '</td>'
|
||||
. '<td style="text-align:center;">'
|
||||
. '<a href="javascript:void(0)"
|
||||
class="button-secondary button opsd_delete_row"
|
||||
title="'. esc_js( __( 'Delete', 'secure-downloads' ) ) .'"
|
||||
data-original-title="Completely "><i class="glyphicon glyphicon-remove"></i></a>'
|
||||
.'</td>'
|
||||
. '</tr>';
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
</tbody>
|
||||
<?php /* ?>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<th colspan="7"><a href="#" class="add button"><?php _e( '+ Add Account' , 'secure-downloads' ); ?></a> <a href="#" class="remove_rows button"><?php _e( 'Remove selected account(s)' , 'secure-downloads' ); ?></a></th>
|
||||
</tr>
|
||||
</tfoot>
|
||||
<?php /**/ ?>
|
||||
</table>
|
||||
<script type="text/javascript">
|
||||
|
||||
jQuery( function ( $ ) { // Shortcut to jQuery(document).ready(function(){ ... });
|
||||
|
||||
|
||||
$('.opsd_input_table tbody th, .opsd_sortable_table tbody td').css('cursor','move');
|
||||
|
||||
$('.opsd_input_table tbody td.sort').css('cursor','move');
|
||||
|
||||
$('.opsd_input_table.sortable tbody').sortable({
|
||||
items:'tr',
|
||||
cursor:'move',
|
||||
axis:'y',
|
||||
scrollSensitivity:40,
|
||||
forcePlaceholderSize: true,
|
||||
helper: 'clone',
|
||||
opacity: 0.65,
|
||||
placeholder: '.opsd_sortable_table .sort',
|
||||
start:function(event,ui){
|
||||
ui.item.css('background-color','#f6f6f6');
|
||||
},
|
||||
stop:function(event,ui){
|
||||
ui.item.removeAttr('style');
|
||||
}
|
||||
});
|
||||
|
||||
jQuery( '.opsd_sortable_table' ).on( 'click', '.opsd_delete_row', function ( event ) { // This delegated event, can be run, when DOM element added after page loaded
|
||||
|
||||
var jq_row = jQuery( this ).closest( 'tr' );
|
||||
|
||||
jq_row.remove();
|
||||
});
|
||||
|
||||
|
||||
jQuery( '.opsd_sortable_table' ).on( 'focusin', 'textarea[name^="pro_description"]', function(){ jQuery( this ).css( 'height', '5em' ); } );
|
||||
jQuery( '.opsd_sortable_table' ).on( 'focusout', 'textarea[name^="pro_description"]', function(){ jQuery( this ).css( 'height', '2em' ); } );
|
||||
|
||||
//jQuery( 'input[name^="pro_path"]' ).on( 'focus', function(){ jQuery( this ).css( 'height', '5em' ); } );
|
||||
//jQuery( 'input[name^="pro_path"]' ).on( 'blur', function(){ jQuery( this ).css( 'height', 'auto' ); } );
|
||||
/** Add new row
|
||||
jQuery('.opsd_sortable_table').on( 'click', 'a.add', function(){
|
||||
|
||||
var size = jQuery('.opsd_sortable_table tbody .account').size();
|
||||
|
||||
jQuery('<tr class="account">\
|
||||
<td class="sort"></td>\
|
||||
<td><legend class="opsd_mobile_legend"><?php echo esc_js( '' ); ?>:</legend><input type="text" name="bank_transfer_account_name[' + size + ']" /></td>\
|
||||
<td><legend class="opsd_mobile_legend"><?php echo esc_js( '' ); ?>:</legend><input type="text" name="bank_transfer_account_number[' + size + ']" /></td>\
|
||||
<td><legend class="opsd_mobile_legend"><?php echo esc_js( '' ); ?>:</legend><input type="text" name="bank_transfer_bank_name[' + size + ']" /></td>\
|
||||
<td><legend class="opsd_mobile_legend"><?php echo esc_js( '' ); ?>:</legend><input type="text" name="bank_transfer_sort_code[' + size + ']" /></td>\
|
||||
</tr>').appendTo('.opsd_sortable_table table tbody');
|
||||
|
||||
jQuery('.opsd_input_table tbody th, .opsd_sortable_table tbody td').css('cursor','move');
|
||||
return false;
|
||||
});
|
||||
*/
|
||||
|
||||
/** Delete current row depend from Focus
|
||||
$('.opsd_input_table .remove_rows').on( 'click', function() {
|
||||
var $tbody = $(this).closest('.opsd_input_table').find('tbody');
|
||||
if ( $tbody.find('tr.current').size() > 0 ) {
|
||||
$current = $tbody.find('tr.current');
|
||||
|
||||
$current.each(function(){
|
||||
$(this).remove();
|
||||
});
|
||||
}
|
||||
return false;
|
||||
});
|
||||
|
||||
var controlled = false;
|
||||
var shifted = false;
|
||||
var hasFocus = false;
|
||||
|
||||
$(document).on( 'keyup keydown', function(e){ shifted = e.shiftKey; controlled = e.ctrlKey || e.metaKey } );
|
||||
|
||||
$('.opsd_input_table').on( 'focus click', 'input', function( e ) {
|
||||
|
||||
$this_table = $(this).closest('table');
|
||||
$this_row = $(this).closest('tr');
|
||||
|
||||
if ( ( e.type == 'focus' && hasFocus != $this_row.index() ) || ( e.type == 'click' && $(this).is(':focus') ) ) {
|
||||
|
||||
hasFocus = $this_row.index();
|
||||
|
||||
if ( ! shifted && ! controlled ) {
|
||||
$('tr', $this_table).removeClass('current').removeClass('last_selected');
|
||||
$this_row.addClass('current').addClass('last_selected');
|
||||
} else if ( shifted ) {
|
||||
$('tr', $this_table).removeClass('current');
|
||||
$this_row.addClass('selected_now').addClass('current');
|
||||
|
||||
if ( $('tr.last_selected', $this_table).size() > 0 ) {
|
||||
if ( $this_row.index() > $('tr.last_selected, $this_table').index() ) {
|
||||
$('tr', $this_table).slice( $('tr.last_selected', $this_table).index(), $this_row.index() ).addClass('current');
|
||||
} else {
|
||||
$('tr', $this_table).slice( $this_row.index(), $('tr.last_selected', $this_table).index() + 1 ).addClass('current');
|
||||
}
|
||||
}
|
||||
|
||||
$('tr', $this_table).removeClass('last_selected');
|
||||
$this_row.addClass('last_selected');
|
||||
} else {
|
||||
$('tr', $this_table).removeClass('last_selected');
|
||||
if ( controlled && $(this).closest('tr').is('.current') ) {
|
||||
$this_row.removeClass('current');
|
||||
} else {
|
||||
$this_row.addClass('current').addClass('last_selected');
|
||||
}
|
||||
}
|
||||
|
||||
$('tr', $this_table).removeClass('selected_now');
|
||||
|
||||
}
|
||||
}).on( 'blur', 'input', function( e ) {
|
||||
hasFocus = false;
|
||||
});
|
||||
*/
|
||||
|
||||
});
|
||||
</script>
|
||||
</div>
|
||||
<?php
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
add_action('opsd_menu_created', array( new OPSD_Page_FilesSortable() , '__construct') ); // Executed after creation of Menu
|
||||
987
wp-content/plugins/secure-downloads/core/admin/page-send.php
Normal file
987
wp-content/plugins/secure-downloads/core/admin/page-send.php
Normal file
@@ -0,0 +1,987 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @category Content of item Listing page
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-11-13
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
/** Show Content
|
||||
* Update Content
|
||||
* Define Slug
|
||||
* Define where to show
|
||||
*/
|
||||
class OPSD_Page_Single extends OPSD_Page_Structure {
|
||||
|
||||
|
||||
public function in_page() {
|
||||
return 'opsd';
|
||||
}
|
||||
|
||||
|
||||
public function tabs() {
|
||||
|
||||
$tabs = array();
|
||||
$tabs[ 'send' ] = array(
|
||||
'title' => __('Send Link', 'secure-downloads') // Title of TAB
|
||||
, 'hint' => __('Send Link', 'secure-downloads') // Hint
|
||||
, 'page_title' => __('Send Link', 'secure-downloads') // Title of Page
|
||||
, 'link' => '' // Can be skiped, then generated link based on Page and Tab tags. Or can be extenral link
|
||||
, 'position' => '' // 'left' || 'right' || ''
|
||||
, 'css_classes' => '' // CSS class(es)
|
||||
, 'icon' => '' // Icon - link to the real PNG img
|
||||
, 'font_icon' => 'glyphicon glyphicon-th' // CSS definition of forn Icon
|
||||
, 'default' => true // Is this tab activated by default or not: true || false.
|
||||
, 'disabled' => false // Is this tab disbaled: true || false.
|
||||
, 'hided' => true // Is this tab hided: true || false.
|
||||
, 'subtabs' => array()
|
||||
|
||||
);
|
||||
// $subtabs = array();
|
||||
// $tabs[ 'items' ][ 'subtabs' ] = $subtabs;
|
||||
return $tabs;
|
||||
}
|
||||
|
||||
|
||||
public function content() {
|
||||
|
||||
// Checking ////////////////////////////////////////////////////////////
|
||||
|
||||
do_action( 'opsd_hook_settings_page_header', array( 'page' => $this->in_page() ) ); // Define Notices Section and show some static messages, if needed.
|
||||
|
||||
// $this->settings_api(); // Init Settings API & Get Data from DB // Define all fields and get values from DB
|
||||
|
||||
|
||||
// Submit /////////////////////////////////////////////////////////////
|
||||
|
||||
$submit_form_name = 'opsd_send_links_form'; // Define form name
|
||||
|
||||
$data_after_update = false;
|
||||
if ( isset( $_POST['is_form_sbmitted_'. $submit_form_name ] ) ) {
|
||||
|
||||
// Nonce checking {Return false if invalid, 1 if generated between, 0-12 hours ago, 2 if generated between 12-24 hours ago. }
|
||||
$nonce_gen_time = check_admin_referer( 'opsd_settings_page_' . $submit_form_name ); // Its stop show anything on submiting, if its not refear to the original page
|
||||
|
||||
// Save Changes
|
||||
$data_after_update = $this->update();
|
||||
$updated_data = '';//$data_after_update['original_validated_data'];
|
||||
} else {
|
||||
$updated_data = '';
|
||||
}
|
||||
|
||||
//$opsd_user_role_master = get_opsd_option( 'opsd_user_role_master' ); // O L D W A Y: Get Fields Data
|
||||
|
||||
// JavaScript: Tooltips, Popover, Datepick (js & css) //////////////////
|
||||
echo '<span class="wpdevelop">';
|
||||
opsd_js_for_items_page();
|
||||
echo '</span>';
|
||||
|
||||
?><span class="wpdevelop"><?php // BS UI CSS Class
|
||||
// T o o l b a r s /////////////////////////////////////////////////
|
||||
// opsd_items_toolbar();
|
||||
?></span><?php
|
||||
|
||||
?><div class="clear" style="height:0px;"></div><?php
|
||||
|
||||
|
||||
// Content ////////////////////////////////////////////////////////////
|
||||
?>
|
||||
<div class="clear" style="margin-bottom:10px;"></div>
|
||||
<span class="metabox-holder">
|
||||
<form name="<?php echo $submit_form_name; ?>" id="<?php echo $submit_form_name; ?>" action="" method="post" >
|
||||
<?php
|
||||
// N o n c e field, and key for checking S u b m i t
|
||||
wp_nonce_field( 'opsd_settings_page_' . $submit_form_name );
|
||||
?><input type="hidden" name="is_form_sbmitted_<?php echo $submit_form_name; ?>" id="is_form_sbmitted_<?php echo $submit_form_name; ?>" value="1" />
|
||||
|
||||
<div class="clear" style="margin-bottom:0px;"></div>
|
||||
|
||||
<div class="opsd_settings_row opsd_settings_row_left" >
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_single_results', __('Send', 'secure-downloads') ); ?>
|
||||
|
||||
<?php
|
||||
|
||||
// Get List of products ////////////////////////////////////
|
||||
$products_csv = get_opsd_option('opsd_products_csv' );
|
||||
|
||||
$products_obj = new OPSD_Products();
|
||||
|
||||
$products_obj->define_products_from_csv( $products_csv ); /** Array
|
||||
(
|
||||
[id] => 0
|
||||
[order] => 0
|
||||
[ip] => 0.0.0.0
|
||||
[ipl] => 0
|
||||
[expire] => +1440 seconds
|
||||
[title] => Personal
|
||||
[size] => 3.45
|
||||
[path] => XXXXXXXXXX/wpbc/personal.zip
|
||||
), ...
|
||||
*/
|
||||
|
||||
$products = $products_obj->get_products();
|
||||
|
||||
//$secret_link = opsd_get_secret_link( $products[0] ); // Get Secret Link
|
||||
|
||||
// Warning - NO Products
|
||||
if ( $products_obj->get_products_count() == 0 ) {
|
||||
|
||||
$notice_id = 'opsd_warning_no_products';
|
||||
if ( ! opsd_section_is_dismissed( $notice_id ) ) {
|
||||
|
||||
?><div id="<?php echo $notice_id; ?>"
|
||||
class="opsd_system_notice opsd_is_dismissible0 opsd_is_hideable0 notice-error opsd_internal_notice"
|
||||
data-nonce="<?php echo wp_create_nonce( $nonce_name = $notice_id . '_opsdnonce' ); ?>"
|
||||
data-user-id="<?php echo get_current_user_id(); ?>"
|
||||
><?php
|
||||
// opsd_x_dismiss_button();
|
||||
echo '<strong>' . __( 'Warning!', 'secure-downloads' ) . '</strong> ';
|
||||
printf( __( 'No products defined at %s menu page.', 'secure-downloads' )
|
||||
, '<a href="' . admin_url( 'admin.php?page=opsd-files' ) . '">'
|
||||
. '<strong>' . 'Secure Downloads > ' . __( 'Files', 'secure-downloads' ) . '</strong>'
|
||||
. '</a>'
|
||||
);
|
||||
?></div><?php
|
||||
}
|
||||
|
||||
$opsd_csv_separator = get_opsd_option( 'opsd_csv_separator' );
|
||||
if ( ( strlen( $products_csv ) > 0 )
|
||||
&& ( strpos( $products_csv, $opsd_csv_separator ) === false ) ) {
|
||||
|
||||
|
||||
$notice_id = 'opsd_warning_wrong_csv_separator';
|
||||
if ( ! opsd_section_is_dismissed( $notice_id ) ) {
|
||||
|
||||
?><div id="<?php echo $notice_id; ?>"
|
||||
class="opsd_system_notice opsd_is_dismissible0 opsd_is_hideable0 notice-warning opsd_internal_notice"
|
||||
data-nonce="<?php echo wp_create_nonce( $nonce_name = $notice_id . '_opsdnonce' ); ?>"
|
||||
data-user-id="<?php echo get_current_user_id(); ?>"
|
||||
><?php
|
||||
// opsd_x_dismiss_button();
|
||||
echo '<strong>' . __( 'Warning!', 'secure-downloads' ) . '</strong> ';
|
||||
printf( __( 'Probabaly you have defined incorrect CSV separator at %s menu page.', 'secure-downloads' )
|
||||
, '<a href="' . admin_url( 'admin.php?page=opsd-settings' ) . '#opsd_general_settings_opsd_misc_metabox">'
|
||||
. '<strong>' . __( 'Settings', 'secure-downloads' ) . '</strong>'
|
||||
. '</a>'
|
||||
);
|
||||
?></div><?php
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
} else {
|
||||
|
||||
if ( ! empty( $data_after_update ) ) {
|
||||
opsd_show_copy_button();
|
||||
}
|
||||
|
||||
?><div class="opsd_link_container wpdevelop"><?php
|
||||
|
||||
// Email //////////////////////////////////////////////////
|
||||
$fields = array( 'type' => 'email',
|
||||
'title' => ''
|
||||
, 'disabled' => false
|
||||
, 'class' => ''
|
||||
, 'css' => ''
|
||||
, 'placeholder' => 'info@server.com'
|
||||
, 'description' => ''
|
||||
, 'attr' => array()
|
||||
, 'group' => 'general'
|
||||
, 'tr_class' => ''
|
||||
, 'only_field' => true
|
||||
, 'description_tag' => 'p'
|
||||
, 'validate_as' => array( 'email' )
|
||||
, 'value' => ( ( ! empty( $_GET[ 'email' ] ) ) ? sanitize_email( $_GET[ 'email' ] ) : '' ) //FixIn: 1.1.5
|
||||
);
|
||||
OPSD_Settings_API::field_text_row_static( 'opsd_email_to', $fields );
|
||||
|
||||
// Send Button ////////////////////////////////////////////
|
||||
?>
|
||||
<a class="button button-primary opsd_send_button opsd_generate_button"
|
||||
href="javascript:void(0)" title="<?php _e('Generate Secure Link for Download' , 'secure-downloads') ?>"
|
||||
><span class="opsd_text_hide_mobile"><?php _e('Generate' , 'secure-downloads') ?> </span><span class="glyphicon glyphicon-share-alt" aria-hidden="true"></span></a>
|
||||
</div>
|
||||
<input type="hidden" value='' name='opsd_action' id='opsd_action' />
|
||||
<?php
|
||||
|
||||
|
||||
|
||||
// Products List //////////////////////////////////////////
|
||||
$options = array( '' => __( 'Please Select', 'secure-downloads' ) );
|
||||
|
||||
$is_group_open = false;
|
||||
|
||||
//FixIn: 1.1.5
|
||||
$selected_product_id = ( ! empty( $_GET[ 'product_id' ] ) ) ? intval( $_GET[ 'product_id' ] ) : 0 ;
|
||||
|
||||
$check_name = '';
|
||||
if ( ! empty( $_GET[ 'product_name' ] ) ) {
|
||||
$check_name = esc_js( $_GET[ 'product_name' ] );
|
||||
}
|
||||
|
||||
foreach ( $products as $product_arr ) {
|
||||
|
||||
//FixIn: 1.1.5
|
||||
if ( ( ! empty( $check_name ) ) && ( $product_arr['title'] == $check_name ) ) { //FixIn: 1.1.3.2
|
||||
$selected_product_id = $product_arr['id'];
|
||||
}
|
||||
|
||||
if ( count($product_arr) == 2 ) { //Group
|
||||
|
||||
if ( $is_group_open ) {
|
||||
$options[ intval( microtime( false ) ) + wp_rand(100) ] = array( 'optgroup' => true, 'title' =>'', 'close' => true ) ; //FixIn: 1.1.2.3
|
||||
}
|
||||
|
||||
$options[ intval( microtime( false ) ) + wp_rand(100) ] = array( 'optgroup' => true, 'title' => $product_arr['title'], 'close' => false ) ; //FixIn: 1.1.2.3
|
||||
$is_group_open = true;
|
||||
|
||||
} else { // Regular option
|
||||
|
||||
|
||||
$options[ $product_arr['id'] ] = $product_arr['title'] . ' ~ ' . $product_arr['version_num'];
|
||||
}
|
||||
}
|
||||
|
||||
//Close group, if opened
|
||||
if ( $is_group_open ) {
|
||||
$options[ intval( microtime( false ) ) + wp_rand(100) ] = array( 'optgroup' => true, 'title' =>'', 'close' => true ) ; //FixIn: 1.1.2.3
|
||||
}
|
||||
|
||||
|
||||
$fields = array(
|
||||
'title' => ''
|
||||
, 'label' => ''
|
||||
, 'disabled' => false
|
||||
, 'disabled_options' => array()
|
||||
, 'class' => 'opsd_product_selection'
|
||||
, 'css' => ''
|
||||
, 'type' => 'select'
|
||||
, 'description' => ''
|
||||
, 'multiple' => ! true
|
||||
, 'attr' => array( 'size' => 1 )
|
||||
, 'options' => $options
|
||||
, 'group' => 'general'
|
||||
, 'tr_class' => ''
|
||||
, 'only_field' => true
|
||||
, 'description_tag' => 'span'
|
||||
, 'value' => ( ( ! empty( $selected_product_id ) ) ? intval( $selected_product_id ) : 1 ) //FixIn: 1.1.4 //FixIn: 1.1.5
|
||||
);
|
||||
OPSD_Settings_API::field_select_row_static( 'opsd_product_selection', $fields );
|
||||
|
||||
}
|
||||
|
||||
do_action( 'opsd_secure_links_send_section_footer' );
|
||||
|
||||
?>
|
||||
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_single_help', __('Info', 'secure-downloads') ); ?>
|
||||
|
||||
<?php //$this->settings_api()->show( 'help' ); ?>
|
||||
<div class="opsd_submmary">
|
||||
<?php printf(__('Nothing yet.', 'secure-downloads'),'<code>[email]</code>') ?>
|
||||
</div>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
</div>
|
||||
<div class="opsd_settings_row opsd_settings_row_right">
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_single_actions', __('Advanced', 'secure-downloads') ); ?>
|
||||
|
||||
<table class="form-table">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td style="padding-left: 0;">
|
||||
|
||||
|
||||
</td>
|
||||
<td>
|
||||
<?php
|
||||
|
||||
$mail_api = new OPSD_Emails_API_LinkUser( OPSD_EMAIL_LINK_USER_ID );
|
||||
|
||||
$field_name = 'send_copy_to_admin';
|
||||
|
||||
$field = array(
|
||||
'title' => ''
|
||||
, 'label' => __('Send copy to administrator', 'secure-downloads')
|
||||
, 'type' => 'checkbox'
|
||||
, 'value' => ( ( $mail_api->fields_values['copy_to_admin'] == 'On' ) ? 'On' : 'Off' )
|
||||
, 'class' => ''
|
||||
, 'css' => ''
|
||||
, 'group' => 'advanced'
|
||||
, 'only_field' => true
|
||||
);
|
||||
OPSD_Settings_API::field_checkbox_row_static( $field_name, $field );
|
||||
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php
|
||||
|
||||
$options = array(
|
||||
'' => __('Default Expiration', 'secure-downloads')
|
||||
, '+5 minutes' => '5 ' . __('minutes', 'secure-downloads')
|
||||
, '+15 minutes' => '15 ' . __('minutes', 'secure-downloads')
|
||||
, '+30 minutes' => '30 ' . __('minutes', 'secure-downloads')
|
||||
, '+45 minutes' => '45 ' . __('minutes', 'secure-downloads')
|
||||
, '+1 hour' => '1 ' . __('hour', 'secure-downloads')
|
||||
, '+6 hours' => '6 ' . __('hours', 'secure-downloads')
|
||||
, '+12 hours' => '12 ' . __('hours', 'secure-downloads')
|
||||
, '+24 hours' => '24 ' . __('hours', 'secure-downloads')
|
||||
, '+3 days' => '3 ' . __('days', 'secure-downloads')
|
||||
, '+5 days' => '5 ' . __('days', 'secure-downloads')
|
||||
, '+7 days' => '7 ' . __('days', 'secure-downloads')
|
||||
, '+30 days' => '30 ' . __('days', 'secure-downloads')
|
||||
, '+90 days' => '90 ' . __('days', 'secure-downloads')
|
||||
, '+365 days' => '1 ' . __('year', 'secure-downloads')
|
||||
, '0' => __('Never', 'secure-downloads') //FixIn: 1.2.2.2
|
||||
);
|
||||
// Expire
|
||||
$fields = array(
|
||||
'title' => __('Link expire after', 'secure-downloads')
|
||||
, 'label' => ''
|
||||
, 'disabled' => false
|
||||
, 'disabled_options' => array()
|
||||
, 'class' => ''
|
||||
, 'css' => ''
|
||||
, 'type' => 'select'
|
||||
, 'description' => ''
|
||||
, 'multiple' => false
|
||||
, 'attr' => array()
|
||||
, 'options' => $options
|
||||
, 'group' => 'advanced'
|
||||
, 'tr_class' => ''
|
||||
, 'only_field' => false
|
||||
, 'description_tag' => 'span'
|
||||
, 'value' => get_opsd_option( 'opsd_defualt_expiration' ) //array( '+24 hours' )
|
||||
);
|
||||
OPSD_Settings_API::field_select_row_static( 'opsd_product_expire', $fields );
|
||||
|
||||
|
||||
// IP lock
|
||||
$fields = array(
|
||||
'title' => __( 'IP Lock', 'secure-downloads')
|
||||
, 'disabled' => false
|
||||
, 'class' => ''
|
||||
, 'css' => 'width:100%;'
|
||||
, 'placeholder' => '0.0.0.0'
|
||||
, 'description' => ''
|
||||
, 'attr' => array()
|
||||
, 'group' => 'advanced'
|
||||
, 'tr_class' => ''
|
||||
, 'only_field' => false
|
||||
, 'description_tag' => 'p'
|
||||
, 'validate_as' => array()
|
||||
, 'value' => get_opsd_option( 'opsd_defualt_iplock' )
|
||||
);
|
||||
OPSD_Settings_API::field_text_row_static( 'opsd_product_ip_lock', $fields );
|
||||
|
||||
?>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
<!-- <input type="button" value="<?php _e('Send', 'secure-downloads'); ?>" class="button button-primary opsd_send_button" /> -->
|
||||
<!-- <input type="submit" value="<?php _e('Submit', 'secure-downloads'); ?>" class="button button-primary opsd_submit_button" />-->
|
||||
|
||||
</form>
|
||||
<?php
|
||||
|
||||
if ( ! empty( $data_after_update ) )
|
||||
echo $data_after_update['sent_summary_content'];
|
||||
?>
|
||||
</span>
|
||||
<?php
|
||||
|
||||
opsd_show_opsd_footer();
|
||||
|
||||
$this->js();
|
||||
$this->css();
|
||||
|
||||
do_action( 'opsd_hook_settings_page_footer', 'send_links' );
|
||||
}
|
||||
|
||||
|
||||
public function update() {
|
||||
|
||||
$post_action_key = 'opsd_action';
|
||||
if ( isset( $_POST[ $post_action_key ] ) && ( $_POST[ $post_action_key ] == 'go_send' ) ) {
|
||||
|
||||
// Get Validated post
|
||||
$validated = array();
|
||||
|
||||
// Email
|
||||
$validated['opsd_email_to'] = OPSD_Settings_API::validate_email_post_static( 'opsd_email_to' );
|
||||
|
||||
// Is send copy to admin
|
||||
$validated['send_copy_to_admin'] = OPSD_Settings_API::validate_checkbox_post_static( 'send_copy_to_admin' );
|
||||
|
||||
// Products
|
||||
$validated['opsd_product_selection'] = OPSD_Settings_API::validate_select_post_static( 'opsd_product_selection' );
|
||||
|
||||
// Expire
|
||||
$validated['opsd_product_expire'] = OPSD_Settings_API::validate_select_post_static( 'opsd_product_expire' );
|
||||
|
||||
// IP lock
|
||||
$validated['opsd_product_ip_lock'] = OPSD_Settings_API::validate_text_post_static( 'opsd_product_ip_lock' );
|
||||
|
||||
// Check if we selected custom email template and need to send email even if the product was not selected
|
||||
$validated['continue_without_product'] = false;
|
||||
$validated = apply_filters( 'opsd_send_secure_links_validate_fields', $validated ); //Hook for validated fields.
|
||||
|
||||
|
||||
$response = opsd_send_secure_download_email_to_user( $validated ); //FixIn: 1.1.3.2
|
||||
|
||||
//debuge($response);
|
||||
|
||||
$sent_summary_content = '';
|
||||
|
||||
switch ( $response[ 'status' ] ) {
|
||||
|
||||
case 'error':
|
||||
|
||||
if ( 'select_valid_product' == $response[ 'error_type' ] ) {
|
||||
|
||||
opsd_show_fixed_message( __( 'Select valid product', 'secure-downloads' ), 3, 'updated error' ); // Show Message
|
||||
}
|
||||
break;
|
||||
|
||||
case 'email_sent':
|
||||
|
||||
// Get Summary about sending email and generating link ...
|
||||
$sent_summary_content = $this->get_sent_summary( $response['mail_api'], $response['product_replace'], $validated );
|
||||
|
||||
opsd_show_fixed_message ( __('Email sent to', 'secure-downloads') . ' ' . $validated['opsd_email_to'], 3 ); // Show Message
|
||||
break;
|
||||
|
||||
case 'link_generated':
|
||||
|
||||
// Get Summary about sending email and generating link ...
|
||||
$sent_summary_content = $this->get_sent_summary( $response['mail_api'], $response['product_replace'], $validated );
|
||||
|
||||
opsd_show_fixed_message ( __('Link generated', 'secure-downloads'), 3 ); // Show Message
|
||||
break;
|
||||
|
||||
default:
|
||||
// Default
|
||||
}
|
||||
|
||||
// Reload page after sending. Stop from sending once again, if refresh browser in mobile browser after some time
|
||||
?>
|
||||
<script type="text/javascript">
|
||||
setTimeout(function() { document.location.href = "<?php echo opsd_get_master_url(); ?>"; }, 30000);
|
||||
</script>
|
||||
<?php
|
||||
|
||||
return array ( 'validated_data' => $validated, 'sent_summary_content' => $sent_summary_content ); // Exit, for do not parse
|
||||
}
|
||||
|
||||
/*
|
||||
//$validated_fields = $this->settings_api()->validate_post(); // Get Validated Settings fields in $_POST request.
|
||||
|
||||
//$validated_fields = apply_filters( 'opsd_settings_validate_fields_before_saving', $validated_fields ); //Hook for validated fields.
|
||||
|
||||
// Skip saving specific option, for example in Demo mode.
|
||||
// unset($validated_fields['opsd_start_day_weeek']);
|
||||
|
||||
//$this->settings_api()->save_to_db( $validated_fields ); // Save fields to DB
|
||||
//opsd_show_changes_saved_message();
|
||||
//opsd_show_fixed_message ( __('Done', 'secure-downloads'), 0 ); // Show Message
|
||||
|
||||
// O L D W A Y: Saving Fields Data
|
||||
// update_opsd_option( 'opsd_is_delete_if_deactive'
|
||||
// , OPSD_Settings_API::validate_checkbox_post('opsd_is_delete_if_deactive') );
|
||||
// ( (isset( $_POST['opsd_is_delete_if_deactive'] ))?'On':'Off') );
|
||||
*/
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
public function get_sent_summary( $mail_api, $replace, $validated ) {
|
||||
|
||||
if ( false === $mail_api ) { // Email disabled
|
||||
$mail_api = new OPSD_Emails_API_LinkUser( OPSD_EMAIL_LINK_USER_ID );
|
||||
}
|
||||
|
||||
// Parse for getting email content /////////////////////////////////
|
||||
$mail_api->set_replace( $replace );
|
||||
$content_email = $mail_api->get_content();
|
||||
$subject_email = $mail_api->get_subject();
|
||||
$mail_api->set_replace(); // Reset Email
|
||||
|
||||
$pos = strpos($content_email, '<body' );
|
||||
if ( $pos !== false ) {
|
||||
$pos = strpos($content_email, '>', ++$pos );
|
||||
$content_email = substr($content_email, ++$pos );
|
||||
}
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
||||
ob_start();
|
||||
|
||||
opsd_open_meta_box_section( 'opsd_sent_summary', __('Summary', 'secure-downloads') );
|
||||
|
||||
//debuge($validated,$replace);
|
||||
?><table class="form-table"><tbody><?php
|
||||
|
||||
?><tr><td colspan="2" style="padding-left: 0;font-size: 1.2em;border-bottom: 2px dashed #ddd;line-height: 1.8em;"><?php
|
||||
if ( ! empty ( $validated['opsd_email_to'] ) )
|
||||
echo __( 'Email have sent to', 'secure-downloads' ) . ' <strong>' . $validated['opsd_email_to'] . '</strong> - ';
|
||||
//echo ( $validated['send_copy_to_admin'] == 'On' ) ? ' [' . __('copy to administrator' , 'secure-downloads') . ']' : '';
|
||||
|
||||
if (
|
||||
( isset( $replace[ 'product_summary' ] ) )
|
||||
&& ( isset( $replace[ 'product_expire_date' ] ) )
|
||||
)
|
||||
echo $replace['product_summary'] . ' <code>' . $replace['product_expire_date'] . '</code>';
|
||||
?></td></tr><?php
|
||||
|
||||
// Link
|
||||
$fields = array(
|
||||
'title' => __( 'Link', 'secure-downloads')
|
||||
, 'disabled' => false
|
||||
, 'class' => ''
|
||||
, 'css' => 'width:100%;'
|
||||
, 'placeholder' => ''
|
||||
, 'description' => ''
|
||||
, 'attr' => array()
|
||||
, 'group' => 'advanced'
|
||||
, 'tr_class' => 'opsd_tr_more_margin'
|
||||
, 'only_field' => false
|
||||
, 'description_tag' => 'p'
|
||||
, 'validate_as' => array()
|
||||
, 'value' => ( isset( $replace[ 'product_link' ] ) ) ? $replace['product_link'] : ''
|
||||
);
|
||||
OPSD_Settings_API::field_text_row_static( 'opsd_sent_summary_link', $fields );
|
||||
|
||||
// email
|
||||
$fields = array(
|
||||
'title' => __( 'To', 'secure-downloads')
|
||||
, 'disabled' => false
|
||||
, 'class' => ''
|
||||
, 'css' => 'width:100%;'
|
||||
, 'placeholder' => ''
|
||||
, 'description' => ''
|
||||
, 'attr' => array()
|
||||
, 'group' => 'advanced'
|
||||
, 'tr_class' => ''
|
||||
, 'only_field' => false
|
||||
, 'description_tag' => 'p'
|
||||
, 'validate_as' => array()
|
||||
, 'value' => $validated['opsd_email_to']
|
||||
);
|
||||
OPSD_Settings_API::field_text_row_static( 'opsd_sent_summary_email', $fields );
|
||||
|
||||
// email
|
||||
$fields = array(
|
||||
'title' => __( 'Subject', 'secure-downloads')
|
||||
, 'disabled' => false
|
||||
, 'class' => ''
|
||||
, 'css' => 'width:100%;'
|
||||
, 'placeholder' => '0.0.0.0'
|
||||
, 'description' => ''
|
||||
, 'attr' => array()
|
||||
, 'group' => 'advanced'
|
||||
, 'tr_class' => ''
|
||||
, 'only_field' => false
|
||||
, 'description_tag' => 'p'
|
||||
, 'validate_as' => array()
|
||||
, 'value' => $subject_email
|
||||
);
|
||||
OPSD_Settings_API::field_text_row_static( 'opsd_sent_summary_subject', $fields );
|
||||
|
||||
|
||||
$field = array(
|
||||
'title' => '',
|
||||
'disabled' => false,
|
||||
'class' => '',
|
||||
'css' => '',
|
||||
'placeholder' => '',
|
||||
'type' => 'text',
|
||||
'description' => '',
|
||||
'attr' => array(),
|
||||
'rows' => 10,
|
||||
'cols' => 20,
|
||||
'teeny' => true,
|
||||
'show_visual_tabs' => true,
|
||||
'default_editor' => 'tinymce', // 'tinymce' | 'html' // 'html' is used for the "Text" editor tab.
|
||||
'drag_drop_upload' => false,
|
||||
'show_in_2_cols' => true,
|
||||
'group' => 'general',
|
||||
'tr_class' => '',
|
||||
'only_field' => false,
|
||||
'description_tag' => 'p'
|
||||
, 'value' => $content_email
|
||||
);
|
||||
|
||||
$email_content = OPSD_Settings_API::field_wp_textarea_row_static( 'show_email_content' , $field );
|
||||
|
||||
?></tbody></table><?php
|
||||
|
||||
opsd_close_meta_box_section();
|
||||
/*
|
||||
?>
|
||||
<script type="text/javascript">
|
||||
jQuery( document ).ready(function(){
|
||||
setTimeout(function() {
|
||||
opsd_scroll_to( '#opsd_sent_summary_metabox' );
|
||||
}, 100)
|
||||
});
|
||||
</script>
|
||||
<?php
|
||||
*/
|
||||
return ob_get_clean();
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
public function js() {
|
||||
?>
|
||||
<script type="text/javascript">
|
||||
// Catch data for summary
|
||||
jQuery('#opsd_email_to').on( "keypress", function( event ) {
|
||||
if( event.which != 13) {
|
||||
opsd_generate_send_info();
|
||||
//return false;
|
||||
}
|
||||
});
|
||||
jQuery('#opsd_email_to,#opsd_product_selection,#opsd_product_expire,#opsd_product_ip_lock').on( 'change', function(){
|
||||
opsd_generate_send_info();
|
||||
} );
|
||||
jQuery(document).ready( function(){
|
||||
setTimeout( opsd_generate_send_info , 1000);
|
||||
// opsd_generate_send_info();
|
||||
});
|
||||
// On click submit form
|
||||
jQuery( '.opsd_send_button' ).on( 'click', function() {
|
||||
if ( jQuery( '.opsd_send_button' ).hasClass( 'disabled' ) ) {
|
||||
return false; // Prevent submit form, if button disabled.
|
||||
}
|
||||
jQuery('#opsd_action').val('go_send');
|
||||
jQuery('#opsd_send_links_form<?php //echo $submit_form_name; ?>').trigger( 'submit' );
|
||||
return false;
|
||||
});
|
||||
//Allow enter key on textareas and submit buttons only
|
||||
jQuery(document).on( "keypress", ":input:not(textarea):not([type=submit])", function( event ) {
|
||||
if( event.which == 13) {
|
||||
if ( jQuery( '.opsd_send_button' ).hasClass( 'disabled' ) ) {
|
||||
return false; // Prevent submit form, if button disabled.
|
||||
}
|
||||
//alert('You pressed enter!');
|
||||
jQuery('#opsd_action').val('go_send');
|
||||
jQuery('#opsd_send_links_form<?php //echo $submit_form_name; ?>').trigger( 'submit' );
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
function opsd_generate_send_info() {
|
||||
|
||||
if ( jQuery( '#opsd_email_to' ).length == 0 )
|
||||
return;
|
||||
|
||||
var selected_products = [];
|
||||
var selected_products_val = [];
|
||||
jQuery('#opsd_product_selection :selected').each(function(i, selected){
|
||||
selected_products[i] = jQuery(selected).text().trim();
|
||||
selected_products_val[i] = jQuery(selected).val().trim();
|
||||
});
|
||||
selected_products = selected_products.join( ', ' );
|
||||
selected_products_val = selected_products_val.join( ', ' );
|
||||
if ( '' == selected_products_val ) {
|
||||
jQuery( '.opsd_send_button' ).addClass( 'disabled' );
|
||||
} else {
|
||||
jQuery( '.opsd_send_button' ).removeClass( 'disabled' )
|
||||
}
|
||||
|
||||
jQuery('.opsd_submmary').html('<table class="form-table"><tbody></tbody></table>');
|
||||
|
||||
if ( jQuery( '#opsd_email_to' ).val().trim() != '' ) {
|
||||
jQuery( '.opsd_send_button .opsd_text_hide_mobile' ).html('<?php echo esc_js( __( 'Send', 'secure-downloads' ) ); ?> ');
|
||||
jQuery('.opsd_submmary .form-table tbody').append( '<tr><th style="width:5em;"><?php echo esc_js( __( 'To', 'secure-downloads' ) ); ?></th><td>[' + jQuery( '#opsd_email_to' ).val().trim() + ']</td></tr>' );
|
||||
} else {
|
||||
jQuery( '.opsd_send_button .opsd_text_hide_mobile' ).html('<?php echo esc_js( __( 'Generate', 'secure-downloads' ) ); ?> ');
|
||||
jQuery('.opsd_submmary .form-table tbody').append( '<tr><th colspan="2" style=""><?php echo esc_js( __( 'Generate Secure Link for Download', 'secure-downloads' ) ); ?></th></tr>' );
|
||||
}
|
||||
|
||||
jQuery('.opsd_submmary .form-table tbody').append( '<tr><th style="width:5em;"><?php echo esc_js( __( 'Products', 'secure-downloads' ) ); ?></th><td>[' + selected_products.trim() + ']</td></tr>' );
|
||||
jQuery('.opsd_submmary .form-table tbody').append( '<tr><th style="width:5em;"><?php echo esc_js( __( 'Expire', 'secure-downloads' ) ); ?></th><td>[' + jQuery('#opsd_product_expire :selected').text().trim() + ']</td></tr>' );
|
||||
if ( jQuery('#opsd_product_ip_lock').val().trim() != '' )
|
||||
jQuery('.opsd_submmary .form-table tbody').append( '<tr><th style="width:5em;"><?php echo esc_js( __( 'IP Loc', 'secure-downloads' ) ); ?></th><td>' + jQuery('#opsd_product_ip_lock').val().trim() + '</td></tr>' );
|
||||
|
||||
jQuery( ".opsd_submmary" ).trigger( "generate_send_info" , [] ); // Action hook
|
||||
}
|
||||
|
||||
</script>
|
||||
<?php
|
||||
}
|
||||
|
||||
|
||||
public function css() {
|
||||
?>
|
||||
<style type="text/css">
|
||||
.opsd_link_container {
|
||||
display: flex;
|
||||
flex-flow: row nowrap;
|
||||
justify-content: flex-start;
|
||||
}
|
||||
.opsd_link_container #opsd_email_to {
|
||||
flex: 65% 1 0;
|
||||
font-size: 1.4em;
|
||||
font-weight: 600;
|
||||
height: 43px;
|
||||
line-height: 2;
|
||||
/*max-width: 25rem;*/
|
||||
min-width: 0;
|
||||
padding: 6px 10px;
|
||||
}
|
||||
.opsd_link_container .opsd_generate_button{
|
||||
flex: 10% 0 0;
|
||||
margin: 0 0 0 1.5em;
|
||||
line-height: 34px;
|
||||
font-size: 1.2em;
|
||||
text-align: center;
|
||||
height: 43px;
|
||||
padding: 5px 20px;
|
||||
box-shadow: none;
|
||||
}
|
||||
.opsd_tr_more_margin th,
|
||||
.opsd_tr_more_margin td {
|
||||
padding-top: 30px !important;
|
||||
}
|
||||
.metabox-holder select option{
|
||||
padding:0.7em 20px;
|
||||
height:1.5em;
|
||||
border-bottom:1px solid #ccc;
|
||||
}
|
||||
select.opsd_product_selection,
|
||||
#select_opsd_form {
|
||||
margin: 30px 0 0;
|
||||
width:100%;
|
||||
|
||||
max-width: 100%;
|
||||
height: 2.2em;
|
||||
/*line-height: 2.2em;*/
|
||||
font-size: 1.2em;
|
||||
}
|
||||
/*#opsd_email_to { */
|
||||
/* width: 75%;*/
|
||||
/* font-size: 1.4em;*/
|
||||
/* font-weight: 600;*/
|
||||
/* height: 2.1em; */
|
||||
/*}*/
|
||||
/*.opsd_page .opsd_send_button { */
|
||||
/* font-size: 1.4em;*/
|
||||
/* height: 2.04em;*/
|
||||
/* font-weight: 600;*/
|
||||
/* line-height: 1.91em;*/
|
||||
/* width: 100%;*/
|
||||
/* overflow: hidden;*/
|
||||
/* text-align: center;*/
|
||||
/* padding:0;*/
|
||||
/*}*/
|
||||
/* iPad mini and all iPhones and other Mobile Devices */
|
||||
@media (max-width: 782px) {
|
||||
.opsd_page .opsd_copy_2_clipboard_button,
|
||||
.opsd_page .opsd_send_button {
|
||||
line-height: 2.15;
|
||||
/* padding: 2px; */
|
||||
/* margin-top: 1px;*/
|
||||
}
|
||||
}
|
||||
</style>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
add_action('opsd_menu_created', array( new OPSD_Page_Single() , '__construct') ); // Executed after creation of Menu
|
||||
|
||||
|
||||
|
||||
|
||||
//function opsd_gotopages() {
|
||||
//
|
||||
// wp_redirect( admin_url('admin.php?page=opsd' ) );
|
||||
//}
|
||||
//add_action('wp_dashboard_setup', 'opsd_gotopages');
|
||||
|
||||
|
||||
function opsd_show_copy_button(){
|
||||
|
||||
if (
|
||||
( ( isset( $_SERVER['SCRIPT_FILENAME'] ) ) && ( strpos( $_SERVER['SCRIPT_FILENAME'], '/email-reminders/www' ) !== false ) )
|
||||
|| ( ( isset( $_SERVER['SCRIPT_FILENAME'] ) ) && ( strpos( $_SERVER['SCRIPT_FILENAME'], 'wpbookingcalendar.com' ) !== false ) )
|
||||
|| ( ( isset( $_SERVER['HTTP_HOST'] ) ) && ( strpos( $_SERVER['HTTP_HOST'], 'wpbookingcalendar.com' ) !== false ) )
|
||||
){
|
||||
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
?>
|
||||
<div class="opsd_link_container wpdevelop" style="margin: 0 0 2em;justify-content: flex-end;">
|
||||
<a class="button button-primary opsd_copy_2_clipboard_button opsd_generate_button js-copy-email-btn" style="margin: 0;"
|
||||
href="javascript:void(0)" title="<?php _e('Copy to clipboard' , 'secure-downloads') ?>"
|
||||
><span class="opsd_text_hide_mobile0 btn_text_inside"><?php _e('Copy to clipboard' , 'secure-downloads') ?> </span><span class="glyphicon glyphicon-copy" aria-hidden="true"></span></a>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
|
||||
copyEmailBtn = document.querySelector('.js-copy-email-btn');
|
||||
|
||||
copyEmailBtn.addEventListener('click', function(event) {
|
||||
|
||||
var inputid = 'show_email_content';
|
||||
var content;
|
||||
var editor = tinyMCE.get(inputid);
|
||||
if (editor) {
|
||||
// Ok, the active tab is Visual
|
||||
content = editor.getContent();
|
||||
} else {
|
||||
// The active tab is HTML, so just query the textarea
|
||||
content = $('#'+inputid).val();
|
||||
}
|
||||
console.log( content );
|
||||
|
||||
// Now get it as HTML (original here https://stackoverflow.com/questions/34191780/javascript-copy-string-to-clipboard-as-text-html )
|
||||
|
||||
// Create container for the HTML
|
||||
// [1]
|
||||
var container = document.createElement('div')
|
||||
container.innerHTML = content
|
||||
|
||||
// Hide element
|
||||
// [2]
|
||||
container.style.position = 'fixed'
|
||||
container.style.pointerEvents = 'none'
|
||||
container.style.opacity = 0
|
||||
|
||||
// Detect all style sheets of the page
|
||||
var activeSheets = Array.prototype.slice.call(document.styleSheets)
|
||||
.filter(function (sheet) {
|
||||
return !sheet.disabled
|
||||
})
|
||||
|
||||
// Mount the container to the DOM to make `contentWindow` available
|
||||
// [3]
|
||||
document.body.appendChild(container)
|
||||
|
||||
// Copy to clipboard
|
||||
// [4]
|
||||
window.getSelection().removeAllRanges()
|
||||
|
||||
var range = document.createRange()
|
||||
range.selectNode(container)
|
||||
window.getSelection().addRange(range)
|
||||
|
||||
// [5.1]
|
||||
document.execCommand('copy')
|
||||
|
||||
// [5.2]
|
||||
for (var i = 0; i < activeSheets.length; i++) activeSheets[i].disabled = true
|
||||
|
||||
// [5.3]
|
||||
|
||||
//if ( ! navigator.clipboard ){
|
||||
|
||||
try{
|
||||
var successful = document.execCommand( 'copy' );
|
||||
var msg = successful ? 'successful' : 'unsuccessful';
|
||||
//console.log( 'Fallback: Copying text command was ' + msg );
|
||||
|
||||
var btn_today = new Date();
|
||||
var btn_date = btn_today.getFullYear()+'-'+(btn_today.getMonth()+1)+'-'+btn_today.getDate();
|
||||
var btn_time = btn_today.getHours() + ":" + btn_today.getMinutes() + ":" + btn_today.getSeconds();
|
||||
var btn_dateTime = ' '+btn_time;
|
||||
jQuery( '.js-copy-email-btn .btn_text_inside').html( 'Copied' + btn_dateTime + ' ' );
|
||||
|
||||
opsd_scroll_to( jQuery( '#opsd_sent_summary_subject' ) );
|
||||
|
||||
} catch ( err ){
|
||||
//console.error( 'Fallback: Oops, unable to copy', err );
|
||||
}
|
||||
// } else {
|
||||
// var type = "text/html";
|
||||
// var blob = new Blob([content], { type });
|
||||
// var data = [new ClipboardItem({ [type]: blob })];
|
||||
//
|
||||
// navigator.clipboard.write(data).then(
|
||||
// function () {
|
||||
// /* success */
|
||||
// console.log( 'Async: Copying to clipboard was successful!' );
|
||||
// },
|
||||
// function (err) {
|
||||
// /* failure */
|
||||
// console.error( 'Async: Could not copy text: ', err );
|
||||
// }
|
||||
// );
|
||||
// }
|
||||
|
||||
|
||||
// [5.4]
|
||||
for (var i = 0; i < activeSheets.length; i++) activeSheets[i].disabled = false
|
||||
|
||||
// Remove the container
|
||||
// [6]
|
||||
document.body.removeChild(container)
|
||||
|
||||
// opsd_copy_text_to_clipboard( content );
|
||||
});
|
||||
|
||||
|
||||
|
||||
function opsd_fallback_copy_text_to_clipboard( text ){
|
||||
var textArea = document.createElement( "textarea" );
|
||||
textArea.value = text;
|
||||
|
||||
// Avoid scrolling to bottom
|
||||
textArea.style.top = "0";
|
||||
textArea.style.left = "0";
|
||||
textArea.style.position = "fixed";
|
||||
|
||||
document.body.appendChild( textArea );
|
||||
textArea.focus();
|
||||
textArea.select();
|
||||
|
||||
try{
|
||||
var successful = document.execCommand( 'copy' );
|
||||
var msg = successful ? 'successful' : 'unsuccessful';
|
||||
console.log( 'Fallback: Copying text command was ' + msg );
|
||||
} catch ( err ){
|
||||
console.error( 'Fallback: Oops, unable to copy', err );
|
||||
}
|
||||
|
||||
document.body.removeChild( textArea );
|
||||
}
|
||||
|
||||
|
||||
function opsd_copy_text_to_clipboard( text ){
|
||||
if ( !navigator.clipboard ){
|
||||
opsd_fallback_copy_text_to_clipboard( text );
|
||||
return;
|
||||
}
|
||||
navigator.clipboard.writeText( text ).then( function (){
|
||||
console.log( 'Async: Copying to clipboard was successful!' );
|
||||
}, function ( err ){
|
||||
console.error( 'Async: Could not copy text: ', err );
|
||||
} );
|
||||
}
|
||||
|
||||
</script>
|
||||
<?php
|
||||
}
|
||||
297
wp-content/plugins/secure-downloads/core/admin/page-settings.php
Normal file
297
wp-content/plugins/secure-downloads/core/admin/page-settings.php
Normal file
@@ -0,0 +1,297 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @category Content of Settings page
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-11-02
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
/** Show Content
|
||||
* Update Content
|
||||
* Define Slug
|
||||
* Define where to show
|
||||
*/
|
||||
class OPSD_Page_SettingsGeneral extends OPSD_Page_Structure {
|
||||
|
||||
private $settings_api = false;
|
||||
|
||||
public function in_page() {
|
||||
|
||||
return 'opsd-settings';
|
||||
}
|
||||
|
||||
/** Get Settings API class - define, show, update "Fields".
|
||||
*
|
||||
* @return object Settings API
|
||||
*/
|
||||
public function settings_api(){
|
||||
|
||||
if ( $this->settings_api === false )
|
||||
$this->settings_api = new OPSD_Settings_API_General();
|
||||
|
||||
return $this->settings_api;
|
||||
}
|
||||
|
||||
public function tabs() {
|
||||
|
||||
$tabs = array();
|
||||
|
||||
$tabs[ 'general' ] = array(
|
||||
'title' => __( 'General', 'secure-downloads' ) // Title of TAB
|
||||
, 'page_title' => __( 'General Settings', 'secure-downloads' ) // Title of Page
|
||||
, 'hint' => __( 'General Settings', 'secure-downloads' ) // Hint
|
||||
, 'link' => '' // Can be skiped, then generated link based on Page and Tab tags. Or can be extenral link
|
||||
, 'position' => '' // 'left' || 'right' || ''
|
||||
, 'css_classes' => '' // CSS class(es)
|
||||
, 'icon' => '' // Icon - link to the real PNG img
|
||||
, 'font_icon' => 'glyphicon glyphicon-cog' // CSS definition of forn Icon
|
||||
, 'default' => true // Is this tab activated by default or not: true || false.
|
||||
);
|
||||
|
||||
$subtabs = array();
|
||||
|
||||
$subtabs['opsd-settings-url'] = array( 'type' => 'goto-link'
|
||||
, 'title' => __('URLs', 'secure-downloads')
|
||||
, 'show_section' => 'opsd_warning_url_settings_calendar_metabox'
|
||||
);
|
||||
|
||||
|
||||
$subtabs['opsd-settings-listing'] = array( 'type' => 'goto-link'
|
||||
, 'title' => __('Misc', 'secure-downloads')
|
||||
, 'show_section' => 'opsd_general_settings_opsd_misc_metabox'
|
||||
);
|
||||
|
||||
$subtabs['opsd-settings-menu-access'] = array( 'type' => 'goto-link'
|
||||
, 'title' => __('Plugin Menu', 'secure-downloads')
|
||||
, 'show_section' => 'opsd_general_settings_permissions_metabox'
|
||||
);
|
||||
|
||||
$subtabs['opsd-settings-uninstall'] = array( 'type' => 'goto-link'
|
||||
, 'title' => __('Uninstall', 'secure-downloads')
|
||||
, 'show_section' => 'opsd_general_settings_uninstall_metabox'
|
||||
);
|
||||
|
||||
$subtabs['opsd-settings-advanced'] = array( 'type' => 'goto-link'
|
||||
, 'title' => __('Advanced', 'secure-downloads')
|
||||
, 'show_section' => 'opsd_general_settings_advanced_metabox'
|
||||
);
|
||||
|
||||
|
||||
|
||||
$subtabs['form-save'] = array(
|
||||
'type' => 'button'
|
||||
, 'title' => __('Save Changes', 'secure-downloads')
|
||||
, 'form' => 'opsd_general_settings_form'
|
||||
);
|
||||
|
||||
|
||||
$tabs[ 'general' ][ 'subtabs' ] = $subtabs;
|
||||
|
||||
$tabs[ 'upgrade' ] = array(
|
||||
'title' => __( 'Addons', 'secure-downloads' ) // Title of TAB
|
||||
, 'page_title' => __( 'Extend functionaity', 'secure-downloads' ) // Title of Page
|
||||
, 'hint' => __( 'Extend functionaity with premium addons', 'secure-downloads' ) // Hint
|
||||
, 'link' => 'https://oplugins.com/plugins/secure-downloads/#premium' // Can be skiped, then generated link based on Page and Tab tags. Or can be extenral link
|
||||
, 'position' => 'right' // 'left' || 'right' || ''
|
||||
, 'css_classes' => '' // CSS class(es)
|
||||
, 'icon' => '' // Icon - link to the real PNG img
|
||||
, 'font_icon' => 'glyphicon glyphicon-shopping-cart' // CSS definition of forn Icon
|
||||
, 'default' => false // Is this tab activated by default or not: true || false.
|
||||
);
|
||||
|
||||
return $tabs;
|
||||
}
|
||||
|
||||
|
||||
public function content() {
|
||||
|
||||
// Checking ////////////////////////////////////////////////////////////
|
||||
|
||||
do_action( 'opsd_hook_settings_page_header', array( 'page' => $this->in_page() ) ); // Define Notices Section and show some static messages, if needed.
|
||||
|
||||
$is_can = apply_opsd_filter('recheck_version', true); if ( ! $is_can ) { ?><script type="text/javascript"> jQuery(document).ready(function(){ jQuery( '.wpdvlp-sub-tabs').remove(); }); </script><?php return; }
|
||||
|
||||
|
||||
// Init Settings API & Get Data from DB ////////////////////////////////
|
||||
$this->settings_api(); // Define all fields and get values from DB
|
||||
|
||||
// Submit /////////////////////////////////////////////////////////////
|
||||
|
||||
$submit_form_name = 'opsd_general_settings_form'; // Define form name
|
||||
|
||||
if ( isset( $_POST['is_form_sbmitted_'. $submit_form_name ] ) ) {
|
||||
|
||||
// Nonce checking {Return false if invalid, 1 if generated between, 0-12 hours ago, 2 if generated between 12-24 hours ago. }
|
||||
$nonce_gen_time = check_admin_referer( 'opsd_settings_page_' . $submit_form_name ); // Its stop show anything on submiting, if its not refear to the original page
|
||||
|
||||
// Save Changes
|
||||
$this->update();
|
||||
}
|
||||
//$opsd_user_role_master = get_opsd_option( 'opsd_user_role_master' ); // O L D W A Y: Get Fields Data
|
||||
|
||||
|
||||
// JavaScript: Tooltips, Popover, Datepick (js & css) //////////////////
|
||||
echo '<span class="wpdevelop">';
|
||||
opsd_js_for_items_page();
|
||||
echo '</span>';
|
||||
|
||||
|
||||
|
||||
// Content ////////////////////////////////////////////////////////////
|
||||
?>
|
||||
<div class="clear" style="margin-bottom:10px;"></div>
|
||||
<span class="metabox-holder">
|
||||
<form name="<?php echo $submit_form_name; ?>" id="<?php echo $submit_form_name; ?>" action="" method="post">
|
||||
<?php
|
||||
// N o n c e field, and key for checking S u b m i t
|
||||
wp_nonce_field( 'opsd_settings_page_' . $submit_form_name );
|
||||
?><input type="hidden" name="is_form_sbmitted_<?php echo $submit_form_name; ?>" id="is_form_sbmitted_<?php echo $submit_form_name; ?>" value="1" />
|
||||
|
||||
<div class="opsd_settings_row opsd_settings_row_left" >
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_general_settings_calendar', __('General', 'secure-downloads') ); ?>
|
||||
|
||||
<?php $this->settings_api()->show( 'general' ); ?>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_warning_url_settings_calendar', __('URL to pages after some errors', 'secure-downloads') ); ?>
|
||||
|
||||
<?php $this->settings_api()->show( 'warning_url' ); ?>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<?php /* ?>
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_general_settings_calendar', __('Calendar', 'secure-downloads') ); ?>
|
||||
|
||||
<?php $this->settings_api()->show( 'calendar' ); ?>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_general_settings_availability', __('Availability', 'secure-downloads') ); ?>
|
||||
|
||||
<?php $this->settings_api()->show( 'availability' ); ?>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_general_settings_form', __('Form', 'secure-downloads') ); ?>
|
||||
|
||||
<?php $this->settings_api()->show( 'form' ); ?>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
<?php */ ?>
|
||||
<?php opsd_open_meta_box_section( 'opsd_general_settings_opsd_misc', __('Miscellaneous', 'secure-downloads') ); ?>
|
||||
|
||||
<?php $this->settings_api()->show( 'opsd_listing' ); ?>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
<div class="opsd_settings_row opsd_settings_row_right">
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_general_settings_information', __('Information', 'secure-downloads') ); ?>
|
||||
|
||||
<?php $this->settings_api()->show( 'information' ); ?>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_general_settings_permissions', __('Plugin Menu', 'secure-downloads') ); ?>
|
||||
|
||||
<?php $this->settings_api()->show( 'permissions' ); ?>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_general_settings_uninstall', __('Uninstall / deactivation', 'secure-downloads') ); ?>
|
||||
|
||||
<?php $this->settings_api()->show( 'uninstall' ); ?>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_general_settings_advanced', __('Advanced', 'secure-downloads') ); ?>
|
||||
|
||||
<?php $this->settings_api()->show( 'advanced' ); ?>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
<input type="submit" value="<?php _e('Save Changes', 'secure-downloads'); ?>" class="button button-primary opsd_submit_button" />
|
||||
</form>
|
||||
<?php if ( ( isset( $_GET['system_info'] ) ) && ( $_GET['system_info'] == 'show' ) ) { ?>
|
||||
|
||||
<div class="clear" style="height:30px;"></div>
|
||||
|
||||
<?php opsd_open_meta_box_section( 'opsd_general_settings_system_info', 'System Info' ); ?>
|
||||
|
||||
<?php opsd_system_info(); ?>
|
||||
|
||||
<?php opsd_close_meta_box_section(); ?>
|
||||
|
||||
<?php } ?>
|
||||
|
||||
</span>
|
||||
<?php
|
||||
|
||||
|
||||
|
||||
do_action( 'opsd_hook_settings_page_footer', 'general_settings' );
|
||||
|
||||
//debuge( 'Content <strong>' . basename(__FILE__ ) . '</strong> <span style="font-size:9px;">' . __FILE__ . '</span>');
|
||||
}
|
||||
|
||||
|
||||
public function update() {
|
||||
//debuge($_POST);
|
||||
$validated_fields = $this->settings_api()->validate_post(); // Get Validated Settings fields in $_POST request.
|
||||
|
||||
$validated_fields = apply_filters( 'opsd_settings_validate_fields_before_saving', $validated_fields ); //Hook for validated fields.
|
||||
//debuge($validated_fields);
|
||||
// Skip saving specific option, for example in Demo mode.
|
||||
// unset($validated_fields['opsd_start_day_weeek']);
|
||||
|
||||
$this->settings_api()->save_to_db( $validated_fields ); // Save fields to DB
|
||||
opsd_show_changes_saved_message();
|
||||
|
||||
//debuge( basename(__FILE__), 'UPDATE', $_POST, $validated_fields);
|
||||
|
||||
// O L D W A Y: Saving Fields Data
|
||||
// update_opsd_option( 'opsd_is_delete_if_deactive'
|
||||
// , OPSD_Settings_API::validate_checkbox_post('opsd_is_delete_if_deactive') );
|
||||
// ( (isset( $_POST['opsd_is_delete_if_deactive'] ))?'On':'Off') );
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
//if ( $is_other_tab ) {
|
||||
//
|
||||
// if ( ( ! isset( $_GET['tab'] ) ) || ( $_GET['tab'] == 'general' ) ) { // If tab was not selected or selected default, then redirect it to the "form" tab.
|
||||
// $_GET['tab'] = 'form';
|
||||
// }
|
||||
//} else {
|
||||
// add_action('opsd_menu_created', array( new OPSD_Page_SettingsGeneral() , '__construct') ); // Executed after creation of Menu
|
||||
//}
|
||||
|
||||
add_action('opsd_menu_created', array( new OPSD_Page_SettingsGeneral() , '__construct') ); // Executed after creation of Menu
|
||||
|
||||
274
wp-content/plugins/secure-downloads/core/any/activation.php
Normal file
274
wp-content/plugins/secure-downloads/core/any/activation.php
Normal file
@@ -0,0 +1,274 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package oPlugins
|
||||
* @category Installation
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-04-09, 2016-03-17
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
/**
|
||||
* Activation | Deactivation Class
|
||||
*/
|
||||
abstract class OPSD_Install {
|
||||
|
||||
private $init_option;
|
||||
|
||||
function __construct() {
|
||||
|
||||
$default_init_option_names = array(
|
||||
'option-version_num' => 'securedownloads_version_num'
|
||||
, 'option-is_delete_if_deactive' => 'securedownloads_is_delete_if_deactive'
|
||||
, 'option-activation_process' => 'securedownloads_activation_process'
|
||||
, 'transient-opsd_activation_redirect' => '_securedownloads_activation_redirect'
|
||||
, 'message-delete_data' => '<strong>Warning!</strong> ' . 'All plugin data will be deleted when plugin had deactivated.' . '<br />'
|
||||
. sprintf( 'If you want to save your plugin data, please uncheck the %s"Delete plugin data"%s at the', '<strong>', '</strong>')
|
||||
, 'link_settings' => '<a href="">Settings</a>'
|
||||
, 'link_whats_new' => '<a href="">Whats New</a>'
|
||||
);
|
||||
|
||||
$init_option = $this->get_init_option_names();
|
||||
|
||||
$this->init_option = wp_parse_args( $init_option, $default_init_option_names );
|
||||
|
||||
|
||||
register_activation_hook( OPSD_FILE, array( $this, 'opsd_activate_initial' ) ); // WordPress > Plugins > "Activate" link.
|
||||
|
||||
register_deactivation_hook( OPSD_FILE, array( $this, 'opsd_deactivate' ) ); // WordPress > Plugins > "Deactivate" link.
|
||||
|
||||
add_filter('upgrader_post_install', array( $this, 'opsd_install_in_bulk_upgrade' ), 10, 2 ); // Upgrade during bulk upgrade of plugins
|
||||
|
||||
// Settings link at the plugin page
|
||||
add_filter('plugin_action_links', array( $this, 'plugin_links'), 10, 2 );
|
||||
// Warning message in plugin info
|
||||
add_filter('plugin_row_meta', array( $this, 'plugin_row_meta'), 10, 4 );
|
||||
|
||||
$this->check_if_need_to_update(); // Check upgrade, if was no activation process
|
||||
}
|
||||
|
||||
|
||||
/** Must be overloaded in child CLASS
|
||||
* Exmaple:
|
||||
* return array(
|
||||
'option-version_num' => 'securedownloads_version_num'
|
||||
, 'option-is_delete_if_deactive' => 'securedownloads_is_delete_if_deactive'
|
||||
, 'option-activation_process' => 'securedownloads_activation_process'
|
||||
, 'transient-opsd_activation_redirect' => '_securedownloads_activation_redirect'
|
||||
, 'message-delete_data' => '<strong>Warning !!!</strong> ' . 'All plugin data will be deleted when plugin had deactivated.' . '<br />'
|
||||
. sprintf( 'If you want to save your plugin data, please uncheck the %s"Delete plugin data"%s at the settings page.', '<strong>', '</strong>')
|
||||
, 'link_settings' => '<a href="">Settings</a>'
|
||||
, 'link_whats_new' => '<a href="">Whats New</a>'
|
||||
);
|
||||
*/
|
||||
abstract function get_init_option_names();
|
||||
|
||||
|
||||
/** Must be overloaded in child CLASS
|
||||
* Exmaple:
|
||||
*
|
||||
return false
|
||||
*/
|
||||
abstract function is_update_from_lower_to_high_version();
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" Update info of plugin at the plugins section ">
|
||||
|
||||
/** Update info of plugin at the plugins section */
|
||||
function plugin_row_meta( $plugin_meta, $plugin_file, $plugin_data, $context ) {
|
||||
|
||||
$this_plugin = plugin_basename( OPSD_FILE );
|
||||
|
||||
if ($plugin_file == $this_plugin ) {
|
||||
|
||||
$is_delete_if_deactive = get_opsd_option( $this->init_option['option-is_delete_if_deactive'] ); // check
|
||||
|
||||
if ($is_delete_if_deactive == 'On') { ?>
|
||||
<div class="plugin-update-tr">
|
||||
<div class="update-message notice inline notice-warning notice-altNO" style="font-size: 1em;line-height: 2em;margin:0 5px 10px;"><?php echo $this->init_option['message-delete_data']; ?></div>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
|
||||
/*
|
||||
[$plugin_meta] => Array
|
||||
(
|
||||
[0] => Version 2.8.35
|
||||
[1] => By wpdevelop
|
||||
[2] => Visit plugin site
|
||||
)
|
||||
|
||||
[$plugin_file] => securedownloads/OPSD.php
|
||||
[$plugin_data] => Array
|
||||
(
|
||||
[Name] => pluginname
|
||||
[PluginURI] => https://oplugins.com/plugins/secure-downloads/#demo
|
||||
[Version] => 2.8.35
|
||||
[Description] => Some description...
|
||||
[Author] => wpdevelop
|
||||
[AuthorURI] => https://oplugins.com/
|
||||
[TextDomain] =>
|
||||
[DomainPath] =>
|
||||
[Network] =>
|
||||
[Title] => Title
|
||||
[AuthorName] => wpdevelop
|
||||
)
|
||||
|
||||
[$context] => all
|
||||
/**/
|
||||
|
||||
// Echo plugin description here
|
||||
return $plugin_meta;
|
||||
|
||||
} else
|
||||
return $plugin_meta;
|
||||
}
|
||||
|
||||
|
||||
// Adds Settings link to plugins settings
|
||||
function plugin_links($links, $file) {
|
||||
|
||||
$this_plugin = plugin_basename( OPSD_FILE );
|
||||
|
||||
if ( $file == $this_plugin ) {
|
||||
|
||||
if ( ! empty( $this->init_option[ 'link_settings' ] ) )
|
||||
array_unshift( $links, $this->init_option[ 'link_settings' ] );
|
||||
|
||||
if ( ! empty( $this->init_option[ 'link_whats_new' ] ) )
|
||||
array_unshift( $links, $this->init_option[ 'link_whats_new' ] );
|
||||
}
|
||||
return $links;
|
||||
}
|
||||
|
||||
// </editor-fold>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
// Check about ability to upgrade, if was no activation process
|
||||
private function check_if_need_to_update() {
|
||||
|
||||
if( is_admin() ) {
|
||||
|
||||
$opsd_version_num = get_option( $this->init_option['option-version_num'] );
|
||||
|
||||
if ($opsd_version_num === false )
|
||||
$opsd_version_num = '0';
|
||||
|
||||
$is_make_activation = false;
|
||||
|
||||
if ( version_compare( OPSD_VERSION_NUM, $opsd_version_num) > 0 ) {
|
||||
|
||||
$is_make_activation = true;
|
||||
|
||||
} else {
|
||||
|
||||
// Check if we was update from free to paid or from lower to higher versions,
|
||||
// and do not make normal activation. In this case we need to make update.
|
||||
$is_make_activation = $this->is_update_from_lower_to_high_version();
|
||||
|
||||
}
|
||||
|
||||
// Add hook for initial activation.
|
||||
if ( $is_make_activation ) {
|
||||
add_action( 'plugins_loaded', array( $this, 'opsd_activate_initial' ) );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/** Upgrade during bulk upgrade of plugins
|
||||
*
|
||||
* @param type $return
|
||||
* @param type $hook_extra
|
||||
* @return type
|
||||
*/
|
||||
public function opsd_install_in_bulk_upgrade( $return, $hook_extra ){
|
||||
|
||||
if ( is_wp_error( $return ) )
|
||||
return $return;
|
||||
|
||||
if ( isset( $hook_extra ) )
|
||||
if ( isset( $hook_extra['plugin'] ) ) {
|
||||
$file_name = basename( OPSD_FILE );
|
||||
$pos = strpos( $hook_extra['plugin'], trim( $file_name ) );
|
||||
if ( $pos !== false ) {
|
||||
$this->opsd_activate();
|
||||
}
|
||||
}
|
||||
return $return;
|
||||
}
|
||||
|
||||
|
||||
/** User clicked on "Activate" link at Plugins Menu.
|
||||
*
|
||||
* @return type
|
||||
*/
|
||||
public function opsd_activate_initial(){
|
||||
|
||||
// Activate the plugin
|
||||
$this->opsd_activate();
|
||||
|
||||
// Bail if this demo or activating from network, or bulk
|
||||
if ( is_network_admin() || isset( $_GET['activate-multi'] ) || opsd_is_this_demo() )
|
||||
return;
|
||||
|
||||
// Add the transient to redirect - Showing Welcome screen
|
||||
set_transient( $this->init_option['transient-opsd_activation_redirect'], true, 30 );
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
/** Run Activate */
|
||||
public function opsd_activate() {
|
||||
|
||||
if ( ( function_exists( 'set_time_limit' ) ) && // Try to extend script running to 15 minutes
|
||||
( ! in_array( ini_get( 'safe_mode' ), array( '1', 'On' ) ) ) // It's doesn't work, if PHP have SAFE MODE ON
|
||||
) set_time_limit( 900 );
|
||||
|
||||
ini_set('memory_limit','256M'); //FixIn:6.1.1.15
|
||||
|
||||
update_opsd_option( $this->init_option['option-activation_process'], 'On' );
|
||||
|
||||
make_opsd_action( 'opsd_activation' ); // S T A R T
|
||||
|
||||
update_opsd_option( $this->init_option['option-version_num'], OPSD_VERSION_NUM );
|
||||
|
||||
update_opsd_option( $this->init_option['option-activation_process'], 'Off');
|
||||
}
|
||||
|
||||
|
||||
/** Run Deactivate */
|
||||
public function opsd_deactivate() {
|
||||
|
||||
if ( ( function_exists( 'set_time_limit' ) ) && // Try to extend script running to 15 minutes
|
||||
( ! in_array( ini_get( 'safe_mode' ), array( '1', 'On' ) ) ) // It's doesn't work, if PHP have SAFE MODE ON
|
||||
) set_time_limit( 900 );
|
||||
|
||||
|
||||
$is_delete_if_deactive = get_opsd_option( $this->init_option['option-is_delete_if_deactive'] ); // check
|
||||
|
||||
if ( $is_delete_if_deactive == 'On' ) {
|
||||
|
||||
make_opsd_action( 'opsd_deactivation' ); // F I N I S H
|
||||
|
||||
delete_opsd_option( $this->init_option['option-version_num'] );
|
||||
|
||||
delete_opsd_option( $this->init_option['option-activation_process'] );
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
2038
wp-content/plugins/secure-downloads/core/any/admin-bs-ui.php
Normal file
2038
wp-content/plugins/secure-downloads/core/any/admin-bs-ui.php
Normal file
File diff suppressed because it is too large
Load Diff
534
wp-content/plugins/secure-downloads/core/any/api-emails.php
Normal file
534
wp-content/plugins/secure-downloads/core/any/api-emails.php
Normal file
@@ -0,0 +1,534 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.1
|
||||
* @package General Emails API
|
||||
* @category General Emails API Fields for Settings page and Functions for Sending emails.
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
* @modified 2016-05-12, 2015-10-06
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
// Email Settings API - Saving different options
|
||||
abstract class OPSD_Emails_API extends OPSD_Settings_API {
|
||||
|
||||
public $sending;
|
||||
public $replace = array();
|
||||
|
||||
|
||||
|
||||
/** Email Settings API Constructor
|
||||
* During creation, system try to load values from DB, if exist.
|
||||
*
|
||||
* @param type $id - "Pure Email Template name
|
||||
*/
|
||||
public function __construct( $id, $init_fields_values = array()) {
|
||||
|
||||
$options = array(
|
||||
'db_prefix_option' => 'opsd_email_'
|
||||
, 'db_saving_type' => 'togather' // { 'togather' (Default), 'separate', 'separate_prefix' }
|
||||
);
|
||||
// Email template saved as:
|
||||
// ( "prefix_email_" . $id ) >>> "prefix_email_new_admin"
|
||||
|
||||
parent::__construct( $id, $options, $init_fields_values ); // Define ID of Setting page and options
|
||||
|
||||
add_filter( 'phpmailer_init', array( $this, 'process_multipart' ) ); // For multipart messages
|
||||
|
||||
add_action( 'wp_mail_failed', array($this, 'email_error_parse') ); // Parse any errors during sending emails.
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** This function must be overriden - Initialise Settings Form Fields
|
||||
|
||||
public function init_settings_fields() {
|
||||
|
||||
$this->fields = array();
|
||||
|
||||
$this->fields['enabled'] = array(
|
||||
'type' => 'checkbox'
|
||||
, 'default' => 'On'
|
||||
, 'title' => __('Enable / Disable', 'secure-downloads')
|
||||
, 'label' => __('Enable this email notification', 'secure-downloads')
|
||||
, 'description' => ''
|
||||
, 'group' => 'general'
|
||||
|
||||
);
|
||||
// ...
|
||||
}
|
||||
/**/
|
||||
|
||||
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" Suport functions " >
|
||||
|
||||
/** List of preg* regular expression patterns to search for replace in plain emails.
|
||||
* More: https://raw.github.com/ushahidi/wp-silcc/master/class.html2text.inc
|
||||
*/
|
||||
private function get_plain_search_array() {
|
||||
return array(
|
||||
"/\r/", // Non-legal carriage return
|
||||
'/&(nbsp|#160);/i', // Non-breaking space
|
||||
'/&(quot|rdquo|ldquo|#8220|#8221|#147|#148);/i', // Double quotes
|
||||
'/&(apos|rsquo|lsquo|#8216|#8217);/i', // Single quotes
|
||||
'/>/i', // Greater-than
|
||||
'/</i', // Less-than
|
||||
'/&/i', // Ampersand
|
||||
'/&/i', // Ampersand
|
||||
'/&/i', // Ampersand
|
||||
'/&(copy|#169);/i', // Copyright
|
||||
'/&(trade|#8482|#153);/i', // Trademark
|
||||
'/&(reg|#174);/i', // Registered
|
||||
'/&(mdash|#151|#8212);/i', // mdash
|
||||
'/&(ndash|minus|#8211|#8722);/i', // ndash
|
||||
'/&(bull|#149|#8226);/i', // Bullet
|
||||
'/&(pound|#163);/i', // Pound sign
|
||||
'/&(euro|#8364);/i', // Euro sign
|
||||
'/$/', // Dollar sign
|
||||
'/&[^&;]+;/i', // Unknown/unhandled entities
|
||||
'/[ ]{2,}/' // Runs of spaces, post-handling
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
|
||||
/** List of symbols "for Replace To" */
|
||||
private function get_plain_replace_array() {
|
||||
|
||||
return array(
|
||||
'', // Non-legal carriage return
|
||||
' ', // Non-breaking space
|
||||
'"', // Double quotes
|
||||
"'", // Single quotes
|
||||
'>', // Greater-than
|
||||
'<', // Less-than
|
||||
'&', // Ampersand
|
||||
'&', // Ampersand
|
||||
'&', // Ampersand
|
||||
'(c)', // Copyright
|
||||
'(tm)', // Trademark
|
||||
'(R)', // Registered
|
||||
'--', // mdash
|
||||
'-', // ndash
|
||||
'*', // Bullet
|
||||
'£', // Pound sign
|
||||
'EUR', // Euro sign. € ?
|
||||
'$', // Dollar sign
|
||||
'', // Unknown/unhandled entities
|
||||
' ' // Runs of spaces, post-handling
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
/** Esacpe and replace any HTML entities
|
||||
*
|
||||
* @param type $string
|
||||
* @return string
|
||||
*/
|
||||
public function esc_to_plain_text( $string ) {
|
||||
|
||||
// //Replace <a href="http://server.com">Link</a> to Link( http://server.com )
|
||||
// $pattern = "/<a(.*)+href=[\"|']+([^\"']+)(?=(\"|'))[^>]*>(.*)<\/a>/" ; //"/(?<=href=(\"|'))[^\"']+(?=(\"|'))/i";
|
||||
// $newurl = "$4 ($2)";
|
||||
// $string = preg_replace($pattern,$newurl,$string);
|
||||
|
||||
$newstring = preg_replace( $this->get_plain_search_array(), $this->get_plain_replace_array(), strip_tags( $string ) );
|
||||
return $newstring;
|
||||
}
|
||||
|
||||
|
||||
/** Set array for replacing shortcodes in Email Content and Subject
|
||||
*
|
||||
* @param array $replace - if this parameter skipped, then array reseted to empty array
|
||||
*/
|
||||
function set_replace( $replace = array() ) {
|
||||
$this->replace = $replace;
|
||||
}
|
||||
|
||||
|
||||
/** Replace shortcodes in givven string. Usually its Email Content and Subject
|
||||
*
|
||||
* @param string $subject
|
||||
*/
|
||||
public function replace_shortcodes( $subject ) {
|
||||
|
||||
$defaults = array(
|
||||
'ip' => apply_opsd_filter( 'opsd_get_user_ip' )
|
||||
, 'blogname' => wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES )
|
||||
, 'siteurl' => get_site_url()
|
||||
);
|
||||
|
||||
$replace = wp_parse_args( $this->replace, $defaults );
|
||||
|
||||
foreach ( $replace as $replace_shortcode => $replace_value ) {
|
||||
if ( is_string( $replace_value ) ) { //FixIn: 1.1.3.1
|
||||
$replace_shortcode = (string) $replace_shortcode;
|
||||
$replace_value = (string) $replace_value;
|
||||
$subject = str_replace( array( '[' . $replace_shortcode . ']'
|
||||
, '{' . $replace_shortcode . '}' )
|
||||
, $replace_value
|
||||
, $subject );
|
||||
}
|
||||
}
|
||||
|
||||
return $subject;
|
||||
}
|
||||
|
||||
// </editor-fold>
|
||||
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" Pure Email functions " >
|
||||
|
||||
/** For MultiPart email define plain text - AltBody
|
||||
*
|
||||
* Also additionaly fix Sender - its have to be same as From
|
||||
*
|
||||
* @param PHPMailer $mailer
|
||||
* @return PHPMailer
|
||||
*/
|
||||
public function process_multipart( $mailer ) {
|
||||
|
||||
//if ( $this->sending && $this->get_email_content_type() == 'multipart' ) {
|
||||
if ( $this->sending ) {
|
||||
|
||||
if ( $this->get_email_content_type() == 'multipart' )
|
||||
$mailer->AltBody = wordwrap( $this->esc_to_plain_text( $this->replace_shortcodes( $this->get_content_plain() ) ) );
|
||||
|
||||
$mailer->Sender = $mailer->From;
|
||||
|
||||
//$this->sending = false; // If we set it to false, then we can not trigger for any Mail errors in this CLASS
|
||||
}
|
||||
|
||||
return $mailer;
|
||||
}
|
||||
|
||||
|
||||
/** Get type of Email: 'plain' | 'html' | 'multipart'
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function get_email_content_type() {
|
||||
|
||||
return $this->fields_values['email_content_type'] && class_exists( 'DOMDocument' ) ? $this->fields_values['email_content_type'] : 'plain';
|
||||
}
|
||||
|
||||
|
||||
/** Get Email Content Type: 'text/plain' | 'text/html' | 'multipart/alternative'
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function get_content_type() {
|
||||
|
||||
switch ( $this->get_email_content_type() ) {
|
||||
case 'html' :
|
||||
return 'text/html';
|
||||
case 'multipart' :
|
||||
return 'multipart/alternative';
|
||||
default :
|
||||
return 'text/plain';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/** Define Email Headers. For exmaple: "Conte type:" 'text/plain' | 'text/html' | 'multipart/alternative' or "From": Name <email@server.com>
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function get_headers( $additional_params = array() ) {
|
||||
|
||||
$mail_headers = '';
|
||||
|
||||
$from_address = $this->get_from__email_address();
|
||||
|
||||
if ( ! empty( $from_address ) ) {
|
||||
$mail_headers .= 'From: ' . $this->get_from__name() . ' <' . $from_address . '> ' . "\r\n" ;
|
||||
} else {
|
||||
/* If we don't have an email from the input headers default to wordpress@$sitename
|
||||
* Some hosts will block outgoing mail from this address if it doesn't exist but
|
||||
* there's no easy alternative. Defaulting to admin_email might appear to be another
|
||||
* option but some hosts may refuse to relay mail from an unknown domain. See
|
||||
* https://core.trac.wordpress.org/ticket/5007.
|
||||
*/
|
||||
}
|
||||
|
||||
$mail_headers .= 'Content-Type: ' . $this->get_content_type() . "\r\n" ;
|
||||
|
||||
$mail_headers = apply_filters( 'opsd_email_api_get_headers_after', $mail_headers, $this->id, $this->fields_values , $this->replace, $additional_params );
|
||||
|
||||
return $mail_headers;
|
||||
}
|
||||
|
||||
|
||||
/** Get Content of Email
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function get_content() {
|
||||
|
||||
if ( $this->get_email_content_type() == 'plain' ) {
|
||||
$email_content = $this->esc_to_plain_text( $this->replace_shortcodes( $this->get_content_plain() ) );
|
||||
} else {
|
||||
$email_content = $this->replace_shortcodes( $this->get_content_html() );
|
||||
}
|
||||
|
||||
$email_content = apply_filters( 'opsd_email_api_get_content_after' , $email_content, $this->id, $this->get_email_content_type() );
|
||||
|
||||
// Remove all shortcodes, which is not replaced early.
|
||||
$email_content = preg_replace ('/[\[\{][a-zA-Z0-9.,_-]{0,}[\]\}]/', '', $email_content);
|
||||
|
||||
return wordwrap( $email_content, 100 );
|
||||
}
|
||||
|
||||
|
||||
/** Get Email Content as Text (from Plain Text template)
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
function get_content_plain() {
|
||||
|
||||
//require_once( dirname(__FILE__) . '/emails_tpl/standard-text-tpl.php' );
|
||||
//require_once( dirname(__FILE__) . '/emails_tpl/plain-text-tpl.php' );
|
||||
if ( isset( $this->fields_values['template_file'] ) ) {
|
||||
$email_tpl_name = $this->fields_values['template_file'];
|
||||
} else {
|
||||
$email_tpl_name = 'plain';
|
||||
}
|
||||
|
||||
if ( file_exists( dirname(__FILE__) . '/emails_tpl/'. $email_tpl_name .'-text-tpl.php' ) )
|
||||
require_once( dirname(__FILE__) . '/emails_tpl/'. $email_tpl_name .'-text-tpl.php' );
|
||||
else
|
||||
require_once( dirname(__FILE__) . '/emails_tpl/plain-text-tpl.php' );
|
||||
|
||||
$fields_values = $this->fields_values;
|
||||
|
||||
$fields_values = apply_filters( 'opsd_email_api_get_content_before' , $fields_values, $this->id , 'plain' ); //Ability to parse 'content', 'header_content', 'footer_content' for different languges, etc ....
|
||||
|
||||
if ( function_exists( 'opsd_email_template_' . $email_tpl_name . '_text' ) )
|
||||
$plain_email = call_user_func_array( 'opsd_email_template_' . $email_tpl_name . '_text' , array( $fields_values ) );
|
||||
else
|
||||
$plain_email = opsd_email_template_text( $fields_values );
|
||||
|
||||
// Replace <p> | <br> to \n
|
||||
$plain_email = preg_replace( '/<(br|p)[\t\s]*[\/]?>/i', "\n", $plain_email );
|
||||
// $plain_email = str_replace( array('<br/>', '<br>'), "\n", $plain_email );
|
||||
|
||||
return $plain_email;
|
||||
}
|
||||
|
||||
|
||||
/** Get Email Content as HTML (from HTML template)
|
||||
*
|
||||
* @return type
|
||||
*/
|
||||
function get_content_html() {
|
||||
|
||||
// Load specific Email Template: ///////////////////////////////////
|
||||
if ( isset( $this->fields_values['template_file'] ) ) {
|
||||
$email_tpl_name = $this->fields_values['template_file'];
|
||||
} else {
|
||||
$email_tpl_name = 'plain';
|
||||
}
|
||||
//require_once( dirname(__FILE__) . '/emails_tpl/standard-html-tpl.php' );
|
||||
//require_once( dirname(__FILE__) . '/emails_tpl/plain-html-tpl.php' );
|
||||
|
||||
if ( file_exists( dirname(__FILE__) . '/emails_tpl/'. $email_tpl_name .'-html-tpl.php' ) )
|
||||
require_once( dirname(__FILE__) . '/emails_tpl/'. $email_tpl_name .'-html-tpl.php' );
|
||||
else
|
||||
require_once( dirname(__FILE__) . '/emails_tpl/plain-html-tpl.php' );
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
||||
$fields_values = $this->fields_values;
|
||||
|
||||
$fields_values = apply_filters( 'opsd_email_api_get_content_before' , $fields_values, $this->id , 'html' ); //Ability to parse 'content', 'header_content', 'footer_content' for different languges, etc ....
|
||||
|
||||
if ( function_exists( 'opsd_email_template_' . $email_tpl_name . '_html' ) )
|
||||
$html_email = call_user_func_array( 'opsd_email_template_' . $email_tpl_name . '_html' , array( $fields_values ) );
|
||||
else
|
||||
$html_email = opsd_email_template_html( $fields_values );
|
||||
|
||||
return $html_email;
|
||||
}
|
||||
|
||||
|
||||
/** Get escaped Email Subject
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function get_subject() {
|
||||
|
||||
$subject = $this->fields_values['subject'];
|
||||
|
||||
$subject = apply_filters( 'opsd_email_api_get_subject_before' , $subject, $this->id );
|
||||
|
||||
$subject = $this->esc_to_plain_text( $this->replace_shortcodes( $subject ) );
|
||||
|
||||
$subject = apply_filters( 'opsd_email_api_get_subject_after' , $subject, $this->id );
|
||||
|
||||
return $subject;
|
||||
}
|
||||
|
||||
|
||||
/** Get escapeed Name from any not supporting characters
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function get_from__name() {
|
||||
return wp_specialchars_decode( esc_html( stripslashes( $this->fields_values['from_name'] ) ), ENT_QUOTES );
|
||||
}
|
||||
|
||||
|
||||
/** Get sanitized Email address
|
||||
*
|
||||
* @return type
|
||||
*/
|
||||
public function get_from__email_address() {
|
||||
return sanitize_email( $this->fields_values['from'] );
|
||||
}
|
||||
|
||||
|
||||
/** For future support, right now does not support
|
||||
*
|
||||
* @return empty string
|
||||
*/
|
||||
public function get_attachments() {
|
||||
return '';
|
||||
}
|
||||
|
||||
|
||||
/** Check email and format it
|
||||
*
|
||||
* @param string $emails
|
||||
* @return string
|
||||
*/
|
||||
public function validate_emails( $emails ) {
|
||||
|
||||
$emails = str_replace(';', ',', $emails);
|
||||
|
||||
if ( !is_array( $emails ) )
|
||||
$emails = explode( ',', $emails );
|
||||
|
||||
$emails_list = array();
|
||||
foreach ( (array) $emails as $recipient ) {
|
||||
|
||||
// Break $recipient into name and address parts if in the format "Foo <bar@baz.com>"
|
||||
$recipient_name = '';
|
||||
if( preg_match( '/(.*)<(.+)>/', $recipient, $matches ) ) {
|
||||
if ( count( $matches ) == 3 ) {
|
||||
$recipient_name = $matches[1];
|
||||
$recipient = $matches[2];
|
||||
}
|
||||
} else {
|
||||
// Check about correct format of email
|
||||
if( preg_match( '/([\w\.\-_]+)?\w+@[\w\-_]+(\.\w+){1,}/im', $recipient, $matches ) ) { //FixIn: 8.7.7.2
|
||||
$recipient = $matches[0];
|
||||
}
|
||||
}
|
||||
|
||||
//$recipient_name = str_replace('"', '', $recipient_name);
|
||||
$recipient_name = trim( wp_specialchars_decode( esc_html( stripslashes( $recipient_name ) ), ENT_QUOTES ) );
|
||||
|
||||
$emails_list[] = ( empty( $recipient_name ) ? '' : $recipient_name . ' ' )
|
||||
. '<' . sanitize_email( $recipient ) . '>';
|
||||
}
|
||||
|
||||
$emails_list = implode( ',', $emails_list );
|
||||
|
||||
return $emails_list;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Make Email Sending by using wp_mail standard function.
|
||||
*
|
||||
* @param string $to - Email
|
||||
* @param array $replace - accociated array of values to replace in email Body and Subject. Exmaple: array( 'name' => 'Jo', 'secondname' => 'Smith' )
|
||||
* @return boolean Sent or Failed to send.
|
||||
*/
|
||||
public function send( $to = '', $replace = array() ) {
|
||||
|
||||
$return = false;
|
||||
|
||||
// if ( empty( $to ) )
|
||||
// return $return;
|
||||
|
||||
$this->sending = true;
|
||||
|
||||
|
||||
$this->set_replace( $replace );
|
||||
|
||||
$to = $this->validate_emails( $to );
|
||||
|
||||
$subject = $this->get_subject();
|
||||
$message = $this->get_content();
|
||||
$headers = $this->get_headers();
|
||||
$attachments = $this->get_attachments();
|
||||
//debuge('In email', htmlentities($to), $subject, htmlentities($message), $headers, $attachments) ;
|
||||
$is_send_email = true;
|
||||
|
||||
$is_send_email = apply_filters( 'opsd_email_api_is_allow_send', $is_send_email, $this->id, $this->fields_values );
|
||||
|
||||
if ( $is_send_email )
|
||||
$return = wp_mail( $to, $subject, $message, $headers, $attachments );
|
||||
|
||||
$this->sending = false;
|
||||
|
||||
// Send Copy to admin email
|
||||
if (
|
||||
( isset( $this->fields_values['copy_to_admin'] ) )
|
||||
&& ( $this->fields_values['copy_to_admin'] == 'On' )
|
||||
){
|
||||
|
||||
$this->sending = true;
|
||||
|
||||
$subject = __('Email copy to', 'secure-downloads') . ' ' . str_replace( array( '<', '>' ), '', $to) . ' - ' . $subject;
|
||||
|
||||
$headers = $this->get_headers( array( 'reply' => $to ) );
|
||||
|
||||
$to = $this->validate_emails( $this->get_from__name() . ' <' . $this->get_from__email_address() . '> ' );
|
||||
|
||||
$is_send_email = apply_filters( 'opsd_email_api_is_allow_send_copy', $is_send_email, $this->id, $this->fields_values );
|
||||
|
||||
if ( $is_send_email )
|
||||
$return_copy = wp_mail( $to, $subject, $message, $headers, $attachments );
|
||||
|
||||
$this->sending = false;
|
||||
}
|
||||
|
||||
$this->set_replace(); // Reset replace parameter
|
||||
|
||||
return $return;
|
||||
}
|
||||
// </editor-fold>
|
||||
|
||||
|
||||
/** Show possible erros during sending emails.
|
||||
*
|
||||
* @param type $wp_error_object - new WP_Error( $e->getCode(), $e->getMessage(), $mail_error_data )
|
||||
*/
|
||||
public function email_error_parse( $wp_error_object ) {
|
||||
//debuge( $wp_error_object );
|
||||
if ( $this->sending ) { // Check if this error generated for email relative to this class.
|
||||
|
||||
$error_description_array = array();
|
||||
if ( isset( $wp_error_object->errors ) )
|
||||
foreach ( $wp_error_object->errors as $key_error => $error_description ) {
|
||||
$error_description_array[] = implode(' ', $error_description );
|
||||
}
|
||||
|
||||
if ( ! empty( $error_description_array ) ) {
|
||||
$error_description = implode(' ', $error_description_array ) ;
|
||||
|
||||
do_action('opsd_email_sending_error', $wp_error_object, $error_description );
|
||||
|
||||
} else {
|
||||
do_action('opsd_email_sending_error', $wp_error_object, '' );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,259 @@
|
||||
<?php /**
|
||||
* @version 1.1
|
||||
* @package Any
|
||||
* @category Menu in Admin Panel
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-11-02
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
class OPSD_Admin_Menus {
|
||||
|
||||
/* Static Variables */
|
||||
static $capability = array( 'administrator' => 'activate_plugins',
|
||||
'editor' => 'publish_pages',
|
||||
'author' => 'publish_posts',
|
||||
'contributor' => 'edit_posts',
|
||||
'subscriber' => 'read'
|
||||
);
|
||||
protected $menu_tag;
|
||||
protected $menu_title;
|
||||
protected $menu_title_second; // For root menu chnage second title in submenu - little hack
|
||||
protected $page_header; // Header - H2, in page content
|
||||
protected $browser_header; // Browser Header Title
|
||||
protected $in_menu;
|
||||
protected $user_role; // Acceess Role for current menu item
|
||||
protected $mune_icon_url; // Icon - if used 'none', then you can define it in the CSS backgound: .toplevel_page_opsd .wp-menu-image { background-image: url("../img/icon-16x16.png"); background-position: 7px 7px; } But its mean that you are need to load this CSS in every admin page.
|
||||
|
||||
public $root_position; /* Positions for Core Menu Items
|
||||
2 Dashboard
|
||||
4 Separator
|
||||
5 Posts
|
||||
10 Media
|
||||
15 Links
|
||||
20 Pages
|
||||
25 Comments
|
||||
59 Separator
|
||||
60 Appearance
|
||||
65 Plugins
|
||||
70 Users
|
||||
75 Tools
|
||||
80 Settings
|
||||
99 Separator
|
||||
*/
|
||||
|
||||
function __construct( $slug, $param = array() ) {
|
||||
|
||||
$this->in_menu = false;
|
||||
$this->menu_tag = $slug; // For exmaple: 'opsd-settings' - its 'page' parameter in URL
|
||||
|
||||
if ( isset( $param['menu_title'] ) ) $this->menu_title = $param['menu_title'];
|
||||
if ( isset( $param['menu_title_second'] ) ) $this->menu_title_second = $param['menu_title_second'];
|
||||
if ( isset( $param['page_header'] ) ) $this->page_header = $param['page_header'];
|
||||
if ( isset( $param['browser_header'] ) ) $this->browser_header = $param['browser_header'];
|
||||
if ( isset( $param['in_menu'] ) ) $this->in_menu = $param['in_menu'];
|
||||
if ( isset( $param['position'] ) ) $this->root_position = $param['position'];
|
||||
else $this->root_position = null;
|
||||
|
||||
if ( isset( $param['mune_icon_url'] ) ) $this->mune_icon_url = $param['mune_icon_url'];
|
||||
else $this->mune_icon_url = 'none';
|
||||
|
||||
if ( isset( $param['user_role'] ) ) $this->user_role = $param['user_role'];
|
||||
else $this->user_role = 'subscriber';
|
||||
|
||||
add_action( 'admin_menu', array($this, 'new_admin_page'), 10 );
|
||||
|
||||
add_action( 'admin_menu', array($this, 'change_second_root_menu_title'), 11 ); // Change Title of Submenu title for root menu item
|
||||
}
|
||||
|
||||
|
||||
public function load_js() {
|
||||
do_action( 'opsd_load_js_on_admin_page' );
|
||||
}
|
||||
|
||||
|
||||
public function load_css() {
|
||||
do_action( 'opsd_load_css_on_admin_page' );
|
||||
}
|
||||
|
||||
|
||||
/** Define Plugin Menu Page
|
||||
*
|
||||
*/
|
||||
public function new_admin_page(){
|
||||
|
||||
if ( $this->in_menu == 'root' ) { // Main Menu
|
||||
|
||||
$page = $this->create_plugin_menu(
|
||||
$this->browser_header // Browser Page Header Title
|
||||
, $this->menu_title // Menu Title
|
||||
, ( ( isset( self::$capability[ $this->user_role ] ) ) ? self::$capability[ $this->user_role ] : self::$capability[ 'subscriber' ] ) // Capabilities
|
||||
, $this->menu_tag // Slug // I was used early -> plugin_basename(OPSD_FILE).'opsd'
|
||||
, $this->mune_icon_url // Icon // - if used 'none', then you can define it in the CSS backgound: .toplevel_page_opsd .wp-menu-image { background-image: url("../img/icon-16x16.png"); background-position: 7px 7px; } But its mean that you are need to load this CSS in every admin page.
|
||||
, array( $this, 'content' ) // Function for output content of page
|
||||
);
|
||||
|
||||
} else { // Sub Menu
|
||||
|
||||
$page = $this->create_plugin_submenu(
|
||||
$this->in_menu // The slug name for parent menu (or file name of standard WordPress admin page)
|
||||
, $this->browser_header // Page Title
|
||||
, $this->menu_title // Menu Title
|
||||
, ( ( isset( self::$capability[ $this->user_role ] ) ) ? self::$capability[ $this->user_role ] : self::$capability[ 'subscriber' ] ) // Capabilities
|
||||
, $this->menu_tag // Slug
|
||||
, array( $this, 'content' ) // Function for output content of page
|
||||
);
|
||||
}
|
||||
|
||||
//do_action('opsd_define_settings_pages', $this->menu_tag ); // Define sub classes, like: page-settings-general.php $this->menu_tag - 'opsd-settings' - its 'page' parameter in URL
|
||||
|
||||
do_action('opsd_menu_created', $this->menu_tag ); // Define sub classes, like: page-settings-general.php $this->menu_tag - 'opsd-settings' - its 'page' parameter in URL
|
||||
do_action('opsd_define_nav_tabs', $this->menu_tag ); // Define Nav tabs.
|
||||
}
|
||||
|
||||
|
||||
/** Content of the Menu Page
|
||||
*
|
||||
Define page S t r u c t u r e, nav T A B s , set N O N C E: opsd_ajax_admin_nonce field
|
||||
|
||||
in ..\any\class\class-admin-page-structure.php
|
||||
|
||||
then show page C O N T E N T in files, like page-structure.php
|
||||
|
||||
$this->menu_tag - 'opsd-settings' - its 'page' parameter in URL
|
||||
*/
|
||||
public function content() {
|
||||
|
||||
do_action('opsd_page_structure_show', $this->menu_tag );
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** Hack for changing Root 2nd Submenu Title
|
||||
*
|
||||
* @global type $submenu
|
||||
*/
|
||||
public function change_second_root_menu_title() {
|
||||
|
||||
// Change Title of the Main menu inside of submenu
|
||||
global $submenu;
|
||||
|
||||
if ( ( $this->in_menu == 'root' )
|
||||
&& ( isset( $submenu[ $this->menu_tag ] ) )
|
||||
&& ( isset( $this->menu_title_second ) )
|
||||
) {
|
||||
$submenu[ $this->menu_tag ][0][0] = $this->menu_title_second;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/** Add Menu
|
||||
*
|
||||
* @param type $menu_page_title
|
||||
* @param type $menu_title
|
||||
* @param type $capability
|
||||
* @param type $menu_slug
|
||||
* @param type $mune_icon_url
|
||||
* @param type $page_content
|
||||
* @param type $page_css
|
||||
* @param type $page_js
|
||||
* @return type
|
||||
*/
|
||||
protected function create_plugin_menu($menu_page_title, $menu_title, $capability, $menu_slug, $mune_icon_url, $page_content ) {
|
||||
/**
|
||||
* add_menu_page( $page_title, $menu_title, $capability, $menu_slug, $function, $icon_url, $position );
|
||||
* @return string The resulting page's hook_suffix
|
||||
*/
|
||||
|
||||
//FixIn: 2.0.1.2
|
||||
// The url to the icon to be used for this menu. Using 'none' would leave div.wp-menu-image empty so an icon can be added as background with CSS.
|
||||
if ( '<svg' == substr( $mune_icon_url, 0, 4 ) ) {
|
||||
/*
|
||||
$mune_icon_url_svg = '<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" class="" viewBox="-2 -1 20 20">
|
||||
<path d="M3.5 0a.5.5 0 0 1 .5.5V1h8V.5a.5.5 0 0 1 1 0V1h1a2 2 0 0 1 2 2v11a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V3a2 2 0 0 1 2-2h1V.5a.5.5 0 0 1 .5-.5zM2 2a1 1 0 0 0-1 1v1h14V3a1 1 0 0 0-1-1H2zm13 3H1v9a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1V5z"/>
|
||||
<path d="M9 7.5a.5.5 0 0 1 .5-.5H15v2H9.5a.5.5 0 0 1-.5-.5v-1zm-2 3v1a.5.5 0 0 1-.5.5H1v-2h5.5a.5.5 0 0 1 .5.5z"/>
|
||||
</svg>';
|
||||
*/
|
||||
$mune_icon_url = sprintf( 'data:image/svg+xml;base64,%s', base64_encode( $mune_icon_url ) );
|
||||
|
||||
} elseif ( $mune_icon_url == 'none' ) {
|
||||
$mune_icon_url = 'none';
|
||||
} elseif ( empty( $mune_icon_url ) ) {
|
||||
$mune_icon_url = '';
|
||||
} else {
|
||||
$mune_icon_url = plugins_url( $mune_icon_url, OPSD_FILE );
|
||||
}
|
||||
|
||||
$page = add_menu_page( $menu_page_title, // The text to be displayed in the title tags of the page when the menu is selected
|
||||
$menu_title, // The text to be used for the menu
|
||||
$capability, // The capability required for this menu to be displayed to the user.
|
||||
$menu_slug, // The slug name to refer to this menu by (should be unique for this menu)
|
||||
$page_content, // The function to be called to output the content for this page.
|
||||
$mune_icon_url//(($mune_icon_url=='none')?'none':((empty($mune_icon_url))?'':plugins_url($mune_icon_url, OPSD_FILE)) ) // The url to the icon to be used for this menu. Using 'none' would leave div.wp-menu-image empty so an icon can be added as background with CSS.
|
||||
, $this->root_position /* @param int $position The position in the menu order this one should appear
|
||||
* Positions for Core Menu Items
|
||||
2 Dashboard
|
||||
4 Separator
|
||||
5 Posts
|
||||
10 Media
|
||||
15 Links
|
||||
20 Pages
|
||||
25 Comments
|
||||
59 Separator
|
||||
60 Appearance
|
||||
65 Plugins
|
||||
70 Users
|
||||
75 Tools
|
||||
80 Settings
|
||||
99 Separator
|
||||
*/
|
||||
);
|
||||
|
||||
add_action( 'admin_print_styles-' . $page, array( $this, 'load_css' ) );
|
||||
|
||||
add_action( 'admin_print_scripts-' . $page, array( $this, 'load_js' ) );
|
||||
|
||||
return $page;
|
||||
}
|
||||
|
||||
|
||||
/** Add Sub Menu
|
||||
*
|
||||
* @param type $parent_menu_slug - The slug name for the parent menu (or the file name of a standard WordPress admin page)
|
||||
* @param type $menu_page_title
|
||||
* @param type $menu_title
|
||||
* @param type $capability
|
||||
* @param type $menu_slug
|
||||
* @param type $page_content
|
||||
* @param type $page_css
|
||||
* @param type $page_js
|
||||
* @return type
|
||||
*/
|
||||
protected function create_plugin_submenu( $parent_menu_slug, $menu_page_title, $menu_title, $capability, $menu_slug, $page_content ) {
|
||||
|
||||
/**
|
||||
* function add_submenu_page( $parent_slug, $page_title, $menu_title, $capability, $menu_slug, $function = '' );
|
||||
* @return string|bool The resulting page's hook_suffix, or false if the user does not have the capability required.
|
||||
*/
|
||||
|
||||
$page = add_submenu_page(
|
||||
$parent_menu_slug, // The slug name for the parent menu (or the file name of a standard WordPress admin page)
|
||||
$menu_page_title, // The text to be displayed in the title tags of the page when the menu is selected
|
||||
$menu_title, // The text to be used for the menu
|
||||
$capability, // The capability required for this menu to be displayed to the user.
|
||||
$menu_slug, // The slug name to refer to this menu by (should be unique for this menu)
|
||||
$page_content // The function to be called to output the content for this page.
|
||||
);
|
||||
|
||||
add_action( 'admin_print_styles-' . $page, array( $this, 'load_css' ) );
|
||||
|
||||
add_action( 'admin_print_scripts-' . $page, array( $this, 'load_js' ) );
|
||||
|
||||
return $page;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,665 @@
|
||||
<?php /**
|
||||
* @version 1.1
|
||||
* @package Any
|
||||
* @category Page Structure in Admin Panel
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-11-02
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit, if accessed directly
|
||||
|
||||
|
||||
/** Define Settings Page Structure */
|
||||
abstract class OPSD_Page_Structure {
|
||||
|
||||
protected static $nav_tabs; // Tabs array, same for all objects
|
||||
|
||||
private $current_page_params; // Parameters for current page, if this page selected, otherwise its = empty array()
|
||||
private $is_only_icons = false;
|
||||
|
||||
protected $tags; // Defining Name of parameter in GET request for Navigation TOP and BOTTOM tabs
|
||||
// - $_GET[ 'tab' ] == 'payment'
|
||||
// - $_GET[ 'subtab' ] == 'paypal'
|
||||
|
||||
public function __construct() {
|
||||
|
||||
$this->tags = array();
|
||||
$this->tags['tab'] = 'tab'; // Defining Name of parameter in GET request - $_GET[ 'tab' ] == 'payment'
|
||||
$this->tags['subtab'] = 'subtab'; // Defining Name of parameter in GET request - $_GET[ 'subtab' ] == 'paypal'
|
||||
|
||||
|
||||
$this->current_page_params = array();
|
||||
self::$nav_tabs = array();
|
||||
|
||||
add_action('opsd_define_nav_tabs', array( $this, 'opsd_define_nav_tabs' ) ); // This Hook fire after creation menu in class OPSD_Admin_Menus
|
||||
|
||||
add_action('opsd_page_structure_show', array( $this, 'content_structure' ) ); // This Hook fire in the class OPSD_Admin_Menus for showing page content of specific menu
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// Abstract Methods
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/** Define slug in what menu to show this page. // Parameter relative: $_GET['page'].
|
||||
*
|
||||
* @return string
|
||||
*
|
||||
* Example:
|
||||
|
||||
return 'opsd-settings';
|
||||
|
||||
*/
|
||||
abstract public function in_page();
|
||||
|
||||
/** Define Tabs and Subtabs of this Admin Page
|
||||
*
|
||||
* @return array();
|
||||
|
||||
* Example:
|
||||
|
||||
$tabs = array();
|
||||
$tabs[ 'form' ] = array(
|
||||
'title' => __('Form', 'secure-downloads') // Title of TAB
|
||||
, 'hint' => __('Customizaton of Form Fields', 'secure-downloads') // Hint
|
||||
, 'page_title' =>ucwords( __('Form fields', 'secure-downloads') ) // Title of Page
|
||||
//, 'link' => '' // Can be skiped, then generated link based on Page and Tab tags. Or can be extenral link
|
||||
//, 'position' => '' // 'left' || 'right' || ''
|
||||
//, 'css_classes' => '' // CSS class(es)
|
||||
//, 'icon' => '' // Icon - link to the real PNG img
|
||||
, 'font_icon' => 'glyphicon glyphicon-edit' // CSS definition of forn Icon
|
||||
, 'default' => false // Is this tab activated by default or not: true || false.
|
||||
, 'disabled' => false // Is this tab disbaled: true || false.
|
||||
, 'hided' => false // Is this tab hided: true || false.
|
||||
, 'subtabs' => array()
|
||||
|
||||
);
|
||||
$tabs[ 'upgrade' ] = array(
|
||||
'title' => __('Upgrade', 'secure-downloads') // Title of TAB
|
||||
, 'hint' => __('Upgrade to higher version', 'secure-downloads') // Hint
|
||||
//, 'page_title' => __('Upgrade', 'secure-downloads') // Title of Page
|
||||
, 'link' => 'http://server.com/' // Can be skiped, then generated link based on Page and Tab tags. Or can be extenral link
|
||||
, 'position' => 'right' // 'left' || 'right' || ''
|
||||
//, 'css_classes' => '' // CSS class(es)
|
||||
//, 'icon' => '' // Icon - link to the real PNG img
|
||||
, 'font_icon' => 'glyphicon glyphicon-shopping-cart'// CSS definition of forn Icon
|
||||
//, 'default' => false // Is this tab activated by default or not: true || false.
|
||||
//, 'subtabs' => array()
|
||||
|
||||
);
|
||||
|
||||
$subtabs = array();
|
||||
|
||||
$subtabs['fields'] = array(
|
||||
'type' => 'subtab' // Required| Possible values: 'subtab' | 'separator' | 'button' | 'goto-link' | 'html'
|
||||
, 'title' => __('Form', 'secure-downloads') // Title of TAB
|
||||
, 'page_title' => __('Form Settings', 'secure-downloads') // Title of Page
|
||||
, 'hint' => __('Customization of Form Settings', 'secure-downloads') // Hint
|
||||
, 'link' => '' // link
|
||||
, 'position' => '' // 'left' || 'right' || ''
|
||||
, 'css_classes' => '' // CSS class(es)
|
||||
//, 'icon' => 'https://www.paypalobjects.com/webstatic/icon/pp258.png' // Icon - link to the real PNG img
|
||||
//, 'font_icon' => 'glyphicon glyphicon-credit-card' // CSS definition of Font Icon
|
||||
, 'default' => true // Is this sub tab activated by default or not: true || false.
|
||||
, 'disabled' => false // Is this sub tab deactivated: true || false.
|
||||
, 'checkbox' => false // or definition array for specific checkbox: array( 'checked' => true, 'name' => 'feature1_active_status' )
|
||||
, 'content' => 'content' // Function to load as conten of this TAB
|
||||
);
|
||||
|
||||
$subtabs['form-separator'] = array(
|
||||
'type' => 'separator' // Required| Possible values: 'subtab' | 'separator' | 'button' | 'goto-link' | 'html'
|
||||
);
|
||||
$subtabs['form-goto'] = array(
|
||||
'type' => 'goto-link' // Required| Possible values: 'subtab' | 'separator' | 'button' | 'goto-link' | 'html'
|
||||
, 'title' =>ucwords( __('Form fields', 'secure-downloads') ) // Title of TAB
|
||||
, 'hint' => '' // Hint
|
||||
, 'show_section' => 'id_of_show_section' // ID of HTML element, for scroll to.
|
||||
);
|
||||
|
||||
ob_start();
|
||||
...
|
||||
$html_element_data = ob_get_clean();
|
||||
|
||||
$subtabs['form-selection'] = array(
|
||||
'type' => 'html' // Required| Possible values: 'subtab' | 'separator' | 'button' | 'goto-link' | 'html'
|
||||
, 'html' => $html_element_data
|
||||
);
|
||||
|
||||
$subtabs['form-save'] = array(
|
||||
'type' => 'button' // Required| Possible values: 'subtab' | 'separator' | 'button' | 'goto-link' | 'html'
|
||||
, 'title' => __('Save Changes', 'secure-downloads') // Title of TAB
|
||||
, 'form' => 'opsd_form' // Required for 'button'! Name of Form to submit
|
||||
);
|
||||
|
||||
$tabs[ 'form' ][ 'subtabs' ] = $subtabs;
|
||||
|
||||
return $tabs;
|
||||
*/
|
||||
abstract public function tabs();
|
||||
|
||||
/** Show Content of this page - Main function.
|
||||
*
|
||||
* In top of this function have to be checking ubout Update (saving POST request).
|
||||
*
|
||||
* Exmaple:
|
||||
|
||||
// S u b m i t ///////////////////////////////////////////////////////
|
||||
|
||||
$this_submit_form = 'opsd_emails_toolbar'; // Define form name
|
||||
|
||||
if ( isset( $_POST['is_form_sbmitted_'. $this_submit_form ] ) ) {
|
||||
|
||||
// Check N o n c e
|
||||
check_admin_referer( 'opsd_settings_page_' . $this_submit_form ); // Its stop show anything on submiting, if its not refear to the original page
|
||||
|
||||
// Make Update of settings
|
||||
$edit_field_data = $this->update_opsd_emails_toolbar( $menu_slug );
|
||||
}
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
*/
|
||||
abstract public function content();
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// C O N T E N T
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/** General Page Structure
|
||||
*
|
||||
* @param string $page_tag - its the same that return $this->in_page()
|
||||
*/
|
||||
public function content_structure( $page_tag ) {
|
||||
|
||||
|
||||
|
||||
if ( ! $this->is_page_activated() )
|
||||
return false;
|
||||
|
||||
|
||||
|
||||
$active_page_tab = $active_page_subtab = '';
|
||||
if ( ( isset( $this->current_page_params['tab'] ) ) && ( ! empty( $this->current_page_params['tab']['tag'] ) ) )
|
||||
$active_page_tab = $this->current_page_params['tab']['tag'];
|
||||
if ( ( isset( $this->current_page_params['subtab'] ) ) && ( ! empty( $this->current_page_params['subtab']['tag'] ) ) )
|
||||
$active_page_subtab = $this->current_page_params['subtab']['tag'];
|
||||
|
||||
$is_show_this_page = apply_filters( 'opsd_before_showing_settings_page_is_show_page', true, $page_tag, $active_page_tab, $active_page_subtab ); // Fires Before showing settings Content page
|
||||
|
||||
if ( $is_show_this_page === false ) return false;
|
||||
|
||||
do_action( 'opsd_before_settings_content', $page_tag, $active_page_tab, $active_page_subtab ); // Fires Before showing settings Content page
|
||||
|
||||
?><div id="<?php echo $page_tag; ?>-admin-page" class="wrap opsd_page"><?php
|
||||
do_action( 'opsd_settings_before_header', $page_tag, $active_page_tab, $active_page_subtab ); // FixIn: N
|
||||
?>
|
||||
<h1 class="opsd_header"><div class="opsd_header_icon"></div><?php echo $this->get_page_header_h1(); ?></h1><?php
|
||||
do_action( 'opsd_settings_after_header', $page_tag, $active_page_tab, $active_page_subtab ); // FixIn: N
|
||||
?>
|
||||
<div class="opsd_admin_message"></div>
|
||||
<div class="opsd_admin_page">
|
||||
<div id="ajax_working"></div>
|
||||
<div class="clear opsd_header_margin"></div>
|
||||
<div id="ajax_respond" class="ajax_respond" style="display:none;"></div>
|
||||
<?php
|
||||
|
||||
// T A B S
|
||||
$this->show_tabs_structure( $page_tag );
|
||||
|
||||
wp_nonce_field('opsd_ajax_admin_nonce', "opsd_admin_panel_nonce" , true , true );
|
||||
|
||||
// C o n t e n t
|
||||
if ( ( isset( $this->current_page_params['subtab'] ) ) && ( isset( $this->current_page_params['subtab']['content'] ) ) ) {
|
||||
|
||||
call_user_func( array( $this, $this->current_page_params['subtab']['content'] ) );
|
||||
|
||||
} else if ( ( isset( $this->current_page_params['tab'] ) ) && ( isset( $this->current_page_params['tab']['content'] ) ) ) {
|
||||
call_user_func( array( $this, $this->current_page_params['tab']['content'] ) );
|
||||
|
||||
} else
|
||||
$this->content();
|
||||
|
||||
do_action('opsd_show_settings_content' , $page_tag, $active_page_tab, $active_page_subtab );
|
||||
?></div>
|
||||
</div><?php
|
||||
|
||||
do_action( 'opsd_after_settings_content', $page_tag, $active_page_tab, $active_page_subtab ); // Fires After showing settings Content page
|
||||
}
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// Active Page Parameters
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/** Check if this page selected (active), depend from the GET parameter
|
||||
* If selected, then define Current Page Parameters.
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
private function is_page_activated() {
|
||||
|
||||
$is_page_selected = false;
|
||||
|
||||
$this_page = $this->in_page();
|
||||
|
||||
foreach ( $this->tabs() as $this_tab_tag => $this_tab ) { // Get First Tab Element, which MUST be subtab element, all other tabs, can be links, not really showing content!!!
|
||||
break;
|
||||
}
|
||||
|
||||
if ( empty( $this_tab ) )
|
||||
return $this_page; // this page empty - tabs is empty array, probabaly its was redefined in child CLASS to $tabs = array(); for not ability to open this page.
|
||||
|
||||
$this_subtab_tag = 0;
|
||||
$this_subtab = array( 'default' => false );
|
||||
|
||||
if ( isset( $this_tab['subtabs'] ) )
|
||||
foreach ( $this_tab['subtabs'] as $temp_this_subtab_tag => $temp_this_subtab ) {
|
||||
|
||||
if ( $temp_this_subtab['type'] == 'subtab' ) { // Get First Subtab element from subtabs array
|
||||
$this_subtab_tag = $temp_this_subtab_tag;
|
||||
$this_subtab = $temp_this_subtab;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
//debuge($this_page, $_REQUEST);
|
||||
if ( ( isset( $_REQUEST[ 'page' ] ) )
|
||||
&& ( $this_page == $_REQUEST[ 'page' ] ) ){ // We are inside of this page. Menu item selected.
|
||||
|
||||
if ( ( ! isset( $_REQUEST[ $this->tags['tab'] ] ) ) // TAB NOT selected && Default
|
||||
//&& ( ! isset( $_REQUEST[ $this->tags['subtab'] ] ) ) // SubTab NOT selected
|
||||
&& ( isset( $this_tab['default'] ) ) && ( $this_tab['default'] )
|
||||
)
|
||||
$is_page_selected = true;
|
||||
|
||||
if ( ( isset( $_REQUEST[ $this->tags['tab'] ] ) ) // TAB Selected
|
||||
&& ( ! isset( $_REQUEST[ $this->tags['subtab'] ] ) ) // SubTab NOT selected && ! exist || Default
|
||||
&& ( $_REQUEST[ $this->tags['tab'] ] == $this_tab_tag )
|
||||
&& ( ( $this_subtab_tag === 0 )
|
||||
|| ( $this_subtab['default'] )
|
||||
)
|
||||
)
|
||||
$is_page_selected = true;
|
||||
|
||||
if ( ( isset( $_REQUEST[ $this->tags['tab'] ] ) ) // TAB Selected
|
||||
&& ( isset( $_REQUEST[ $this->tags['subtab'] ] ) ) // SubTab Selected
|
||||
&& ( $_REQUEST[ $this->tags['tab'] ] == $this_tab_tag )
|
||||
&& ( $_REQUEST[ $this->tags['subtab'] ] == $this_subtab_tag )
|
||||
)
|
||||
$is_page_selected = true;
|
||||
}
|
||||
|
||||
|
||||
if ( $is_page_selected ) // If this page activated, then define Current Page parameters
|
||||
$this->define_current_page_parameters( $this_tab_tag, $this_tab, $this_subtab_tag, $this_subtab );
|
||||
|
||||
return $is_page_selected;
|
||||
}
|
||||
|
||||
|
||||
/** Define parameters for current selected page
|
||||
*
|
||||
* @param type $paramas
|
||||
*/
|
||||
private function define_current_page_parameters( $this_tab_tag, $this_tab, $this_subtab_tag, $this_subtab ) {
|
||||
|
||||
$this->current_page_params = array(
|
||||
'tab' => array_merge ( $this_tab, array( 'tag' => $this_tab_tag ) )
|
||||
, 'subtab' => array_merge ( $this_subtab, array( 'tag' => $this_subtab_tag ) )
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
/** Get Header Title (H1) of this selected page
|
||||
* Firstly check in subtabs, otherwise get from tabs and if not exist then
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
private function get_page_header_h1() {
|
||||
|
||||
if ( ! empty( $this->current_page_params ) ) {
|
||||
|
||||
if ( isset( $this->current_page_params['subtab']['page_title'] ) )
|
||||
return $this->current_page_params['subtab']['page_title'];
|
||||
|
||||
if ( isset( $this->current_page_params['tab']['page_title'] ) )
|
||||
return $this->current_page_params['tab']['page_title'];
|
||||
}
|
||||
|
||||
return '';
|
||||
}
|
||||
|
||||
|
||||
/** Get all SubTabs of current opened page Tab
|
||||
*
|
||||
* @param string $menu_in_page_tag - Optional. Menu Tag, the same as $this->in_page();
|
||||
* @return array
|
||||
*/
|
||||
private function get_all_sub_tabs_of_selected_tab( $menu_in_page_tag = false ) {
|
||||
|
||||
if ($menu_in_page_tag === false )
|
||||
$menu_in_page_tag = $this->in_page();
|
||||
|
||||
$all_sub_tabs_of_selected_tab = self::$nav_tabs[ $menu_in_page_tag ][ $this->current_page_params['tab']['tag'] ]['subtabs'];
|
||||
|
||||
return $all_sub_tabs_of_selected_tab;
|
||||
}
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// T A B s
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
// Define ------------------------------------------------------------------
|
||||
|
||||
/** Define TABS structure.
|
||||
* General structure of tabs for every plugin menu page.
|
||||
*/
|
||||
public function opsd_define_nav_tabs() { // Function executed after creation menu in class OPSD_Admin_Menus
|
||||
/*
|
||||
Array (
|
||||
[opsd-resources] => Array ()
|
||||
[opsd-settings] => Array
|
||||
(
|
||||
[general] => Array
|
||||
(
|
||||
[title] => General
|
||||
[page_title] => General Settings
|
||||
...
|
||||
[subtabs] => Array ()
|
||||
)
|
||||
[help] => Array
|
||||
(
|
||||
[title] => Help
|
||||
[page_title] =>
|
||||
...
|
||||
[subtabs] => Array ()
|
||||
)
|
||||
[form] => Array
|
||||
(
|
||||
[title] => Form
|
||||
[hint] => Customizaton of Form Fields
|
||||
[page_title] => Form Fields
|
||||
...
|
||||
[subtabs] => Array
|
||||
(
|
||||
[goto-form] => Array
|
||||
(
|
||||
[type] => goto-link
|
||||
[title] => Form Fields
|
||||
...
|
||||
[content] => content
|
||||
[update] => update
|
||||
)
|
||||
|
||||
[goto-content-data] => Array
|
||||
(
|
||||
[type] => button
|
||||
[title] => Save Changes
|
||||
[form] => opsd_form
|
||||
...
|
||||
)
|
||||
|
||||
)
|
||||
|
||||
)
|
||||
[payment] => Array
|
||||
(
|
||||
[title] => Payments
|
||||
[hint] => Customizaton of Payment
|
||||
[page_title] => Payment Gateways
|
||||
...
|
||||
[subtabs] => Array
|
||||
(
|
||||
[paypal] => Array
|
||||
(
|
||||
[type] => subtab
|
||||
[title] => PayPal
|
||||
...
|
||||
)
|
||||
|
||||
[sage] => Array
|
||||
(
|
||||
[type] => subtab
|
||||
[title] => Sage
|
||||
...
|
||||
)
|
||||
|
||||
)
|
||||
|
||||
)
|
||||
|
||||
)
|
||||
|
||||
)
|
||||
*/
|
||||
|
||||
if ( ! isset( self::$nav_tabs[ $this->in_page() ] ) )
|
||||
self::$nav_tabs[ $this->in_page() ] = array(); // If this page does not exist, then define it.
|
||||
|
||||
$current_tab = $this->tabs();
|
||||
$current_subtabs = array(); // Get Subtabs in separate array.
|
||||
foreach ( $current_tab as $tab_tag => $tab_array ) {
|
||||
|
||||
if ( isset( $tab_array[ 'subtabs' ] ) ) {
|
||||
$current_subtabs[ $tab_tag ] = $tab_array[ 'subtabs' ]; // Create new Subtabs array
|
||||
|
||||
unset( $current_tab[ $tab_tag ][ 'subtabs' ] ); // Detach Subtabs array from Tab array. Its required for do not overwrite subtabs with already exist subtabs in previlosly defined tab.
|
||||
} else
|
||||
$current_subtabs[ $tab_tag ] = array();
|
||||
}
|
||||
|
||||
|
||||
foreach ( $current_tab as $tab_tag => $tab_array ) {
|
||||
|
||||
if ( ! isset( self::$nav_tabs[ $this->in_page() ][ $tab_tag ] ) ) { // If this tab ( for exmaple "payment") declared previously, then does not do anything
|
||||
|
||||
self::$nav_tabs[ $this->in_page() ][ $tab_tag ] = $current_tab[ $tab_tag ];
|
||||
self::$nav_tabs[ $this->in_page() ][ $tab_tag ][ 'subtabs' ] = array();
|
||||
}
|
||||
|
||||
if ( isset(self::$nav_tabs[ $this->in_page() ] ) ) {
|
||||
// Merge subtabs (Ex: PayPal and Sage) and attach to current tab: (Ex: payment)
|
||||
self::$nav_tabs[ $this->in_page() ][ $tab_tag ][ 'subtabs' ] = array_merge(
|
||||
self::$nav_tabs[ $this->in_page() ][ $tab_tag ][ 'subtabs' ]
|
||||
, $current_subtabs[ $tab_tag ]
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/** Get array of visible TABs
|
||||
* Tabs that do not hided or disbaled
|
||||
*
|
||||
* @param string $menu_in_page_tag - Menu Tag, the same as $this->in_page();
|
||||
* @return type
|
||||
*/
|
||||
private function get_visible_tabs( $menu_in_page_tag ) {
|
||||
|
||||
$visible_tabs = array();
|
||||
|
||||
foreach ( self::$nav_tabs[ $menu_in_page_tag ] as $tab_tag => $tab ) {
|
||||
|
||||
if ( empty( $tab['disabled'] )
|
||||
&& empty( $tab['hided'] )
|
||||
) {
|
||||
$visible_tabs[$tab_tag] = $tab;
|
||||
}
|
||||
}
|
||||
|
||||
return $visible_tabs;
|
||||
}
|
||||
|
||||
// Showing -----------------------------------------------------------------
|
||||
|
||||
/**
|
||||
*
|
||||
* @param string $menu_in_page_tag - Menu Tag, the same as $this->in_page();
|
||||
* @return boolean - true if nav tabs exist and false if does not exist
|
||||
*/
|
||||
public function show_tabs_structure( $menu_in_page_tag ) {
|
||||
|
||||
// Exit if no Tabs in this page.
|
||||
if ( empty( self::$nav_tabs[ $menu_in_page_tag ] ) )
|
||||
return false;
|
||||
|
||||
// Exit if tabs hidded or disbaled
|
||||
$visible_tabs = $this->get_visible_tabs( $menu_in_page_tag );
|
||||
if ( empty( $visible_tabs ) )
|
||||
return false;
|
||||
|
||||
?><span class="wpdevelop wpdvlp-nav-tabs-container">
|
||||
<div class="clear"></div><?php
|
||||
|
||||
opsd_bs_toolbar_tabs_html_container_start();
|
||||
|
||||
do_action( 'opsd_toolbar_top_tabs_before' , $menu_in_page_tag );
|
||||
|
||||
$this->show_tabs_line( $menu_in_page_tag ); // T O P T A B S
|
||||
|
||||
do_action( 'opsd_toolbar_top_tabs_after' , $menu_in_page_tag );
|
||||
|
||||
opsd_bs_toolbar_tabs_html_container_end();
|
||||
|
||||
|
||||
$bottom_tabs = $this->get_all_sub_tabs_of_selected_tab( $menu_in_page_tag );
|
||||
|
||||
if ( ! empty( $bottom_tabs ) ) { // S U B T A B S
|
||||
|
||||
opsd_bs_toolbar_sub_html_container_start();
|
||||
|
||||
$this->show_subtabs_line( $bottom_tabs, $menu_in_page_tag );
|
||||
|
||||
opsd_bs_toolbar_sub_html_container_end();
|
||||
|
||||
} // Bottom Tabs
|
||||
|
||||
?></span><?php
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
/** Show Top nav TABs line
|
||||
*
|
||||
* @param string $menu_in_page_tag - Menu Tag, the same as $this->in_page();
|
||||
*/
|
||||
public function show_tabs_line( $menu_in_page_tag ) {
|
||||
|
||||
foreach ( self::$nav_tabs[ $menu_in_page_tag ] as $tab_tag => $tab ) {
|
||||
|
||||
$css_classes = ( ( isset($tab['css_classes']) ) ? $tab['css_classes'] : '' );
|
||||
|
||||
if ( ( isset( $this->current_page_params['tab'] ) ) && ( $this->current_page_params['tab']['tag'] == $tab_tag ) )
|
||||
$css_classes .= ' nav-tab-active';
|
||||
|
||||
if ( ! empty( $tab['position'] ) )
|
||||
$css_classes .= ' nav-tab-position-' . $tab['position'];
|
||||
|
||||
if ( ! empty( $tab['hided'] ) )
|
||||
$css_classes .= ' hide';
|
||||
|
||||
if ( ( isset( $tab['disabled'] ) ) && ( $tab['disabled'] ) )
|
||||
$css_classes .= ' wpdevelop-tab-disabled';
|
||||
|
||||
$tab['css_classes'] = $css_classes;
|
||||
|
||||
$tab['link'] = ( ! empty($tab['link']) ? $tab['link'] : $this->get_tab_url( $menu_in_page_tag, $tab_tag ) );
|
||||
|
||||
if ( // Recheck active status of default TAB
|
||||
( isset( $_REQUEST[ $this->tags['tab'] ] ) ) // Some Tab selected
|
||||
&& ( $_REQUEST[ $this->tags['tab'] ] !== $tab_tag ) // This tag not in URL
|
||||
&& ( isset($tab['default']) && ( $tab['default'] ) ) // This tab default, need to set it as not defaultm for not showing it selected
|
||||
)
|
||||
$tab['default'] = false;
|
||||
|
||||
opsd_bs_display_tab( $tab );
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/** Show Sub Menu Lines at the Settings page for Active Tab
|
||||
*
|
||||
* @param array $bottom_tabs
|
||||
* @param string $menu_in_page_tag - Menu Tag, the same as $this->in_page();
|
||||
*/
|
||||
public function show_subtabs_line( $bottom_tabs, $menu_in_page_tag ) {
|
||||
|
||||
if ( ! empty( $bottom_tabs ) )
|
||||
foreach ( $bottom_tabs as $tab_tag => $tab ) {
|
||||
|
||||
switch ( $tab['type'] ) {
|
||||
case 'separator': // Separator
|
||||
?><span class="wpdevelop-submenu-tab-separator-vertical"></span><?php
|
||||
break;
|
||||
|
||||
case 'button': // Button
|
||||
?><div class="clear-for-mobile"></div><input
|
||||
type="button"
|
||||
class="button button-primary opsd_submit_button"
|
||||
value="<?php echo $tab['title']; ?>"
|
||||
onclick="if (typeof document.forms['<?php echo $tab['form']; ?>'] !== 'undefined'){ document.forms['<?php echo $tab['form']; ?>'].submit(); } else { opsd_admin_show_message( '<?php echo ' <strong>', __('Error', 'secure-downloads') ,'!</strong> ', __('Form', 'secure-downloads') , ' <strong>' , $tab['form'] , '</strong> ', __('does not exist', 'secure-downloads'); ?>.', 'error', 10000 ); }"
|
||||
/><?php
|
||||
break;
|
||||
|
||||
case 'html': // HTML
|
||||
echo $tab['html'];
|
||||
break;
|
||||
|
||||
case 'goto-link':
|
||||
?><a class="nav-tab wpdevelop-submenu-tab go-to-link"
|
||||
original-title="<?php echo (empty($tab['hint'])?'':$tab['hint']); ?>"
|
||||
onclick="javascript:opsd_scroll_to('#<?php echo esc_js( $tab['show_section'] ); ?>' );"
|
||||
href="javascript:void(0);"><span><?php echo $tab['title']; ?></span></a><?php
|
||||
break;
|
||||
|
||||
default: // Link
|
||||
|
||||
$css_classes = ( ( isset($tab['css_classes']) ) ? $tab['css_classes'] : '' );
|
||||
if ( ! empty($tab['position'] ) )
|
||||
$css_classes .= ' nav-tab-position-'.$tab['position'];
|
||||
if ( $tab_tag == $this->current_page_params['subtab']['tag'] )
|
||||
$css_classes .= ' wpdevelop-submenu-tab-selected';
|
||||
if ( $tab['disabled'] )
|
||||
$css_classes .= ' wpdevelop-submenu-tab-disabled';
|
||||
|
||||
$tab['css_classes'] = $css_classes;
|
||||
|
||||
$tab['link'] = ( ! empty($tab['link']) ? $tab['link'] : $this->get_tab_url( $menu_in_page_tag, $this->current_page_params['tab']['tag'], $tab_tag ) );
|
||||
|
||||
$tab['top'] = false;
|
||||
opsd_bs_display_tab( $tab );
|
||||
|
||||
break;
|
||||
|
||||
} // End Switch
|
||||
} // End Bottom Tabs Loop
|
||||
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// Support
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/** Get URL of settings page, based on Page Slug and Tab Slug
|
||||
*
|
||||
* @param string $page_tag
|
||||
* @param string $tab_name
|
||||
* @param string $subtab_name ( Optional )
|
||||
* @return string - Escaped URL to plugin page.
|
||||
*/
|
||||
private function get_tab_url( $page_tag, $tab_name, $subtab_name = false ){
|
||||
if ( $subtab_name === false )
|
||||
return esc_url( admin_url( add_query_arg( array( 'page' => $page_tag, $this->tags['tab'] => $tab_name ), 'admin.php' ) ) );
|
||||
else
|
||||
return esc_url( admin_url( add_query_arg( array( 'page' => $page_tag, $this->tags['tab'] => $tab_name, $this->tags['subtab'] => $subtab_name ), 'admin.php' ) ) );
|
||||
}
|
||||
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
157
wp-content/plugins/secure-downloads/core/any/class-css-js.php
Normal file
157
wp-content/plugins/secure-downloads/core/any/class-css-js.php
Normal file
@@ -0,0 +1,157 @@
|
||||
<?php /**
|
||||
* @version 1.1
|
||||
* @package Any
|
||||
* @category Load JS and CSS files
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-10-28
|
||||
*/
|
||||
|
||||
abstract class OPSD_JS_CSS {
|
||||
|
||||
public $objects = array();
|
||||
public $type; // css || js
|
||||
|
||||
function __construct() {
|
||||
$this->define();
|
||||
add_action( 'admin_enqueue_scripts', array( $this, 'registerScripts' ) );
|
||||
add_action( 'wp_enqueue_scripts', array( $this, 'registerScripts' ) );
|
||||
|
||||
add_action( 'opsd_load_js_on_admin_page', array( $this, 'load_js_on_admin_page' ) ); // Load JS. Hook fire only in admin pages of plugin. CLASS: OPSD_Admin_Menus (..\any\class\class-admin-menu.php)
|
||||
add_action( 'opsd_load_css_on_admin_page', array( $this, 'load_css_on_admin_page' ) ); // Load CSS. Hook fire only in admin pages of plugin. CLASS: OPSD_Admin_Menus (..\any\class\class-admin-menu.php)
|
||||
}
|
||||
|
||||
public function load_css_on_admin_page() {
|
||||
|
||||
if ( $this->getType() == 'css' )
|
||||
$this->load();
|
||||
}
|
||||
|
||||
public function load_js_on_admin_page() {
|
||||
|
||||
if ( $this->getType() == 'js' )
|
||||
$this->load();
|
||||
}
|
||||
|
||||
/** Define all Scripts or Styles here */
|
||||
abstract public function define();
|
||||
|
||||
/** Enqueue Scripts or Styles.
|
||||
*
|
||||
* @param type $where_to_load - can be "admin" or "client"
|
||||
*/
|
||||
abstract public function enqueue( $where_to_load );
|
||||
|
||||
|
||||
/** Deregister some Conflict scripts from other plugins.
|
||||
*
|
||||
* @param type $where_to_load - can be "admin" or "client"
|
||||
*/
|
||||
abstract public function remove_conflicts( $where_to_load );
|
||||
|
||||
|
||||
// Define CSS or JavaScript
|
||||
public function setType($param) {
|
||||
$this->type = $param;
|
||||
}
|
||||
|
||||
// Get type of this script
|
||||
public function getType() {
|
||||
return $this->type;
|
||||
}
|
||||
|
||||
// Add new Style or Script
|
||||
public function add($param) {
|
||||
$this->objects[] = $param;
|
||||
}
|
||||
|
||||
|
||||
private function isLoad( $whereToLoadArray ) {
|
||||
$is_load = false;
|
||||
|
||||
if ( ( is_admin() ) && ( in_array('admin', $whereToLoadArray ) ) )
|
||||
$is_load = true;
|
||||
|
||||
if ( ( ! is_admin() ) && ( in_array('client', $whereToLoadArray ) ) )
|
||||
$is_load = true;
|
||||
|
||||
return $is_load;
|
||||
}
|
||||
|
||||
|
||||
// Register
|
||||
public function registerScripts() {
|
||||
|
||||
//if ( function_exists( 'wp_dequeue_script' ) )
|
||||
$this->remove_conflicts( ( is_admin() ? 'admin': 'client' ) );
|
||||
|
||||
foreach( $this->objects as $script ) {
|
||||
|
||||
if ( $this->isLoad( $script['where_to_load'] ) ) {
|
||||
|
||||
if ( $this->getType() == 'css' )
|
||||
wp_register_style( $script['handle'], $script['src'], $script['deps'], $script['version'] );
|
||||
else
|
||||
wp_register_script( $script['handle'], $script['src'], $script['deps'], $script['version'] );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Load scripts or styles here
|
||||
public function load(){
|
||||
|
||||
$is_load_scripts = true;
|
||||
|
||||
$is_load_scripts = apply_filters( 'opsd_is_load_script_on_this_page', $is_load_scripts );
|
||||
|
||||
if ( ! $is_load_scripts ) return; // Exist, if on some page we do not need to load scripts
|
||||
|
||||
|
||||
foreach( $this->objects as $num => $script ) {
|
||||
|
||||
if ( $this->isLoad( $script['where_to_load'] ) ) {
|
||||
|
||||
if ( $this->getType() == 'css' ) {
|
||||
|
||||
if ( $script['condition'] === false )
|
||||
|
||||
wp_enqueue_style( $script['handle'] );
|
||||
|
||||
else {
|
||||
|
||||
if (! function_exists('wp_style_add_data') ) { // This function is available only since WordPress 3.6.0 Update
|
||||
wp_enqueue_style( $script['handle'] );
|
||||
wp_style_add_data( $script['handle'], 'conditional', $script['condition'] );
|
||||
} else { // Add additional "dynamic CSS" if the WP version older than 3.6.0 (its function suport since WP 3.3)
|
||||
if ( ($num-1) > -1 ) { // Its because "wp_add_inline_style" add the CSS to the already added style. So its require that some other simple style was added before
|
||||
wp_enqueue_style( $this->objects[($num-1)]['handle'] );
|
||||
wp_add_inline_style( $this->objects[($num-1)]['handle'],
|
||||
sprintf("<!--[if ".$script['condition']."]>\n" .
|
||||
"<link rel='stylesheet' id='".$script['handle']."-css' href='". $script['src'] ."?ver=" . $script['version'] . "' type='text/css' media='all' />\n" .
|
||||
"<![endif]-->\n")
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
} else {
|
||||
wp_enqueue_script( $script['handle'] );
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
$this->enqueue( ( is_admin() ? 'admin': 'client' ) );
|
||||
|
||||
if ( $this->getType() == 'css' )
|
||||
do_action( 'opsd_enqueue_style', ( is_admin() ? 'admin': 'client' ) );
|
||||
|
||||
if ( $this->getType() == 'js' )
|
||||
do_action( 'opsd_enqueue_script', ( is_admin() ? 'admin': 'client' ) );
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,146 @@
|
||||
/*
|
||||
Document : admin resources-table
|
||||
Created on : 2016-08-09, 11:38:06
|
||||
Author : wpdevelop
|
||||
Description: Resource Table CSS
|
||||
*/
|
||||
|
||||
/* General Class */
|
||||
.opsd_resources_table {
|
||||
|
||||
}
|
||||
|
||||
/* Resources Table */
|
||||
.opsd_resources_table .table,
|
||||
.opsd_resources_table .table.widefat {
|
||||
border: 0px solid #bbb;
|
||||
box-shadow: 0 0 2px #aaa;
|
||||
}
|
||||
.opsd_resources_table table > thead > tr > th {
|
||||
background-color: #ffffff;
|
||||
border-bottom: 2px solid #e5e5e5;
|
||||
}
|
||||
.wpdevelop.opsd_resources_table table > tfoot > tr > th {
|
||||
background-color: #ffffff;
|
||||
border-top: 2px solid #e5e5e5;
|
||||
}
|
||||
.opsd_resources_table thead th,
|
||||
.opsd_resources_table tfoot th {
|
||||
font-weight:600;
|
||||
text-align: left;
|
||||
}
|
||||
.opsd_resources_table th a,
|
||||
.opsd_resources_table th a:hover,
|
||||
.opsd_resources_table th a:focus {
|
||||
text-decoration: none;
|
||||
}
|
||||
.wpdevelop.opsd_resources_table table > tbody > tr.row_selected_color > th,
|
||||
.wpdevelop.opsd_resources_table table > tbody > tr.row_selected_color > td {
|
||||
background: #b5d4ef;
|
||||
border-color: #ccc !important;
|
||||
}
|
||||
.opsd_resources_table th a span.glyphicon {
|
||||
font-size: 0.8em;
|
||||
font-weight: 400;
|
||||
padding-left: 2px;
|
||||
}
|
||||
|
||||
.wpdevelop.opsd_resources_table .table > thead > tr > th,
|
||||
.wpdevelop.opsd_resources_table .table > tbody > tr > th,
|
||||
.wpdevelop.opsd_resources_table .table > tfoot > tr > th,
|
||||
.wpdevelop.opsd_resources_table .table > thead > tr > td,
|
||||
.wpdevelop.opsd_resources_table .table > tbody > tr > td,
|
||||
.wpdevelop.opsd_resources_table .table > tfoot > tr > td {
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
/* Labels Colors */
|
||||
.opsd_resources_table .label {
|
||||
border: 1px solid #EEEEEE;
|
||||
box-shadow: 0 0 1px #ddd;
|
||||
padding: 2px 5px;
|
||||
white-space: nowrap;
|
||||
line-height: 2.4em;
|
||||
}
|
||||
.opsd_resources_table .label span,
|
||||
.opsd_resources_table .label a,
|
||||
.opsd_resources_table .label a:hover{
|
||||
color:#fff;
|
||||
text-decoration: none;
|
||||
}
|
||||
.opsd_resources_table .label-pending {
|
||||
background: #FFBB45;
|
||||
}
|
||||
.opsd_resources_table .label-approved {
|
||||
background: #9BE;
|
||||
}
|
||||
.opsd_resources_table .label-trash {
|
||||
background: #D94A48;
|
||||
color: #fff;
|
||||
text-shadow: 0 0 1px #E00;
|
||||
}
|
||||
.opsd_resources_table .label-success {
|
||||
|
||||
}
|
||||
.opsd_resources_table .label-unknown {
|
||||
background-color: #999 !important;
|
||||
}
|
||||
.opsd_resources_table .label-error {
|
||||
background-color: #FA773D !important;
|
||||
}
|
||||
.opsd_resources_table .payment-label-success {
|
||||
background-color: #468847 !important;
|
||||
}
|
||||
.opsd_resources_table .payment-label-pending {
|
||||
background-color: #992 !important;
|
||||
}
|
||||
.opsd_resources_table .payment-label-unknown {
|
||||
background-color: #999 !important;
|
||||
}
|
||||
.opsd_resources_table .payment-label-error {
|
||||
background-color: #FA773D !important;
|
||||
}
|
||||
|
||||
.opsd_resources_table .field-currency {
|
||||
color: #444;
|
||||
display: inline;
|
||||
font-size: 15px;
|
||||
font-weight: 600;
|
||||
line-height: 1.7em;
|
||||
height: 26px;
|
||||
padding:0;
|
||||
vertical-align: top;
|
||||
}
|
||||
.wpdevelop.opsd_resources_table .table > tbody > tr > td select.form-control,
|
||||
.opsd_resources_table select {
|
||||
width:auto;
|
||||
height:2em;
|
||||
padding: 2px;
|
||||
border-radius: 0;
|
||||
}
|
||||
@media (max-width: 782px) {
|
||||
.opsd_resources_table th.opsd_hide_mobile,
|
||||
.opsd_resources_table td.opsd_hide_mobile {
|
||||
display: none;
|
||||
}
|
||||
.opsd_resources_table th.opsd_col_id,
|
||||
.opsd_resources_table td.opsd_col_id {
|
||||
width: 4em;
|
||||
}
|
||||
.opsd_resources_table th.opsd_col_title,
|
||||
.opsd_resources_table td.opsd_col_title {
|
||||
width: 9em;
|
||||
}
|
||||
.opsd_resources_table .field-currency {
|
||||
line-height: 2.1em;
|
||||
}
|
||||
#wpbody .opsd_resources_table select {
|
||||
height:32px;
|
||||
}
|
||||
}
|
||||
@media (max-width: 600px) {
|
||||
.opsd_resources_table th.opsd_hide_mobile_xs,
|
||||
.opsd_resources_table td.opsd_hide_mobile_xs {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,358 @@
|
||||
/*
|
||||
Document : admin-opsd-listing
|
||||
Created on : 09.02.2014, 11:38:06
|
||||
Author : wpdevelop
|
||||
Description: Listing Table CSS
|
||||
*/
|
||||
|
||||
/* Header */
|
||||
.opsd-listing-header {
|
||||
background: #e4e4e4; /* for non-css3 browsers */
|
||||
border: 1px solid #C6C6C6;
|
||||
border-bottom-color: #CCC;
|
||||
border-radius: 4px 4px 0 0;
|
||||
-moz-border-radius: 4px 4px 0 0;
|
||||
-webkit-border-radius: 4px 4px 0 0;
|
||||
-ms-border-radius: 4px 4px 0 0;
|
||||
color: #333;
|
||||
font-size: 12px;
|
||||
font-weight: 600;
|
||||
margin: 0;
|
||||
padding: 2px 0px;
|
||||
text-shadow: 0 1px 1px #F5F5F5;
|
||||
}
|
||||
|
||||
/* Row */
|
||||
.opsd-listing-row {
|
||||
border: 1px solid #C6C6C6;
|
||||
border-top: none;
|
||||
margin: 0px;
|
||||
padding: 0px;
|
||||
}
|
||||
.opsd-listing-row.row_alternative_color.row,
|
||||
.opsd-listing-row.row_alternative_color {
|
||||
background: #F7F7F7;
|
||||
}
|
||||
.opsd-listing-row.row.row_selected_color {
|
||||
background: #9cf;
|
||||
border-color: #aaa !important;
|
||||
}
|
||||
.opsd-listing-row.opsd-listing-last_row {
|
||||
border-radius: 0 0 4px 4px;
|
||||
-moz-border-radius: 0 0 4px 4px;
|
||||
-webkit-border-radius: 0 0 4px 4px;
|
||||
-ms-border-radius: 0 0 4px 4px;
|
||||
}
|
||||
|
||||
/* Columns */
|
||||
.opsd-listing-collumn {
|
||||
margin: 5px 0px 2px;
|
||||
}
|
||||
.opsd-listing-collumn .field-id {
|
||||
|
||||
color: #999;
|
||||
font-size: 10px;
|
||||
font-weight: 600;
|
||||
text-align: right;
|
||||
|
||||
/* background-color: #777;
|
||||
border: 1px solid #FFF;
|
||||
border-radius: 10px 10px 10px 10px;
|
||||
box-shadow: 0 0 2px #888;
|
||||
color: #EEE;
|
||||
font-size: 9px;
|
||||
font-weight: 600;
|
||||
padding: 2px 4px;
|
||||
text-shadow: 0 0 3px #333;*/
|
||||
}
|
||||
.opsd-listing-collumn .field-id span.label {
|
||||
border-radius: 10px;
|
||||
-moz-border-radius: 10px;
|
||||
-webkit-border-radius: 10px;
|
||||
background: #bbb;
|
||||
color: #fff;
|
||||
margin: 0;
|
||||
padding: 2px 5px;
|
||||
background: #888;
|
||||
border:none;
|
||||
line-height:2.8em;
|
||||
}
|
||||
.opsd-listing-collumn.field-system-info {
|
||||
font-size: 9px;
|
||||
font-style: italic;
|
||||
line-height: 1.2em;
|
||||
text-align: left;
|
||||
text-shadow: 0 -1px 0 #eee;
|
||||
white-space: nowrap;
|
||||
padding: 2em 5px 0;
|
||||
text-align: right;
|
||||
color: #777;
|
||||
}
|
||||
.opsd-listing-collumn.field-system-info .field-creation-date {
|
||||
font-weight: 600;
|
||||
}
|
||||
/* Checkbox */
|
||||
.opsd-listing-collumn .field-checkbox {
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
/* Main Content */
|
||||
.opsd-listing-collumn.field-content,
|
||||
.opsd-listing-collumn .standard-content-form {
|
||||
text-align: left;
|
||||
word-wrap: break-word;
|
||||
line-height: 1.7em;
|
||||
}
|
||||
/* Data Titles style - Yellow Values*/
|
||||
.opsd-listing-collumn .fieldvalue {
|
||||
background: #FE9;
|
||||
color: #333;
|
||||
font-size: 0.9em;
|
||||
font-weight: 400;
|
||||
margin: 0 3px 0 0;
|
||||
padding: 2px 3px;
|
||||
border-radius: 3px;
|
||||
-moz-border-radius: 3px;
|
||||
-webkit-border-radius: 3px;
|
||||
/* text-shadow: 0 1px 1px #EEE;*/
|
||||
}
|
||||
|
||||
/* Labels Colors */
|
||||
.opsd-listing-collumn .label {
|
||||
border: 1px solid #EEEEEE;
|
||||
box-shadow: 0 0 1px #ddd;
|
||||
padding: 2px 5px;
|
||||
white-space: nowrap;
|
||||
line-height: 2.4em;
|
||||
}
|
||||
.opsd-listing-collumn .label span,
|
||||
.opsd-listing-collumn .label a,
|
||||
.opsd-listing-collumn .label a:hover{
|
||||
color:#fff;
|
||||
text-decoration: none;
|
||||
}
|
||||
.opsd-listing-collumn .label-pending {
|
||||
background: #FFBB45;
|
||||
}
|
||||
.opsd-listing-collumn .label-approved {
|
||||
background: #9BE;
|
||||
}
|
||||
.opsd-listing-collumn .label-trash {
|
||||
background: #D94A48;
|
||||
color: #fff;
|
||||
text-shadow: 0 0 1px #E00;
|
||||
}
|
||||
.opsd-listing-collumn .label-success {
|
||||
|
||||
}
|
||||
.opsd-listing-collumn .label-unknown {
|
||||
background-color: #999 !important;
|
||||
}
|
||||
.opsd-listing-collumn .label-error {
|
||||
background-color: #FA773D !important;
|
||||
}
|
||||
.opsd-listing-collumn .payment-label-success {
|
||||
background-color: #468847 !important;
|
||||
}
|
||||
.opsd-listing-collumn .payment-label-pending {
|
||||
background-color: #992 !important;
|
||||
}
|
||||
.opsd-listing-collumn .payment-label-unknown {
|
||||
background-color: #999 !important;
|
||||
}
|
||||
.opsd-listing-collumn .payment-label-error {
|
||||
background-color: #FA773D !important;
|
||||
}
|
||||
|
||||
/* Pagination */
|
||||
.opsd-pagination .button{
|
||||
box-shadow: none;
|
||||
height: 32px;
|
||||
line-height: 30px;
|
||||
margin: 0 0 5px;
|
||||
padding: 0 15px;
|
||||
}
|
||||
.wpdevelop.opsd-pagination .container-fluid .row .btn-toolbar .btn-group > .button.disabled {
|
||||
box-shadow: none !important;
|
||||
}
|
||||
.wpdevelop.opsd-pagination .btn-toolbar .btn-group > .button.active {
|
||||
box-shadow: 0 1px 5px -4px rgba(0, 0, 0, 0.5) inset;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
@media (max-width: 782px) {
|
||||
.opsd-listing-header .opsd-listing-collumn {
|
||||
font-size: 1.2em;
|
||||
line-height: 2.2em;
|
||||
margin:0;
|
||||
}
|
||||
.opsd-listing-header .opsd-listing-collumn input[type=checkbox] {
|
||||
margin:-4px 0 0;
|
||||
}
|
||||
.opsd-listing-collumn.field-system-info {
|
||||
padding:0 5px;
|
||||
}
|
||||
/* Pagination */
|
||||
.opsd-pagination .button {
|
||||
font-size: 14px;
|
||||
height: 36px;
|
||||
line-height: 34px;
|
||||
margin: 0 0 5px;
|
||||
padding: 0 16px;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* C U S T O M ****************************************************************/
|
||||
|
||||
/* New Label */
|
||||
.opsd-listing-collumn.new-label {
|
||||
margin: 5px 0 0 -32px;
|
||||
position: absolute !important;
|
||||
}
|
||||
.opsd-listing-collumn.new-label a{
|
||||
font-size:13px;
|
||||
}
|
||||
.opsd-listing-collumn.new-label a i.glyphicon{
|
||||
color:#8ac;
|
||||
}
|
||||
/* Dates */
|
||||
.opsd-listing-collumn.field-dates .field-securedownloads-date,
|
||||
.opsd-listing-collumn.field-dates .field-securedownloads-date:hover {
|
||||
background: none repeat scroll 0 0 #FFBB45;
|
||||
border: 1px solid #EEE;
|
||||
border-radius: 5px 5px 5px 5px;
|
||||
box-shadow: 0 0 1px #CCC;
|
||||
color: #FFF;
|
||||
font-weight: 600;
|
||||
padding: 4px 10px 4px;
|
||||
text-decoration: none;
|
||||
text-shadow: 0 0px 0 #CCC;
|
||||
white-space: nowrap;
|
||||
font-size: 0.85em;
|
||||
line-height: 2.5em;
|
||||
}
|
||||
.opsd-listing-collumn.field-dates .field-securedownloads-date.approved,
|
||||
.opsd-listing-collumn.field-dates .field-securedownloads-date.approved:hover {
|
||||
background: none repeat scroll 0 0 #9BE;
|
||||
}
|
||||
.opsd-listing-collumn.field-dates .field-securedownloads-time {
|
||||
color: #555;
|
||||
text-decoration: none;
|
||||
text-shadow: 0 0 1px #AAA;
|
||||
}
|
||||
.opsd-listing-collumn.field-dates .date_tire {
|
||||
font-size: 17px;
|
||||
font-weight: 600;
|
||||
}
|
||||
.opsd-listing-collumn.field-dates .securedownloads_dates_small,
|
||||
.opsd-listing-collumn.field-dates .securedownloads_dates_full {
|
||||
line-height: 24px;
|
||||
}
|
||||
.opsd-listing-collumn.field-dates .date_from_dif_type {
|
||||
color: #FFF;
|
||||
text-shadow: 0 -1px 0 #BBB;
|
||||
}
|
||||
/* Actions buttons */
|
||||
.opsd-listing-collumn.field-action-buttons {
|
||||
padding-right: 2px;
|
||||
}
|
||||
.opsd-listing-collumn.field-action-buttons a.button {
|
||||
margin:0 5px 5px 0;
|
||||
}
|
||||
.opsd-listing-collumn .glyphicon.red_icon_color {
|
||||
color:#d54e21;
|
||||
}
|
||||
.opsd-listing-collumn .opsd-buttons-separator {
|
||||
margin-right: 15px;
|
||||
}
|
||||
.opsd_free .opsd-listing-collumn .opsd-buttons-separator {
|
||||
margin-right: 0px;
|
||||
}
|
||||
/* Cost Group */
|
||||
.opsd-listing-collumn.field-action-buttons .cost-fields-group {
|
||||
float:left;
|
||||
}
|
||||
.opsd-listing-collumn.field-action-buttons .cost-fields-group .field-currency {
|
||||
color: #444;
|
||||
display: inline;
|
||||
font-size: 15px;
|
||||
font-weight: 600;
|
||||
line-height: 26px;
|
||||
height: 26px;
|
||||
padding:0;
|
||||
vertical-align: top;
|
||||
}
|
||||
.opsd-listing-collumn.field-action-buttons .cost-fields-group.control-group .btn-toolbar .input-group > input[type="text"].field-securedownloads-cost {
|
||||
display: inline-block;
|
||||
margin: 0 5px 5px 0;
|
||||
width: 75px;
|
||||
font-weight: 600;
|
||||
border-radius: 2px;
|
||||
-moz-border-radius: 2px;
|
||||
-webkit-border-radius: 2px;
|
||||
}
|
||||
.opsd-listing-collumn.field-action-buttons select.opsd-select-locale {
|
||||
display: none;
|
||||
margin: 0 5px 5px 0;
|
||||
}
|
||||
.opsd_free .opsd-listing-collumn.field-system-info {
|
||||
padding:0 5px;
|
||||
margin-top:-0.5em;
|
||||
}
|
||||
/* Columns customizations - labels header */
|
||||
#listing_visible_opsd .opsd-listing-header .opsd_column_3 {
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.label_resource_not_exist {
|
||||
color: #000;
|
||||
font-weight: 600;
|
||||
text-shadow: 0 1px 0 #59D;
|
||||
text-transform: none;
|
||||
}
|
||||
.opsd-listing-row .securedownloads_row_modification_element {
|
||||
display: none;
|
||||
clear: both;
|
||||
width: 100%;
|
||||
}
|
||||
.opsd-listing-row .securedownloads_row_modification_element_changing_resource {
|
||||
height: auto;
|
||||
}
|
||||
.opsd-listing-row .securedownloads_row_modification_element .btn-save-cost,
|
||||
.opsd-listing-row .securedownloads_row_modification_element.securedownloads_edit_note a,
|
||||
.opsd-listing-row .securedownloads_row_modification_element select{
|
||||
float: left;
|
||||
margin: 0 0 5px 5px;
|
||||
}
|
||||
#hided_boking_modifications_elements,
|
||||
.hided_boking_modifications_elements { /* FixIn:5.4.5.1 */
|
||||
display: none;
|
||||
}
|
||||
|
||||
@media (max-width: 782px) {
|
||||
/* New Label */
|
||||
.opsd-listing-collumn.new-label {
|
||||
margin: 7px 0 0 -26px;
|
||||
position: absolute !important;
|
||||
}
|
||||
/* Dates */
|
||||
.opsd-listing-collumn .field-id.text-center,
|
||||
.opsd-listing-collumn .securedownloads-labels.text-center,
|
||||
.opsd-listing-collumn.securedownloads-dates.text-center{
|
||||
text-align: left;
|
||||
}
|
||||
.opsd-listing-collumn.field-action-buttons .control-group a.button {
|
||||
height: 34px;
|
||||
}
|
||||
/* Cost Group */
|
||||
.opsd-listing-collumn.field-action-buttons .cost-fields-group .field-currency {
|
||||
line-height: 34px;
|
||||
height: 34px;
|
||||
font-size: 18px;
|
||||
}
|
||||
.opsd-listing-collumn.field-action-buttons .cost-fields-group.control-group .btn-toolbar .input-group > input[type="text"].field-securedownloads-cost {
|
||||
padding: 2px 5px;
|
||||
}
|
||||
}
|
||||
242
wp-content/plugins/secure-downloads/core/any/css/admin-menu.css
Normal file
242
wp-content/plugins/secure-downloads/core/any/css/admin-menu.css
Normal file
@@ -0,0 +1,242 @@
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package: Tabs
|
||||
* @category: Admin UI
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015.04.10
|
||||
*/
|
||||
|
||||
|
||||
/* Top Tab Menu ***************************************************************/
|
||||
.wpdvlp-top-tabs {
|
||||
margin:0;
|
||||
position: relative;
|
||||
width: auto;
|
||||
}
|
||||
.wpdvlp-top-tabs .wpdvlp-tabs-wrapper {
|
||||
height: 28px;
|
||||
margin-bottom: -1px;
|
||||
width: 100%;
|
||||
}
|
||||
.wpdvlp-top-tabs .nav-tabs {
|
||||
float: left;
|
||||
margin-left: 0;
|
||||
padding-left: 0px;
|
||||
/* border-bottom: none !important;*/
|
||||
border-bottom: 1px solid #CCC;
|
||||
width: 100%;
|
||||
}
|
||||
.wpdvlp-top-tabs .nav-tab {
|
||||
border-radius: 3px 3px 0 0;
|
||||
-moz-border-radius: 3px 3px 0 0;
|
||||
-webkit-border-top-left-radius: 3px;
|
||||
-webkit-border-top-right-radius: 3px;
|
||||
border-color: #D5D5D5 #D5D5D5 #BBC #D5D5D5;
|
||||
border-style: solid;
|
||||
border-width: 1px 1px 0;
|
||||
border-bottom: none;
|
||||
display: inline-block;
|
||||
background: none repeat scroll 0 0 #F4F4F4;
|
||||
background: #DFDFDF;
|
||||
color: #464646;
|
||||
font-weight: 600;
|
||||
font-size: 13px;
|
||||
text-decoration: none;
|
||||
text-shadow: 0 1px 0 #F1F1F1;
|
||||
line-height: 18px;
|
||||
padding: 4px 14px 6px;
|
||||
padding: 5px 15px 5px;
|
||||
margin: 0 5px 0 0;
|
||||
}
|
||||
.wpdvlp-top-tabs .pull-right .nav-tab {
|
||||
margin: 0 0 0 5px;
|
||||
}
|
||||
.wpdvlp-top-tabs a.nav-tab:hover,
|
||||
.wpdvlp-top-tabs a.nav-tab:visited,
|
||||
.wpdvlp-top-tabs a.nav-tab:link ,
|
||||
.wpdvlp-sub-tabs a.nav-tab:hover,
|
||||
.wpdvlp-sub-tabs a.nav-tab:visited,
|
||||
.wpdvlp-sub-tabs a.nav-tab:link {
|
||||
text-decoration: none;
|
||||
outline: none;
|
||||
}
|
||||
/* IE6 */
|
||||
* html .wpdvlp-top-tabs .nav-tab {
|
||||
padding: 4px 14px 5px 32px;
|
||||
}
|
||||
.wpdvlp-top-tabs a.nav-tab:hover {
|
||||
color: #D54E21 !important;
|
||||
background-color: #E7E7E7 !important;
|
||||
}
|
||||
.wpdvlp-top-tabs .nav-tab-active,
|
||||
.wpdvlp-top-tabs a.nav-tab-active:hover,
|
||||
.wpdvlp-top-tabs a.nav-tab-active:focus {
|
||||
border-color: #777;
|
||||
border-bottom-color: #AAB;
|
||||
background: none repeat scroll 0 0 #7A7A88;
|
||||
text-shadow: 0 0px 0 #111;
|
||||
border-width: 1px;
|
||||
color: #FFF;
|
||||
}
|
||||
.wpdvlp-top-tabs a.nav-tab-active:hover,
|
||||
.wpdvlp-top-tabs a.nav-tab-active:focus {
|
||||
color: #FFF !important;
|
||||
background: none repeat scroll 0 0 #7A7A88 !important;
|
||||
}
|
||||
.wpdvlp-top-tabs .nav-tab-position-right {
|
||||
float:right;
|
||||
margin: 0 0 0 5px;
|
||||
}
|
||||
|
||||
/* Sub Menu *******************************************************************/
|
||||
.wpdvlp-sub-tabs {
|
||||
height: auto;
|
||||
clear: both;
|
||||
border: 1px solid #BBC;
|
||||
border-top: none;
|
||||
-moz-border-radius: 0px 0px 3px 3px;
|
||||
-moz-box-shadow: 0 1px 1px #DDD;
|
||||
-webkit-border-radius: 0px 0px 3px 3px;
|
||||
-webkit-box-shadow: 0 1px 1px #DDD;
|
||||
border-radius: 0px 0px 3px 3px;
|
||||
box-shadow: 0 1px 1px #DDD;
|
||||
background: #EEE;
|
||||
margin: 0;
|
||||
padding: 5px;
|
||||
}
|
||||
.wpdvlp-sub-tabs .wpdvlp-tabs-wrapper {
|
||||
height: auto;
|
||||
margin-bottom: -1px;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.wpdvlp-sub-tabs .nav-tabs {
|
||||
border: none;
|
||||
width: auto;
|
||||
height: auto;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
.wpdvlp-sub-tabs .nav-tabs .nav-tab {
|
||||
border: 1px solid #bbb;
|
||||
|
||||
background: #F5F5F5;
|
||||
color: #777;
|
||||
font-weight: 600;
|
||||
font-size:13px;
|
||||
height: 18px;
|
||||
line-height: 16px;
|
||||
|
||||
padding: 6px 10px 4px;
|
||||
margin: 5px 2px -4px;
|
||||
border-bottom: none;
|
||||
|
||||
border-top-left-radius: 3px;
|
||||
border-top-right-radius: 3px;
|
||||
box-sizing: content-box;
|
||||
}
|
||||
.wpdvlp-top-tabs .nav-tabs .nav-tab input[type="checkbox"],
|
||||
.wpdvlp-sub-tabs .nav-tabs .nav-tab input[type="checkbox"] {
|
||||
margin: 0 0 0 8px !important;
|
||||
vertical-align: middle;
|
||||
}
|
||||
.wpdvlp-sub-tabs .nav-tabs .nav-tab.wpdevelop-submenu-tab-selected,
|
||||
.wpdvlp-sub-tabs .nav-tabs .nav-tab.wpdevelop-submenu-tab-selected:hover {
|
||||
border-color: #777;
|
||||
border-bottom-color: #AAB;
|
||||
text-shadow: 0 0px 0 #111;
|
||||
border-width: 1px;
|
||||
color: #FFF !important;
|
||||
background: none repeat scroll 0 0 #7A7A88 !important;
|
||||
}
|
||||
.wpdvlp-top-tabs .nav-tabs .nav-tab.wpdevelop-tab-disabled,
|
||||
.wpdvlp-sub-tabs .nav-tabs .nav-tab.wpdevelop-submenu-tab-disabled {
|
||||
color: #bbb;
|
||||
text-shadow: 0 -1px 1px #fff;
|
||||
}
|
||||
.wpdvlp-top-tabs .nav-tabs .nav-tab.nav-tab-active.wpdevelop-tab-disabled,
|
||||
.wpdvlp-sub-tabs .nav-tabs .nav-tab.wpdevelop-submenu-tab-selected.wpdevelop-submenu-tab-disabled {
|
||||
color: #555 !important;
|
||||
text-shadow: 0 0 1px #aaa;
|
||||
}
|
||||
.wpdvlp-sub-tabs .nav-tabs .nav-tab.go-to-link,
|
||||
.wpdvlp-sub-tabs .nav-tabs .nav-tab.go-to-link:hover,
|
||||
.wpdvlp-sub-tabs .nav-tabs .nav-tab.go-to-link:active {
|
||||
box-shadow: 0 0 0;
|
||||
font-weight: 400;
|
||||
border:none;
|
||||
background: transparent !important;
|
||||
margin:0 0 -4px;
|
||||
box-shadow: none;
|
||||
}
|
||||
.wpdvlp-sub-tabs .nav-tabs .nav-tab.go-to-link span {
|
||||
border-bottom: 1px dashed;
|
||||
padding:0 2px;
|
||||
}
|
||||
.wpdvlp-sub-tabs .opsd_submit_button {
|
||||
float:right;
|
||||
margin:0px 5px 0px 0px;
|
||||
}
|
||||
.wpdvlp-sub-tabs .wpdevelop-submenu-tab-separator-vertical {
|
||||
-moz-box-shadow: 1px 0px 0px #FEFEFE;
|
||||
-webkit-box-shadow: 1px 0px 0px #FEFEFE;
|
||||
box-shadow: 1px 0px 0px #FEFEFE;
|
||||
border-right: #BBB solid 1px;
|
||||
border-left: #CCC solid 1px;
|
||||
background: none;
|
||||
color: #777;
|
||||
padding: 5px 0px 5px;
|
||||
margin: 10px 15px 0px 10px;
|
||||
}
|
||||
.clear-for-mobile {
|
||||
display:none;
|
||||
}
|
||||
/* iPad mini and all iPhones and other Mobile Devices */
|
||||
@media (max-width: 782px) {
|
||||
/* Settings Top TABS */
|
||||
.wpdvlp-top-tabs .nav-tab {
|
||||
padding: 10px 15px 5px;
|
||||
padding: 8px 15px 8px;
|
||||
font-size: 1.2em;
|
||||
}
|
||||
.wpdvlp-top-tabs .nav-tab .nav-tab-text {
|
||||
display:none;
|
||||
}
|
||||
.wpdevelop-submenu-tab.nav-tab {
|
||||
border-radius: 0 !important;
|
||||
-moz-border-radius:0 !important;
|
||||
-webkit-border-radius:0 !important;
|
||||
display: block;
|
||||
float: none;
|
||||
width: auto;
|
||||
clear:both;
|
||||
vertical-align: middle !important;
|
||||
border-bottom: 1px solid #bbb !important;
|
||||
margin:-1px 0 0 !important;
|
||||
padding:0px 10px !important;
|
||||
height:3em !important;
|
||||
line-height:3em !important;
|
||||
}
|
||||
.wpdevelop-submenu-tab-separator-vertical {
|
||||
display:none;
|
||||
}
|
||||
.wpdevelop-submenu-tab.go-to-link {
|
||||
border-bottom: none !important;
|
||||
width:auto;
|
||||
}
|
||||
.clear-for-mobile {
|
||||
clear:both;
|
||||
width:100%;
|
||||
height:10px;
|
||||
display:block;
|
||||
}
|
||||
.wpdevelop-submenu-tab input[type="checkbox"] {
|
||||
margin: -4px 0 0 8px !important
|
||||
vertical-align: middle !important;
|
||||
padding:0px !important;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,589 @@
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package: Admin Panel
|
||||
* @category: Admin UI
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-04-11
|
||||
*/
|
||||
|
||||
/* Admin Content Pages */
|
||||
|
||||
/* Top Header at the page */
|
||||
.opsd_page h2.opsd_header {
|
||||
color: #595959;
|
||||
font-size: 2em;
|
||||
line-height: 2em;
|
||||
padding:0;
|
||||
text-shadow: 0 0 1px #aaaaaa;
|
||||
margin-bottom:10px;
|
||||
}
|
||||
|
||||
.opsd_page .wpdevelop label{
|
||||
font-weight: 400;
|
||||
}
|
||||
.opsd_page .wpdevelop label.opsd-required{
|
||||
font-weight: 600;
|
||||
}
|
||||
.opsd_page .wpdevelop optgroup {
|
||||
font-weight: 600;
|
||||
}
|
||||
.opsd_page .wpdevelop .visibility_container {
|
||||
display:none;
|
||||
}
|
||||
.opsd_page .wpdevelop .opsd-no-margin {
|
||||
margin:0;
|
||||
}
|
||||
.opsd_page .wpdevelop .opsd-no-padding {
|
||||
padding:0;
|
||||
}
|
||||
.wpdevelop a.button:focus,
|
||||
.wpdevelop a.button:hover {
|
||||
text-decoration: none;
|
||||
}
|
||||
/* Support CSS Classes **/
|
||||
.wpdevelop .visible_items,
|
||||
.visible_items {
|
||||
display: block;
|
||||
}
|
||||
.wpdevelop .hidden_items,
|
||||
.hidden_items {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* M E S S A G E S - Backward compatibility - For showing correctly messages in WP 4.0 */
|
||||
.opsd_page .notice {
|
||||
background: #fff;
|
||||
border-left: 4px solid #fff;
|
||||
-webkit-box-shadow: 0 1px 1px 0 rgba( 0, 0, 0, 0.1 );
|
||||
box-shadow: 0 1px 1px 0 rgba( 0, 0, 0, 0.1 );
|
||||
margin: 5px 15px 2px;
|
||||
padding: 1px 12px;
|
||||
}
|
||||
.opsd_page .notice-success,
|
||||
.opsd_page div.updated {
|
||||
border-left-color: #46b450;
|
||||
}
|
||||
.opsd_page div.notice-warning {
|
||||
border-left-color: #ffb900;
|
||||
}
|
||||
.opsd_page .notice-error,
|
||||
.opsd_page div.error {
|
||||
border-left-color: #dc3232;
|
||||
}
|
||||
.opsd_page .notice-info {
|
||||
border-left-color: #00a0d2;
|
||||
}
|
||||
/* Messages that show at top of admin panel pages */
|
||||
.opsd_page div.opsd_inner_message {
|
||||
padding:10px;
|
||||
/* Overide position and style of Updated Message. If in new WP updates this meesage showing incorrectly, remove this code */
|
||||
position: absolute;
|
||||
display: inline;
|
||||
z-index: 10000;
|
||||
width: 98%;
|
||||
margin: 3px 0 0;
|
||||
top: 5px;
|
||||
left: 0;
|
||||
padding: 12px;
|
||||
box-sizing: border-box;
|
||||
min-height:1em;
|
||||
height:auto;
|
||||
/* From WordPress 4.4.1 */
|
||||
/*
|
||||
border-left: 4px solid #fff;
|
||||
background: #fff none repeat scroll 0 0;
|
||||
box-shadow: 0 1px 1px 0 rgba(0, 0, 0, 0.1);
|
||||
*/
|
||||
}
|
||||
/* From WordPress 4.4.1 */
|
||||
.opsd_page div.opsd_inner_message a.close,
|
||||
.opsd_page div.opsd_inner_message a.close:hover,
|
||||
.opsd_page div.opsd_inner_message a.close:focus{
|
||||
font-size: 18px;
|
||||
float: right;
|
||||
text-decoration: none;
|
||||
}
|
||||
/* Form Messages */
|
||||
.wpdevelop .alert.opsd-near-field-message {
|
||||
height: auto;
|
||||
font-size: 0.9em;
|
||||
background-image: none;
|
||||
}
|
||||
/* Alerts & Help messages */
|
||||
.opsd-info-message,
|
||||
.opsd-error-message,
|
||||
.opsd-success-message,
|
||||
.opsd-help-message{
|
||||
display: block;
|
||||
margin: 10px 0;
|
||||
padding: 5px 10px;
|
||||
font-weight: 400;
|
||||
text-align: center;
|
||||
color:#777;
|
||||
background-color: #faf8f8;
|
||||
/* border: 1px solid #E6DB55;*/
|
||||
border: 2px dashed #bbb;
|
||||
border-radius: 3px;
|
||||
-moz-border-radius: 3px;
|
||||
-webkit-border-radius: 3px;
|
||||
line-height: 1.9em;
|
||||
font-size: 1em;
|
||||
padding: 5px 10px !important;
|
||||
width: auto !important;
|
||||
box-sizing: padding-box;
|
||||
-moz-box-sizing: padding-box;
|
||||
-webkit-box-sizing: padding-box;
|
||||
}
|
||||
.opsd-help-message {
|
||||
background-color: #FFFDFD;
|
||||
text-align: left;
|
||||
}
|
||||
.opsd-error-message {
|
||||
background-color: #FFEEEE;
|
||||
border-color: #FFBBBB;
|
||||
}
|
||||
.opsd-success-message {
|
||||
background-color: #F5FFF0;
|
||||
border-color: #AAEEAA;
|
||||
}
|
||||
.opsd-demo-alert-not-allow {
|
||||
color: #AA4400;
|
||||
font-size: 1.1em;
|
||||
font-weight: 400;
|
||||
text-shadow: 0 -1px 0 #FFEEEE;
|
||||
}
|
||||
|
||||
.opsd_inner_message {
|
||||
margin-bottom: 25px !important;
|
||||
}
|
||||
.opsd_inner_message .close{
|
||||
float: right;
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
.opsd_page div.opsd_outer_message {
|
||||
position: relative;
|
||||
display: block;
|
||||
margin: 5px 0 15px !important;
|
||||
}
|
||||
|
||||
.alert.alert-block {
|
||||
border:2px dashed;
|
||||
}
|
||||
.message {
|
||||
border-left-width: 3px solid #f90;
|
||||
clear: both;
|
||||
display: block;
|
||||
position: relative;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
/* Internal Settings Message */
|
||||
.opsd-settings-notice {
|
||||
background: #ffffff;
|
||||
border-left: 4px solid #fff;
|
||||
box-shadow: 0 1px 1px 0 rgba(0, 0, 0, 0.1);
|
||||
margin: 5px 0 2px 0;
|
||||
padding: 1px 12px;
|
||||
line-height: 2.5em;
|
||||
text-align:left;
|
||||
}
|
||||
.opsd-settings-notice.notice-success {
|
||||
border-left-color: #46b450;
|
||||
}
|
||||
.opsd-settings-notice.notice-success.notice-alt {
|
||||
background-color: #ecf7ed;
|
||||
}
|
||||
.opsd-settings-notice.notice-warning {
|
||||
border-left-color: #ffb900;
|
||||
}
|
||||
.opsd-settings-notice.notice-warning.notice-alt {
|
||||
background-color: #fff8e5;
|
||||
}
|
||||
.opsd-settings-notice.notice-error {
|
||||
border-left-color: #dc3232;
|
||||
}
|
||||
.opsd-settings-notice.notice-error.notice-alt {
|
||||
background-color: #fbeaea;
|
||||
}
|
||||
.opsd-settings-notice.notice-info {
|
||||
border-left-color: #00a0d2;
|
||||
}
|
||||
.opsd-settings-notice.notice-info.notice-alt {
|
||||
background-color: #e5f5fa;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* Modal Content for popup windows ********************************************/
|
||||
.opsd_popup_modal {
|
||||
display: none;
|
||||
}
|
||||
|
||||
|
||||
/* Sort Table */
|
||||
table.opsd_sort_table {
|
||||
border-radius: 5px;
|
||||
-moz-border-radius: 5px;
|
||||
-webkit-border-radius: 5px;
|
||||
}
|
||||
.opsd_sort_table thead th {
|
||||
padding:8px 0;
|
||||
text-align: center;
|
||||
font-weight: 600;
|
||||
font-size:1em;
|
||||
color:#555 !important;
|
||||
}
|
||||
.opsd_sort_table tfoot th {
|
||||
padding:10px;
|
||||
}
|
||||
.opsd_sort_table .widefat th.sort,
|
||||
.opsd_sort_table .widefat td.sort {
|
||||
width: 30px;
|
||||
padding-top:4px;
|
||||
padding-left:4px;
|
||||
}
|
||||
.opsd_sort_table .widefat td.sort::before{
|
||||
color: #aaa;
|
||||
content: "\f333";
|
||||
|
||||
display: inline-block;
|
||||
font-family: dashicons;
|
||||
font-size: 20px;
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
height: 20px;
|
||||
line-height: 1;
|
||||
text-align: center;
|
||||
text-decoration-color: inherit;
|
||||
text-decoration-line: inherit;
|
||||
text-decoration-style: inherit;
|
||||
vertical-align: top;
|
||||
width: 20px;
|
||||
padding:4px 0 0 2px;
|
||||
}
|
||||
.opsd_sort_table .widefat td.sort span.glyphicon {
|
||||
vertical-align: middle;
|
||||
}
|
||||
.opsd_sort_table .widefat td {
|
||||
padding:0;
|
||||
}
|
||||
.opsd_sort_table .widefat th input[type=text],
|
||||
.opsd_sort_table .widefat td input[type=text]{
|
||||
width:100%;
|
||||
margin:0;
|
||||
padding-left:5px;
|
||||
height: 36px;
|
||||
}
|
||||
.opsd_sortable_table.widefat {
|
||||
background:#FAFAFA;
|
||||
}
|
||||
.opsd_sortable_table.widefat td.border_bottom {
|
||||
border-bottom: 1px solid #ddd;
|
||||
}
|
||||
.opsd_sortable_table td input[type=text]{
|
||||
border-radius: 0;
|
||||
}
|
||||
/* Color Picker */
|
||||
.opsd_page .wpdevelop .wp-picker-container .wp-color-result,
|
||||
.opsd_sortable_table td .wp-picker-container .wp-color-result {
|
||||
height: 24px;
|
||||
|
||||
clear:both;
|
||||
}
|
||||
.opsd_sortable_table td .opsd-field-colors {
|
||||
padding:2px 10px 2px;
|
||||
border:1px solid #ccc;
|
||||
font-weight: 600;
|
||||
font-size:16px;
|
||||
border-radius:3px;
|
||||
-moz-border-radius:3px;
|
||||
-webkit-border-radius:3px;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
/* Settings table customization */
|
||||
.opsd_page .form-table th,
|
||||
.opsd_page .form-table td {
|
||||
padding:10px 0;
|
||||
}
|
||||
.form-table th label {
|
||||
line-height: 2em;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
/* Dismiss button for Welcome Page Panel *************************************/
|
||||
.opsd-panel-dismiss {
|
||||
position: absolute;
|
||||
top: 5px;
|
||||
right: 10px;
|
||||
padding: 8px 3px;
|
||||
font-size: 13px;
|
||||
text-decoration: none;
|
||||
line-height: 1;
|
||||
outline: 0 none;
|
||||
cursor: pointer;
|
||||
}
|
||||
.opsd-panel-dismiss:before {
|
||||
content: ' ';
|
||||
position: absolute;
|
||||
left: -12px;
|
||||
width: 10px;
|
||||
height: 100%;
|
||||
background: url('../../../../../wp-admin/images/xit.gif') 0 7% no-repeat;
|
||||
}
|
||||
.opsd-panel-dismiss:hover:before {
|
||||
background-position: 100% 7%;
|
||||
}
|
||||
|
||||
/* SORTED Support Styles and Tricks *******************************************/
|
||||
.opsd_mobile_legend {
|
||||
display:none;
|
||||
}
|
||||
/* Align blocks */
|
||||
.opsd-align-right {
|
||||
float: right !important;
|
||||
}
|
||||
.opsd-align-left {
|
||||
float: left !important;
|
||||
}
|
||||
|
||||
/* Align text */
|
||||
.opsd-text-right {
|
||||
text-align: right !important;
|
||||
}
|
||||
.opsd-text-left {
|
||||
text-align: left !important;
|
||||
}
|
||||
.opsd-text-center {
|
||||
text-align: center !important;
|
||||
}
|
||||
.opsd-text-justify {
|
||||
text-align: justify !important;
|
||||
}
|
||||
|
||||
.clear-line {
|
||||
clear:both;
|
||||
width:100%;
|
||||
}
|
||||
/* Trick - Fix HEIGHT for the container with FLOAT elements inside */
|
||||
.clearfix-height:after {
|
||||
content: ".";
|
||||
display: block;
|
||||
clear: both;
|
||||
visibility: hidden;
|
||||
line-height: 0;
|
||||
height: 0;
|
||||
}
|
||||
.clearfix-height {
|
||||
display: inline-block;
|
||||
}
|
||||
html[xmlns] .clearfix-height {
|
||||
display: block;
|
||||
}
|
||||
html[xmlns] .clearfix-height.hidden_items {
|
||||
display: none;
|
||||
}
|
||||
* html .clearfix-height {
|
||||
height: 1%;
|
||||
}
|
||||
|
||||
/* Sortable table */
|
||||
.opsd_sortable_table thead th {
|
||||
padding:10px 0;
|
||||
font-weight: 600;
|
||||
}
|
||||
.opsd_sortable_table tfoot th {
|
||||
padding:10px;
|
||||
}
|
||||
.opsd_sortable_table .widefat th.sort,
|
||||
.opsd_sortable_table .widefat td.sort {
|
||||
width:30px;
|
||||
}
|
||||
.opsd_sortable_table .widefat td.sort::before{
|
||||
color: #aaa;
|
||||
content: "\f333";
|
||||
|
||||
display: inline-block;
|
||||
font-family: dashicons;
|
||||
font-size: 20px;
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
height: 20px;
|
||||
line-height: 1;
|
||||
text-align: center;
|
||||
text-decoration-color: inherit;
|
||||
text-decoration-line: inherit;
|
||||
text-decoration-style: inherit;
|
||||
vertical-align: top;
|
||||
width: 20px;
|
||||
padding:4px 0 0 2px;
|
||||
}
|
||||
.branch-3-5 .opsd_sortable_table .widefat td.sort::before,
|
||||
.branch-3-6 .opsd_sortable_table .widefat td.sort::before,
|
||||
.branch-3-7 .opsd_sortable_table .widefat td.sort::before {
|
||||
content: "=";
|
||||
}
|
||||
.opsd_sortable_table .widefat td {
|
||||
padding:0;
|
||||
}
|
||||
.opsd_sortable_table .widefat th input[type=text],
|
||||
.opsd_sortable_table .widefat td input[type=text]{
|
||||
width:100%;
|
||||
margin:0;
|
||||
padding-left:5px;
|
||||
}
|
||||
|
||||
|
||||
/* Hack to fix checkbox height in Firefox, otherwise sometimes, there exist weird artefact */
|
||||
@-moz-document url-prefix() {
|
||||
.opsd_page input[type='checkbox'] {
|
||||
/*height: auto;*/ /* FixIn: 1.1.1.1 */
|
||||
}
|
||||
.opsd_page input[type='radio'] {
|
||||
/*height: auto;*/ /* FixIn: 1.1.1.1 */
|
||||
/*height: 32px;*/
|
||||
}
|
||||
}
|
||||
|
||||
/* Ajax loading icon */
|
||||
.opsd_ajax_icon {
|
||||
font-size: 9px;
|
||||
margin: 0px 5px 5px 5px;
|
||||
line-height: 1em;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
|
||||
/* Rotate Icons for Loading ***********************************************/
|
||||
.opsd_spin {
|
||||
-webkit-animation: spin 2s infinite linear;
|
||||
-moz-animation: spin 2s infinite linear;
|
||||
-o-animation: spin 2s infinite linear;
|
||||
animation: spin 2s infinite linear;
|
||||
}
|
||||
@-moz-keyframes spin {
|
||||
0% {
|
||||
-moz-transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-moz-transform: rotate(359deg);
|
||||
}
|
||||
}
|
||||
@-webkit-keyframes spin {
|
||||
0% {
|
||||
-webkit-transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-webkit-transform: rotate(359deg);
|
||||
}
|
||||
}
|
||||
@-o-keyframes spin {
|
||||
0% {
|
||||
-o-transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-o-transform: rotate(359deg);
|
||||
}
|
||||
}
|
||||
@keyframes spin {
|
||||
0% {
|
||||
-webkit-transform: rotate(0deg);
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-webkit-transform: rotate(359deg);
|
||||
transform: rotate(359deg);
|
||||
}
|
||||
}
|
||||
.opsd_rotate-90 {
|
||||
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=1);
|
||||
-webkit-transform: rotate(90deg);
|
||||
-moz-transform: rotate(90deg);
|
||||
-ms-transform: rotate(90deg);
|
||||
-o-transform: rotate(90deg);
|
||||
transform: rotate(90deg);
|
||||
}
|
||||
.opsd_rotate-180 {
|
||||
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=2);
|
||||
-webkit-transform: rotate(180deg);
|
||||
-moz-transform: rotate(180deg);
|
||||
-ms-transform: rotate(180deg);
|
||||
-o-transform: rotate(180deg);
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
.opsd_rotate-270 {
|
||||
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=3);
|
||||
-webkit-transform: rotate(270deg);
|
||||
-moz-transform: rotate(270deg);
|
||||
-ms-transform: rotate(270deg);
|
||||
-o-transform: rotate(270deg);
|
||||
transform: rotate(270deg);
|
||||
}
|
||||
.opsd_flip-horizontal {
|
||||
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1);
|
||||
-webkit-transform: scale(-1, 1);
|
||||
-moz-transform: scale(-1, 1);
|
||||
-ms-transform: scale(-1, 1);
|
||||
-o-transform: scale(-1, 1);
|
||||
transform: scale(-1, 1);
|
||||
}
|
||||
.opsd_flip-vertical {
|
||||
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1);
|
||||
-webkit-transform: scale(1, -1);
|
||||
-moz-transform: scale(1, -1);
|
||||
-ms-transform: scale(1, -1);
|
||||
-o-transform: scale(1, -1);
|
||||
transform: scale(1, -1);
|
||||
}
|
||||
/******************************************************************************/
|
||||
|
||||
/* iPad mini and all iPhones and other Mobile Devices */
|
||||
@media (max-width: 782px) {
|
||||
.opsd_mobile_legend {
|
||||
display:inline;
|
||||
font-size: 14px;
|
||||
font-weight: 400;
|
||||
float: left;
|
||||
line-height: 1.3em;
|
||||
}
|
||||
.opsd_mobile_legend.clear{
|
||||
float:none;
|
||||
display:block;
|
||||
}
|
||||
.wpdevelop .hide-sm {
|
||||
display:none;
|
||||
}
|
||||
/* Messages that show at top of admin panel pages */
|
||||
.opsd_page div.opsd_inner_message {
|
||||
/* Overide position and style of Updated Message. If in new WP updates this meesage showing incorrectly, remove this code */
|
||||
margin: 20px 0 25px 10px;
|
||||
position: fixed;
|
||||
top: 32px;
|
||||
width: 96%;
|
||||
padding: 10px 12px;
|
||||
min-height: 1em;
|
||||
height: auto;
|
||||
}
|
||||
}
|
||||
@media (max-width: 480px) {
|
||||
.wpdevelop .hide-xs {
|
||||
display:none;
|
||||
}
|
||||
}
|
||||
|
||||
/* Support new fonts in WP 4.6 */ /* FixIn: 6.2.2.4 */
|
||||
.wpdevelop .label,
|
||||
.wpdevelop strong {
|
||||
font-weight: 600;
|
||||
}
|
||||
.wpdevelop [class^="icon-"] {
|
||||
margin-top: 2px;
|
||||
}
|
||||
.wpdevelop .button [class^="icon-"] {
|
||||
margin-top: 3px;
|
||||
}
|
||||
@@ -0,0 +1,441 @@
|
||||
/**
|
||||
* @version 1.1
|
||||
* @package: Tabs
|
||||
* @category: Admin UI
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-10-29
|
||||
*/
|
||||
/* DropDown Selectbox */
|
||||
.wpdevelop .btn-group.open .dropdown-toggle {
|
||||
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.125) inset;
|
||||
background: #ccc;
|
||||
}
|
||||
/* Drop Down Menu */
|
||||
.wpdevelop ul.dropdown-menu {
|
||||
display: none;
|
||||
}
|
||||
.wpdevelop .dropdown-menu li {
|
||||
padding:0;
|
||||
margin:0;
|
||||
}
|
||||
.wpdevelop .dropdown-menu li.dropdown-header {
|
||||
padding:0 15px;
|
||||
color: #999;
|
||||
font-size: 0.8em;
|
||||
font-style: italic;
|
||||
font-weight: 600;
|
||||
}
|
||||
.wpdevelop .dropdown-menu > .disabled > a,
|
||||
.wpdevelop .dropdown-menu > .disabled > a:focus,
|
||||
.wpdevelop .dropdown-menu > .disabled > a:hover {
|
||||
color:#ccc;
|
||||
}
|
||||
.wpdevelop .dropdown-menu > li > a,
|
||||
.wpdevelop .dropdown-menu a {
|
||||
clear: both;
|
||||
display: block;
|
||||
font-weight: 400;
|
||||
padding:5px 15px;
|
||||
white-space: nowrap;
|
||||
font-size:13px;
|
||||
line-height: 18px;
|
||||
}
|
||||
.wpdevelop .dropdown-menu li > a:hover,
|
||||
.wpdevelop .dropdown-menu li.active > a,
|
||||
.wpdevelop .dropdown-menu li.active > a:hover {
|
||||
background: #08c;
|
||||
color: #fff;
|
||||
text-decoration-color: -moz-use-text-color;
|
||||
text-decoration-line: none;
|
||||
text-decoration-style: solid;
|
||||
}
|
||||
/* radio button or checbox togther with selctbox as option in dropdown list */
|
||||
.wpdevelop .dropdown-menu li .btn-toolbar .input-group {
|
||||
margin:2px 5px 4px 5px;
|
||||
}
|
||||
.wpdevelop .dropdown-menu li .btn-toolbar .input-group .input-group-addon {
|
||||
background: none;
|
||||
border: none;
|
||||
box-shadow: none;
|
||||
}
|
||||
.wpdevelop .dropdown-menu li .btn-toolbar .input-group .input-group-addon input {
|
||||
margin:0 5px 0 0;
|
||||
vertical-align: middle;
|
||||
}
|
||||
.wpdevelop .dropdown-menu li .btn-toolbar .input-group .input-group-addon label {
|
||||
color: #444;
|
||||
margin: 0;
|
||||
vertical-align: middle;
|
||||
line-height: 16px;
|
||||
}
|
||||
.wpdevelop .dropdown-menu li .btn-toolbar .input-group select {
|
||||
border-radius:0px;
|
||||
-moz-border-radius: 0px;
|
||||
-webkit-border-radius: 0px;
|
||||
}
|
||||
/* button group in drop down list*/
|
||||
.wpdevelop .dropdown-menu li .btn-toolbar .btn-group {
|
||||
float: right;
|
||||
margin: 0 5px;
|
||||
}
|
||||
.wpdevelop .dropdown-menu li .btn-toolbar .btn-group a.button {
|
||||
clear:none;
|
||||
}
|
||||
.wpdevelop .dropdown-menu li .btn-toolbar .input-group.text-group {
|
||||
display:block;
|
||||
}
|
||||
.wpdevelop .dropdown-menu li .btn-toolbar .input-group.text-group .input-group-addon {
|
||||
text-align: left;
|
||||
}
|
||||
.wpdevelop .dropdown-menu li .btn-toolbar .input-group.text-group .dropdown-menu-text-element{
|
||||
box-sizing: padding-box;
|
||||
float: left;
|
||||
font-size: 11px;
|
||||
padding: 0 0 0 15px;
|
||||
width: 50%;
|
||||
}
|
||||
.wpdevelop .dropdown-menu li .btn-toolbar .input-group.text-group .dropdown-menu-text-element.dropdown-menu-text-element-count-1 {
|
||||
width: 100%;
|
||||
}
|
||||
.wpdevelop .dropdown-menu li .btn-toolbar .input-group.text-group .dropdown-menu-text-element input[type=text] {
|
||||
font-size: 12px;
|
||||
width: 100%;
|
||||
}
|
||||
/* Containers in Toolbars */
|
||||
.wpdevelop .visibility_container .tab-bottom {
|
||||
-moz-border-bottom-colors: none;
|
||||
-moz-border-image: none;
|
||||
-moz-border-left-colors: none;
|
||||
-moz-border-right-colors: none;
|
||||
-moz-border-top-colors: none;
|
||||
background: none repeat scroll 0 0 #EEE;
|
||||
border-color: #BBC;
|
||||
border-width: 1px;
|
||||
border-style: dashed solid solid;
|
||||
border-radius: 0 0 5px 5px;
|
||||
-moz-border-radius: 0 0 5px 5px;
|
||||
-webkit-border-radius: 0 0 5px 5px;
|
||||
-ms-border-radius: 0 0 5px 5px;
|
||||
box-shadow: 0 0 1px #DDD;
|
||||
padding: 0px 7px;
|
||||
position: absolute;
|
||||
margin-top: 4px;
|
||||
}
|
||||
.wpdevelop .visibility_container .tab-bottom a {
|
||||
color:#777;
|
||||
}
|
||||
.wpdevelop .visibility_container .control-group {
|
||||
float:left;
|
||||
margin-right:15px;
|
||||
margin-top:8px;
|
||||
min-height: 29px;
|
||||
}
|
||||
.wpdevelop .control-group .dropdown-toggle label.label_in_filters {
|
||||
font-weight: 600;
|
||||
}
|
||||
/* Buttons Group */
|
||||
.wpdevelop .btn-group a.button:focus,
|
||||
.wpdevelop .btn-group a.button:hover,
|
||||
.wpdevelop .form-group .input-group a.button:focus,
|
||||
.wpdevelop .form-group .input-group a.button:hover{
|
||||
text-decoration: none;
|
||||
}
|
||||
.wpdevelop .control-group .btn-group > .button{
|
||||
float: left;
|
||||
margin:0 0 0 -1px;
|
||||
position: relative;
|
||||
}
|
||||
.wpdevelop .control-group .btn-group > .button.active {
|
||||
background-color: #E6E6E6;
|
||||
background-image: none;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15) inset, 0 1px 2px rgba(0, 0, 0, 0.05);
|
||||
color: rgba(0, 0, 0, 0.5);
|
||||
outline: 0 none;
|
||||
border-color: #CCCCCC;
|
||||
}
|
||||
|
||||
/* control-group | btn-group */
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > input[type='text'],
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-btn .button {
|
||||
height: 34px;
|
||||
line-height: 1.42857143;
|
||||
|
||||
height: 28px;
|
||||
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > select,
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > input[type='text'],
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-addon {
|
||||
padding: 4px 12px;
|
||||
font-size: 13px;
|
||||
box-shadow: inset 0 0px 0 #fff,0 1px 0 rgba(0,0,0,.08);
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-addon {
|
||||
text-shadow: 0 1px 1px #fff;
|
||||
background-color: #eee;
|
||||
color: #444;
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-addon > input {
|
||||
vertical-align: bottom;
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-btn .button {
|
||||
line-height: 26px;
|
||||
font-size: 13px;
|
||||
vertical-align: middle;
|
||||
padding: 0 10px -1px;
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > input[type='text'] {
|
||||
padding: 4px 4px 4px 8px;
|
||||
height: 28px;
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > select {
|
||||
height: 28px;
|
||||
line-height: 22px;
|
||||
padding: 0 12px;
|
||||
font-size: 13px;
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > select option:disabled {
|
||||
color: #bbb;
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group .input-group-btn .button {
|
||||
box-shadow: 0 0 0 #ffffff inset, 0 1px 0 rgba(0, 0, 0, 0.08);
|
||||
}
|
||||
.wpdevelop .control-group-text {
|
||||
float:left;
|
||||
margin-right:10px;
|
||||
height:28px;
|
||||
line-height:28px;
|
||||
}
|
||||
.wpdevelop .btn-toolbar .input-group > .input-group-btn .button.disabled,
|
||||
.wpdevelop .btn-toolbar .btn-group > .button.disabled,
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-btn .button.disabled,
|
||||
.wpdevelop .control-group .btn-toolbar .btn-group > .button.disabled {
|
||||
box-shadow: 0 1px 0 #cfcfcf !important;
|
||||
}
|
||||
.wpdevelop .btn-toolbar .input-group > .input-group-btn .button.active,
|
||||
.wpdevelop .btn-toolbar .btn-group > .button.active,
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-btn .button.active,
|
||||
.wpdevelop .control-group .btn-toolbar .btn-group > .button.active {
|
||||
transform: none;
|
||||
border-color: #ccc;
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > input[type='text'],
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-btn .button,
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-addon,
|
||||
.wpdevelop .control-group .btn-toolbar .btn-group > .button,
|
||||
.wpdevelop .control-group .btn-toolbar .btn-group > input[type=text],
|
||||
.wpdevelop .control-group .btn-toolbar .btn-group > select {
|
||||
border-radius: 0;
|
||||
-moz-border-radius: 0;
|
||||
-webkit-border-radius: 0;
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > input[type='text']:first-child,
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-btn:first-child .button,
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-addon:first-child,
|
||||
.wpdevelop .control-group .btn-toolbar .btn-group > .button:first-child,
|
||||
.wpdevelop .control-group .btn-toolbar .btn-group > input[type=text]:first-child,
|
||||
.wpdevelop .control-group .btn-toolbar .btn-group > select:first-child {
|
||||
border-bottom-left-radius: 4px;
|
||||
-moz-border-radius-bottomleft: 4px;
|
||||
-webkit-border-bottom-left-radius: 4px;
|
||||
border-top-left-radius: 4px;
|
||||
-moz-border-radius-topleft: 4px;
|
||||
-webkit-border-top-left-radius: 4px;
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > input[type='text']:last-child,
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-btn:last-child .button,
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-addon:last-child,
|
||||
.wpdevelop .control-group .btn-toolbar .btn-group > .button:last-child,
|
||||
.wpdevelop .control-group .btn-toolbar .btn-group > input[type=text]:last-child,
|
||||
.wpdevelop .control-group .btn-toolbar .btn-group > select:last-child {
|
||||
border-bottom-right-radius: 4px;
|
||||
-moz-border-radius-bottomright: 4px;
|
||||
-webkit-border-bottom-right-radius: 4px;
|
||||
border-top-right-radius: 4px;
|
||||
-moz-border-radius-topright: 4px;
|
||||
-webkit-border-top-right-radius: 4px;
|
||||
margin-left: -1px;
|
||||
}
|
||||
.wpdevelop .control-group .btn-group .dropdown-toggle label{
|
||||
margin-bottom: 3px;
|
||||
}
|
||||
.wpdevelop .control-group .btn-group .dropdown-toggle span.opsd_selected_in_dropdown{
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
margin-bottom: 3px;
|
||||
}
|
||||
/* .form-group */
|
||||
.wpdevelop .form-group .input-group > .button,
|
||||
.wpdevelop .form-group .input-group .input-group-btn .button {
|
||||
display: inline-block;
|
||||
font-size: 14px;
|
||||
font-weight: 400;
|
||||
height:34px;
|
||||
line-height: 1.42857;
|
||||
margin-bottom: 0;
|
||||
padding: 6px 12px;
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
white-space: nowrap;
|
||||
border-radius: 0;
|
||||
-moz-border-radius: 0;
|
||||
-webkit-border-radius: 0;
|
||||
}
|
||||
.wpdevelop .form-group .input-group .input-group-btn .btn-toolbar .btn-group .button {
|
||||
border-radius: 4px;
|
||||
-moz-border-radius: 4px;
|
||||
-webkit-border-radius: 4px;
|
||||
margin:0;
|
||||
}
|
||||
.wpdevelop .form-group .input-group > .button:first-child,
|
||||
.wpdevelop .form-group .input-group > input[type=text]:first-child,
|
||||
.wpdevelop .form-group .input-group > select:first-child,
|
||||
.wpdevelop .form-group .input-group .input-group-btn:first-child .button,
|
||||
.wpdevelop .form-group .input-group .input-group-btn .btn-toolbar .btn-group .button:first-child{
|
||||
border-bottom-left-radius: 4px;
|
||||
-moz-border-radius-bottomleft: 4px;
|
||||
-webkit-border-bottom-left-radius: 4px;
|
||||
border-top-left-radius: 4px;
|
||||
-moz-border-radius-topleft: 4px;
|
||||
-webkit-border-top-left-radius: 4px;
|
||||
margin-left: 0;
|
||||
}
|
||||
.wpdevelop .form-group .input-group > .button:last-child,
|
||||
.wpdevelop .form-group .input-group > input[type=text]:last-child,
|
||||
.wpdevelop .form-group .input-group > select:last-child,
|
||||
.wpdevelop .form-group .input-group > .dropdown-toggle,
|
||||
.wpdevelop .form-group .input-group > .input-group-btn:last-child .button,
|
||||
.wpdevelop .form-group .input-group .input-group-btn .btn-toolbar > .btn-group > .button:last-child {
|
||||
border-bottom-right-radius: 4px;
|
||||
-moz-border-radius-bottomright: 4px;
|
||||
-webkit-border-bottom-right-radius: 4px;
|
||||
border-top-right-radius: 4px;
|
||||
-moz-border-radius-topright: 4px;
|
||||
-webkit-border-top-right-radius: 4px;
|
||||
margin-left: -1px;
|
||||
}
|
||||
.wpdevelop .form-group .input-group ul.dropdown-menu {
|
||||
margin-top:0;
|
||||
border-top-right-radius: 0;
|
||||
-moz-border-radius-topright: 0;
|
||||
-webkit-border-top-right-radius: 0;
|
||||
border-top-left-radius: 0;
|
||||
-moz-border-radius-topleft: 0;
|
||||
-webkit-border-top-left-radius: 0;
|
||||
}
|
||||
|
||||
/* Fix: for showing correct width in Chrome. Its trick, so need to test more... 2016-08-31 */
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-addon,
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-btn {
|
||||
width:auto;
|
||||
}
|
||||
|
||||
/* .btn-group-vertical */
|
||||
|
||||
.wpdevelop .btn-group-vertical > .button,
|
||||
.wpdevelop .btn-group-vertical > .btn-group,
|
||||
.wpdevelop .btn-group-vertical > .btn-group > .button {
|
||||
display: block;
|
||||
float: none;
|
||||
width: 100%;
|
||||
max-width: 100%;
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
box-sizing: border-box;
|
||||
margin-bottom: 0;
|
||||
}
|
||||
.wpdevelop .btn-group-vertical > .btn-group > .button {
|
||||
float: none;
|
||||
}
|
||||
.wpdevelop .btn-group-vertical > .button + .button,
|
||||
.wpdevelop .btn-group-vertical > .button + .btn-group,
|
||||
.wpdevelop .btn-group-vertical > .btn-group + .button,
|
||||
.wpdevelop .btn-group-vertical > .btn-group + .btn-group {
|
||||
margin-top: -1px;
|
||||
margin-left: 0;
|
||||
}
|
||||
.wpdevelop .btn-group-vertical > .button:not(:first-child):not(:last-child) {
|
||||
border-radius: 0;
|
||||
}
|
||||
.wpdevelop .btn-group-vertical > .button:first-child:not(:last-child) {
|
||||
border-top-right-radius: 4px;
|
||||
border-bottom-right-radius: 0;
|
||||
border-bottom-left-radius: 0;
|
||||
}
|
||||
.wpdevelop .btn-group-vertical > .button:last-child:not(:first-child) {
|
||||
border-bottom-left-radius: 4px;
|
||||
border-top-right-radius: 0;
|
||||
border-top-left-radius: 0;
|
||||
}
|
||||
.wpdevelop .btn-group-vertical > .btn-group:not(:first-child):not(:last-child) > .button {
|
||||
border-radius: 0;
|
||||
}
|
||||
.wpdevelop .btn-group-vertical > .btn-group:first-child:not(:last-child) > .button:last-child,
|
||||
.wpdevelop .btn-group-vertical > .btn-group:first-child:not(:last-child) > .dropdown-toggle {
|
||||
border-bottom-right-radius: 0;
|
||||
border-bottom-left-radius: 0;
|
||||
}
|
||||
.wpdevelop .btn-group-vertical > .btn-group:last-child:not(:first-child) > .button:first-child {
|
||||
border-top-right-radius: 0;
|
||||
border-top-left-radius: 0;
|
||||
}
|
||||
/*******************************************************************************/
|
||||
|
||||
@media (max-width: 782px) {
|
||||
.wpdevelop .opsd-sm-100 {
|
||||
width:100% !important;
|
||||
}
|
||||
|
||||
/* .wpdevelop .control-group .btn-toolbar .input-group {
|
||||
margin-bottom: 10px;
|
||||
}*/
|
||||
.wpdevelop .in-button-text {
|
||||
display:none;
|
||||
}
|
||||
.wpdevelop .control-group .btn-group > .button,
|
||||
.wpdevelop .control-group .btn-toolbar .btn-group > .button,
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-btn .button {
|
||||
height: 34px;
|
||||
line-height: 1.5em;
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > input[type='text']{
|
||||
height: 40px;
|
||||
padding: 0 12px;
|
||||
line-height: 29px;
|
||||
font-size: 1.2em;
|
||||
}
|
||||
#wpbody .wpdevelop .control-group .btn-toolbar .input-group > select {
|
||||
height: 34px;
|
||||
line-height: 28px;
|
||||
font-size: 1.2em;
|
||||
}
|
||||
.wpdevelop .control-group-text {
|
||||
height: 34px;
|
||||
line-height: 34px;
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-addon,
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-btn {
|
||||
height: 40px;
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-btn .button {
|
||||
margin:0 0 0 -1px;
|
||||
height: 40px;
|
||||
line-height: 39px;
|
||||
padding: 0 15px;
|
||||
}
|
||||
.wpdevelop .control-group .btn-toolbar .input-group > .input-group-addon {
|
||||
|
||||
padding-top:0;
|
||||
padding-bottom:0;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 400px) {
|
||||
.wpdevelop .opsd-sm-100 {
|
||||
width:100% !important;
|
||||
}
|
||||
}
|
||||
61
wp-content/plugins/secure-downloads/core/any/css/dismiss.css
Normal file
61
wp-content/plugins/secure-downloads/core/any/css/dismiss.css
Normal file
@@ -0,0 +1,61 @@
|
||||
/**
|
||||
* @version 1.0
|
||||
* @desciption Dismiss Button and System Notices
|
||||
* @usage Admin panel
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2017-04-23
|
||||
*/
|
||||
|
||||
/* System Notice */
|
||||
.opsd_page .opsd_system_notice {
|
||||
-moz-box-sizing: border-box;
|
||||
-webkit-box-sizing: border-box;
|
||||
box-sizing: border-box;
|
||||
min-height:1em;
|
||||
height:auto;
|
||||
padding: 1em;
|
||||
margin: 5px 0 15px !important;
|
||||
position: relative;
|
||||
display: block;
|
||||
width:100%
|
||||
}
|
||||
.opsd_page .opsd_internal_notice {
|
||||
box-sizing: border-box;
|
||||
min-height: 1em;
|
||||
height: auto;
|
||||
position: relative;
|
||||
display: block;
|
||||
width: 100%;
|
||||
|
||||
background: #fff;
|
||||
border-left-style: solid;
|
||||
border-left-width: 4px;
|
||||
-moz-box-shadow: 0 0 2px 0 rgba(0,0,0,.2);
|
||||
-webkit-box-shadow: 0 0 2px 0 rgba(0,0,0,.2);
|
||||
box-shadow: 0 0 2px 0 rgba(0,0,0,.2);
|
||||
margin: 5px 15px 2px;
|
||||
}
|
||||
.opsd_page .opsd_system_notice a,
|
||||
.opsd_page .opsd_system_notice a:hover,
|
||||
.opsd_page .opsd_system_notice a:focus,
|
||||
.opsd_page .opsd_internal_notice a,
|
||||
.opsd_page .opsd_internal_notice a:hover,
|
||||
.opsd_page .opsd_internal_notice a:focus {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
/* Dismiss X button */
|
||||
.opsd_page .opsd_dismiss,
|
||||
.opsd_page a.opsd_dismiss:hover,
|
||||
.opsd_page a.opsd_dismiss:focus{
|
||||
font-size: 18px;
|
||||
float: right;
|
||||
text-decoration: none;
|
||||
padding: 5px 10px 10px;
|
||||
margin: -7px;
|
||||
outline: none;
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
<?php
|
||||
// Silence is golden.
|
||||
@@ -0,0 +1,74 @@
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package: Admin Panel
|
||||
* @category: Admin UI
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-04-11
|
||||
*/
|
||||
|
||||
/* Admin Content Pages */
|
||||
.opsd_page .opsd_admin_page .opsd_header_margin {
|
||||
height:10px;
|
||||
}
|
||||
/* Collapse & expand elements in settings meta boxes */
|
||||
.opsd_page .meta-box .postbox .handlediv {
|
||||
background: url("../../../../../../wp-admin/images/arrows.png") no-repeat scroll 5px -27px transparent;
|
||||
}
|
||||
.opsd_page .meta-box .postbox.closed .handlediv {
|
||||
background-position:5px 10px;
|
||||
}
|
||||
.opsd_page .meta-box .postbox .handlediv:hover {
|
||||
cursor: pointer !important;
|
||||
}
|
||||
.opsd_page .meta-box .postbox .hndle:hover {
|
||||
cursor: default !important;
|
||||
}
|
||||
|
||||
/* Settings Menuboxes */
|
||||
.opsd_settings_row.opsd_settings_row_left {
|
||||
width:64%;
|
||||
float:left;
|
||||
margin-right:1%;
|
||||
}
|
||||
.opsd_settings_row.opsd_settings_row_right {
|
||||
width:35%;
|
||||
float:left;
|
||||
}
|
||||
|
||||
/* Set switched Meta Boxes size*/
|
||||
.opsd_settings_row.opsd_settings_row_left_small {
|
||||
width:35%;
|
||||
}
|
||||
.opsd_settings_row.opsd_settings_row_right_big {
|
||||
width:64%;
|
||||
}
|
||||
/* FixIn: 7.0.1.54 */
|
||||
.opsd_page input::-moz-placeholder,
|
||||
.opsd_page textarea::-moz-placeholder{
|
||||
color: #ccc;
|
||||
opacity: 1;
|
||||
}
|
||||
.opsd_page input:-ms-input-placeholder,
|
||||
.opsd_page textarea:-ms-input-placeholder{
|
||||
color: #ccc;
|
||||
}
|
||||
.opsd_page input::-webkit-input-placeholder,
|
||||
.opsd_page textarea::-webkit-input-placeholder{
|
||||
color: #ccc;
|
||||
}
|
||||
|
||||
/* iPad mini and all iPhones and other Mobile Devices */
|
||||
@media (max-width: 782px) {
|
||||
/* Settings Top TABS */
|
||||
.opsd_page .opsd_admin_page .metabox-holder .opsd_settings_row {
|
||||
width:100%;
|
||||
float:none;
|
||||
}
|
||||
.opsd_text_hide_mobile {
|
||||
display:none;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
<?php
|
||||
// Silence is golden.
|
||||
@@ -0,0 +1,81 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @package: Emails
|
||||
* @category: Templates
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-06-16
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
/**
|
||||
* get email template
|
||||
*
|
||||
* @param array $fields_values
|
||||
*/
|
||||
function opsd_email_template_plain_html( $fields_values ) {
|
||||
ob_start();
|
||||
|
||||
// $base_color = 'background-color:' . ( empty( $fields_values['base_color'] ) ? '#557da1' : $fields_values['base_color'] ) . ';';
|
||||
// $background_color = 'background-color:' . ( empty( $fields_values['background_color'] ) ? '#FDFDFD' : $fields_values['background_color'] ) . ';';
|
||||
// $body_color = 'background-color:' . ( empty( $fields_values['body_color'] ) ? '#F5F5F5' : $fields_values['body_color'] ) . ';';
|
||||
// $text_color = 'color:' . ( empty( $fields_values['text_color'] ) ? '#333333' : $fields_values['text_color'] ) . ';';
|
||||
|
||||
$base_color = '';
|
||||
$background_color = '';
|
||||
$body_color = '';
|
||||
$text_color = '';
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// HTML Email Template
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"> <!-- dir="<?php echo is_rtl() ? 'rtl' : 'ltr'?>" -->
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title></title>
|
||||
</head>
|
||||
<body style="Margin:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;min-width:100%;<?php echo $body_color; ?>" <?php echo is_rtl() ? 'rightmargin="0"' : 'leftmargin="0"'; ?> >
|
||||
<div class="wrapper" style="table-layout:fixed;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%;Margin:0;padding-top:10px;padding-bottom:10px;padding-right:10px;padding-left:10px;<?php echo $body_color; ?>" <?php echo is_rtl() ? 'dir="rtl"' : 'dir="ltr"'?> >
|
||||
<?php
|
||||
|
||||
if ( ! empty( $fields_values['header_content'] ) ) {
|
||||
?><p style="Margin:0;Margin-bottom:10px;font-family:Helvetica, Roboto, Arial, sans-serif;line-height:150%;font-size:14px;" ><?php
|
||||
|
||||
echo ( wp_kses_post( wptexturize( $fields_values['header_content'] ) ) );
|
||||
|
||||
?></p><?php
|
||||
}
|
||||
|
||||
?><p style="Margin:0;font-size:14px;Margin-bottom:10px;font-family:Helvetica, Roboto, Arial, sans-serif;line-height:150%;<?php echo $text_color; ?>" ><?php
|
||||
|
||||
$h2_headers = array('<p class="h2" style="Margin-bottom:10px;font-family:Helvetica, Roboto, Arial, sans-serif;display:block;font-size:18px;font-weight:bold;line-height:130%;Margin:16px 0 8px;text-align:left;color:#557da1;" >', '</p>');
|
||||
$fields_values['content'] = str_replace( array( '<h2>', '</h2>' ), $h2_headers, $fields_values['content'] );
|
||||
|
||||
echo ( wp_kses_post( wptexturize( $fields_values['content'] ) ) );
|
||||
|
||||
?></p><?php
|
||||
|
||||
if ( ! empty( $fields_values['footer_content'] ) ) {
|
||||
|
||||
?><p style="Margin:0;Margin-bottom:10px;font-family:Helvetica, Roboto, Arial, sans-serif;line-height:150%;font-size:11px;" ><?php
|
||||
|
||||
echo ( wp_kses_post( wptexturize( $fields_values['footer_content'] ) ) );
|
||||
|
||||
?></p><?php
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</body>
|
||||
<?php
|
||||
|
||||
return ob_get_clean(); // Return this email content
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @package: Emails
|
||||
* @category: Templates
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-06-16
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
/**
|
||||
* get email template
|
||||
*
|
||||
* @param array $fields_values
|
||||
*/
|
||||
function opsd_email_template_plain_text( $fields_values ) {
|
||||
|
||||
ob_start();
|
||||
|
||||
if ( ! empty($fields_values['header_content'] ) ) {
|
||||
|
||||
echo wp_kses_post( wptexturize( $fields_values['header_content'] ) ) . "\n\n"; //Header
|
||||
}
|
||||
|
||||
echo ( wp_kses_post( wptexturize( $fields_values['content'] ) ) ); //Content
|
||||
|
||||
if ( ! empty( $fields_values['footer_content'] ) ) {
|
||||
|
||||
echo "\n\n" . wp_kses_post( wptexturize( $fields_values['footer_content'] ) ); //Footer
|
||||
}
|
||||
return ob_get_clean(); // Return this email content
|
||||
}
|
||||
@@ -0,0 +1,654 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @package: Emails
|
||||
* @category: Templates
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-06-16
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
/**
|
||||
* get email template
|
||||
*
|
||||
* @param array $fields_values
|
||||
*/
|
||||
function opsd_email_template_standard_html( $fields_values ) {
|
||||
ob_start();
|
||||
|
||||
$base_color = 'background-color:' . ( empty( $fields_values['base_color'] ) ? '#557da1' : $fields_values['base_color'] ) . ';';
|
||||
$background_color = 'background-color:' . ( empty( $fields_values['background_color'] ) ? '#FDFDFD' : $fields_values['background_color'] ) . ';';
|
||||
$body_color = 'background-color:' . ( empty( $fields_values['body_color'] ) ? '#F5F5F5' : $fields_values['body_color'] ) . ';';
|
||||
$text_color = 'color:' . ( empty( $fields_values['text_color'] ) ? '#333333' : $fields_values['text_color'] ) . ';';
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// HTML Email Template
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"> <!-- dir="<?php echo is_rtl() ? 'rtl' : 'ltr'?>" -->
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title></title>
|
||||
<style type="text/css">
|
||||
body {
|
||||
Margin: 0;
|
||||
padding: 0;
|
||||
min-width: 100%;
|
||||
<?php echo $background_color; ?>
|
||||
}
|
||||
table {
|
||||
border-spacing: 0;
|
||||
font-family: sans-serif;
|
||||
<?php echo $text_color; ?>
|
||||
}
|
||||
td {
|
||||
padding: 0;
|
||||
}
|
||||
img {
|
||||
border: 0;
|
||||
}
|
||||
.wrapper {
|
||||
width: 100%;
|
||||
table-layout: fixed;
|
||||
-webkit-text-size-adjust: 100%;
|
||||
-ms-text-size-adjust: 100%;
|
||||
Margin: 0;
|
||||
padding: 70px 0 70px 0;
|
||||
<?php echo $background_color; ?>
|
||||
}
|
||||
.webkit {
|
||||
max-width: 600px;
|
||||
}
|
||||
@-ms-viewport {
|
||||
width: device-width;
|
||||
}
|
||||
.outer {
|
||||
Margin: 0 auto;
|
||||
width: 96%;
|
||||
max-width: 600px;
|
||||
box-shadow: 0 1px 4px rgba(0,0,0,0.1) !important;
|
||||
border: 1px solid #dcdcdc;
|
||||
border-radius: 3px !important;
|
||||
<?php echo $body_color; ?>
|
||||
}
|
||||
.full-width-image img {
|
||||
width: 100%;
|
||||
height: auto;
|
||||
}
|
||||
.header {
|
||||
border-radius: 3px 3px 0 0 !important;
|
||||
color: #ffffff; border-bottom: 0;
|
||||
font-weight: bold;
|
||||
line-height: 100%;
|
||||
vertical-align: middle;
|
||||
font-family: Helvetica, Roboto, Arial, sans-serif;
|
||||
<?php echo $base_color; ?>
|
||||
}
|
||||
.footer .inner {
|
||||
text-align: center;
|
||||
}
|
||||
.footer .inner p {
|
||||
font-size: 11px;
|
||||
}
|
||||
.inner {
|
||||
padding: 48px;
|
||||
}
|
||||
.header .inner {
|
||||
padding: 10px;
|
||||
}
|
||||
p {
|
||||
Margin: 0;
|
||||
}
|
||||
p.footer {
|
||||
font-size: 11px;
|
||||
}
|
||||
a {
|
||||
color: #ee6a56;
|
||||
text-decoration: underline;
|
||||
}
|
||||
.h1 {
|
||||
font-size: 21px;
|
||||
font-weight: bold;
|
||||
Margin-bottom: 18px;
|
||||
}
|
||||
.header .inner .h1 {
|
||||
color: #ffffff;
|
||||
display: block;
|
||||
font-family: Helvetica, Roboto, Arial, sans-serif;
|
||||
font-size: 30px;
|
||||
font-weight: 300;
|
||||
line-height: 150%;
|
||||
Margin: 0;
|
||||
padding: 26px 48px;
|
||||
text-align: left;
|
||||
text-shadow: 0 1px 0 #7797b4;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
}
|
||||
.h2 {
|
||||
font-size: 18px;
|
||||
font-weight: bold;
|
||||
Margin-bottom: 12px;
|
||||
}
|
||||
.one-column .contents {
|
||||
text-align: left;
|
||||
}
|
||||
.one-column p {
|
||||
font-size: 14px;
|
||||
Margin-bottom: 10px;
|
||||
font-family: Helvetica, Roboto, Arial, sans-serif;
|
||||
font-size: 14px;
|
||||
line-height: 150%;
|
||||
color: #737373;
|
||||
}
|
||||
.one-column p.h2,
|
||||
.two-column .column .contents p.h2 {
|
||||
display: block;
|
||||
font-size: 18px;
|
||||
font-weight: bold;
|
||||
line-height: 130%;
|
||||
Margin: 16px 0 8px;
|
||||
text-align: left;
|
||||
color: #557da1;
|
||||
}
|
||||
.two-column {
|
||||
text-align: center;
|
||||
font-size: 0;
|
||||
}
|
||||
|
||||
.two-column .column {
|
||||
width: 100%;
|
||||
max-width: 280px;
|
||||
display: inline-block;
|
||||
vertical-align: top;
|
||||
}
|
||||
.two-column .column .contents p{
|
||||
font-size: 14px;
|
||||
Margin-bottom: 10px;
|
||||
font-family: Helvetica, Roboto, Arial, sans-serif;
|
||||
font-size: 14px;
|
||||
line-height: 150%;
|
||||
color: #737373;
|
||||
}
|
||||
.two-column .inner,
|
||||
.footer .inner {
|
||||
padding: 10px 48px;
|
||||
}
|
||||
.contents {
|
||||
width: 100%;
|
||||
}
|
||||
.header .inner {
|
||||
width: 100%;
|
||||
}
|
||||
.footer .inner {
|
||||
width: 100%;
|
||||
border-top:1px solid #dddddd;
|
||||
}
|
||||
.two-column .contents {
|
||||
font-size: 14px;
|
||||
text-align: left;
|
||||
}
|
||||
.two-column img {
|
||||
width: 100%;
|
||||
height: auto;
|
||||
}
|
||||
.two-column .text {
|
||||
padding-top: 10px;
|
||||
}
|
||||
.two-column p {
|
||||
font-size: 14px;
|
||||
Margin-bottom: 10px;
|
||||
font-family: Helvetica, Roboto, Arial, sans-serif;
|
||||
font-size: 14px;
|
||||
line-height: 150%;
|
||||
color: #737373;
|
||||
}
|
||||
@media screen and (max-width: 400px) {
|
||||
.two-column .column {
|
||||
max-width: 100% !important;
|
||||
}
|
||||
}
|
||||
@media screen and (min-width: 401px) and (max-width: 620px) {
|
||||
.two-column .column {
|
||||
max-width: 50% !important;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
<!--[if (gte mso 9)|(IE)]>
|
||||
<style type="text/css">
|
||||
table {border-collapse: collapse !important;}
|
||||
</style>
|
||||
<![endif]-->
|
||||
</head>
|
||||
<body style="Margin:0;padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;min-width:100%;<?php echo $background_color; ?>" <?php echo is_rtl() ? 'rightmargin="0"' : 'leftmargin="0"'; ?> >
|
||||
<center class="wrapper" style="width:100%;table-layout:fixed;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%;Margin:0;padding-top:70px;padding-bottom:70px;padding-right:0;padding-left:0;<?php echo $background_color; ?>" <?php echo is_rtl() ? 'dir="rtl"' : 'dir="ltr"'?> >
|
||||
<div class="webkit" style="max-width:600px;" >
|
||||
<!--[if (gte mso 9)|(IE)]>
|
||||
<table width="600" align="center" style="border-spacing:0;font-family:sans-serif;<?php echo $text_color; ?>" >
|
||||
<tr>
|
||||
<td style="padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;" >
|
||||
<![endif]-->
|
||||
<table class="outer" align="center" style="border-spacing:0;font-family:sans-serif;<?php echo $text_color; ?><?php echo $body_color; ?>Margin:0 auto;width:96%;max-width:600px;box-shadow:0 1px 4px rgba(0,0,0,0.1) !important;border-width:1px;border-style:solid;border-color:#dcdcdc;border-radius:3px !important;" >
|
||||
<?php if ( ! empty( $fields_values['header_img600_src'] ) ) { ?>
|
||||
<!-- Header IMG: 1 column template row -->
|
||||
<tr> <!-- This image must be 600px width (NOT wider). If less, then we need to set in CSS width in px of this image -->
|
||||
<td class="full-width-image" style="padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;" >
|
||||
<img src="images/header.jpg" alt="" style="border-width:0;width:100%;height:auto;" /> <!-- src="<?php $fields_values['header_img600_src']; ?>" -->
|
||||
</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
<!-- Header: 1 column template row -->
|
||||
<tr>
|
||||
<td class="one-column" style="padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;" >
|
||||
<table width="100%" class="header" style="<?php echo $base_color; ?>border-spacing:0;border-radius:3px 3px 0 0 !important;color:#ffffff;border-bottom-width:0;font-weight:bold;line-height:100%;vertical-align:middle;font-family:Helvetica, Roboto, Arial, sans-serif;" >
|
||||
<tr>
|
||||
<td class="inner" style="padding-top:10px;padding-bottom:10px;padding-right:10px;padding-left:10px;width:100%;" >
|
||||
<p class="h1" style="Margin-bottom:10px;color:#ffffff;display:block;font-family:Helvetica, Roboto, Arial, sans-serif;font-size:30px;font-weight:300;line-height:150%;Margin:0;padding-top:26px;padding-bottom:26px;padding-right:48px;padding-left:48px;text-align:left;text-shadow:0 1px 0 #7797b4;-webkit-font-smoothing:antialiased;" ><?php echo ( wp_kses_post( wptexturize( $fields_values['header_content'] ) ) ); ?></p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<!-- Content: 1 column template row -->
|
||||
<tr>
|
||||
<td class="one-column" style="padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;" >
|
||||
<table width="100%" style="border-spacing:0;font-family:sans-serif;<?php echo $text_color; ?>" >
|
||||
<tr>
|
||||
<td class="inner contents" style="padding-top:48px;padding-bottom:48px;padding-right:48px;padding-left:48px;width:100%;text-align:left;" >
|
||||
<p style="Margin:0;font-size:14px;Margin-bottom:10px;font-family:Helvetica, Roboto, Arial, sans-serif;line-height:150%;color:#737373;" ><?php
|
||||
|
||||
$h2_headers = array('<p class="h2" style="Margin-bottom:10px;font-family:Helvetica, Roboto, Arial, sans-serif;display:block;font-size:18px;font-weight:bold;line-height:130%;Margin:16px 0 8px;text-align:left;color:#557da1;" >', '</p>');
|
||||
$fields_values['content'] = str_replace( array( '<h2>', '</h2>' ), $h2_headers, $fields_values['content'] );
|
||||
|
||||
echo ( wp_kses_post( wptexturize( $fields_values['content'] ) ) );
|
||||
?></p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<!-- Footer: 1 column template row -->
|
||||
<tr>
|
||||
<td class="one-column" style="padding-top:0;padding-bottom:0;padding-right:0;padding-left:0;" >
|
||||
<table width="100%" class="footer" style="border-spacing:0;font-family:sans-serif;<?php echo $text_color; ?>" >
|
||||
<tr>
|
||||
<td class="inner" style="text-align:center;padding-top:10px;padding-bottom:10px;padding-right:48px;padding-left:48px;width:100%;border-top-width:1px;border-top-style:solid;border-top-color:#dddddd;" >
|
||||
<p style="Margin:0;Margin-bottom:10px;font-family:Helvetica, Roboto, Arial, sans-serif;line-height:150%;color:#737373;font-size:11px;" >
|
||||
<?php /* <a style="color:#ee6a56;text-decoration:underline;" >Forward to a Friend</a> <a style="color:#ee6a56;text-decoration:underline;" >Unsubscribe</a> <a style="color:#ee6a56;text-decoration:underline;" >Preferences</a><br /> */
|
||||
echo ( wp_kses_post( wptexturize( $fields_values['footer_content'] ) ) ); ?>
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<!--[if (gte mso 9)|(IE)]>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<![endif]-->
|
||||
</div>
|
||||
</center>
|
||||
</body>
|
||||
<?php
|
||||
|
||||
return ob_get_clean(); // Return this email content
|
||||
}
|
||||
|
||||
|
||||
return;
|
||||
|
||||
// Exist from this file, at the bottom - original static HTML template for email
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc=" Source Code of template for parsing at http://inliner.cm/ " >
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Source Code of template for parsing at http://inliner.cm/
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml"> <!-- dir="<?php echo is_rtl() ? 'rtl' : 'ltr'?>" -->
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title></title>
|
||||
<style type="text/css">
|
||||
body {
|
||||
Margin: 0;
|
||||
padding: 0;
|
||||
min-width: 100%;
|
||||
background-color: #ffffff;
|
||||
}
|
||||
table {
|
||||
border-spacing: 0;
|
||||
font-family: sans-serif;
|
||||
color: #333333;
|
||||
}
|
||||
td {
|
||||
padding: 0;
|
||||
}
|
||||
img {
|
||||
border: 0;
|
||||
}
|
||||
.wrapper {
|
||||
width: 100%;
|
||||
table-layout: fixed;
|
||||
-webkit-text-size-adjust: 100%;
|
||||
-ms-text-size-adjust: 100%;
|
||||
Margin: 0;
|
||||
padding: 70px 0 70px 0;
|
||||
background-color: #f5f5f5;
|
||||
}
|
||||
.webkit {
|
||||
max-width: 600px;
|
||||
}
|
||||
@-ms-viewport {
|
||||
width: device-width;
|
||||
}
|
||||
/* width 100% */
|
||||
.outer {
|
||||
Margin: 0 auto;
|
||||
width: 96%;
|
||||
max-width: 600px;
|
||||
box-shadow: 0 1px 4px rgba(0,0,0,0.1) !important;
|
||||
border: 1px solid #dcdcdc;
|
||||
border-radius: 3px !important;
|
||||
background-color: #fdfdfd;
|
||||
}
|
||||
|
||||
.full-width-image img {
|
||||
width: 100%;
|
||||
height: auto;
|
||||
}
|
||||
.header {
|
||||
border-radius: 3px 3px 0 0 !important;
|
||||
color: #ffffff; border-bottom: 0;
|
||||
font-weight: bold;
|
||||
line-height: 100%;
|
||||
vertical-align: middle;
|
||||
font-family: Helvetica, Roboto, Arial, sans-serif;
|
||||
background-color: #557da1;
|
||||
}
|
||||
.footer .inner {
|
||||
text-align: center;
|
||||
}
|
||||
.footer .inner p {
|
||||
font-size: 11px;
|
||||
}
|
||||
.inner {
|
||||
padding: 48px;
|
||||
}
|
||||
.header .inner {
|
||||
padding: 10px;
|
||||
}
|
||||
p {
|
||||
Margin: 0;
|
||||
}
|
||||
p.footer {
|
||||
font-size: 11px;
|
||||
}
|
||||
a {
|
||||
color: #ee6a56;
|
||||
text-decoration: underline;
|
||||
}
|
||||
.h1 {
|
||||
font-size: 21px;
|
||||
font-weight: bold;
|
||||
Margin-bottom: 18px;
|
||||
}
|
||||
.header .inner .h1 {
|
||||
color: #ffffff;
|
||||
display: block;
|
||||
font-family: Helvetica, Roboto, Arial, sans-serif;
|
||||
font-size: 30px;
|
||||
font-weight: 300;
|
||||
line-height: 150%;
|
||||
Margin: 0;
|
||||
padding: 26px 48px;
|
||||
text-align: left;
|
||||
text-shadow: 0 1px 0 #7797b4;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
}
|
||||
.h2 {
|
||||
font-size: 18px;
|
||||
font-weight: bold;
|
||||
Margin-bottom: 12px;
|
||||
}
|
||||
.one-column .contents {
|
||||
text-align: left;
|
||||
}
|
||||
.one-column p {
|
||||
font-size: 14px;
|
||||
Margin-bottom: 10px;
|
||||
font-family: Helvetica, Roboto, Arial, sans-serif;
|
||||
font-size: 14px;
|
||||
line-height: 150%;
|
||||
color: #737373;
|
||||
}
|
||||
.one-column p.h2,
|
||||
.two-column .column .contents p.h2 {
|
||||
display: block;
|
||||
font-size: 18px;
|
||||
font-weight: bold;
|
||||
line-height: 130%;
|
||||
Margin: 16px 0 8px;
|
||||
text-align: left;
|
||||
color: #557da1;
|
||||
}
|
||||
.two-column {
|
||||
text-align: center;
|
||||
font-size: 0;
|
||||
}
|
||||
/* Previously 300px. - TODO: need to test if we really need to have here 280 or 300px in the different email applications. Also its possible that we need to have header images, not 280px but only 260px.... */
|
||||
.two-column .column {
|
||||
width: 100%;
|
||||
max-width: 280px;
|
||||
display: inline-block;
|
||||
vertical-align: top;
|
||||
}
|
||||
.two-column .column .contents p{
|
||||
font-size: 14px;
|
||||
Margin-bottom: 10px;
|
||||
font-family: Helvetica, Roboto, Arial, sans-serif;
|
||||
font-size: 14px;
|
||||
line-height: 150%;
|
||||
color: #737373;
|
||||
}
|
||||
.two-column .inner,
|
||||
.footer .inner {
|
||||
padding: 10px 48px;
|
||||
}
|
||||
.contents {
|
||||
width: 100%;
|
||||
}
|
||||
.header .inner {
|
||||
width: 100%;
|
||||
}
|
||||
.footer .inner {
|
||||
width: 100%;
|
||||
border-top:1px solid #dddddd;
|
||||
}
|
||||
.two-column .contents {
|
||||
font-size: 14px;
|
||||
text-align: left;
|
||||
}
|
||||
.two-column img {
|
||||
width: 100%;
|
||||
height: auto;
|
||||
}
|
||||
.two-column .text {
|
||||
padding-top: 10px;
|
||||
}
|
||||
.two-column p {
|
||||
font-size: 14px;
|
||||
Margin-bottom: 10px;
|
||||
font-family: Helvetica, Roboto, Arial, sans-serif;
|
||||
font-size: 14px;
|
||||
line-height: 150%;
|
||||
color: #737373;
|
||||
}
|
||||
/*Media Queries*/
|
||||
@media screen and (max-width: 400px) {
|
||||
.two-column .column {
|
||||
max-width: 100% !important;
|
||||
}
|
||||
}
|
||||
@media screen and (min-width: 401px) and (max-width: 620px) {
|
||||
.two-column .column {
|
||||
max-width: 50% !important;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
<!--[if (gte mso 9)|(IE)]>
|
||||
<style type="text/css">
|
||||
table {border-collapse: collapse;}
|
||||
</style>
|
||||
<![endif]-->
|
||||
</head>
|
||||
<body> <!-- <?php echo is_rtl() ? 'rightmargin="0"' : 'leftmargin="0"'; ?> -->
|
||||
<center class="wrapper" > <!-- <?php echo is_rtl() ? 'dir="rtl"' : 'dir="ltr"'?> -->
|
||||
<div class="webkit">
|
||||
<!--[if (gte mso 9)|(IE)]>
|
||||
<table width="600" align="center">
|
||||
<tr>
|
||||
<td>
|
||||
<![endif]-->
|
||||
<table class="outer" align="center">
|
||||
<!-- <?php if ( ! empty( $fields_values['header_img600_src'] ) ) { ?> -->
|
||||
<!-- Header IMG: 1 column template row -->
|
||||
<tr> <!-- This image must be 600px width (NOT wider). If less, then we need to set in CSS width in px of this image -->
|
||||
<td class="full-width-image">
|
||||
<img src="images/header.jpg" alt="" /> <!-- src="<?php $fields_values['header_img600_src']; ?>" -->
|
||||
</td>
|
||||
</tr>
|
||||
<!-- <?php } ?> -->
|
||||
<!-- Header: 1 column template row -->
|
||||
<tr>
|
||||
<td class="one-column">
|
||||
<table width="100%" class="header">
|
||||
<tr>
|
||||
<td class="inner">
|
||||
<p class="h1">HTML Email Header</p> <!-- <?php echo ( wp_kses_post( wptexturize( $fields_values['header_content'] ) ) ); ?> -->
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<!-- Content: 1 column template row -->
|
||||
<tr>
|
||||
<td class="one-column">
|
||||
<table width="100%">
|
||||
<tr>
|
||||
<td class="inner contents"> <!-- <?php echo ( wp_kses_post( wptexturize( $fields_values['content'] ) ) ); ?> -->
|
||||
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed aliquet diam a facilisis eleifend. Cras ac justo felis. Mauris faucibus, orci eu blandit fermentum, lorem nibh sollicitudin mi, sit amet interdum metus urna ut lacus.</p>
|
||||
<p class="h2">Lorem ipsum dolor</p>
|
||||
<p>Fusce eu euismod leo, a accumsan tellus. Quisque vitae dolor eu justo cursus egestas. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Sed sit amet sapien odio. Sed pellentesque arcu mi, quis malesuada lectus lacinia et. Cras a tempor leo.</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<!-- <?php if ( ( ! empty( $fields_values['content_column_1'] ) ) && ( ! empty( $fields_values['content_column_2'] ) ) ) { ?> -->
|
||||
<!-- Content: 2 columns template row -->
|
||||
<tr>
|
||||
<td class="two-column">
|
||||
<!--[if (gte mso 9)|(IE)]>
|
||||
<table width="100%">
|
||||
<tr>
|
||||
<td width="50%" valign="top">
|
||||
<![endif]-->
|
||||
<div class="column">
|
||||
<!-- Column 1 -->
|
||||
<table width="100%">
|
||||
<tr>
|
||||
<td class="inner">
|
||||
<table class="contents">
|
||||
<!-- <?php if ( ! empty( $fields_values['header_column_1_img260_src'] ) ) { ?> -->
|
||||
<tr>
|
||||
<td>
|
||||
<!-- width of image must be 260px -->
|
||||
<img src="images/two-column-01.jpg" alt="" /> <!-- src="<?php $fields_values['header_column_1_img260_src']; ?>" -->
|
||||
</td>
|
||||
</tr>
|
||||
<!-- <?php } ?> -->
|
||||
<tr>
|
||||
<td class="text"> <!-- <?php echo ( wp_kses_post( wptexturize( $fields_values['content_column_1'] ) ) ); ?> -->
|
||||
<p>Column 1 Content .... Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed aliquet diam a facilisis eleifend. Cras ac justo felis. Mauris faucibus, orci eu blandit fermentum, lorem nibh sollicitudin mi, sit amet interdum metus urna ut lacus. </p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<!--[if (gte mso 9)|(IE)]>
|
||||
</td><td width="50%" valign="top">
|
||||
<![endif]-->
|
||||
<div class="column">
|
||||
<!-- Column 2 -->
|
||||
<table width="100%">
|
||||
<tr>
|
||||
<td class="inner">
|
||||
<table class="contents">
|
||||
<!-- <?php if ( ! empty( $fields_values['header_column_2_img260_src'] ) ) { ?> -->
|
||||
<tr>
|
||||
<td>
|
||||
<!-- width of image must be 260px -->
|
||||
<img src="images/two-column-02.jpg" alt="" /> <!-- src="<?php $fields_values['header_column_2_img260_src']; ?>" -->
|
||||
</td>
|
||||
</tr>
|
||||
<!-- <?php } ?> -->
|
||||
<tr>
|
||||
<td class="text"> <!-- <?php echo ( wp_kses_post( wptexturize( $fields_values['content_column_2'] ) ) ); ?> -->
|
||||
<p>Column 2 Content .... Fusce eu euismod leo, a accumsan tellus. Quisque vitae dolor eu justo cursus egestas. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Sed sit amet sapien odio. Sed pellentesque arcu mi, quis malesuada lectus lacinia et. Cras a tempor leo. </p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<!--[if (gte mso 9)|(IE)]>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<![endif]-->
|
||||
</td>
|
||||
</tr>
|
||||
<!-- <?php } ?> -->
|
||||
<!-- Footer: 1 column template row -->
|
||||
<tr>
|
||||
<td class="one-column">
|
||||
<table width="100%" class="footer">
|
||||
<tr>
|
||||
<td class="inner"> <!-- <?php echo ( wp_kses_post( wptexturize( $fields_values['footer_content'] ) ) ); ?> -->
|
||||
<p>
|
||||
<a>Forward to a Friend</a> <a>Unsubscribe</a> <a>Preferences</a><br />
|
||||
You are receiving this email because you are either purchased product at OPSD or you entered your email at OPSD
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
<!--[if (gte mso 9)|(IE)]>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<![endif]-->
|
||||
</div>
|
||||
</center>
|
||||
</body>
|
||||
<?php
|
||||
// </editor-fold>
|
||||
@@ -0,0 +1,41 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @package: Emails
|
||||
* @category: Templates
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-06-16
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
/**
|
||||
* get email template
|
||||
*
|
||||
* @param array $fields_values
|
||||
*/
|
||||
function opsd_email_template_standard_text( $fields_values ) {
|
||||
|
||||
ob_start();
|
||||
|
||||
if ( ! empty($fields_values['header_content'] ) ) {
|
||||
|
||||
echo "= " . wp_kses_post( wptexturize( $fields_values['header_content'] ) ) . " =\n\n";
|
||||
|
||||
echo "----------------------------------------------------------------------\n\n";
|
||||
}
|
||||
|
||||
echo ( wp_kses_post( wptexturize( $fields_values['content'] ) ) );
|
||||
|
||||
if ( ! empty( $fields_values['footer_content'] ) ) {
|
||||
|
||||
echo "\n---------------------------------------------------------------------\n\n";
|
||||
|
||||
echo ( wp_kses_post( wptexturize( $fields_values['footer_content'] ) ) );
|
||||
}
|
||||
return ob_get_clean(); // Return this email content
|
||||
}
|
||||
7
wp-content/plugins/secure-downloads/core/any/index.php
Normal file
7
wp-content/plugins/secure-downloads/core/any/index.php
Normal file
@@ -0,0 +1,7 @@
|
||||
<?php
|
||||
// Silence is golden.
|
||||
|
||||
// Replace OPSD to ...
|
||||
// _opsd_ to _bk_ (...) in get_opsd_option ....
|
||||
// - opsd to ...
|
||||
// , 'secure-downloads') ==> ...
|
||||
622
wp-content/plugins/secure-downloads/core/any/js/admin-support.js
Normal file
622
wp-content/plugins/secure-downloads/core/any/js/admin-support.js
Normal file
@@ -0,0 +1,622 @@
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package Support Functions
|
||||
* @subpackage BackEnd Main Script Lib
|
||||
* @category Scripts
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-04-09
|
||||
*/
|
||||
|
||||
|
||||
/** Scroll to specific HTML element
|
||||
*
|
||||
* @param {type} object_name
|
||||
* @returns {undefined}
|
||||
*/
|
||||
function opsd_scroll_to( object_name ) {
|
||||
if ( jQuery( object_name ).length > 0 ) {
|
||||
var targetOffset = jQuery( object_name ).offset().top;
|
||||
// targetOffset = targetOffset - 50;
|
||||
if (targetOffset<0) targetOffset = 0;
|
||||
if ( jQuery('#wpadminbar').length > 0 ) targetOffset = targetOffset - 50;
|
||||
else targetOffset = targetOffset - 20;
|
||||
jQuery('html,body').animate({scrollTop: targetOffset}, 500);
|
||||
}
|
||||
}
|
||||
|
||||
function opsd_animate_border( element, time, colors, x ) {
|
||||
|
||||
if (x >= colors.length) {
|
||||
x = 0;
|
||||
} else {
|
||||
x++;
|
||||
var color;
|
||||
if ( colors[x] === '' ) {
|
||||
color = ''
|
||||
} else {
|
||||
color = '#'+colors[x]
|
||||
}
|
||||
element.css('border-color', color)
|
||||
setTimeout(function() {
|
||||
opsd_animate_border( element, time, colors, x );
|
||||
}, time)
|
||||
}
|
||||
}
|
||||
|
||||
function opsd_field_highlight( object_name ) {
|
||||
|
||||
if ( jQuery( object_name ).length > 0 ) {
|
||||
|
||||
opsd_scroll_to( object_name );
|
||||
|
||||
opsd_animate_border(
|
||||
jQuery( object_name ) // Element
|
||||
, 200 // Time in ms
|
||||
, ['f87000', '', 'f87000', '', 'f87000', '', 'f87000', '', 'f87000', '', 'f87000', ''] // Colors Array
|
||||
, 0
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/** Show Yes/No dialog
|
||||
*
|
||||
* @param {type} message_question
|
||||
* @returns {Boolean}
|
||||
*/
|
||||
function opsd_are_you_sure( message_question ){
|
||||
var answer = confirm( message_question );
|
||||
if ( answer) { return true; }
|
||||
else { return false;}
|
||||
}
|
||||
|
||||
function opsd_admin_show_message_processing( message_type ){
|
||||
|
||||
var message = '' ;
|
||||
|
||||
if ( message_type == 'saving' )
|
||||
message += opsd_message_saving;
|
||||
else if ( message_type == 'updating' )
|
||||
message += opsd_message_updating;
|
||||
else if ( message_type == 'deleting' )
|
||||
message += opsd_message_deleting;
|
||||
else
|
||||
message += opsd_message_processing;
|
||||
|
||||
if ( message == 'undefined' )
|
||||
message = 'Processing'
|
||||
|
||||
message = ' <span class="wpdevelop"><span class="glyphicon glyphicon-refresh opsd_spin opsd_ajax_icon" aria-hidden="true"></span></span> ' + message + '...';
|
||||
|
||||
opsd_admin_show_message( message, 'info', 10000 );
|
||||
}
|
||||
|
||||
/** Show Alert Messages
|
||||
*
|
||||
* @param {type} message
|
||||
* @param {type} m_type
|
||||
* @param {type} m_delay
|
||||
* @returns {undefined}
|
||||
*/
|
||||
function opsd_admin_show_message( message, m_type, m_delay ){
|
||||
|
||||
var alert_class = 'notice '; //'alert ';
|
||||
if (m_type == 'error') alert_class += 'notice-error '; //'alert-danger ';
|
||||
if (m_type == 'warning') alert_class += 'notice-warning ';
|
||||
if (m_type == 'info') alert_class += 'notice-info '; //'alert-info ';
|
||||
if (m_type == 'success') alert_class += 'alert-success updated ';
|
||||
|
||||
jQuery('#ajax_working').html( '<div id="opsd_alert_message" class="opsd_alert_message">' +
|
||||
'<div class="opsd_inner_message '+alert_class+'"> ' +
|
||||
'<a class="close" href="javascript:void(0)" onclick="javascript:jQuery(this).parent().hide();">×</a> ' +
|
||||
message +
|
||||
'</div>' +
|
||||
'</div>'
|
||||
);
|
||||
jQuery('#opsd_alert_message').animate( {opacity: 1}, m_delay ).fadeOut(500);
|
||||
}
|
||||
|
||||
|
||||
function opsd_close_dropdown_selectbox( selector_id ) {
|
||||
jQuery('#' + selector_id + '_container li input[type=checkbox],#' + selector_id + '_container li input[type=radio]').prop('checked', false);
|
||||
jQuery('#' + selector_id + '_container').hide();
|
||||
}
|
||||
// Show Container depend from the selected option in dropdown list
|
||||
function opsd_show_selected_in_dropdown( selector_id, title, value ){
|
||||
jQuery('#' + selector_id + '_selector .opsd_selected_in_dropdown').html( title );
|
||||
jQuery('#' + selector_id ).val( value );
|
||||
}
|
||||
|
||||
// Show Container depend from the selected Radio Option and Selectbox value in dropdown list
|
||||
// Exmaple: opsd_show_selected_in_dropdown__radio_select_option( 'wh_ ... _date', 'wh_ ... _date2', 'wh_ ... _datedays_interval_Radios' );
|
||||
function opsd_show_selected_in_dropdown__radio_select_option( selector_id, selector_id2, radio_name ){
|
||||
|
||||
// Get selected value in radio buttons
|
||||
var rad_val = jQuery('input:radio[name="' + radio_name + '"]:checked').val();
|
||||
|
||||
if ( rad_val != 'undefined' ) {
|
||||
|
||||
var select_box = jQuery('input:radio[name="' + radio_name + '"]:checked').parents('.input-group').find('select');
|
||||
// Selectbox exist
|
||||
if ( select_box.length > 0 ) {
|
||||
// Get label near selected radiobutton and selected Tilte in selectbox
|
||||
var title = jQuery('input:radio[name="' + radio_name + '"]:checked').parent().find('label').html() + ' ' +
|
||||
jQuery('input:radio[name="' + radio_name + '"]:checked').parents('.input-group').find('select option:selected').text();
|
||||
// Get Value of selected option in selectbox
|
||||
var value = jQuery('input:radio[name="' + radio_name + '"]:checked').parents('.input-group').find('select option:selected').val();
|
||||
// Set Title in dropdown list
|
||||
jQuery('#' + selector_id + '_selector .opsd_selected_in_dropdown').html( title );
|
||||
// Set value of radio button
|
||||
jQuery('#' + selector_id ).val( rad_val );
|
||||
// Set value of selectbox
|
||||
jQuery('#' + selector_id2 ).val( value );
|
||||
} else {
|
||||
// 2 Text Fields
|
||||
var text_box = jQuery('input:radio[name="' + radio_name + '"]:checked').parents('.text-group').find('input[type="text"]');
|
||||
if ( text_box.length > 0 ) {
|
||||
var text_divs = jQuery('input:radio[name="' + radio_name + '"]:checked').parents('.text-group').find('.dropdown-menu-text-element');
|
||||
|
||||
// Check if we have 2 DIV elements with text fields
|
||||
if ( text_box.length > 0 ) {
|
||||
|
||||
var id_list = [ selector_id, selector_id2 ];
|
||||
var title = '';
|
||||
//Loop our text DIV elements
|
||||
jQuery('input:radio[name="' + radio_name + '"]:checked').parents('.text-group').find('.dropdown-menu-text-element').each(function( i ) {
|
||||
|
||||
if ( title != '' )
|
||||
title += ' - ';
|
||||
title += jQuery(this).find('input[type="text"]').val();
|
||||
jQuery('#' + id_list[ i ] ).val( jQuery(this).find('input[type="text"]').val() );
|
||||
});
|
||||
// Set Title in dropdown list
|
||||
jQuery('#' + selector_id + '_selector .opsd_selected_in_dropdown').html( title );
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Hide dropdown list
|
||||
jQuery('#' + selector_id + '_container').hide();
|
||||
}
|
||||
|
||||
//Set status of all checkbos in one time
|
||||
function opsd_set_checkbox_in_table( el_stutus, el_class ){
|
||||
jQuery('.'+el_class).attr('checked', el_stutus);
|
||||
|
||||
if ( el_stutus ) {
|
||||
jQuery('.'+el_class).parent().parent().parent().parent().addClass('row_selected_color');
|
||||
// jQuery('.'+el_class).parent().parent().addClass('warning');
|
||||
} else {
|
||||
jQuery('.'+el_class).parent().parent().parent().parent().removeClass('row_selected_color');
|
||||
// jQuery('.'+el_class).parent().parent().removeClass('warning');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/** Ajax Request
|
||||
*
|
||||
* @param {type} us_id
|
||||
* @param {type} window_id
|
||||
* @returns {undefined}
|
||||
*/
|
||||
//<![CDATA[
|
||||
function opsd_verify_window_opening( us_id, window_id ){
|
||||
|
||||
var is_closed = 0;
|
||||
|
||||
if (jQuery('#' + window_id ).hasClass('closed') == true){
|
||||
jQuery('#' + window_id ).removeClass('closed');
|
||||
} else {
|
||||
jQuery('#' + window_id ).addClass('closed');
|
||||
is_closed = 1;
|
||||
}
|
||||
|
||||
|
||||
jQuery.ajax({ // Start Ajax Sending
|
||||
url: opsd_ajaxurl,
|
||||
type:'POST',
|
||||
success: function (data, textStatus){if( textStatus == 'success') jQuery('#ajax_respond').html( data );},
|
||||
error:function (XMLHttpRequest, textStatus, errorThrown){ window.status = 'Ajax sending Error status:'+ textStatus; alert(XMLHttpRequest.status + ' ' + XMLHttpRequest.statusText); if ( XMLHttpRequest.status == 500 ) { alert('Error: 500'); } } ,
|
||||
// beforeSend: someFunction,
|
||||
data:{
|
||||
action: 'USER_SAVE_WINDOW_STATE',
|
||||
user_id: us_id ,
|
||||
window: window_id,
|
||||
is_closed: is_closed,
|
||||
opsd_nonce: jQuery('#opsd_admin_panel_nonce').val()
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
//]]>
|
||||
|
||||
|
||||
|
||||
/** Ajax Request - Saving Custom Data for User
|
||||
*
|
||||
* @param {int} us_id
|
||||
* @param {string} data_name
|
||||
* @param {string} data_value - serialized data
|
||||
* @param {int} is_reload - { 0 | 1 } reload or not page
|
||||
*/
|
||||
//<![CDATA[
|
||||
function opsd_save_custom_user_data( us_id, data_name, data_value , is_reload ){
|
||||
|
||||
opsd_admin_show_message_processing( 'saving' );
|
||||
|
||||
jQuery.ajax({ // Start Ajax Sending
|
||||
url: opsd_ajaxurl,
|
||||
type:'POST',
|
||||
success: function (data, textStatus){if( textStatus == 'success') jQuery('#ajax_respond').html( data );},
|
||||
error:function (XMLHttpRequest, textStatus, errorThrown){ window.status = 'Ajax sending Error status:'+ textStatus; alert(XMLHttpRequest.status + ' ' + XMLHttpRequest.statusText); if ( XMLHttpRequest.status == 500 ) { alert('Error: 500'); } } ,
|
||||
// beforeSend: someFunction,
|
||||
data:{
|
||||
action: 'USER_SAVE_CUSTOM_DATA',
|
||||
user_id: us_id,
|
||||
data_name: data_name,
|
||||
data_value: decodeURIComponent( data_value ),
|
||||
is_reload: is_reload,
|
||||
opsd_nonce: jQuery('#opsd_admin_panel_nonce').val()
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
//]]>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Contact Form
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
function opsd_submit_client_form( submit_form, wpdev_active_locale ){
|
||||
|
||||
var count = submit_form.elements.length;
|
||||
var formdata = '';
|
||||
var inp_value;
|
||||
var element;
|
||||
var el_type;
|
||||
|
||||
for (i=0; i<count; i++) {
|
||||
element = submit_form.elements[i];
|
||||
|
||||
if ( (element.type !=='button') && (element.type !=='hidden') ) {
|
||||
|
||||
// Get Value of Element
|
||||
if ( element.type == 'checkbox' ){
|
||||
|
||||
if ( element.value == '' ) {
|
||||
inp_value = element.checked;
|
||||
} else {
|
||||
if ( element.checked )
|
||||
inp_value = element.value;
|
||||
else
|
||||
inp_value = '';
|
||||
}
|
||||
|
||||
} else if ( element.type == 'radio' ) {
|
||||
|
||||
if ( element.value == '' ) {
|
||||
inp_value = element.checked;
|
||||
} else {
|
||||
if ( element.checked )
|
||||
inp_value = element.value;
|
||||
else
|
||||
inp_value = '';
|
||||
}
|
||||
/*
|
||||
if ( element.checked )
|
||||
inp_value = element.value;
|
||||
else
|
||||
continue;
|
||||
*/
|
||||
|
||||
} else {
|
||||
inp_value = element.value;
|
||||
}
|
||||
|
||||
// Get value in selectbox of multiple selection
|
||||
if (element.type =='select-multiple') {
|
||||
inp_value = jQuery('[name="'+element.name+'"]').val() ;
|
||||
if ( ( inp_value == null ) || ( inp_value.toString() == '' ) )
|
||||
inp_value='';
|
||||
}
|
||||
|
||||
/*if ( element.name == ('phone') ) {
|
||||
// we validate a phone number of 10 digits with no comma, no spaces, no punctuation and there will be no + sign in front the number - See more at: http://www.w3resource.com/javascript/form/phone-no-validation.php#sthash.U9FHwcdW.dpuf
|
||||
var reg = /^\d{10}$/;
|
||||
var message_verif_phone = "Please enter correctly phone number";
|
||||
if ( inp_value != '' )
|
||||
if(reg.test(inp_value) == false) {opsd_show_error_message( element , message_verif_phone);return;}
|
||||
}*/
|
||||
|
||||
|
||||
// Validation Check -- Requred fields
|
||||
if ( element.className.indexOf( 'opsd-validate-required' ) !== -1 ){
|
||||
|
||||
if ( ( element.type =='checkbox' ) && ( element.checked === false ) ) {
|
||||
if ( ! jQuery(':checkbox[name="'+element.name+'"]', submit_form).is(":checked") ) {
|
||||
opsd_show_error_message( element , opsd_global1.message_verif_requred_for_check_box);
|
||||
return;
|
||||
}
|
||||
}
|
||||
if ( element.type =='radio' ) {
|
||||
if ( ! jQuery(':radio[name="'+element.name+'"]', submit_form).is(":checked") ) {
|
||||
opsd_show_error_message( element , opsd_global1.message_verif_requred_for_radio_box);
|
||||
return;
|
||||
}
|
||||
}
|
||||
if ( ( element.type !='checkbox' ) && ( element.type !='radio' ) && ( inp_value === '' ) ) {
|
||||
opsd_show_error_message( element , opsd_global1.message_verif_requred);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
// Validation Check --- Email correct filling field
|
||||
if ( element.className.indexOf( 'opsd-validate-email' ) !== -1 ){
|
||||
var reg = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,})$/;
|
||||
if ( ( inp_value != '' ) && ( reg.test(inp_value) == false ) ) {
|
||||
opsd_show_error_message( element , opsd_global1.message_verif_email );
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
// Validation Check --- Same Email Field
|
||||
if ( ( element.className.indexOf('wpdev-validates-as-email') !== -1 ) && ( element.className.indexOf('same_as_') !== -1 ) ) {
|
||||
|
||||
// Get the name of Primary Email field from the "same_as_NAME" class
|
||||
var primary_email_name = element.className.match(/same_as_([^\s])+/gi);
|
||||
if (primary_email_name != null) { // We found
|
||||
primary_email_name = primary_email_name[0].substr(8);
|
||||
|
||||
// Recehck if such primary email field exist in the form
|
||||
if (jQuery('[name="' + primary_email_name + '"]').length > 0) {
|
||||
|
||||
// Recheck the values of the both emails, if they do not equla show warning
|
||||
if ( jQuery('[name="' + primary_email_name + '"]').val() !== inp_value ) {
|
||||
opsd_show_error_message( element , message_verif_same_emeil );return;
|
||||
}
|
||||
}
|
||||
}
|
||||
// Skip one loop for the email veryfication field
|
||||
continue;
|
||||
} */
|
||||
|
||||
/*
|
||||
// Get Form Data
|
||||
if ( element.name !== ('captcha_input' ) ) {
|
||||
if (formdata !=='') formdata += '~'; // next field element
|
||||
|
||||
el_type = element.type;
|
||||
if ( element.className.indexOf('wpdev-validates-as-email') !== -1 ) el_type='email';
|
||||
if ( element.className.indexOf('wpdev-validates-as-coupon') !== -1 ) el_type='coupon';
|
||||
|
||||
inp_value = inp_value + '';
|
||||
inp_value = inp_value.replace(new RegExp("\\^",'g'), '^'); // replace registered characters
|
||||
inp_value = inp_value.replace(new RegExp("~",'g'), '~'); // replace registered characters
|
||||
|
||||
inp_value = inp_value.replace(/"/g, '"'); // replace double quot
|
||||
inp_value = inp_value.replace(/'/g, '''); // replace single quot
|
||||
|
||||
formdata += el_type + '^' + element.name + '^' + inp_value ; // element attr
|
||||
} */
|
||||
}
|
||||
|
||||
} // End Fields Loop
|
||||
|
||||
|
||||
submit_form.submit(); // Submit Form, if previously was no interuptions
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Show message under specific element
|
||||
*
|
||||
* @param {type} element - jQuery definition of the element
|
||||
* @param {type} errorMessage - String message
|
||||
* @param {type} message_type "" | "alert-warning" | "alert-success" | "alert-info" | "alert-danger"
|
||||
*/
|
||||
function opsd_show_message_under_element( element , errorMessage , message_type) {
|
||||
|
||||
opsd_scroll_to( element );
|
||||
|
||||
if ( jQuery( element ).attr('type') == "radio" ) {
|
||||
jQuery( element ).parent().parent().parent()
|
||||
.after('<span class="opsd-near-field-message alert '+ message_type +'">'+ errorMessage +'</span>'); // Show message
|
||||
|
||||
} else if (jQuery( element ).attr('type') == "checkbox") {
|
||||
jQuery( element ).parent()
|
||||
.after('<span class="opsd-near-field-message alert '+ message_type +'">'+ errorMessage +'</span>'); // Show message
|
||||
|
||||
} else {
|
||||
jQuery( element )
|
||||
.after('<span class="opsd-near-field-message alert '+ message_type +'">'+ errorMessage +'</span>'); // Show message
|
||||
}
|
||||
jQuery(".widget_opsd .opsd-near-field-message")
|
||||
.css( {'vertical-align': 'sub' } ) ;
|
||||
jQuery(".opsd-near-field-message")
|
||||
.animate( {opacity: 1}, 10000 )
|
||||
.fadeOut( 2000 );
|
||||
}
|
||||
|
||||
|
||||
// Show Error Message in Form at Front End
|
||||
function opsd_show_error_message( element , errorMessage) {
|
||||
|
||||
// Scroll to the element
|
||||
opsd_scroll_to( element );
|
||||
|
||||
jQuery("[name='"+ element.name +"']")
|
||||
.fadeOut( 350 ).fadeIn( 300 )
|
||||
.fadeOut( 350 ).fadeIn( 400 )
|
||||
.fadeOut( 350 ).fadeIn( 300 )
|
||||
.fadeOut( 350 ).fadeIn( 400 )
|
||||
.animate( {opacity: 1}, 4000 )
|
||||
; // mark red border
|
||||
|
||||
if (jQuery("[name='"+ element.name +"']").attr('type') == "radio") {
|
||||
jQuery("[name='"+ element.name +"']").parent().parent()//.parent()
|
||||
.after('<span class="opsd-near-field-message alert alert-warning">'+ errorMessage +'</span>'); // Show message
|
||||
|
||||
} else if (jQuery("[name='"+ element.name +"']").attr('type') == "checkbox") {
|
||||
jQuery("[name='"+ element.name +"']").parent().parent()
|
||||
.after('<span class="opsd-near-field-message alert alert-warning">'+ errorMessage +'</span>'); // Show message
|
||||
|
||||
} else {
|
||||
jQuery("[name='"+ element.name +"']")
|
||||
.after('<span class="opsd-near-field-message alert alert-warning">'+ errorMessage +'</span>'); // Show message
|
||||
}
|
||||
jQuery(".opsd-near-field-message")
|
||||
.css( {'padding' : '5px 5px 4px', 'margin' : '2px', 'vertical-align': 'top', 'line-height': '32px' } );
|
||||
|
||||
if ( element.type == 'checkbox' )
|
||||
jQuery(".opsd-near-field-message").css( { 'vertical-align': 'middle'} );
|
||||
|
||||
jQuery(".widget_opsd .opsd-near-field-message")
|
||||
.css( {'vertical-align': 'sub' } ) ;
|
||||
jQuery(".opsd-near-field-message")
|
||||
.animate( {opacity: 1}, 10000 )
|
||||
.fadeOut( 2000 );
|
||||
element.focus(); // make focus to elemnt
|
||||
return;
|
||||
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Reload the page with new parameter value.
|
||||
*
|
||||
* @param {type} url - full URL of the page, can include or exclude that parameter
|
||||
* @param {type} param - URL parameter name
|
||||
* @param {type} value - URL parameter value
|
||||
* @returns {undefined}
|
||||
*/
|
||||
function opsd_reload_page_with_paramater( url, param, value ) {
|
||||
var hash = {};
|
||||
var parser = document.createElement('a');
|
||||
|
||||
parser.href = url;
|
||||
|
||||
var parameters = parser.search.split(/\?|&/);
|
||||
|
||||
for(var i=0; i < parameters.length; i++) {
|
||||
if(!parameters[i])
|
||||
continue;
|
||||
|
||||
var ary = parameters[i].split('=');
|
||||
hash[ary[0]] = ary[1];
|
||||
}
|
||||
|
||||
hash[param] = value;
|
||||
|
||||
var list = [];
|
||||
Object.keys(hash).forEach(function (key) {
|
||||
list.push(key + '=' + hash[key]);
|
||||
});
|
||||
|
||||
parser.search = '?' + list.join('&');
|
||||
//return parser.href;
|
||||
window.location.href = parser.href;
|
||||
}
|
||||
|
||||
jQuery( window ).on( "load", function (){ //FixIn: 8.7.9.7
|
||||
|
||||
// Color Text picker ///////////////////////////////////////////////////////
|
||||
if ( jQuery('.field-text-color').length > 0 ) {
|
||||
jQuery('.field-text-color').iris( {
|
||||
change: function(event, ui){
|
||||
jQuery(this).css( { backgroundColor: ui.color.toString() } );
|
||||
jQuery(this).closest('.fields-color-group').find('.fieldvalue').css( { color: ui.color.toString() } );
|
||||
}
|
||||
, hide: true
|
||||
, border: true
|
||||
, palettes: ['#333', '#555', '#777', '#aaa', '#fff']
|
||||
} ).each( function() {
|
||||
jQuery(this).css( { backgroundColor: jQuery(this).val() } );
|
||||
})
|
||||
.on( 'click', function(){
|
||||
jQuery('.iris-picker').hide();
|
||||
jQuery(this).closest('div').find('.iris-picker').show();
|
||||
});
|
||||
}
|
||||
// Color Background picker /////////////////////////////////////////////////
|
||||
if ( jQuery('.field-background-color').length > 0 ) {
|
||||
jQuery('.field-background-color').iris( {
|
||||
change: function(event, ui){
|
||||
jQuery(this).css( { backgroundColor: ui.color.toString() } );
|
||||
jQuery(this).closest('.fields-color-group').find('.fieldvalue').css( { backgroundColor: ui.color.toString() } );
|
||||
}
|
||||
, hide: true
|
||||
, border: true
|
||||
, palettes: [ '#FFEE99', '#459', '#78b', '#ab0', '#df5d5d', '#f0f']
|
||||
} ).each( function() {
|
||||
jQuery(this).css( { backgroundColor: jQuery(this).val() } );
|
||||
})
|
||||
.on( 'click', function(){
|
||||
jQuery('.iris-picker').hide();
|
||||
jQuery(this).closest('div').find('.iris-picker').show();
|
||||
});
|
||||
|
||||
jQuery('.field-text-color, .field-background-color').on( 'click', function(event){
|
||||
event.stopPropagation();
|
||||
});
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// General Color picker in settings table //////////////////////////////////
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
if ( jQuery('.opsd_colorpick').length > 0 ) {
|
||||
jQuery('.opsd_colorpick').iris( {
|
||||
change: function(event, ui){
|
||||
jQuery(this).css( { backgroundColor: ui.color.toString() } );
|
||||
}
|
||||
, hide: true
|
||||
, border: true
|
||||
, palettes: ['#125', '#459', '#78b', '#ab0', '#de3', '#f0f']
|
||||
} ).each( function() {
|
||||
jQuery(this).css( { backgroundColor: jQuery(this).val() } );
|
||||
})
|
||||
.on( 'click', function(){
|
||||
jQuery('.iris-picker').hide();
|
||||
jQuery(this).closest('td').find('.iris-picker').show();
|
||||
});
|
||||
|
||||
jQuery('body').on( 'click', function() {
|
||||
jQuery('.iris-picker').hide();
|
||||
});
|
||||
|
||||
jQuery('.opsd_colorpick').on( 'click', function(event){
|
||||
event.stopPropagation();
|
||||
});
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// Support Functions
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/**
|
||||
* Reset of WP Editor or TextArea Content
|
||||
* @param {string} editor_textarea_id - ID of element
|
||||
* @param {string} editor_textarea_content - Content
|
||||
*/
|
||||
function opsd_reset_wp_editor_content( editor_textarea_id, editor_textarea_content ) {
|
||||
if( typeof tinymce != "undefined" ) {
|
||||
var editor = tinymce.get( editor_textarea_id );
|
||||
if( editor && editor instanceof tinymce.Editor ) {
|
||||
editor.setContent( editor_textarea_content );
|
||||
editor.save( { no_events: true } );
|
||||
} else {
|
||||
jQuery( '#' + editor_textarea_id ).val( editor_textarea_content );
|
||||
}
|
||||
} else {
|
||||
jQuery( '#' + editor_textarea_id ).val( editor_textarea_content );
|
||||
}
|
||||
}
|
||||
57
wp-content/plugins/secure-downloads/core/any/js/dismiss.js
Normal file
57
wp-content/plugins/secure-downloads/core/any/js/dismiss.js
Normal file
@@ -0,0 +1,57 @@
|
||||
/**
|
||||
* @version 1.0
|
||||
* @desciption Dismiss Notices - Ajax handler
|
||||
* @usage Admin panel
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2017-04-23
|
||||
*/
|
||||
|
||||
/** Ajax Request - Dismiss */
|
||||
jQuery( function ( $ ) { // Shortcut to jQuery(document).ready(function(){ ... });
|
||||
|
||||
jQuery( '.opsd_is_dismissible' ).on( 'click', '.opsd_dismiss', function ( event ) { // This delegated event, can be run, when DOM element added after page loaded
|
||||
|
||||
var jq_el = jQuery( this ).closest( '.opsd_is_dismissible' ); // Get dismissible HTML element
|
||||
|
||||
var params_obj = {};
|
||||
params_obj.id = jq_el.attr( 'id' );
|
||||
params_obj.nonce = jq_el.attr( 'data-nonce' );
|
||||
params_obj.user_id = jq_el.attr( 'data-user-id' );
|
||||
|
||||
jQuery.post( opsd_ajaxurl, {
|
||||
action: 'OPSD_DISMISS',
|
||||
user_id: params_obj.user_id ,
|
||||
nonce: params_obj.nonce,
|
||||
element_id: params_obj.id,
|
||||
is_closed: 1
|
||||
},
|
||||
function ( response_data, textStatus, jqXHR ) { // success
|
||||
// console.log( response_data ); console.log( textStatus); console.log( jqXHR ); // Debug
|
||||
// jQuery( '#ajax_respond' ).html( response_data ); // For ability to show response, add such DIV element to page
|
||||
}
|
||||
).fail( function ( jqXHR, textStatus, errorThrown ) { if ( window.console && window.console.log ){ console.log( 'Ajax_Error', jqXHR, textStatus, errorThrown ); } })
|
||||
// .done( function ( data, textStatus, jqXHR ) { if ( window.console && window.console.log ){ console.log( 'second success', data, textStatus, jqXHR ); } })
|
||||
// .always( function ( data_jqXHR, textStatus, jqXHR_errorThrown ) { if ( window.console && window.console.log ){ console.log( 'always finished', data_jqXHR, textStatus, jqXHR_errorThrown ); } })
|
||||
;
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
|
||||
/* Hide */
|
||||
jQuery( function ( $ ) { // Shortcut to jQuery(document).ready(function(){ ... });
|
||||
|
||||
jQuery( '.opsd_is_hideable' ).on( 'click', '.opsd_dismiss', function ( event ) { // This delegated event, can be run, when DOM element added after page loaded
|
||||
|
||||
var jq_el = jQuery( this ).closest( '.opsd_is_hideable' ); // Get hideable HTML element
|
||||
|
||||
jq_el.hide();
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
@@ -0,0 +1,2 @@
|
||||
<?php
|
||||
// Silence is golden.
|
||||
@@ -0,0 +1,187 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @description Dismiss Class
|
||||
* @category Dismiss panels Class
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-11-13
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
/** Dismiss Class
|
||||
* @usage:
|
||||
*
|
||||
* Inline Setting Notice Dismiss'
|
||||
*
|
||||
$notice_id = 'opsd_upload_help_section';
|
||||
if ( ! opsd_section_is_dismissed( $notice_id ) ) {
|
||||
|
||||
?><div id="<?php echo $notice_id; ?>"
|
||||
class="opsd_system_notice opsd_is_dismissible opsd_is_hideable notice-warning opsd_internal_notice"
|
||||
data-nonce="<?php echo wp_create_nonce( $nonce_name = $notice_id . '_opsdnonce' ); ?>"
|
||||
data-user-id="<?php echo get_current_user_id(); ?>"
|
||||
><?php
|
||||
opsd_x_dismiss_button();
|
||||
....
|
||||
?></div><?php
|
||||
*
|
||||
* System Notice
|
||||
*
|
||||
$notice_id = 'opsd_system_notice_free_instead_paid';
|
||||
if ( ! opsd_section_is_dismissed( $notice_id ) ) {
|
||||
?><div id="<?php echo $notice_id; ?>"
|
||||
class="opsd_system_notice opsd_is_dismissible opsd_is_hideable updated notice-warning"
|
||||
data-nonce="<?php echo wp_create_nonce( $nonce_name = $notice_id . '_opsdnonce' ); ?>"
|
||||
data-user-id="<?php echo get_current_user_id(); ?>"
|
||||
><?php
|
||||
opsd_x_dismiss_button();
|
||||
...
|
||||
?></div><?php
|
||||
*
|
||||
*/
|
||||
final class OPSD_Dismiss {
|
||||
|
||||
static private $instance = NULL; // Define only one instance of this class
|
||||
|
||||
/** Get only one instance of this class
|
||||
*
|
||||
* @return class OPSD_Dismiss
|
||||
*/
|
||||
public static function init() {
|
||||
|
||||
if ( ! isset( self::$instance ) && ! ( self::$instance instanceof OPSD_Dismiss ) ) {
|
||||
|
||||
self::$instance = new OPSD_Dismiss;
|
||||
|
||||
// JS & CSS
|
||||
add_action( 'opsd_enqueue_js_files', array( self::$instance, 'opsd_js_load_files' ), 50 );
|
||||
add_action( 'opsd_enqueue_css_files', array( self::$instance, 'opsd_enqueue_css_files' ), 50 );
|
||||
|
||||
// Ajax Handlers. Note. "locale_for_ajax" recehcked in opsd-ajax.php
|
||||
add_action( 'wp_ajax_' . 'OPSD_DISMISS', array( self::$instance, 'opsd_ajax_' . 'OPSD_DISMISS' ) ); // Admin & Client (logged in usres)
|
||||
//add_action( 'wp_ajax_nopriv_' . 'OPSD_DISMISS', array( self::$instance, 'opsd_ajax_' . 'OPSD_DISMISS' ) ); // Client (not logged in)
|
||||
}
|
||||
|
||||
return self::$instance;
|
||||
}
|
||||
|
||||
|
||||
/** Ajax Handler
|
||||
* for request like:
|
||||
* action: 'OPSD_DISMISS',
|
||||
user_id: panel_obj.user_id ,
|
||||
nonce: panel_obj.nonce,
|
||||
element_id: panel_obj.id,
|
||||
is_closed: 1
|
||||
*
|
||||
*/
|
||||
public function opsd_ajax_OPSD_DISMISS() {
|
||||
|
||||
if ( ! isset( $_POST['element_id'] ) || empty( $_POST['element_id'] ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
$action_name = $_POST['element_id'] . '_opsdnonce';
|
||||
$nonce_post_key = 'nonce';
|
||||
|
||||
// Check Security
|
||||
$result = check_ajax_referer( $action_name, $nonce_post_key );
|
||||
|
||||
// Save status
|
||||
update_user_option( (int) $_POST[ 'user_id' ], 'opsd_win_' . esc_attr( $_POST[ 'element_id' ] ), (int) $_POST[ 'is_closed' ] );
|
||||
|
||||
// send JSON
|
||||
wp_send_json( array( 'response' => 'success' ) ); // Return JS OBJ: response_data = { response: "success" } in "dismiss.js"
|
||||
// This function call wp_die( '', '', array( 'response' => null, ) )
|
||||
}
|
||||
|
||||
|
||||
/** JSS */
|
||||
public function opsd_js_load_files( $where_to_load ) {
|
||||
|
||||
$in_footer = true;
|
||||
|
||||
if ( ( is_admin() ) && ( in_array( $where_to_load, array( 'admin', 'both' ) ) ) ) {
|
||||
|
||||
wp_enqueue_script( 'opsd-dismiss', opsd_plugin_url( '/core/any/js/dismiss.js' ), array( 'opsd-global-vars' ), '1.1', $in_footer );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/** CSS */
|
||||
public function opsd_enqueue_css_files( $where_to_load ) {
|
||||
|
||||
if ( ( is_admin() ) && ( in_array( $where_to_load, array( 'admin', 'both' ) ) ) ) {
|
||||
|
||||
wp_enqueue_style( 'opsd-dismiss', opsd_plugin_url( '/core/any/css/dismiss.css' ), array(), OPSD_VERSION_NUM );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/** Check if this section dismissed or not.
|
||||
*
|
||||
* @param string $section_html_id
|
||||
* @return boolean
|
||||
*/
|
||||
public function is_dismissed( $section_html_id ) {
|
||||
|
||||
if ( '1' == get_user_option( 'opsd_win_' . $section_html_id ) )
|
||||
return true;
|
||||
else
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
function opsd_dismiss() {
|
||||
return OPSD_Dismiss::init();
|
||||
}
|
||||
opsd_dismiss(); // Run
|
||||
|
||||
|
||||
/** Check if specific section dismissed or not
|
||||
*
|
||||
* @param type $section_html_id
|
||||
* @return boolean
|
||||
*/
|
||||
function opsd_section_is_dismissed( $section_html_id ) {
|
||||
|
||||
$opsd_dismiss = opsd_dismiss();
|
||||
|
||||
return $opsd_dismiss->is_dismissed( $section_html_id );
|
||||
}
|
||||
|
||||
|
||||
/** Show dismiss X button
|
||||
*
|
||||
* @param string $title
|
||||
* @param array $attributes_arr - array of attributes, like: array( 'class' => 'opsd_dismiss' )
|
||||
* @param bool $echo
|
||||
* @return string of dismiss button
|
||||
*/
|
||||
function opsd_x_dismiss_button( $title = '×', $attributes_arr = array(), $echo = true ) {
|
||||
|
||||
$defaults = array(
|
||||
'style' => ''
|
||||
, 'class' => 'opsd_dismiss'
|
||||
, 'title' => esc_js( __( 'Close', 'secure-downloads' ) )
|
||||
);
|
||||
$attributes_arr = wp_parse_args( $attributes_arr, $defaults );
|
||||
|
||||
$attr_echo = array();
|
||||
foreach ( $attributes_arr as $attr_name => $attr_value ) {
|
||||
$attr_echo[] = esc_attr( $attr_name ) . '="' . esc_attr( $attr_value ) . '"';
|
||||
}
|
||||
$attr_echo = implode( ' ', $attr_echo );
|
||||
|
||||
if ( ! $echo ) { ob_start(); }
|
||||
|
||||
?><a href="javascript:void(0)" <?php echo $attr_echo; ?> ><?php echo $title; ?></a><?php
|
||||
|
||||
if ( ! $echo ) { return ob_get_clean(); }
|
||||
}
|
||||
@@ -0,0 +1,385 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @description Notices Class
|
||||
* @category Show system Notices
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-11-13
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
/** Showing our system notices in admin panel */
|
||||
class OPSD_Notices {
|
||||
|
||||
|
||||
function __construct() {
|
||||
|
||||
// Hooks for showing notices only at specific admin pages
|
||||
add_action( 'opsd_hook_opsd_page_header', array( $this, 'show_system_notices' ) );
|
||||
add_action( 'opsd_settings_after_header', array( $this, 'show_system_notices' ) );
|
||||
}
|
||||
|
||||
|
||||
/** Check and show some system messages
|
||||
*
|
||||
* @param array $page_arr array( 'page' => $this->in_page() ) || array( 'page' => $this->in_page(), 'subpage' => 'emails_settings' )
|
||||
*/
|
||||
public function show_system_notices( $page_arr ) {
|
||||
|
||||
if ( ! in_array( $page_arr, array( 'opsd-files', 'opsd', 'opsd-settings' ) ) )
|
||||
return false;
|
||||
|
||||
///////////////////////////////////////////////////////////
|
||||
$notice_id = 'opsd_system_notice_nginix';
|
||||
///////////////////////////////////////////////////////////
|
||||
if ( ( isset( $_SERVER[ 'SERVER_SOFTWARE' ] ) )
|
||||
&& ( stristr( $_SERVER[ 'SERVER_SOFTWARE' ], 'nginx' ) !== false )
|
||||
&& ( ! opsd_section_is_dismissed( $notice_id ) )
|
||||
//|| true
|
||||
) {
|
||||
// Rules for NGINX
|
||||
$opsd_upload = opsd_upload();
|
||||
$upload_path = $opsd_upload->get_protected_dir();
|
||||
if ( isset( $_SERVER[ 'DOCUMENT_ROOT' ] ) )
|
||||
$upload_path = str_replace( $_SERVER[ 'DOCUMENT_ROOT' ], '', $upload_path ); // replace document root because nginx uses path from document root
|
||||
$nx_rules = "location " . $upload_path . " {\n deny all; \n return 403;\n}";
|
||||
|
||||
// echo '<div class="error notice is-dismissible dlm-notice" id="nginx_rules" data-nonce="' . wp_create_nonce( 'opsd_dismiss_notice-nginx_rules' ) . '">';
|
||||
?><div id="<?php echo $notice_id; ?>"
|
||||
class="opsd_system_notice opsd_is_dismissible opsd_is_hideable updated error"
|
||||
data-nonce="<?php echo wp_create_nonce( $nonce_name = $notice_id . '_opsdnonce' ); ?>"
|
||||
data-user-id="<?php echo get_current_user_id(); ?>"
|
||||
><?php
|
||||
|
||||
opsd_x_dismiss_button();
|
||||
|
||||
echo '<strong>' . __( 'Warning!', 'secure-downloads' ) . '</strong> ';
|
||||
printf( __( 'Your download files are not protected with .htaccess file, because your server is running on NGINX. To protect these files, you must add the following rules to your nginx config to disable direct file access: %s', 'secure-downloads' )
|
||||
, '<br/><pre style="line-height: 1.55em;pre-wrap;"><code>' . $nx_rules . '</code></pre>' );
|
||||
//FixIn:1.1.1
|
||||
printf( __( 'By default the file is named %s and placed in the %s directory. (For the open source NGINX product, the location depends on the package system used to install NGINX and the operating system. It is typically one of %s)', 'secure-downloads' )
|
||||
, '<code>nginx.conf</code>'
|
||||
, '<code>/etc/nginx</code>'
|
||||
, '<code>/usr/local/nginx/conf</code>, <code>/etc/nginx</code>, <code>/usr/local/etc/nginx</code>.'
|
||||
);
|
||||
echo ' ';
|
||||
printf( __( 'Please contact your server administrator or support of hosting company about more details of your server configuration.', 'secure-downloads' ) );
|
||||
?></div><?php
|
||||
} else {
|
||||
|
||||
//FixIn:1.1.1
|
||||
$notice_id = 'opsd_system_notice_nginix_recheck';
|
||||
if ( ! opsd_section_is_dismissed( $notice_id ) ) {
|
||||
|
||||
// // Rules for NGINX
|
||||
// $opsd_upload = opsd_upload();
|
||||
// $upload_path = $opsd_upload->get_protected_dir();
|
||||
// if ( isset( $_SERVER[ 'DOCUMENT_ROOT' ] ) )
|
||||
// $upload_path = str_replace( $_SERVER[ 'DOCUMENT_ROOT' ], '', $upload_path ); // replace document root because nginx uses path from document root
|
||||
// $nx_rules = "location " . $upload_path . " {\n deny all; \n return 403;\n}";
|
||||
|
||||
|
||||
// echo '<div class="error notice is-dismissible dlm-notice" id="nginx_rules" data-nonce="' . wp_create_nonce( 'opsd_dismiss_notice-nginx_rules' ) . '">';
|
||||
?><div id="<?php echo $notice_id; ?>"
|
||||
class="opsd_system_notice opsd_is_dismissible opsd_is_hideable updated notice-warning"
|
||||
data-nonce="<?php echo wp_create_nonce( $nonce_name = $notice_id . '_opsdnonce' ); ?>"
|
||||
data-user-id="<?php echo get_current_user_id(); ?>"
|
||||
><?php
|
||||
|
||||
opsd_x_dismiss_button();
|
||||
|
||||
//FixIn: 1.1.2.6
|
||||
// Rules for NGINX
|
||||
$opsd_upload = opsd_upload();
|
||||
$upload_path2 = $opsd_upload->get_protected_dir();
|
||||
if ( isset( $_SERVER[ 'DOCUMENT_ROOT' ] ) )
|
||||
$upload_path2 = str_replace( $_SERVER[ 'DOCUMENT_ROOT' ], '', $upload_path2 ); // replace document root because nginx uses path from document root
|
||||
$nx_rules = "location " . $upload_path2 . " {\n deny all; \n return 403;\n}";
|
||||
|
||||
|
||||
echo '<strong>' . __( 'Note!', 'secure-downloads' ) . '</strong> ';
|
||||
printf( __( 'If your server is running on NGINX or your server use NGINX as proxy server for managing static content like images or zip files, then some or all your download files are not protected with .htaccess file.', 'secure-downloads' )
|
||||
, '<br/><pre style="line-height: 1.55em;pre-wrap;"><code>' . $nx_rules . '</code></pre>' );
|
||||
echo ' <br/>';
|
||||
printf( __( 'Please contact your server administrator or support of hosting company about more details of your server configuration.', 'secure-downloads' ) );
|
||||
?></div><?php
|
||||
|
||||
}
|
||||
}
|
||||
///////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////
|
||||
$notice_id = 'opsd_system_notice_free_instead_paid';
|
||||
///////////////////////////////////////////////////////////
|
||||
if ( opsd_is_updated_paid_to_free()
|
||||
&& ( ! opsd_section_is_dismissed( $notice_id ) )
|
||||
// || true
|
||||
) {
|
||||
|
||||
?><div id="<?php echo $notice_id; ?>"
|
||||
class="opsd_system_notice opsd_is_dismissible opsd_is_hideable updated notice-warning"
|
||||
data-nonce="<?php echo wp_create_nonce( $nonce_name = $notice_id . '_opsdnonce' ); ?>"
|
||||
data-user-id="<?php echo get_current_user_id(); ?>"
|
||||
><?php
|
||||
|
||||
opsd_x_dismiss_button();
|
||||
|
||||
echo '<strong>' . __( 'Warning!', 'secure-downloads' ) . '</strong> ';
|
||||
printf( __( 'Probabaly you updated your paid version of Secure Downloads by free version or update process failed. You can request the new update of your paid version at %1sthis page%2s.', 'secure-downloads' )
|
||||
, '<a href="https://oplugins.com/plugins/secure-downloads/request-update/" target="_blank">', '</a>' );
|
||||
|
||||
?></div><?php
|
||||
}
|
||||
///////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////
|
||||
$notice_id = 'opsd-panel-get-started';
|
||||
///////////////////////////////////////////////////////////
|
||||
|
||||
if ( ! opsd_section_is_dismissed( $notice_id ) ) {
|
||||
?>
|
||||
<style type="text/css" media="screen">
|
||||
/* OPSD Welcome Panel */
|
||||
.opsd-panel .welcome-panel {
|
||||
background: linear-gradient(to top, #F5F5F5, #FAFAFA) repeat scroll 0 0 #F5F5F5;
|
||||
border-color: #DFDFDF;
|
||||
position: relative;
|
||||
overflow: auto;
|
||||
margin: 5px 0 20px;
|
||||
padding: 23px 10px 12px;
|
||||
border-width: 1px;
|
||||
border-style: solid;
|
||||
border-radius: 3px;
|
||||
font-size: 13px;
|
||||
line-height: 2.1em;
|
||||
}
|
||||
.opsd-panel .welcome-panel h3 {
|
||||
margin: 0;
|
||||
font-size: 21px;
|
||||
font-weight: 400;
|
||||
line-height: 1.2;
|
||||
}
|
||||
.opsd-panel .welcome-panel h4 {
|
||||
margin: 1.33em 0 0;
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
}
|
||||
.opsd-panel .welcome-panel a{
|
||||
color:#21759B;
|
||||
}
|
||||
.opsd-panel .welcome-panel .about-description {
|
||||
font-size: 16px;
|
||||
margin: 0;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-panel-close {
|
||||
position: absolute;
|
||||
top: 5px;
|
||||
right: 10px;
|
||||
padding: 8px 3px;
|
||||
font-size: 13px;
|
||||
text-decoration: none;
|
||||
line-height: 1;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-panel-close:before {
|
||||
content: ' ';
|
||||
position: absolute;
|
||||
left: -12px;
|
||||
width: 10px;
|
||||
height: 100%;
|
||||
background: url('../wp-admin/images/xit.gif') 0 7% no-repeat;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-panel-close:hover:before {
|
||||
background-position: 100% 7%;
|
||||
}
|
||||
.opsd-panel .welcome-panel .button.button-hero {
|
||||
margin: 15px 0 3px;
|
||||
}
|
||||
.opsd-panel .welcome-panel-content {
|
||||
margin-left: 13px;
|
||||
max-width: 1500px;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-panel-column-container {
|
||||
clear: both;
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-panel-column {
|
||||
width: 32%;
|
||||
min-width: 200px;
|
||||
float: left;
|
||||
}
|
||||
.ie8 .opsd-panel .welcome-panel .welcome-panel-column {
|
||||
min-width: 230px;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-panel-column:first-child {
|
||||
width: 36%;
|
||||
}
|
||||
.opsd-panel .welcome-panel-column p {
|
||||
margin-top: 7px;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-icon {
|
||||
background: none;
|
||||
display: block;
|
||||
padding: 2px 0 8px 2px;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-add-page {
|
||||
background-position: 0 2px;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-edit-page {
|
||||
background-position: 0 -90px;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-learn-more {
|
||||
background-position: 0 -136px;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-comments {
|
||||
background-position: 0 -182px;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-view-site {
|
||||
background-position: 0 -274px;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-widgets-menus {
|
||||
background-position: 1px -229px;
|
||||
line-height: 14px;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-write-blog {
|
||||
background-position: 0 -44px;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-panel-column ul {
|
||||
margin: 0.8em 1em 1em 0;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-panel-column li {
|
||||
line-height: 1.7em;
|
||||
list-style-type: none;
|
||||
margin:0;
|
||||
padding:0;
|
||||
}
|
||||
@media screen and (max-width: 870px) {
|
||||
.opsd-panel .welcome-panel .welcome-panel-column,
|
||||
.opsd-panel .welcome-panel .welcome-panel-column:first-child {
|
||||
display: block;
|
||||
float: none;
|
||||
width: 100%;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-panel-column li {
|
||||
display: inline-block;
|
||||
margin-right: 13px;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-panel-column ul {
|
||||
margin: 0.4em 0 0;
|
||||
}
|
||||
.opsd-panel .welcome-panel .welcome-icon {
|
||||
padding-left: 25px;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
<div id="<?php echo $notice_id ?>"
|
||||
class="opsd-panel opsd_is_dismissible opsd_is_hideable "
|
||||
data-nonce="<?php echo wp_create_nonce( $nonce_name = $notice_id . '_opsdnonce' ); ?>"
|
||||
data-user-id="<?php echo get_current_user_id(); ?>"
|
||||
|
||||
><div class="welcome-panel"><?php
|
||||
|
||||
opsd_x_dismiss_button( '×', array( 'style' => 'font-size:1.5em;margin-top:-0.8em;' ) );
|
||||
|
||||
?>
|
||||
<div class="welcome-panel-content">
|
||||
<p class="about-description"><?php _e( 'We’ve assembled some links to get you started:', 'secure-downloads'); ?></p>
|
||||
<div class="welcome-panel-column-container">
|
||||
<div class="welcome-panel-column">
|
||||
<h4><?php _e( 'Upload your files to secure direcory', 'secure-downloads'); ?>:</h4>
|
||||
<ul>
|
||||
<li><div class="welcome-icon"><?php
|
||||
printf( __( 'Open %s menu page', 'secure-downloads')
|
||||
, '<a href="' . admin_url( 'admin.php?page=opsd-files' ) . '">'
|
||||
. '<strong>' . 'Secure Downloads > ' . __( 'Files', 'secure-downloads' ) . '</strong>'
|
||||
. '</a>'
|
||||
);
|
||||
?></div></li>
|
||||
<li><div class="welcome-icon"><?php
|
||||
echo '1. ' . sprintf( __( 'Click on %s"Add New"%s button and upload your files.', 'secure-downloads' ), '<strong>', '</strong>' );
|
||||
?></div></li>
|
||||
<li><div class="welcome-icon"><?php
|
||||
echo '2. ' . sprintf( __( 'Enter Title, Version Number and Description at %s"Attachment details"%s section.', 'secure-downloads' ), '<strong>', '</strong>' );
|
||||
?></div></li>
|
||||
<li><div class="welcome-icon"><?php
|
||||
echo '3. ' . sprintf( __( 'Select one or multiple files, click insert button and Save changes.', 'secure-downloads' ) );
|
||||
|
||||
?></div></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="welcome-panel-column">
|
||||
<h4><?php _e( 'Next Steps', 'secure-downloads'); ?>.</h4>
|
||||
<ul>
|
||||
<li><div class="welcome-icon"><?php
|
||||
printf( __( 'Open %s menu page and %s send predefined email with secure link %s to your customer or simply %s generate secure link %s', 'secure-downloads')
|
||||
, '<a href="' . admin_url( 'admin.php?page=opsd' ) . '">'
|
||||
. '<strong>' . __( 'Secure Links', 'secure-downloads' ) . '</strong>'
|
||||
. '</a>'
|
||||
, '<strong>', '</strong>'
|
||||
, '<strong>', '</strong>.'
|
||||
);
|
||||
?></div></li>
|
||||
<li><div class="welcome-icon"><?php
|
||||
printf( __( 'Configure different options in %sSettings%s.' , 'secure-downloads'),
|
||||
'<a href="' . esc_url( opsd_get_settings_url() ) . '">', '</a>' );
|
||||
?></div></li>
|
||||
<li><div class="welcome-icon"><?php
|
||||
printf( __( 'Configure your predefined %sEmail Templates%s.', 'secure-downloads'),
|
||||
'<a href="' . esc_url( opsd_get_settings_url() . '&tab=email' ) . '">', '</a>' );
|
||||
?></div></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="welcome-panel-column welcome-panel-last">
|
||||
<h4><?php _e( 'Tips', 'secure-downloads'); ?></h4>
|
||||
<ul>
|
||||
<li><div class="welcome-icon"><?php
|
||||
printf( __( 'You can easy reorder files list at %s page.', 'secure-downloads')
|
||||
, '<a href="' . admin_url( 'admin.php?page=opsd-files&tab=files-sortable' ) . '">'
|
||||
. '<strong>' . __( 'Sortable List', 'secure-downloads' ) . '</strong>'
|
||||
. '</a>'
|
||||
);
|
||||
?></div></li>
|
||||
<li><div class="welcome-icon"><?php
|
||||
echo '<strong>' . __( 'Note', 'secure-downloads' ) . '</strong>. '
|
||||
. __( 'You can use line with simple text without CSV separators for definition of sections in file list.', 'secure-downloads')
|
||||
;
|
||||
?></div></li>
|
||||
|
||||
<li><div class="welcome-icon"><?php
|
||||
printf( __( 'Still having questions? Contact %sSupport%s.', 'secure-downloads'),
|
||||
'<a href="https://oplugins.com/support/" target="_blank">',
|
||||
'</a>' );
|
||||
?></div></li>
|
||||
<li><div class="welcome-icon"><?php
|
||||
printf( __( 'Do you require new feature? Send your %ssuggestion%s to us.', 'secure-downloads'),
|
||||
'<a href="mailto:newfeature@oplugins.com?Subject=Secure%20Downloads" target="_blank">',
|
||||
'</a>' );
|
||||
?></div></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="welcome-icon welcome-widgets-menus" style="text-align:right;font-style:italic;"><?php
|
||||
printf( __( 'Need even more functionality? Check %s higher versions %s', 'secure-downloads'),
|
||||
'<a href="https://oplugins.com/plugins/secure-downloads/#premium" target="_blank">',
|
||||
'</a>'
|
||||
); ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php
|
||||
|
||||
|
||||
?></div></div><?php
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
new OPSD_Notices(); // Run
|
||||
2
wp-content/plugins/secure-downloads/core/index.php
Normal file
2
wp-content/plugins/secure-downloads/core/index.php
Normal file
@@ -0,0 +1,2 @@
|
||||
<?php
|
||||
// Silence is golden.
|
||||
268
wp-content/plugins/secure-downloads/core/opsd-activation.php
Normal file
268
wp-content/plugins/secure-downloads/core/opsd-activation.php
Normal file
@@ -0,0 +1,268 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @subpackage Activation / Deactivation
|
||||
* @category Functions
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
* @modified 2016-03-17
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
/** Activation & Deactivation of Secure Downloads */
|
||||
class OPSD_ItemInstall extends OPSD_Install {
|
||||
|
||||
/** Overload Secure Downloads option names and some other parameters */
|
||||
public function get_init_option_names() {
|
||||
|
||||
add_opsd_action( 'opsd_activate_user', array( $this, 'opsd_activate') ); // Hook for MU User activation
|
||||
|
||||
return array(
|
||||
'option-version_num' => 'opsd_version_num'
|
||||
, 'option-is_delete_if_deactive' => 'opsd_is_delete_if_deactive'
|
||||
, 'option-activation_process' => 'opsd_activation_process'
|
||||
, 'transient-opsd_activation_redirect' => '_opsd_activation_redirect'
|
||||
, 'message-delete_data' => '<strong>' . __('Warning!', 'secure-downloads') . '</strong> '
|
||||
. __('All plugin data will be deleted when the plugin is deactivated.', 'secure-downloads')
|
||||
. '<br />'
|
||||
. sprintf( __('If you want to save your plugin data, please uncheck the %s"Delete data"%s at the' , 'secure-downloads')
|
||||
, '<strong>', '</strong>')
|
||||
. '<a href="' . esc_url( admin_url( add_query_arg( array( 'page' => 'opsd-settings' ), 'admin.php' ) ) )
|
||||
. '#opsd_general_settings_uninstall_metabox"> ' . __('settings page', 'secure-downloads') . '.'
|
||||
. ' </a>'
|
||||
, 'link_settings' => '<a href="' . esc_url( admin_url( add_query_arg( array( 'page' => 'opsd-settings' ), 'admin.php' ) ) )
|
||||
. '">'.__("Settings", 'secure-downloads').'</a>'
|
||||
, 'link_whats_new' => ''
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
/** Check if was updated from lower to high version */
|
||||
public function is_update_from_lower_to_high_version() {
|
||||
|
||||
$is_make_activation = false;
|
||||
|
||||
// Check conditions for different version about Upgrade
|
||||
if ( ( class_exists( 'opsd_personal' ) ) && ( ! opsd_is_table_exists( 'itemtypes' ) ) )
|
||||
$is_make_activation = true;
|
||||
|
||||
return $is_make_activation;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// A c t i v a t e & D e a c t i v a t e
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/** Activation */
|
||||
function opsd_activate() {
|
||||
|
||||
// Check for blank data install
|
||||
$opsd_secret_key = get_opsd_option( 'opsd_secret_key' );
|
||||
if ( empty( $opsd_secret_key ) )
|
||||
$is_first_time_install = true;
|
||||
else
|
||||
$is_first_time_install = false;
|
||||
|
||||
|
||||
make_opsd_action( 'opsd_before_activation' );
|
||||
|
||||
opsd_load_translation();
|
||||
|
||||
$version = get_opsd_version();
|
||||
$is_demo = opsd_is_this_demo();
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// Options
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
$default_options_to_add = opsd_get_default_options();
|
||||
|
||||
|
||||
foreach ( $default_options_to_add as $default_option_name => $default_option_value ) {
|
||||
|
||||
add_opsd_option( $default_option_name, $default_option_value );
|
||||
}
|
||||
|
||||
// Check for blank data install
|
||||
if ( $is_first_time_install )
|
||||
opsd_create_blank_files();
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// DB Tables
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// Other versions Activation
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
make_opsd_action( 'opsd_other_versions_activation' );
|
||||
|
||||
make_opsd_action( 'opsd_after_activation' );
|
||||
}
|
||||
add_opsd_action( 'opsd_activation', 'opsd_activate' );
|
||||
|
||||
|
||||
|
||||
// Deactivate
|
||||
function opsd_deactivate() {
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// Options
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
$default_options_to_add = opsd_get_default_options();
|
||||
foreach ( $default_options_to_add as $default_option_name => $default_option_value) {
|
||||
|
||||
delete_opsd_option( $default_option_name );
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// Widgets
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
delete_opsd_option( 'opsd_activation_redirect_for_version' );
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// DB Tables
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
global $wpdb;
|
||||
// $wpdb->query( "DROP TABLE IF EXISTS {$wpdb->prefix}opsd" );
|
||||
|
||||
// Delete all users item windows states
|
||||
if ( false === $wpdb->query( "DELETE FROM {$wpdb->usermeta} WHERE meta_key LIKE '%opsd_%'" ) ){ // All users data
|
||||
debuge_error('Error during deleting user meta at DB',__FILE__,__LINE__);
|
||||
die();
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// Other versions Deactivation
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
make_opsd_action('opsd_other_versions_deactivation');
|
||||
}
|
||||
add_opsd_action( 'opsd_deactivation', 'opsd_deactivate' );
|
||||
|
||||
|
||||
/** Default Options
|
||||
*
|
||||
* $option_name = '';
|
||||
* $options_for_delete = opsd_get_default_options( $option_name, $is_get_multiuser_general_options );
|
||||
*/
|
||||
function opsd_get_default_options( $option_name = '' ) {
|
||||
|
||||
$is_demo = opsd_is_this_demo();
|
||||
|
||||
$default_options = array();
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// General Settings
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
$default_options[ 'opsd_download_url_path' ] = '';
|
||||
$default_options[ 'opsd_protected_directory_name_level1' ] = 'opsd_' . wp_generate_password( 20, false, false );
|
||||
$default_options[ 'opsd_secret_key' ] = wp_generate_password( 30, false, false );
|
||||
$default_options[ 'opsd_defualt_expiration' ] = '+24 hours';
|
||||
$default_options[ 'opsd_defualt_iplock' ] = '';
|
||||
// URLs
|
||||
$default_options[ 'opsd_url_wrong_hash' ] = '';
|
||||
$default_options[ 'opsd_url_download_expired' ] = '';
|
||||
$default_options[ 'opsd_url_ip_not_valied' ] = '';
|
||||
$default_options[ 'opsd_url_file_not_exist' ] = '';
|
||||
$default_options[ 'opsd_url_error_opening_file' ] = '';
|
||||
// Miscellaneous
|
||||
$default_options[ 'opsd_csv_separator' ] = ',';
|
||||
$default_options[ 'opsd_date_format' ] = get_option( 'date_format' );
|
||||
$default_options[ 'opsd_time_format' ] = get_option( 'time_format' );
|
||||
// Advanced
|
||||
$default_options[ 'opsd_is_not_load_bs_script_in_admin' ] = 'Off';
|
||||
/**
|
||||
$default_options[ 'opsd_is_not_load_bs_script_in_client' ] = 'Off';
|
||||
$default_options[ 'opsd_is_load_js_css_on_specific_pages' ] = 'Off';
|
||||
$default_options[ 'opsd_pages_for_load_js_css' ] = '';
|
||||
*/
|
||||
// User permissions
|
||||
$default_options[ 'opsd_user_role_master' ] = ( $is_demo ) ? 'subscriber' : 'editor';
|
||||
$default_options[ 'opsd_user_role_addnew' ] = ( $is_demo ) ? 'subscriber' : 'editor';
|
||||
$default_options[ 'opsd_user_role_settings' ] = ( $is_demo ) ? 'subscriber' : 'editor';
|
||||
// Position
|
||||
$default_options[ 'opsd_menu_position' ] = ( $is_demo ) ? 'top' : 'top';
|
||||
// Uninstall
|
||||
$default_options[ 'opsd_is_delete_if_deactive' ] = ($is_demo) ? 'On' : 'Off';
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// Emails
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
$user_info = array( 'name' => '' );
|
||||
if ( is_user_logged_in() ) {
|
||||
$user_data = get_userdata( get_current_user_id() );
|
||||
$user_info['name'] = ( $user_data ) ? $user_data->display_name : '';
|
||||
}
|
||||
|
||||
$email_settings = array();
|
||||
$email_settings['enabled'] = 'On';
|
||||
$email_settings['copy_to_admin'] = 'On';
|
||||
$email_settings['from'] = get_option( 'admin_email' );
|
||||
$email_settings['from_name'] = $user_info['name'];
|
||||
$email_settings['subject'] = sprintf( __( 'Delivery of %s', 'secure-downloads'), '[product_title] [product_version]' );
|
||||
$email_settings['content'] = sprintf( __( 'Hello. %sThank you for requesting %s To download %s click the link below: %s Thank you, %s', 'secure-downloads' )
|
||||
, '<br/>'
|
||||
, '[product_title] [product_version]<br/><br/>'
|
||||
, '<strong>[product_description]</strong>'
|
||||
, '<br/> --- <br/> [product_summary] - [product_expire_date] <br/> --- <br/> <br/> '
|
||||
, '[siteurl]<br/> [current_date] [current_time]' );
|
||||
$email_settings['header_content'] = '';
|
||||
$email_settings['footer_content'] = '';
|
||||
$email_settings['template_file'] = 'plain';
|
||||
$email_settings['base_color'] = '#557da1';
|
||||
$email_settings['background_color'] = '#f5f5f5';
|
||||
$email_settings['body_color'] = '#fdfdfd';
|
||||
$email_settings['text_color'] = '#505050';
|
||||
$email_settings['email_content_type'] = 'html';
|
||||
$default_options[ 'opsd_email_link_user' ] = $email_settings;
|
||||
|
||||
// Just modify some params in previos email
|
||||
$email_settings[ 'to' ] = $email_settings['from'];
|
||||
$email_settings[ 'to_name' ] = $email_settings['from_name'];
|
||||
$email_settings['subject'] = sprintf( __( 'Download notification of %s', 'secure-downloads'), '[product_title] [ [product_id] ]' );
|
||||
$email_settings['content'] = sprintf( __( 'Hi. %s The %s have been downloaded. %s ===== User Info ===== %s To: %s IP: %s User agent: %s Request url: %s ====================== %s ===== Product Summary ===== %s Expire at %s ====================== %s', 'secure-downloads' )
|
||||
, '<br/><br/>'
|
||||
, '<strong>[product_title] [product_version]</strong> [ID=[product_id]]'
|
||||
, '<br/><br/>'
|
||||
, '<br/>'
|
||||
, '[link_sent_to]' . '<br/>'
|
||||
, '[remote_ip]' . '<br/>'
|
||||
, '[user_agent]' . '<br/>'
|
||||
, '[request_url]' . '<br/>'
|
||||
, '<br/><br/>'
|
||||
, '<br/>[product_summary] <br/>[product_description] <br/>'
|
||||
, '<strong>[product_expire_date]</strong> '. '<br/>'
|
||||
, '<br/> <br/><strong>[current_date] [current_time]</strong>'
|
||||
);
|
||||
$default_options[ 'opsd_email_download_notification' ] = $email_settings;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// C S V P R O D U C T S - F I L E S
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
$default_options[ 'opsd_products_csv' ] = '';
|
||||
|
||||
|
||||
if ( ! empty( $option_name ) ) {
|
||||
|
||||
if ( isset( $default_options[ $option_name ] ) )
|
||||
return $default_options[ $option_name ]; // Return 1 option
|
||||
else
|
||||
return false; // Option does NOT exist
|
||||
|
||||
} else {
|
||||
return $default_options; // Return ALL
|
||||
}
|
||||
}
|
||||
151
wp-content/plugins/secure-downloads/core/opsd-ajax.php
Normal file
151
wp-content/plugins/secure-downloads/core/opsd-ajax.php
Normal file
@@ -0,0 +1,151 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @subpackage Ajax Responder
|
||||
* @category Items
|
||||
*
|
||||
* @author wpdevelop
|
||||
* @link https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2014.05.26
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// S u p p o r t f u n c t i o n s f o r A j a x ///////////////
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
// Verify the nonce.
|
||||
function opsd_check_nonce_in_admin_panel( $action_check = 'opsd_ajax_admin_nonce' ){
|
||||
|
||||
$nonce = ( isset($_REQUEST['opsd_nonce']) ) ? $_REQUEST['opsd_nonce'] : '';
|
||||
|
||||
if ( '' === $nonce ) return false; // Its was request from some other plugin //FixIn: 1.1.4.1
|
||||
|
||||
if ( ! wp_verify_nonce( $nonce, $action_check ) ) { // This nonce is not valid.
|
||||
?>
|
||||
<script type="text/javascript">
|
||||
jQuery("#ajax_respond").after( "<div class='wpdevelop'><div class='alert alert-warning alert-danger'><?php
|
||||
printf(__('%sError!%s Request do not pass security check! Please refresh the page and try one more time.' , 'secure-downloads'),'<strong>','</strong>');
|
||||
?></div></div>" );
|
||||
if ( jQuery("#ajax_message").length )
|
||||
jQuery("#ajax_message").slideUp();
|
||||
</script>
|
||||
<?php
|
||||
die;
|
||||
}
|
||||
return true; //FixIn: 1.1.4.1
|
||||
}
|
||||
|
||||
|
||||
// Check and (re)Load specific Locale for the Ajax request - based on "admin_init" hook
|
||||
function opsd_check_locale_for_ajax() {
|
||||
|
||||
add_opsd_filter('opsd_check_for_active_language', 'opsd_check_for_active_language'); // Add Hook for ability to check the content for active lanaguges
|
||||
|
||||
if (isset($_POST['opsd_active_locale'])) { // Reload locale according request parameter
|
||||
global $l10n;
|
||||
if (isset($l10n['secure-downloads'])) unset($l10n['secure-downloads']);
|
||||
|
||||
if(! defined('OPSD_RELOAD') ) define('OPSD_RELOAD', esc_js( $_POST['opsd_active_locale'] ) );
|
||||
|
||||
// Reload locale settings, its required for the correct dates format
|
||||
if (isset($l10n['default'])) unset($l10n['default']); // Unload locale
|
||||
add_filter('locale', 'opsd_get_locale',999); // Set filter to load the locale of the Secure Downloads
|
||||
load_default_textdomain(); // Load default locale
|
||||
global $wp_locale;
|
||||
$wp_locale = new WP_Locale(); // Reload class
|
||||
|
||||
opsd_load_locale(OPSD_RELOAD);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// A j a x H o o k s f o r s p e c i f i c A c t i o n s /////
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
function opsd_ajax_USER_SAVE_WINDOW_STATE() {
|
||||
|
||||
// if ( ! opsd_check_nonce_in_admin_panel() ) return false; //FixIn: 1.1.4.1
|
||||
// update_user_option($_POST['user_id'],'opsd_win_' . $_POST['window'] ,$_POST['is_closed']);
|
||||
|
||||
if ( ! opsd_check_nonce_in_admin_panel() ) return false; //FixIn: 1.1.4.1
|
||||
update_user_option( (int) $_POST['user_id'], 'opsd_win_' . esc_attr( $_POST['window'] ) , (int) $_POST['is_closed'] );
|
||||
|
||||
}
|
||||
|
||||
|
||||
/** Save Custom User Data */
|
||||
function opsd_ajax_USER_SAVE_CUSTOM_DATA() {
|
||||
|
||||
if ( ! opsd_check_nonce_in_admin_panel() ) return false; //FixIn: 1.1.4.1
|
||||
/* Exmaple of $_POST:
|
||||
[data_name] => add_opsd_calendar_options
|
||||
[data_value] => calendar_months_count=1&calendar_months_num_in_1_row=1&calendar_width=500px&calendar_cell_height
|
||||
*/
|
||||
$post_param = explode( '&', $_POST['data_value'] ); // "&" was set by jQuery.param( data_params ) in client side.
|
||||
$data_to_save = array();
|
||||
foreach ( $post_param as $param ) {
|
||||
$param_data = explode( '=', $param );
|
||||
|
||||
$data_to_save[ $param_data[0] ] = ( isset( $param_data[1] ) ) ? esc_attr( $param_data[1] ) : '';
|
||||
}
|
||||
/* Exmaple:
|
||||
Array
|
||||
(
|
||||
[calendar_months_count] => 1
|
||||
[calendar_months_num_in_1_row] => 1
|
||||
[calendar_width] => 500px
|
||||
[calendar_cell_height] =>
|
||||
)
|
||||
*/
|
||||
|
||||
// Save Custom User Data
|
||||
update_user_option( (int) $_POST['user_id'], 'opsd_custom_' . esc_attr( $_POST['data_name'] ) , serialize( $data_to_save ) );
|
||||
|
||||
?> <script type="text/javascript">
|
||||
var my_message = '<?php echo html_entity_decode( esc_js( __('Saved' , 'secure-downloads') ),ENT_QUOTES) ; ?>';
|
||||
opsd_admin_show_message( my_message, 'success', 1000 );
|
||||
<?php if ( ! empty( $_POST['is_reload'] ) == 1 ) { ?>
|
||||
setTimeout(function ( ) {location.reload(true);} ,1500);
|
||||
<?php } ?>
|
||||
</script> <?php
|
||||
die();
|
||||
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// R u n A j a x //////////////////////////////////
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
if ( is_admin() && ( defined( 'DOING_AJAX' ) ) && ( DOING_AJAX ) ) {
|
||||
|
||||
|
||||
// Reload Locale if its required
|
||||
add_action( 'admin_init', 'opsd_check_locale_for_ajax' );
|
||||
|
||||
// Hooks list
|
||||
$actions_list = array(
|
||||
|
||||
|
||||
'USER_SAVE_WINDOW_STATE' => 'admin'
|
||||
,'USER_SAVE_CUSTOM_DATA' => 'admin'
|
||||
);
|
||||
|
||||
foreach ($actions_list as $action_name => $action_where) {
|
||||
|
||||
if ( ( isset($_POST['action']) ) && ( $_POST['action'] == $action_name ) ){
|
||||
|
||||
if ( ( $action_where == 'admin' ) || ( $action_where == 'both' ) )
|
||||
add_action( 'wp_ajax_' . $action_name, 'opsd_ajax_' . $action_name); // Admin & Client (logged in usres)
|
||||
|
||||
if ( ( $action_where == 'both' ) || ( $action_where == 'client' ) )
|
||||
add_action( 'wp_ajax_nopriv_' . $action_name, 'opsd_ajax_' . $action_name); // Client (not logged in)
|
||||
}
|
||||
}
|
||||
}
|
||||
39
wp-content/plugins/secure-downloads/core/opsd-constants.php
Normal file
39
wp-content/plugins/secure-downloads/core/opsd-constants.php
Normal file
@@ -0,0 +1,39 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @subpackage Define Constants
|
||||
* @category Items
|
||||
*
|
||||
* @author wpdevelop
|
||||
* @link https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2014.05.17
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// USERS CONFIGURABLE CONSTANTS //////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
if (!defined('OPSD_SHOW_INFO_IN_FORM')) define('OPSD_SHOW_INFO_IN_FORM', false ); // This feature can impact to the performance
|
||||
if (!defined('OPSD_SHOW_OPSD_NOTES')) define('OPSD_SHOW_OPSD_NOTES', false ); // Set notes of the specific item visible by default.
|
||||
if (!defined('OPSD_CUSTOM_FORMS_FOR_REGULAR_USERS')) define('OPSD_CUSTOM_FORMS_FOR_REGULAR_USERS', false ); // Only for MultiUser version
|
||||
if (!defined('OPSD_SHOW_DEPOSIT_AND_TOTAL_PAYMENT')) define('OPSD_SHOW_DEPOSIT_AND_TOTAL_PAYMENT', false ); // Show both deposit and total cost payment forms, after visitor submit item. Important! Please note, in this case at admin panel for item will be saved deposit cost and notes about deposit, do not depend from the visitor choise of this payment. So you need to check each such payment manually.
|
||||
if (!defined('OPSD_STRICTLY_FROM_EMAILS')) define('OPSD_STRICTLY_FROM_EMAILS', true ); // If true, plugin will send emails with "From" address that defined in "From" field at item > Settings > Emails page. Otherwise (if false), when sending the copy of Confirmation email to admin, sends a "from" field of email not the email of server, but email from the person, who made reservation. Its useful for "reply to this emails", but when receiving such email, Yahoo mail for instance rejects it, and google mail puts a warning about fishing etc.
|
||||
if (!defined('OPSD_IS_SEND_EMAILS_ON_COST_CHANGE')) define('OPSD_IS_SEND_EMAILS_ON_COST_CHANGE', false ); //FixIn: 6.0.1.7 // Is send modification email, if cost was changed in admin panel
|
||||
if (!defined('OPSD_LAST_CHECKOUT_DAY_AVAILABLE')) define('OPSD_LAST_CHECKOUT_DAY_AVAILABLE', false ); //FixIn: 6.2.3.6 // Its will remove last selected day of item during saving it as item.
|
||||
if (!defined('OPSD_PAYMENT_FORM_ONLY_IN_REQUEST')) define('OPSD_PAYMENT_FORM_ONLY_IN_REQUEST', false ); // Its will show payment form only in payment request during sending from item Listing page and do not show payment form after visitor made the item.
|
||||
if (!defined('OPSD_AUTO_APPROVE_WHEN_ZERO_COST')) define('OPSD_AUTO_APPROVE_WHEN_ZERO_COST', false ); // Auto approve item, if the cost of item == 0
|
||||
if (!defined('OPSD_CHECK_LESS_THAN_PARAM_IN_SEARCH')) define('OPSD_CHECK_LESS_THAN_PARAM_IN_SEARCH', false ); // Check in search results custom fields parameters relative to less than in search form, and not only equal.
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// SYSTEM CONSTANTS //////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
if (!defined('OPSD_MINOR_UPDATE')) define('OPSD_MINOR_UPDATE', true );
|
||||
if (!defined('IS_USE_OPSD_CACHE')) define('IS_USE_OPSD_CACHE', true );
|
||||
if (!defined('OPSD_DEBUG_MODE')) define('OPSD_DEBUG_MODE', false );
|
||||
if (!defined('OPSD_MIN')) define('OPSD_MIN', false );//TODO: Finish with this contstant, right now its not working correctly with TRUE status
|
||||
if (!defined('OPSD_RESPONSE')) define('OPSD_RESPONSE', false );
|
||||
171
wp-content/plugins/secure-downloads/core/opsd-core.php
Normal file
171
wp-content/plugins/secure-downloads/core/opsd-core.php
Normal file
@@ -0,0 +1,171 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @subpackage Core Functions
|
||||
* @category Functions
|
||||
*
|
||||
* @author wpdevelop
|
||||
* @link https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 29.09.2015
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Internal plugin action hooks system ///////////////////////////////////
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
global $opsd_action, $opsd_filter;
|
||||
|
||||
|
||||
function add_opsd_filter($filter_type, $filter) {
|
||||
global $opsd_filter;
|
||||
|
||||
$args = array();
|
||||
if ( is_array($filter) && 1 == count($filter) && is_object($filter[0]) ) // array(&$this)
|
||||
$args[] =& $filter[0];
|
||||
else
|
||||
$args[] = $filter;
|
||||
for ( $a = 2; $a < func_num_args(); $a++ )
|
||||
$args[] = func_get_arg($a);
|
||||
|
||||
if ( is_array($opsd_filter) )
|
||||
|
||||
if ( isset($opsd_filter[$filter_type]) ) {
|
||||
if ( is_array($opsd_filter[$filter_type]) )
|
||||
$opsd_filter[$filter_type][]= $args;
|
||||
else
|
||||
$opsd_filter[$filter_type]= array($args);
|
||||
} else
|
||||
$opsd_filter[$filter_type]= array($args);
|
||||
else
|
||||
$opsd_filter = array( $filter_type => array( $args ) ) ;
|
||||
}
|
||||
|
||||
function remove_opsd_filter($filter_type, $filter) {
|
||||
global $opsd_filter;
|
||||
|
||||
if ( isset($opsd_filter[$filter_type]) ) {
|
||||
for ($i = 0; $i < count($opsd_filter[$filter_type]); $i++) {
|
||||
if ( $opsd_filter[$filter_type][$i][0] == $filter ) {
|
||||
$opsd_filter[$filter_type][$i] = null;
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function apply_opsd_filter($filter_type) {
|
||||
global $opsd_filter;
|
||||
|
||||
|
||||
$args = array();
|
||||
for ( $a = 1; $a < func_num_args(); $a++ )
|
||||
$args[] = func_get_arg($a);
|
||||
|
||||
if ( count($args) > 0 )
|
||||
$value = $args[0];
|
||||
else
|
||||
$value = false;
|
||||
|
||||
if ( is_array($opsd_filter) )
|
||||
if ( isset($opsd_filter[$filter_type]) )
|
||||
foreach ($opsd_filter[$filter_type] as $filter) {
|
||||
$filter_func = array_shift($filter);
|
||||
$parameter = $args;
|
||||
$value = call_user_func_array($filter_func,$parameter );
|
||||
}
|
||||
return $value;
|
||||
}
|
||||
|
||||
|
||||
function make_opsd_action($action_type) {
|
||||
global $opsd_action;
|
||||
|
||||
|
||||
$args = array();
|
||||
for ( $a = 1; $a < func_num_args(); $a++ )
|
||||
$args[] = func_get_arg($a);
|
||||
|
||||
if ( is_array($opsd_action) )
|
||||
if ( isset($opsd_action[$action_type]) )
|
||||
foreach ($opsd_action[$action_type] as $action) {
|
||||
$action_func = array_shift($action);
|
||||
$parameter = $action;
|
||||
call_user_func_array($action_func,$args );
|
||||
}
|
||||
}
|
||||
|
||||
function add_opsd_action($action_type, $action) {
|
||||
global $opsd_action;
|
||||
|
||||
$args = array();
|
||||
if ( is_array($action) && 1 == count($action) && is_object($action[0]) ) // array(&$this)
|
||||
$args[] =& $action[0];
|
||||
else
|
||||
$args[] = $action;
|
||||
for ( $a = 2; $a < func_num_args(); $a++ )
|
||||
$args[] = func_get_arg($a);
|
||||
|
||||
if ( is_array($opsd_action) )
|
||||
if ( isset($opsd_action[$action_type]) ) {
|
||||
if ( is_array($opsd_action[$action_type]) )
|
||||
$opsd_action[$action_type][]= $args;
|
||||
else
|
||||
$opsd_action[$action_type]= array($args);
|
||||
} else
|
||||
$opsd_action[$action_type]= array($args);
|
||||
|
||||
else
|
||||
$opsd_action = array( $action_type => array( $args ) ) ;
|
||||
}
|
||||
|
||||
function remove_opsd_action($action_type, $action) {
|
||||
global $opsd_action;
|
||||
|
||||
if ( isset($opsd_action[$action_type]) ) {
|
||||
for ($i = 0; $i < count($opsd_action[$action_type]); $i++) {
|
||||
if ( $opsd_action[$action_type][$i][0] == $action ) {
|
||||
$opsd_action[$action_type][$i] = null;
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
function get_opsd_option( $option, $default = false ) {
|
||||
|
||||
$u_value = apply_opsd_filter('opsd_get_option', 'no-values' , $option, $default );
|
||||
if ( $u_value !== 'no-values' ) return $u_value;
|
||||
|
||||
return get_option( $option, $default );
|
||||
}
|
||||
|
||||
function update_opsd_option ( $option, $newvalue ) {
|
||||
|
||||
$u_value = apply_opsd_filter('opsd_update_option', 'no-values' , $option, $newvalue );
|
||||
if ( $u_value !== 'no-values' ) return $u_value;
|
||||
|
||||
return update_option($option, $newvalue);
|
||||
}
|
||||
|
||||
function delete_opsd_option ( $option ) {
|
||||
|
||||
$u_value = apply_opsd_filter('opsd_delete_option', 'no-values' , $option );
|
||||
if ( $u_value !== 'no-values' ) return $u_value;
|
||||
|
||||
return delete_option($option );
|
||||
}
|
||||
|
||||
function add_opsd_option( $option, $value = '', $deprecated = '', $autoload = 'yes' ) {
|
||||
|
||||
$u_value = apply_opsd_filter('opsd_add_option', 'no-values' , $option, $value, $deprecated, $autoload );
|
||||
if ( $u_value !== 'no-values' ) return $u_value;
|
||||
|
||||
return add_option( $option, $value , $deprecated , $autoload );
|
||||
}
|
||||
|
||||
|
||||
122
wp-content/plugins/secure-downloads/core/opsd-css.php
Normal file
122
wp-content/plugins/secure-downloads/core/opsd-css.php
Normal file
@@ -0,0 +1,122 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @package
|
||||
* @category Core
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* //FixIn: 1.2.2.1
|
||||
* @modified 2013.10.16, 2023-04-15
|
||||
*/
|
||||
|
||||
class OPSD_CSS extends OPSD_JS_CSS{
|
||||
|
||||
public function define() {
|
||||
|
||||
$this->setType('css');
|
||||
|
||||
/*
|
||||
// Exmaples of usage Font Avesome: http://fontawesome.io/icons/
|
||||
|
||||
$this->add( array(
|
||||
'handle' => 'font-awesome',
|
||||
'src' => OPSD_PLUGIN_URL . 'assets/libs/font-awesome-4.3.0/css/font-awesome.css' ,
|
||||
'deps' => false,
|
||||
'version' => '4.3.0',
|
||||
'where_to_load' => array( 'admin' ),
|
||||
'condition' => false
|
||||
) );
|
||||
|
||||
// Exmaples of usage Font Avesome 3.2.1 (benefits of this version - support IE7): http://fontawesome.io/3.2.1/examples/
|
||||
$this->add( array(
|
||||
'handle' => 'font-awesome',
|
||||
'src' => OPSD_PLUGIN_URL . '/assets/libs/font-awesome/css/font-awesome.css' ,
|
||||
'deps' => false,
|
||||
'version' => '3.2.1',
|
||||
'where_to_load' => array( 'admin' ),
|
||||
'condition' => false
|
||||
) );
|
||||
$this->add( array(
|
||||
'handle' => 'font-awesome-ie7',
|
||||
'src' => OPSD_PLUGIN_URL . '/assets/libs/font-awesome/css/font-awesome-ie7.css' ,
|
||||
'deps' => array('font-awesome'),
|
||||
'version' => '3.2.1',
|
||||
'where_to_load' => array( 'admin' ),
|
||||
'condition' => 'IE 7' // CSS condition. Exmaple: <!--[if IE 7]>
|
||||
) );
|
||||
*/
|
||||
|
||||
}
|
||||
|
||||
|
||||
public function enqueue( $where_to_load ) {
|
||||
|
||||
|
||||
if ( $where_to_load == 'admin' ) { // Admin CSS files
|
||||
|
||||
//FixIn: 1.2.2.1
|
||||
wp_enqueue_style( 'wpdevelop-bts', opsd_plugin_url( '/assets/libs/bootstrap/css/bootstrap.css' ), array(), '3.3.5.1' );
|
||||
wp_enqueue_style( 'wpdevelop-bts-theme', opsd_plugin_url( '/assets/libs/bootstrap/css/bootstrap-theme.css' ), array(), '3.3.5.1' );
|
||||
|
||||
// wp_enqueue_style('opsd-chosen', opsd_plugin_url( '/assets/libs/chosen/chosen.css' ), array(), OPSD_VERSION_NUM); //FixIn: 1.2.1
|
||||
wp_enqueue_style( 'opsd-admin-support', opsd_plugin_url( '/core/any/css/admin-support.css' ), array(), OPSD_VERSION_NUM );
|
||||
wp_enqueue_style( 'opsd-admin-menu', opsd_plugin_url( '/core/any/css/admin-menu.css' ), array(), OPSD_VERSION_NUM );
|
||||
wp_enqueue_style( 'opsd-admin-toolbar', opsd_plugin_url( '/core/any/css/admin-toolbar.css' ), array(), OPSD_VERSION_NUM );
|
||||
wp_enqueue_style( 'opsd-settings-page', opsd_plugin_url( '/core/any/css/settings-page.css' ), array(), OPSD_VERSION_NUM );
|
||||
wp_enqueue_style( 'opsd-admin-listing-table', opsd_plugin_url( '/core/any/css/admin-listing-table.css' ), array(), OPSD_VERSION_NUM );
|
||||
wp_enqueue_style( 'opsd-br-table', opsd_plugin_url( '/core/any/css/admin-br-table.css' ), array(), OPSD_VERSION_NUM );
|
||||
wp_enqueue_style( 'opsd-admin-modal-popups', opsd_plugin_url( '/css/modal.css' ), array(), OPSD_VERSION_NUM );
|
||||
wp_enqueue_style( 'opsd-admin-pages', opsd_plugin_url( '/css/admin.css' ), array(), OPSD_VERSION_NUM );
|
||||
wp_enqueue_style( 'opsd-css-print', opsd_plugin_url( '/css/print.css' ), array(), OPSD_VERSION_NUM );
|
||||
|
||||
global $wp_version;
|
||||
/* FixIn: 2.0.13.1 */
|
||||
if ( ( version_compare( $wp_version, '5.3', '>=' ) )
|
||||
|| ( version_compare( $wp_version, '5.3-RC2-46574', '>=' ) )
|
||||
) {
|
||||
/* The SVG is arrow-down-alt2 from Dashicons. */
|
||||
$css = "
|
||||
.wp-core-ui .wpdevelop .control-group .btn-toolbar .input-group > select,
|
||||
.wp-core-ui .wpdevelop select.form-control {
|
||||
background: #fff url('data:image/svg+xml;charset=US-ASCII,%3Csvg%20width%3D%2220%22%20height%3D%2220%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M5%206l5%205%205-5%202%201-7%207-7-7%202-1z%22%20fill%3D%22%23555%22%2F%3E%3C%2Fsvg%3E') no-repeat right 5px top 55%;
|
||||
padding: 2px 30px 2px 10px;
|
||||
}
|
||||
";
|
||||
wp_add_inline_style( 'opsd-admin-support', $css );
|
||||
}
|
||||
|
||||
|
||||
//FixIn: 1.2.2.1
|
||||
if ( ( $where_to_load != 'admin' ) || ( opsd_is_new_opsd_page() ) ) { // Client or Add New item page
|
||||
wp_enqueue_style( 'opsd-client-pages', opsd_plugin_url( '/css/client.css' ), array(), OPSD_VERSION_NUM );
|
||||
}
|
||||
if ( ( $where_to_load != 'admin' ) || ( opsd_is_master_page() ) ) {
|
||||
wp_enqueue_style( 'opsd-admin-popover', opsd_plugin_url( '/css/popover.css' ), array(), OPSD_VERSION_NUM );
|
||||
}
|
||||
wp_enqueue_style( 'opsd-calendar', opsd_plugin_url( '/css/calendar.css' ), array(), OPSD_VERSION_NUM );
|
||||
} // Calendar Skins
|
||||
|
||||
do_action( 'opsd_enqueue_css_files', $where_to_load );
|
||||
}
|
||||
|
||||
|
||||
public function remove_conflicts( $where_to_load ) {
|
||||
|
||||
if ( opsd_is_master_page() ) {
|
||||
if (function_exists('wp_dequeue_style')) {
|
||||
/*
|
||||
wp_dequeue_style( 'cs-alert' );
|
||||
wp_dequeue_style( 'cs-framework' );
|
||||
wp_dequeue_style( 'cs-font-awesome' );
|
||||
wp_dequeue_style( 'icomoon' );
|
||||
*/
|
||||
wp_dequeue_style( 'chosen');
|
||||
wp_dequeue_style( 'toolset-font-awesome-css' ); // Remove this script sitepress-multilingual-cms/res/css/font-awesome.min.css?ver=3.1.6, which is load by the "sitepress-multilingual-cms"
|
||||
wp_dequeue_style( 'toolset-font-awesome' ); //FixIn: 5.4.5.8
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
173
wp-content/plugins/secure-downloads/core/opsd-debug.php
Normal file
173
wp-content/plugins/secure-downloads/core/opsd-debug.php
Normal file
@@ -0,0 +1,173 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.1
|
||||
* @package Any
|
||||
* @category Dubug info showing
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 09.09.2015
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// D e b u g f u n c t i o n s ///////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/*
|
||||
* Show values of the arguments list
|
||||
*/
|
||||
if (!function_exists ('debuge')) {
|
||||
function debuge() {
|
||||
$numargs = func_num_args();
|
||||
$var = func_get_args();
|
||||
$makeexit = is_bool( $var[count($var)-1] ) ? $var[ count($var) - 1 ]:false;
|
||||
echo "<div><pre class='prettyprint linenums'>";
|
||||
print_r ( $var );
|
||||
echo "</pre></div>";
|
||||
echo '<script type="text/javascript"> jQuery(".ajax_respond_insert, .ajax_respond").show(); </script>';
|
||||
if ( $makeexit ) {
|
||||
echo '<div style="font-size:18px;float:right;">' . get_num_queries(). '/' . timer_stop(0, 3) . 'qps</div>';
|
||||
exit;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* Show Speed of the execution and number of queries.
|
||||
*/
|
||||
if (!function_exists ('debuge_speed')) {
|
||||
function debuge_speed() {
|
||||
echo '<div style="font-size:18px;float:right;">' . get_num_queries(). '/' . timer_stop(0, 3) . 'qps</div>';
|
||||
}
|
||||
}
|
||||
|
||||
/** Show error info
|
||||
*/
|
||||
if (!function_exists ('debuge_error')) {
|
||||
function debuge_error( $msg , $file_name='', $line_num=''){
|
||||
echo get_debuge_error( $msg , $file_name , $line_num );
|
||||
}
|
||||
}
|
||||
if (!function_exists ('get_debuge_error')) {
|
||||
function get_debuge_error( $msg , $file_name='', $line_num=''){
|
||||
|
||||
$ver_num = ( ! defined('OPSD_VERSION') ) ? '' : '|V:' . OPSD_VERSION ;
|
||||
|
||||
$last_db_error = '';
|
||||
global $EZSQL_ERROR;
|
||||
if (isset($EZSQL_ERROR[ (count($EZSQL_ERROR)-1)])) {
|
||||
|
||||
$last_db_error2 = $EZSQL_ERROR[ (count($EZSQL_ERROR)-1)];
|
||||
|
||||
if ( (isset($last_db_error2['query'])) && (isset($last_db_error2['error_str'])) ) {
|
||||
|
||||
$str = str_replace( array( '"', "'" ), '', $last_db_error2['error_str'] );
|
||||
$query = str_replace( array( '"', "'" ), '', $last_db_error2['query'] );
|
||||
|
||||
$str = htmlspecialchars( $str, ENT_QUOTES );
|
||||
$query = htmlspecialchars( $query , ENT_QUOTES );
|
||||
|
||||
$last_db_error = $str ;
|
||||
$last_db_error .= '::<span style="color:#300;">'.$query.'</span>';
|
||||
}
|
||||
}
|
||||
return $msg . '<br /><span style="font-size:11px;"> ['
|
||||
. 'F:' . str_replace( dirname( $file_name ) , '' , $file_name )
|
||||
. '| L:' . $line_num
|
||||
. $ver_num
|
||||
. '| DB:' . $last_db_error
|
||||
. '] </span>' ;
|
||||
}
|
||||
}
|
||||
|
||||
// Usage: if ( function_exists ('opsd_check_post_key_max_number')) { opsd_check_post_key_max_number(); }
|
||||
if ( ! function_exists ('opsd_check_post_key_max_number')) {
|
||||
function opsd_check_post_key_max_number() {
|
||||
|
||||
/*
|
||||
$post_max_totalname_length = intval( ( ini_get( 'suhosin.post.max_totalname_length' ) ) ? ini_get( 'suhosin.post.max_totalname_length' ) : '9999999' );
|
||||
$request_max_totalname_length = intval( ( ini_get( 'suhosin.request.max_totalname_length' ) ) ? ini_get( 'suhosin.request.max_totalname_length' ) : '9999999' );
|
||||
$post_max_name_length = intval( ( ini_get( 'suhosin.post.max_name_length' ) ) ? ini_get( 'suhosin.post.max_name_length' ) : '9999999' );
|
||||
$request_max_varname_length = intval( ( ini_get( 'suhosin.request.max_varname_length' ) ) ? ini_get( 'suhosin.request.max_varname_length' ) : '9999999' );
|
||||
*/
|
||||
$php_ini_vars = array(
|
||||
'suhosin.post.max_totalname_length'
|
||||
, 'suhosin.request.max_totalname_length'
|
||||
, 'suhosin.post.max_name_length'
|
||||
, 'suhosin.request.max_varname_length'
|
||||
);
|
||||
|
||||
foreach ( $_POST as $key_name => $post_value ) {
|
||||
|
||||
$key_length = strlen( $key_name );
|
||||
|
||||
foreach ( $php_ini_vars as $php_ini_var ) {
|
||||
|
||||
$php_ini_var_length = intval( ( ini_get( $php_ini_var ) ) ? ini_get( $php_ini_var ) : '9999999' );
|
||||
|
||||
if ( $key_length > $php_ini_var_length ) {
|
||||
|
||||
opsd_show_message_in_settings( 'Your php.ini configuration limited to '
|
||||
. '<strong> '. $php_ini_var . ' = ' . $php_ini_var_length . '</strong>.'
|
||||
. ' '
|
||||
. 'Plugin require at least ' . ( intval( $key_length ) + 1 ). ', '
|
||||
. 'for saving option: ' . '<strong>'. $key_name . '</strong>'
|
||||
, 'error'
|
||||
, __('Error' , 'secure-downloads') . '.' );
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ( ! function_exists( 'debuge_log' ) ) { //FixIn: 1.1.2.4
|
||||
/** Write debuge log to file ../wp-content/upload/opsd_debug.log
|
||||
*
|
||||
* @param type $param
|
||||
*/
|
||||
function debuge_log( $param ) {
|
||||
|
||||
|
||||
$content = "\n---\n"
|
||||
. 'Log: [' . date_i18n( 'Y-m-d H:m:s' ) . ']'
|
||||
. "\n---\n"
|
||||
. str_replace( ',', "\n,", json_encode( $param ) );
|
||||
|
||||
|
||||
// Install files and folders for uploading files and prevent hotlinking
|
||||
$upload_dir = wp_upload_dir();
|
||||
|
||||
$files = array(
|
||||
array(
|
||||
'base' => $upload_dir['basedir'],
|
||||
'file' => 'opsd_debug.log',
|
||||
'content' => $content
|
||||
|
||||
)
|
||||
);
|
||||
|
||||
foreach ( $files as $file ) {
|
||||
|
||||
if ( ( wp_mkdir_p( $file['base'] ) ) // Recursive directory creation based on full path.
|
||||
//&& ( ! file_exists( trailingslashit( $file['base'] ) . $file['file'] ) ) // If file not exist
|
||||
) {
|
||||
|
||||
// Append new lines to bottom (if we need to rewrite, then use 'w'
|
||||
if ( $file_handle = @fopen( trailingslashit( $file['base'] ) . $file['file'], 'a' ) ) {
|
||||
|
||||
fwrite( $file_handle, $file['content'] );
|
||||
fclose( $file_handle );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
1278
wp-content/plugins/secure-downloads/core/opsd-download.php
Normal file
1278
wp-content/plugins/secure-downloads/core/opsd-download.php
Normal file
File diff suppressed because it is too large
Load Diff
325
wp-content/plugins/secure-downloads/core/opsd-emails.php
Normal file
325
wp-content/plugins/secure-downloads/core/opsd-emails.php
Normal file
@@ -0,0 +1,325 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.1
|
||||
* @package Secure Downloads
|
||||
* @category Send Emails
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 15.09.2015
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Emails
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/**
|
||||
* Check email and format it
|
||||
*
|
||||
* @param string $emails
|
||||
* @return string
|
||||
*/
|
||||
function opsd_validate_emails( $emails ) {
|
||||
|
||||
$emails = str_replace(';', ',', $emails);
|
||||
|
||||
if ( !is_array( $emails ) )
|
||||
$emails = explode( ',', $emails );
|
||||
|
||||
$emails_list = array();
|
||||
foreach ( (array) $emails as $recipient ) {
|
||||
|
||||
// Break $recipient into name and address parts if in the format "Foo <bar@baz.com>"
|
||||
$recipient_name = '';
|
||||
if( preg_match( '/(.*)<(.+)>/', $recipient, $matches ) ) {
|
||||
if ( count( $matches ) == 3 ) {
|
||||
$recipient_name = $matches[1];
|
||||
$recipient = $matches[2];
|
||||
}
|
||||
} else {
|
||||
// Check about correct format of email
|
||||
if( preg_match( '/([\w\.\-_]+)?\w+@[\w\-_]+(\.\w+){1,}/im', $recipient, $matches ) ) { //FixIn: 8.7.7.2
|
||||
$recipient = $matches[0];
|
||||
}
|
||||
}
|
||||
|
||||
$recipient_name = str_replace('"', '', $recipient_name);
|
||||
$recipient_name = trim( wp_specialchars_decode( esc_html( stripslashes( $recipient_name ) ), ENT_QUOTES ) );
|
||||
|
||||
$emails_list[] = ( empty( $recipient_name ) ? '' : $recipient_name . ' ' )
|
||||
. '<' . sanitize_email( $recipient ) . '>';
|
||||
}
|
||||
|
||||
$emails_list = implode( ',', $emails_list );
|
||||
|
||||
return $emails_list;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
function opsd_check_for_several_emails_in_form( $mail_recipients, $formdata, $bktype ) { // FixIn: 6.0.1.9
|
||||
|
||||
$possible_other_emails = explode('~',$formdata);
|
||||
$possible_other_emails = array_map("explode", array_fill(0,count($possible_other_emails),'^'), $possible_other_emails);
|
||||
$other_emails = array();
|
||||
foreach ( $possible_other_emails as $possible_emails ) {
|
||||
if ( ( $possible_emails[0] == 'email' )
|
||||
//&& ( $possible_emails[1] != 'email' . $bktype )
|
||||
&& ( ! empty($possible_emails[2]) )
|
||||
)
|
||||
$other_emails[]=$possible_emails[2];
|
||||
}
|
||||
if ( count( $other_emails ) > 1 ) {
|
||||
$other_emails = implode(',',$other_emails);
|
||||
$mail_recipients = $other_emails;
|
||||
}
|
||||
return $mail_recipients;
|
||||
}
|
||||
|
||||
|
||||
// N E W /////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
/** Parse email and get Parts of Email - Name and Email
|
||||
*
|
||||
* @param string $email
|
||||
* @return array [email] => beta@oplugins.com
|
||||
[title] => item system
|
||||
[original] => "Item system"
|
||||
[original_to_show] => "Item system" <beta@oplugins.com>
|
||||
*/
|
||||
function opsd_get_email_parts( $email ) {
|
||||
|
||||
$email_to_parse = html_entity_decode( $email ); // Convert " to " etc...
|
||||
|
||||
$pure_name = '';
|
||||
$pure_email = '';
|
||||
if( preg_match( '/(.*)<(.+)>/', $email_to_parse, $matches ) ) {
|
||||
if ( count( $matches ) == 3 ) {
|
||||
$pure_name = $matches[1];
|
||||
$pure_email = $matches[2];
|
||||
}
|
||||
} else { // Check about correct format of email
|
||||
if( preg_match( '/([\w\.\-_]+)?\w+@[\w-_]+(\.\w+){1,}/im', $email_to_parse, $matches ) ) {
|
||||
$pure_email = $matches[0];
|
||||
}
|
||||
}
|
||||
|
||||
$pure_name = trim( wp_specialchars_decode( esc_html( stripslashes( $pure_name ) ), ENT_QUOTES ) , ' "');
|
||||
|
||||
$return_email = array(
|
||||
'email' => sanitize_email( $pure_email )
|
||||
, 'title' => $pure_name
|
||||
, 'original' => $email_to_parse
|
||||
, 'original_to_show' => htmlentities( $email_to_parse ) // Convert " to " etc...
|
||||
);
|
||||
|
||||
return $return_email;
|
||||
}
|
||||
|
||||
|
||||
// Get Emails Help Shortcodes for Settings pages
|
||||
function opsd_get_email_help_shortcodes( $skip_shortcodes = array() , $email_example = '') {
|
||||
|
||||
$fields = array();
|
||||
$fields[] = '<strong>' . __('You can use following shortcodes in content of this template' , 'secure-downloads') . '</strong>';
|
||||
|
||||
$fields[] = sprintf( __( '%s - ID of product', 'secure-downloads' ) , '<code>[product_id]</code>' );
|
||||
$fields[] = sprintf( __( '%s - title of product', 'secure-downloads' ) , '<code>[product_title]</code>' );
|
||||
$fields[] = sprintf( __( '%s - version number of product', 'secure-downloads' ) , '<code>[product_version]</code>' );
|
||||
$fields[] = sprintf( __( '%s - description of product', 'secure-downloads' ) , '<code>[product_description]</code>' );
|
||||
$fields[] = sprintf( __( '%s - secure URL for product download','secure-downloads'), '<code>[product_link]</code>' );
|
||||
$fields[] = sprintf( __( '%s - filename of the product', 'secure-downloads' ) , '<code>[product_filename]</code>' );
|
||||
|
||||
$fields[] = sprintf( __( '%s - the download size in a friendly format such as %s or %s', 'secure-downloads' ), '<code>[product_size]</code>', '500 KB', '3.45 MB' );
|
||||
$fields[] = sprintf( __( '%s - expiry time in friendly format (e.g. 24 hours or 2 days etc)', 'secure-downloads' ), '<code>[product_expire_after]</code>' );
|
||||
$fields[] = sprintf( __( '%s - exact expiry date and time (e.g. 2017-03-21 18:30)', 'secure-downloads' ), '<code>[product_expire_date]</code>' );
|
||||
$fields[] = sprintf( __( '%s - complete product details including title, size, link etc', 'secure-downloads' ), '<code>[product_summary]</code>' );
|
||||
$fields[] = '<hr/>';
|
||||
$fields[] = sprintf( __( '%s - email, which was sent to secure link', 'secure-downloads' ), '<code>[link_sent_to]</code>' );
|
||||
// $fields[] = sprintf( __( '%s - order', 'secure-downloads' ), '<code>[order]</code>' );
|
||||
$fields[] = '<hr/>';
|
||||
$fields[] = sprintf( __( '%s - website URL ', 'secure-downloads' ), '<code>[siteurl]</code>' );
|
||||
$fields[] = sprintf( __( '%s - IP address of the user, who made this action ', 'secure-downloads' ), '<code>[remote_ip]</code>' );
|
||||
$fields[] = sprintf( __( '%s - contents of the User-Agent header from the current request, if there is one ', 'secure-downloads' ), '<code>[user_agent]</code>' );
|
||||
$fields[] = sprintf( __( '%s - address of the page (if any), where visitor make this action ', 'secure-downloads' ), '<code>[request_url]</code>' );
|
||||
$fields[] = sprintf( __( '%s - date of this action ', 'secure-downloads' ), '<code>[current_date]</code>' );
|
||||
$fields[] = sprintf( __( '%s - time of this action ', 'secure-downloads' ), '<code>[current_time]</code>' );
|
||||
|
||||
|
||||
/*
|
||||
//$fields[] = __('HTML tags is accepted.' , 'secure-downloads');
|
||||
// $fields[] = '<hr/>';
|
||||
// // show_additional_translation_shortcode_help
|
||||
// $fields[] = '<strong>' . sprintf(__('Configuration in several languages' , 'secure-downloads') ) . '.</strong>';
|
||||
// $fields[] = sprintf(__('%s - start new translation section, where %s - locale of translation' , 'secure-downloads'),'<code>[lang=LOCALE]</code>','<code>LOCALE</code>');
|
||||
// $fields[] = sprintf(__('Example #1: %s - start French translation section' , 'secure-downloads'),'<code>[lang=fr_FR]</code>');
|
||||
// $fields[] = sprintf(__('Example #2: "%s" - English and French translation of some message' , 'secure-downloads'),'<code>Thank you for your item.[lang=fr_FR]Je vous remercie de votre reservation.</code>');
|
||||
*/
|
||||
|
||||
return $fields;
|
||||
}
|
||||
|
||||
|
||||
/** Check Email subject about Language sections
|
||||
*
|
||||
* @param string $subject
|
||||
* @param string $email_id
|
||||
* @return string
|
||||
*/
|
||||
function opsd_email_api_get_subject_before( $subject, $email_id ) {
|
||||
|
||||
$subject = apply_opsd_filter('opsd_check_for_active_language', $subject );
|
||||
|
||||
return $subject;
|
||||
}
|
||||
add_filter( 'opsd_email_api_get_subject_before', 'opsd_email_api_get_subject_before', 10, 2 ); // Hook fire in api-email.php
|
||||
|
||||
|
||||
/** Check Email sections content about Language sections
|
||||
*
|
||||
* @param array $fields_values - list of params to parse: 'content', 'header_content', 'footer_content' for different languges, etc ....
|
||||
* @param string $email_id - Email ID
|
||||
* @param string $email_type - 'plain' | 'html'
|
||||
*/
|
||||
function opsd_email_api_get_content_before( $fields_values, $email_id , $email_type ) {
|
||||
|
||||
if ( isset( $fields_values['content'] ) ) {
|
||||
$fields_values['content'] = apply_opsd_filter('opsd_check_for_active_language', $fields_values['content'] );
|
||||
if ($email_type == 'html')
|
||||
$fields_values['content'] = make_clickable( $fields_values['content'] );
|
||||
}
|
||||
|
||||
if ( isset( $fields_values['header_content'] ) )
|
||||
$fields_values['header_content'] = apply_opsd_filter('opsd_check_for_active_language', $fields_values['header_content'] );
|
||||
|
||||
if ( isset( $fields_values['footer_content'] ) )
|
||||
$fields_values['footer_content'] = apply_opsd_filter('opsd_check_for_active_language', $fields_values['footer_content'] );
|
||||
|
||||
return $fields_values;
|
||||
}
|
||||
add_filter( 'opsd_email_api_get_content_before', 'opsd_email_api_get_content_before', 10, 3 ); // Hook fire in api-email.php
|
||||
|
||||
|
||||
/** Modify email content, if needed. - In HTML mail content, make links clickable.
|
||||
*
|
||||
* @param array $email_content - content of Email
|
||||
* @param string $email_id - Email ID
|
||||
* @param string $email_type - 'plain' | 'html'
|
||||
*/
|
||||
function opsd_email_api_get_content_after( $email_content, $email_id , $email_type ) {
|
||||
|
||||
if ( ( $email_type == 'html' ) || ( $email_type == 'multipart' ) )
|
||||
$email_content = make_clickable( $email_content );
|
||||
|
||||
return $email_content;
|
||||
}
|
||||
add_filter( 'opsd_email_api_get_content_after', 'opsd_email_api_get_content_after', 10, 3 ); // Hook fire in api-email.php
|
||||
|
||||
|
||||
/** Check Email Headers - in New item Email (to admin) set Reply-To header to visitor email.
|
||||
*
|
||||
* @param string $headers
|
||||
* @param string $email_id - Email ID
|
||||
* @param array $fields_values - list of params to parse: 'content', 'header_content', 'footer_content' for different languges, etc ....
|
||||
* @param array $replace_array - list of relpaced shortcodes
|
||||
* @return string
|
||||
*/
|
||||
function opsd_email_api_get_headers_after( $mail_headers, $email_id , $fields_values , $replace_array, $additional_params = array() ) {
|
||||
|
||||
/*
|
||||
// Default in api-emails.php:
|
||||
// $mail_headers = 'From: ' . $this->get_from__name() . ' <' . $this->get_from__email_address() . '> ' . "\r\n" ;
|
||||
// $mail_headers .= 'Content-Type: ' . $this->get_content_type() . "\r\n" ;
|
||||
//
|
||||
// $mail_headers = "From: $mail_sender\n";
|
||||
// preg_match('/<(.*)>/', $mail_sender, $simple_email_matches );
|
||||
// $reply_to_email = ( count( $simple_email_matches ) > 1 ) ? $simple_email_matches[1] : $mail_sender;
|
||||
// $mail_headers .= 'Reply-To: ' . $reply_to_email . "\n";
|
||||
// $mail_headers .= 'X-Sender: ' . $reply_to_email . "\n";
|
||||
// $mail_headers .= 'Return-Path: ' . $reply_to_email . "\n";
|
||||
*/
|
||||
|
||||
//debuge($mail_headers, $email_id , $fields_values , $replace_array);
|
||||
if (
|
||||
( $email_id == 'new_admin' ) // Only for email: "New item to Admin"
|
||||
|| ( isset( $additional_params['reply'] ) )
|
||||
) {
|
||||
if ( isset( $replace_array['email'] ) ) { // Get email from the item form.
|
||||
|
||||
$reply_to_email = sanitize_email( $replace_array['email'] );
|
||||
if ( ! empty( $reply_to_email ) )
|
||||
$mail_headers .= 'Reply-To: ' . $reply_to_email . "\r\n" ;
|
||||
|
||||
// $mail_headers .= 'X-Sender: ' . $reply_to_email . "\r\n" ;
|
||||
// $mail_headers .= 'Return-Path: ' . $reply_to_email . "\r\n" ;
|
||||
}
|
||||
}
|
||||
|
||||
return $mail_headers;
|
||||
}
|
||||
add_filter( 'opsd_email_api_get_headers_after', 'opsd_email_api_get_headers_after', 10, 5 ); // Hook fire in api-email.php
|
||||
|
||||
|
||||
/** Check if we can send Email - block sending in live demos
|
||||
*
|
||||
* @param bool $is_send_email
|
||||
* @param string $email_id
|
||||
* @param array $fields_values - list of params to parse: 'content', 'header_content', 'footer_content' for different languges, etc ....
|
||||
* @return bool
|
||||
*/
|
||||
function opsd_email_api_is_allow_send( $is_send_email, $email_id, $fields_values ) {
|
||||
//debuge($fields_values);
|
||||
if ( opsd_is_this_demo() )
|
||||
$is_send_email = false;
|
||||
|
||||
return $is_send_email;
|
||||
}
|
||||
add_filter( 'opsd_email_api_is_allow_send', 'opsd_email_api_is_allow_send', 100, 3 ); // Hook fire in api-email.php
|
||||
add_filter( 'opsd_email_api_is_allow_send_copy' , 'opsd_email_api_is_allow_send' , 100, 3);
|
||||
|
||||
/** Show warning about not sending emails, and reason about this.
|
||||
*
|
||||
* @param object $wp_error_object - WP Error object
|
||||
* @param string $error_description - Description
|
||||
*/
|
||||
function opsd_email_sending_error( $wp_error_object, $error_description = '' ) {
|
||||
|
||||
if ( empty( $error_description ) ) {
|
||||
// $error_description = __( 'Unknown exception', 'secure-downloads') . '.'; // Overwrite to show error, if no description ???
|
||||
}
|
||||
|
||||
if ( ! empty( $error_description ) ) {
|
||||
|
||||
$error_description = '' . __('Error', 'secure-downloads') . '! ' . __('Email had not sent. Some error occuered.', 'secure-downloads') . ' ' . $error_description;
|
||||
|
||||
// Admin side
|
||||
if ( function_exists( 'opsd_show_message' ) ) {
|
||||
opsd_show_message ( $error_description , 15 , 'error');
|
||||
|
||||
}
|
||||
|
||||
// Front-end
|
||||
?>
|
||||
<script type="text/javascript">
|
||||
if (typeof( opsd_show_message_under_element ) == 'function') {
|
||||
opsd_show_message_under_element( '.opsd_form' , '<?php echo esc_js( $error_description ) ; ?>', '');
|
||||
}
|
||||
</script>
|
||||
<?php
|
||||
} else {
|
||||
|
||||
// Error that have no description. Its can be Empty Object like this: WP_Error Object( 'errors' => array(), 'error_data' => array() ), or NOT
|
||||
// debuge( $wp_error_object );
|
||||
}
|
||||
}
|
||||
add_action('opsd_email_sending_error', 'opsd_email_sending_error', 10, 2);
|
||||
1942
wp-content/plugins/secure-downloads/core/opsd-functions.php
Normal file
1942
wp-content/plugins/secure-downloads/core/opsd-functions.php
Normal file
File diff suppressed because it is too large
Load Diff
66
wp-content/plugins/secure-downloads/core/opsd-include.php
Normal file
66
wp-content/plugins/secure-downloads/core/opsd-include.php
Normal file
@@ -0,0 +1,66 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @subpackage Files Loading
|
||||
* @category Items
|
||||
*
|
||||
* @author wpdevelop
|
||||
* @link https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 29.09.2015
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// L O A D F I L E S
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/any/class-css-js.php' ); // Abstract. Loading CSS & JS files = Package: Any =
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/any/class-admin-settings-api.php' ); // Abstract. Settings API.
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/any/class-admin-page-structure.php' ); // Abstract. Page Structure in Admin Panel
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/any/class-admin-menu.php' ); // CLASS. Menus of plugin
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/any/admin-bs-ui.php' ); // Functions. Toolbar BS UI Elements
|
||||
if( is_admin() ) {
|
||||
require_once OPSD_PLUGIN_DIR . '/core/any/opsd-class-dismiss.php'; // Class - Dismiss
|
||||
require_once OPSD_PLUGIN_DIR . '/core/any/opsd-class-notices.php'; // Class - Notices
|
||||
}
|
||||
|
||||
// Functions ////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/opsd-debug.php' ); // Debug = Package: OPSD =
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/opsd-core.php' ); // Core
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/opsd-translation.php' ); // Translations
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/opsd-functions.php' ); // Functions
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/opsd-products.php' ); // Products Functions
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/opsd-download.php' ); // Download Functions
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/opsd-upload.php' ); // Upload Functions
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/opsd-emails.php' ); // Emails
|
||||
|
||||
// JS & CSS ////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/opsd-css.php' ); // Load CSS
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/opsd-js.php' ); // Load JavaScript and define JS Varibales
|
||||
|
||||
// Admin UI ////////////////////////////////////////////////////////////////////////////////
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/admin/opsd-toolbars.php' ); // Toolbar - BS UI Elements
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/admin/opsd-dashboard.php' ); // Dashboard Widget
|
||||
|
||||
// Admin Pages ////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/admin/page-send.php' ); // Master page
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/admin/page-files-add.php' ); // Add New page
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/admin/page-files-sortable.php' ); // Sortable List page
|
||||
|
||||
//require_once( OPSD_PLUGIN_DIR . '/core/admin/exmpl-opsd-class-listing.php' ); // CLASS. item Listing Table // 4.F.U.T.U.R.E
|
||||
//require_once( OPSD_PLUGIN_DIR . '/core/admin/exmpl-page-with-toolbars-listing.php' ); // Template of page with toolbars // 4.F.U.T.U.R.E
|
||||
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/admin/page-settings.php' ); // Settings page
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/admin/api-settings.php' ); // Settings API
|
||||
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/admin/page-email-link-user.php' ); // Email - send email with download link to user
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/admin/page-email-download_notification.php' ); // Email - send email about downloads happend
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/any/activation.php' );
|
||||
require_once( OPSD_PLUGIN_DIR . '/core/opsd-activation.php' );
|
||||
|
||||
make_opsd_action( 'opsd_loaded_php_files' );
|
||||
291
wp-content/plugins/secure-downloads/core/opsd-js.php
Normal file
291
wp-content/plugins/secure-downloads/core/opsd-js.php
Normal file
@@ -0,0 +1,291 @@
|
||||
<?php /**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @category JavaScript files and varibales
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 19.10.2015
|
||||
*/
|
||||
|
||||
class OPSD_JS extends OPSD_JS_CSS {
|
||||
|
||||
public function define() {
|
||||
|
||||
$this->setType('js');
|
||||
|
||||
/*
|
||||
$this->add( array(
|
||||
'handle' => 'opsd-datepick',
|
||||
'src' => opsd_plugin_url( '/js/datepick/jquery.datepick.js'),
|
||||
'deps' => array( 'opsd-global-vars' ),
|
||||
'version' => '1.1',
|
||||
'where_to_load' => array( 'admin', 'client' ), //Usage: array( 'admin', 'client' )
|
||||
'condition' => false
|
||||
) );
|
||||
*/
|
||||
}
|
||||
|
||||
/** Enqueue Files and Varibales.
|
||||
* Useful in case, if we use get_options and current user functions...
|
||||
*
|
||||
* @param type $where_to_load
|
||||
*/
|
||||
public function enqueue( $where_to_load ) {
|
||||
|
||||
opsd_js_load_vars( $where_to_load );
|
||||
|
||||
// Define JavaScript varibales in all other files
|
||||
do_action( 'opsd_define_js_vars', $where_to_load );
|
||||
|
||||
opsd_js_load_libs( $where_to_load );
|
||||
opsd_js_load_files( $where_to_load );
|
||||
|
||||
if ( opsd_is_new_opsd_page() )
|
||||
$where_to_load = 'both';
|
||||
|
||||
// Load JavaScript files in all other versions
|
||||
do_action( 'opsd_enqueue_js_files', $where_to_load );
|
||||
}
|
||||
|
||||
/** Deregister some conflict scripts from other plugins.
|
||||
*
|
||||
* @param type $where_to_load
|
||||
*/
|
||||
public function remove_conflicts( $where_to_load ) {
|
||||
|
||||
if ( opsd_is_master_page() ) {
|
||||
if (function_exists('wp_dequeue_script')) {
|
||||
|
||||
//wp_dequeue_script( 'jquery.cookie' );
|
||||
//wp_dequeue_script( 'jquery-interdependencies' );
|
||||
//wp_dequeue_script( 'chosen' ); //FixIn: 1.2.1
|
||||
wp_dequeue_script( 'cs-framework' );
|
||||
wp_dequeue_script( 'cgmp-jquery-tools-tooltip' ); // Remove this script jquery.tools.tooltip.min.js, which is load by the "Comprehensive Google Map Plugin"
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** Define JavaScript Varibales */
|
||||
function opsd_js_load_vars( $where_to_load ) {
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// JavaScripts Variables
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
if ( $where_to_load == 'admin' ) { //FixIn: 1.1.2
|
||||
wp_enqueue_script( 'opsd-global-vars', opsd_plugin_url( '/js/opsd_vars.js' ), array( 'jquery' ), '1.1' ); // Blank JS File
|
||||
|
||||
wp_localize_script( 'opsd-global-vars'
|
||||
, 'opsd_global1', array(
|
||||
'opsd_ajaxurl' => admin_url( 'admin-ajax.php' )
|
||||
, 'opsd_plugin_url' => plugins_url( '' , OPSD_FILE )
|
||||
, 'opsd_today' => '[' . intval(date_i18n('Y')) //FixIn:6.1
|
||||
.','. intval(date_i18n('m'))
|
||||
.','. intval(date_i18n('d'))
|
||||
.','. intval(date_i18n('H'))
|
||||
.','. intval(date_i18n('i'))
|
||||
.']'
|
||||
, 'opsd_plugin_filename' => OPSD_PLUGIN_FILENAME
|
||||
, 'message_verif_requred' => esc_js(__('This field is required' , 'secure-downloads'))
|
||||
, 'message_verif_requred_for_check_box' => esc_js(__('This checkbox must be checked' , 'secure-downloads'))
|
||||
, 'message_verif_requred_for_radio_box' => esc_js(__('At least one option must be selected' , 'secure-downloads'))
|
||||
, 'message_verif_emeil' => esc_js(__('Incorrect email field' , 'secure-downloads'))
|
||||
, 'message_verif_same_emeil' => esc_js(__('Your emails do not match' , 'secure-downloads')) // Email Addresses Do Not Match
|
||||
|
||||
, 'opsd_active_locale' => opsd_get_locale()
|
||||
, 'opsd_message_processing' => esc_js( __('Processing' , 'secure-downloads') )
|
||||
, 'opsd_message_deleting' => esc_js( __('Deleting' , 'secure-downloads') )
|
||||
, 'opsd_message_updating' => esc_js( __('Updating' , 'secure-downloads') )
|
||||
, 'opsd_message_saving' => esc_js( __('Saving' , 'secure-downloads') )
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/** Default JavaScripts Libraries */
|
||||
function opsd_js_load_libs( $where_to_load ) {
|
||||
|
||||
// jQuery
|
||||
wp_enqueue_script( 'jquery' );
|
||||
|
||||
//FixIn: 1.1.5.1
|
||||
|
||||
// Default Admin Libs
|
||||
if ( ( $where_to_load == 'admin' )
|
||||
// || ( is_admin() && ( defined( 'DOING_AJAX' ) ) && ( DOING_AJAX ) )
|
||||
) {
|
||||
|
||||
wp_enqueue_media();
|
||||
|
||||
wp_enqueue_script('thickbox');
|
||||
// Load thickbox CSS
|
||||
wp_enqueue_style('thickbox');
|
||||
|
||||
wp_enqueue_style( 'wp-color-picker' ); // Color Picker
|
||||
wp_enqueue_script( 'wp-color-picker' );
|
||||
wp_enqueue_script( 'jquery-ui-sortable' ); // UI Sortable
|
||||
// if ( opsd_is_master_page() )
|
||||
// wp_enqueue_script( 'jquery-ui-dialog' ); // UI Dialog - for payment request dialog
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
/** Load JavaScript Files */
|
||||
function opsd_js_load_files( $where_to_load ) {
|
||||
|
||||
// Bootstrap
|
||||
if ( ( ( is_admin() ) && ( get_opsd_option( 'opsd_is_not_load_bs_script_in_admin' ) !== 'On') )
|
||||
// || ( ( ! is_admin() ) && ( get_opsd_option( 'opsd_is_not_load_bs_script_in_client' ) !== 'On' ) )
|
||||
) {
|
||||
wp_enqueue_script( 'wpdevelop-bootstrap', opsd_plugin_url( '/assets/libs/bootstrap/js/bootstrap.js' ), array( 'opsd-global-vars' ), '3.3.5.1');
|
||||
}
|
||||
|
||||
// Datepicker
|
||||
// wp_enqueue_script( 'opsd-datepick', opsd_plugin_url( '/js/datepick/jquery.datepick.js'), array( 'opsd-global-vars' ), '1.1');
|
||||
|
||||
// Localization
|
||||
// $calendar_localization_url = opsd_get_calendar_localization_url();
|
||||
// if ( ! empty( $calendar_localization_url ) )
|
||||
// wp_enqueue_script( 'opsd-datepick-localize', $calendar_localization_url, array( 'opsd-datepick' ), '1.1');
|
||||
//opsd_load_calendar_localization_file();
|
||||
|
||||
if ( ( $where_to_load == 'client' ) || ( opsd_is_new_opsd_page() ) ) {
|
||||
|
||||
// Client
|
||||
// wp_enqueue_script( 'opsd-main-client', opsd_plugin_url( '/js/client.js'), array( 'opsd-datepick' ), '1.1');
|
||||
}
|
||||
|
||||
if ( $where_to_load == 'admin' ) {
|
||||
|
||||
// Admin
|
||||
wp_enqueue_script( 'opsd-admin-main', opsd_plugin_url( '/js/admin.js'), array( 'opsd-global-vars' ), '1.1');
|
||||
wp_enqueue_script( 'opsd-admin-support', opsd_plugin_url( '/core/any/js/admin-support.js'), array( 'opsd-global-vars' ), '1.1');
|
||||
|
||||
// Chosen Library
|
||||
// wp_enqueue_script( 'opsd-chosen', opsd_plugin_url( '/assets/libs/chosen/chosen.jquery.min.js'), array( 'opsd-global-vars' ), '1.1' ); //FixIn: 1.1.2.5
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Support JavaScript functions
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/** Load Datepicker Localization JS File */
|
||||
/*
|
||||
function opsd_load_calendar_localization_file() {
|
||||
|
||||
// Datepicker Localization - translation for calendar. Example: $locale = 'fr_FR';
|
||||
$locale = opsd_get_locale();
|
||||
if ( ! empty( $locale ) ) {
|
||||
|
||||
$locale_lang = substr( $locale, 0, 2 );
|
||||
$locale_country = substr( $locale, 3 );
|
||||
|
||||
if ( ( $locale_lang !== 'en') && ( opsd_is_file_exist( '/js/datepick/jquery.datepick-' . $locale_lang . '.js' ) ) ) {
|
||||
|
||||
wp_enqueue_script( 'opsd-datepick-localize', opsd_plugin_url( '/js/datepick/jquery.datepick-'. $locale_lang . '.js' ), array( 'opsd-datepick' ), '1.1');
|
||||
|
||||
} else if ( ( ! in_array( $locale, array( 'en_US', 'en_CA', 'en_GB', 'en_AU' ) ) ) // English Exceptions
|
||||
&& ( opsd_is_file_exist( '/js/datepick/jquery.datepick-'. $locale_country . '.js' ) )
|
||||
) {
|
||||
|
||||
wp_enqueue_script( 'opsd-datepick-localize', opsd_plugin_url( '/js/datepick/jquery.datepick-'. $locale_country . '.js' ), array( 'opsd-datepick' ), '1.1');
|
||||
}
|
||||
}
|
||||
}*/
|
||||
|
||||
|
||||
/** Get URL Datepicker Localization JS File
|
||||
*
|
||||
* @return string - URL to calendar skin
|
||||
*/
|
||||
/*
|
||||
function opsd_get_calendar_localization_url() {
|
||||
// Datepicker Localization - translation for calendar. Example: $locale = 'fr_FR';
|
||||
$locale = opsd_get_locale();
|
||||
|
||||
$calendar_localization_url = false;
|
||||
|
||||
if ( ! empty( $locale ) ) {
|
||||
|
||||
$locale_lang = substr( $locale, 0, 2 );
|
||||
$locale_country = substr( $locale, 3 );
|
||||
|
||||
if ( ( $locale_lang !== 'en') && ( opsd_is_file_exist( '/js/datepick/jquery.datepick-' . $locale_lang . '.js' ) ) ) {
|
||||
|
||||
$calendar_localization_url = opsd_plugin_url( '/js/datepick/jquery.datepick-'. $locale_lang . '.js' );
|
||||
|
||||
} else if ( ( ! in_array( $locale, array( 'en_US', 'en_CA', 'en_GB', 'en_AU' ) ) ) // English Exceptions
|
||||
&& ( opsd_is_file_exist( '/js/datepick/jquery.datepick-'. $locale_country . '.js' ) )
|
||||
) {
|
||||
|
||||
$calendar_localization_url = opsd_plugin_url( '/js/datepick/jquery.datepick-'. $locale_country . '.js' );
|
||||
}
|
||||
}
|
||||
|
||||
return $calendar_localization_url;
|
||||
}
|
||||
*/
|
||||
|
||||
/** Get Registred jQuery version
|
||||
*
|
||||
* @global type $wp_scripts
|
||||
* @return string - jQuery version
|
||||
*/
|
||||
function opsd_get_registered_jquery_version() {
|
||||
global $wp_scripts;
|
||||
|
||||
$version = false;
|
||||
|
||||
if ( is_a( $wp_scripts, 'WP_Scripts' ) )
|
||||
if (isset( $wp_scripts->registered['jquery'] ))
|
||||
$version = $wp_scripts->registered['jquery']->ver;
|
||||
return $version;
|
||||
}
|
||||
|
||||
|
||||
/** Check if we activated loading of JS/CSS only on specific pages and then load or no it
|
||||
*
|
||||
* @param boolean $is_load_scripts - Default: true
|
||||
* @return boolean - true | false
|
||||
*/
|
||||
function opsd_is_load_css_js_on_client_page( $is_load_scripts ) {
|
||||
|
||||
return true;
|
||||
|
||||
if ( ! is_admin() ) { // Check on Client side only
|
||||
|
||||
$opsd_is_load_js_css_on_specific_pages = get_opsd_option( 'opsd_is_load_js_css_on_specific_pages' );
|
||||
if ( $opsd_is_load_js_css_on_specific_pages == 'On' ) {
|
||||
|
||||
$opsd_pages_for_load_js_css = get_opsd_option( 'opsd_pages_for_load_js_css' );
|
||||
|
||||
$opsd_pages_for_load_js_css = preg_split('/[\r\n]+/', $opsd_pages_for_load_js_css, -1, PREG_SPLIT_NO_EMPTY);
|
||||
|
||||
$request_uri = $_SERVER['REQUEST_URI']; // FixIn:5.4.1
|
||||
if ( strpos( $request_uri, 'opsd_hash=') !== false ) {
|
||||
$request_uri = parse_url($request_uri);
|
||||
if ( ( ! empty($request_uri ) ) && ( isset($request_uri['path'] ) ) ){
|
||||
$request_uri = $request_uri['path'];
|
||||
} else {
|
||||
$request_uri = $_SERVER['REQUEST_URI'];
|
||||
}
|
||||
}
|
||||
|
||||
if ( ( ! empty($opsd_pages_for_load_js_css ) ) && ( ! in_array( $request_uri, $opsd_pages_for_load_js_css ) ) )
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
add_filter( 'opsd_is_load_script_on_this_page', 'opsd_is_load_css_js_on_client_page' );
|
||||
307
wp-content/plugins/secure-downloads/core/opsd-products.php
Normal file
307
wp-content/plugins/secure-downloads/core/opsd-products.php
Normal file
@@ -0,0 +1,307 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package Products
|
||||
* @subpackage Support for Download Functions
|
||||
* @category Products
|
||||
*
|
||||
* @author wpdevelop
|
||||
* @link https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2017-03-01
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
/** Products for downloading */
|
||||
class OPSD_Products {
|
||||
|
||||
protected $products = array();
|
||||
|
||||
public static $settings = array( 'csv_separator' => ',' ); // unlike a const, static property values can be changed
|
||||
|
||||
function __construct( $csv = '' ) {
|
||||
|
||||
$opsd_csv_separator = get_opsd_option( 'opsd_csv_separator' );
|
||||
if ( ! empty( $opsd_csv_separator ) )
|
||||
self::$settings[ 'csv_separator' ] = $opsd_csv_separator;
|
||||
|
||||
if ( ! empty( $csv ) ) {
|
||||
$this->define_products_from_csv( $csv );
|
||||
}
|
||||
}
|
||||
|
||||
/** Parse CSV in specific format and Load Products.
|
||||
*
|
||||
* @param string $csv
|
||||
*/
|
||||
public function define_products_from_csv( $csv = '' ) {
|
||||
|
||||
if ( empty( $csv ) ) {
|
||||
$csv = get_opsd_option('opsd_products_csv' );
|
||||
}
|
||||
|
||||
// ID | Title | Version Number | Desciption | Path
|
||||
//
|
||||
// $this->products = array(); //Do we need to reset exist products list
|
||||
|
||||
$defaults = array( 'id' => ''
|
||||
, 'order' => '0'
|
||||
, 'ip' => '0.0.0.0' // '0.0.0.0' or '0' - Its means any IP
|
||||
, 'expire' => '+1 day' // for usage in strtotime function
|
||||
);
|
||||
|
||||
if ( ! empty( $csv ) ) {
|
||||
|
||||
$csv = str_replace( array("\r\n", "\r"), "\n", $csv );
|
||||
$csv_lines = explode( "\n", $csv );
|
||||
|
||||
foreach ( $csv_lines as $csv_line ) {
|
||||
|
||||
//0,Prod,Description,XXXXXXXXXX/fold/product.zip,0,1440
|
||||
$product_from_csv = explode( self::$settings['csv_separator'], $csv_line );
|
||||
if ( count($product_from_csv) > 4 ) {
|
||||
$product_arr = array();
|
||||
$i = 0;
|
||||
|
||||
// 137^Title OPSD^Version Number OPSD^Description^http://new/wp-content/uploads/opsd_lSJacOT1yVLFnrkqt2xR/2017/04/1-1.txt
|
||||
|
||||
$product_arr[ 'id' ] = trim( $product_from_csv[ $i ++ ] );
|
||||
$product_arr[ 'title' ] = trim( $product_from_csv[ $i ++ ] );
|
||||
$product_arr[ 'version_num' ] = trim( $product_from_csv[ $i ++ ] );
|
||||
$product_arr[ 'description' ] = trim( $product_from_csv[ $i ++ ] );
|
||||
$product_arr[ 'path' ] = trim( str_replace( site_url(), '', $product_from_csv[ $i ++ ] ) ); // Get local relative path
|
||||
|
||||
$this->products[] = wp_parse_args( $product_arr, $defaults ); // Add Product
|
||||
} else if ( count( $product_from_csv ) == 1 ){
|
||||
|
||||
|
||||
// Get section title - usually its contain only from TEXT row without COLUMN SEPARTORs
|
||||
$this->products[] = array( 'id' => floatval( microtime( false ) ) + wp_rand( 100 ), 'title' => $product_from_csv[0] ); //FixIn: 1.1.2.3
|
||||
}
|
||||
}
|
||||
}
|
||||
//debuge($this->products);
|
||||
}
|
||||
|
||||
|
||||
/** Count Real Products with Path to files
|
||||
*
|
||||
* @return int
|
||||
*/
|
||||
function get_products_count() {
|
||||
$cnt = 0;
|
||||
foreach ( $this->products as $prod ) {
|
||||
if ( ! empty( $prod[ 'path' ] ) )
|
||||
$cnt ++;
|
||||
}
|
||||
return $cnt;
|
||||
}
|
||||
|
||||
|
||||
/** Save products from products array
|
||||
*
|
||||
* @param array $new_products_arr
|
||||
*/
|
||||
public function save_products( $new_products_arr ) {
|
||||
|
||||
if ( is_array( $new_products_arr )) {
|
||||
|
||||
$csv_line = array();
|
||||
foreach ( $new_products_arr as $product_arr ) {
|
||||
|
||||
$csv_arr = array();
|
||||
|
||||
if ( isset( $product_arr['id'] ) ) {
|
||||
$csv_arr[] = str_replace( self::$settings['csv_separator'], '_', $product_arr['id'] ); // Fix issue of not have separator in contne of field
|
||||
}
|
||||
if ( isset( $product_arr['title'] ) ) {
|
||||
$csv_arr[] = str_replace( self::$settings['csv_separator'], '_', $product_arr['title'] ); // Fix issue of not have separator in contne of field
|
||||
}
|
||||
if ( isset( $product_arr['version_num'] ) ) {
|
||||
$csv_arr[] = str_replace( self::$settings['csv_separator'], '_', $product_arr['version_num'] ); // Fix issue of not have separator in contne of field
|
||||
}
|
||||
if ( isset( $product_arr['description'] ) ) {
|
||||
$csv_arr[] = str_replace( self::$settings['csv_separator'], '_', $product_arr['description'] ); // Fix issue of not have separator in contne of field
|
||||
}
|
||||
if ( isset( $product_arr['path'] ) ) {
|
||||
$csv_arr[] = str_replace( self::$settings['csv_separator'], '', $product_arr['path'] ); // Fix issue of not have separator in contne of field
|
||||
}
|
||||
|
||||
$csv_line[] = implode( self::$settings['csv_separator'], $csv_arr );
|
||||
}
|
||||
|
||||
$csv_line = implode( "\n", $csv_line );
|
||||
|
||||
update_opsd_option( 'opsd_products_csv', $csv_line );
|
||||
|
||||
return $csv_line;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
public function get_products() {
|
||||
return $this->products;
|
||||
}
|
||||
|
||||
|
||||
/** Get product by ID
|
||||
*
|
||||
* @param type $id
|
||||
* @return array | boolean
|
||||
*/
|
||||
public function get_product( $id ) {
|
||||
foreach ( $this->products as $product ) {
|
||||
if ( $product['id'] == $id )
|
||||
return $product;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/** Get Array of properties for specific product
|
||||
*
|
||||
* @param int $product_id - id of resource
|
||||
* @return array (
|
||||
[id] => 2
|
||||
[order] => 0
|
||||
[ip] => 0.0.0.0
|
||||
[ipl] => 0
|
||||
[expire] => +1440 seconds
|
||||
[title] => Pro (1 site usage)
|
||||
[size] => 3.45
|
||||
[path] => XXXXXXXXXX/pro/pro.zip
|
||||
*/
|
||||
function opsd_get_product( $product_id ) {
|
||||
|
||||
$products_obj = new OPSD_Products( get_opsd_option('opsd_products_csv' ) );
|
||||
|
||||
return $products_obj->get_product( $product_id );
|
||||
}
|
||||
|
||||
|
||||
/** Get replace shortcode for different products.
|
||||
*
|
||||
* @param array $product_id_arr - product array
|
||||
* @param array $opt - optional array with parameters, which redefined default product values array(
|
||||
'expire' => '+1 day'
|
||||
'ip' => '149.10.0.1'
|
||||
)
|
||||
* @return array array (
|
||||
[products_list] => Array( .... )
|
||||
[product_id] - ID of product
|
||||
[product_title] - title of product
|
||||
[product_description] - description of product
|
||||
[product_link] - secure URL for product download
|
||||
[product_filename] - filename of the product
|
||||
[product_size] - the download size in a friendly format such as 500 KB or 3.45 MB
|
||||
[product_expire_after] - expiry time in friendly format (e.g. 24 hours or 2 days etc)
|
||||
[product_expire_date] - exact expiry date and time (e.g. 2017-03-21 18:30)
|
||||
[product_summary] - complete product details including title, size, link etc
|
||||
---
|
||||
[siteurl] - inserting your site URL
|
||||
[remote_ip] - inserting IP address of the user who made this action
|
||||
[user_agent] - inserting contents of the User-Agent: header from the current request, if there is one
|
||||
[request_url] - inserting address of the page (if any), where visitor make this action
|
||||
[current_date] - inserting date of this action
|
||||
[current_time] - inserting time of this action
|
||||
)
|
||||
*/
|
||||
function opsd_get_product_replace_shortcodes( $product_id_arr = array(), $opt = array() ) {
|
||||
|
||||
$replace = array( 'products_list' => array() );
|
||||
|
||||
// Init and load all products
|
||||
$products_obj = new OPSD_Products( get_opsd_option('opsd_products_csv' ) );
|
||||
$product_id_arr = (array) $product_id_arr;
|
||||
|
||||
foreach ( $product_id_arr as $product_id ) {
|
||||
|
||||
$products_replace = array();
|
||||
|
||||
$product_arr = $products_obj->get_product( $product_id );
|
||||
|
||||
if ( ( empty( $product_arr[ 'path' ] ) )
|
||||
|| ( empty( $product_arr[ 'id' ] ) )
|
||||
)
|
||||
continue;
|
||||
|
||||
$products_replace['product_id'] = $product_arr['id']; // 1
|
||||
$products_replace['product_title'] = apply_opsd_filter( 'opsd_check_for_active_language', $product_arr['title'] ); // Product Name
|
||||
$products_replace['product_version'] = apply_opsd_filter( 'opsd_check_for_active_language', $product_arr['version_num'] ); // May be update num
|
||||
$products_replace['product_description']= apply_opsd_filter( 'opsd_check_for_active_language', $product_arr['description'] ); // Tra ta ta ...
|
||||
|
||||
if ( ! empty( $opt[ 'order' ] ) ) {
|
||||
|
||||
$products_replace['order'] = $opt[ 'order' ];
|
||||
|
||||
if ( strpos( $opt[ 'order' ], '@' ) !== false ) {
|
||||
$products_replace['link_sent_to'] = $opt[ 'order' ];
|
||||
}
|
||||
}
|
||||
|
||||
$products_replace['product_link'] = opsd_get_secret_link( $product_arr, $opt ); // http://server.com/?prefix=922015&product=MSwxNDg5OTI3Njg4LDAsMC4wLjAuMCwwLGFmYTFmMW/product.zip
|
||||
$products_replace['product_link'] = htmlspecialchars_decode(
|
||||
// '<a href="' .
|
||||
esc_url( $products_replace['product_link'] )
|
||||
// . '">' . __('here', 'secure-downloads') . '</a>'
|
||||
);
|
||||
// Get Redable Size of file
|
||||
$real_link = rtrim( get_site_url() , '/' ) . '/' . ltrim( $product_arr[ 'path' ], '/\\' );
|
||||
|
||||
$real_size = OPSD_Download::get_file_size( OPSD_Download::get_local_path_from_real_link( $real_link ) );
|
||||
$redable_size = OPSD_Download::readable_format_file_size( $real_size );
|
||||
|
||||
$products_replace['product_size'] = $redable_size; // 2.93 MB
|
||||
$products_replace['product_filename'] = OPSD_Download::get_file_name_from_path( $real_link ); // product.zip
|
||||
|
||||
// Do we ovveride expire CSV parameter from request FORM
|
||||
if ( ! empty( $opt['expire'] ) ) $product_arr['expire'] = $opt['expire'];
|
||||
|
||||
if ( opsd_is_valid_timestamp( $product_arr['expire'] ) ) {
|
||||
$expire_time_stamp = $product_arr['expire'];
|
||||
} else {
|
||||
$expire_time_stamp = strtotime( $product_arr['expire'] , current_time( 'timestamp' ) );
|
||||
}
|
||||
|
||||
$readable_expire = OPSD_Download::readable_format_seconds_to_words( $expire_time_stamp - current_time( 'timestamp' ) );
|
||||
|
||||
// 2 days
|
||||
$products_replace['product_expire_after'] = $readable_expire;
|
||||
|
||||
// 2017-03-19 14:48:08
|
||||
$products_replace['product_expire_date'] = date_i18n( get_opsd_option( 'opsd_date_format' ) . ' ' . get_opsd_option( 'opsd_time_format' )
|
||||
, $expire_time_stamp );
|
||||
|
||||
$products_replace['product_summary'] = '<strong>' . $products_replace['product_title'] . '</strong> '
|
||||
. '<a href="' . $products_replace['product_link'] . '" target="_blank">'
|
||||
. $products_replace['product_filename']
|
||||
. '</a>'
|
||||
. ' ('. $products_replace['product_size'] .')'
|
||||
. ' ~ ' . __( 'expire in', 'secure-downloads' ) . ' ' . $products_replace['product_expire_after'];
|
||||
$replace['products_list'][]= $products_replace;
|
||||
}
|
||||
|
||||
$replace[ 'siteurl' ] = htmlspecialchars_decode( '<a href="' . home_url() . '">' . home_url() . '</a>' );
|
||||
$replace[ 'remote_ip' ] = opsd_get_user_ip(); // The IP address from which the user is viewing the current page.
|
||||
$replace[ 'user_agent' ] = (isset($_SERVER['HTTP_USER_AGENT'])) ? $_SERVER['HTTP_USER_AGENT'] : ''; // Contents of the User-Agent: header from the current request, if there is one.
|
||||
$replace[ 'request_url' ] = (isset($_SERVER['HTTP_REFERER'])) ? $_SERVER['HTTP_REFERER'] : ''; // The address of the page (if any) where action was occured. Because we are sending it in Ajax request, we need to use the REFERER HTTP
|
||||
$replace[ 'current_date' ] = date_i18n( get_opsd_option( 'opsd_date_format' ) );
|
||||
$replace[ 'current_time' ] = date_i18n( get_opsd_option( 'opsd_time_format' ) );
|
||||
|
||||
// Get values for 1-st product
|
||||
if ( ! empty( $replace['products_list'] ) ){
|
||||
foreach ( $replace['products_list'][0] as $product_key => $product_value ) {
|
||||
$replace[ $product_key ] = $product_value;
|
||||
}
|
||||
}
|
||||
|
||||
//debuge('$replace',$replace);
|
||||
|
||||
return $replace;
|
||||
}
|
||||
244
wp-content/plugins/secure-downloads/core/opsd-translation.php
Normal file
244
wp-content/plugins/secure-downloads/core/opsd-translation.php
Normal file
@@ -0,0 +1,244 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @subpackage Translations Functions
|
||||
* @category Functions
|
||||
*
|
||||
* @author wpdevelop
|
||||
* @link https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 29.09.2015
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Transaltions ////////////////////////////////////////////////////////////
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
// New in WP 6.2 - firstly loaded transaltion from wp-content/languges and then chek only
|
||||
// use the override_load_textdomain filter to load your text domains manually.
|
||||
// apply_filters( 'override_load_textdomain', bool $override, string $domain, string $mofile )
|
||||
|
||||
/** Check text for active language section
|
||||
*
|
||||
* @param string $content_orig
|
||||
* @return string
|
||||
* Usage:
|
||||
* $text = apply_opsd_filter('opsd_check_for_active_language', $text );
|
||||
*/
|
||||
function opsd_check_for_active_language($content_orig){
|
||||
|
||||
$content = $content_orig;
|
||||
|
||||
$languages = array();
|
||||
$content_ex = explode('[lang',$content);
|
||||
|
||||
foreach ($content_ex as $value) {
|
||||
|
||||
if (substr($value,0,1) == '=') {
|
||||
|
||||
$pos_s = strpos($value,'=');
|
||||
$pos_f = strpos($value,']');
|
||||
$key = trim( substr($value, ($pos_s+1), ($pos_f-$pos_s-1) ) );
|
||||
$value_l = trim( substr($value, $pos_f+1 ) );
|
||||
$languages[$key] = $value_l;
|
||||
|
||||
} else
|
||||
$languages['default'] = $value;
|
||||
}
|
||||
|
||||
$locale = opsd_get_locale();
|
||||
// $locale = 'fr_FR';
|
||||
|
||||
if ( isset( $languages[$locale] ) ) $return_text = $languages[ $locale ];
|
||||
else $return_text = $languages[ 'default' ];
|
||||
|
||||
$return_text = opsd_check_qtranslate( $return_text, $locale );
|
||||
|
||||
$return_text = opsd_check_wpml_tags( $return_text, $locale ); //FixIn: 5.4.5.8
|
||||
|
||||
return $return_text;
|
||||
}
|
||||
|
||||
|
||||
/** Register and Translate everything in [wpml]Some Text to translate[/wpml] tags.
|
||||
*
|
||||
* @param string $text
|
||||
* @param string $locale
|
||||
* @return string
|
||||
*/
|
||||
function opsd_check_wpml_tags( $text, $locale='' ) { //FixIn: 5.4.5.8
|
||||
|
||||
if ( $locale == '' ) {
|
||||
$locale = opsd_get_locale();
|
||||
}
|
||||
if ( strlen( $locale ) > 2 ) {
|
||||
$locale = substr($locale, 0, 2 );
|
||||
}
|
||||
|
||||
$is_tranlsation_exist_s = strpos( $text, '[wpml]' );
|
||||
$is_tranlsation_exist_f = strpos( $text, '[/wpml]' );
|
||||
|
||||
if ( ( $is_tranlsation_exist_s !== false ) && ( $is_tranlsation_exist_f !== false ) ) {
|
||||
|
||||
$shortcode = 'wpml';
|
||||
|
||||
// Find anything between [wpml] and [/wpml] shortcodes. Magic here: [\s\S]*? - fit to any text
|
||||
preg_match_all( '/\[' . $shortcode . '\]([\s\S]*?)\[\/' . $shortcode . '\]/i', $text, $wpml_translations, PREG_SET_ORDER );
|
||||
//debuge( $wpml_translations );
|
||||
|
||||
foreach ( $wpml_translations as $translation ) {
|
||||
$text_to_replace = $translation[0];
|
||||
$translation_to_check = $translation[1];
|
||||
|
||||
if ( function_exists ( 'icl_register_string' ) ){
|
||||
|
||||
if ( false ) { // Depricated functions
|
||||
|
||||
// Help: https://wpml.org/documentation/support/translation-for-texts-by-other-plugins-and-themes/
|
||||
icl_register_string('Item Calendar', 'opsd-' . tag_escape( $translation_to_check ) , $translation_to_check );
|
||||
|
||||
//TODO: Need to execurte this after deactivation of plugin or after updating of some option...
|
||||
//icl_unregister_string ( 'Item Calendar', 'opsd-' . tag_escape( $translation_to_check ) );
|
||||
|
||||
if ( function_exists ( 'icl_translate' ) ){
|
||||
$translation_to_check = icl_translate ( 'Item Calendar', 'opsd-' . tag_escape( $translation_to_check ) , $translation_to_check );
|
||||
}
|
||||
|
||||
} else { // WPML Version: 3.2
|
||||
|
||||
// Help info: do_action( 'wpml_register_single_string', string $context, string $name, string $value )
|
||||
// https://wpml.org/wpml-hook/wpml_register_string_for_translation/
|
||||
do_action( 'wpml_register_single_string', 'Item Calendar', 'opsd-' . tag_escape( $translation_to_check ) , $translation_to_check );
|
||||
|
||||
|
||||
// Help info: apply_filters( 'wpml_translate_single_string', string $original_value, string $context, string $name, string $$language_code )
|
||||
// https://wpml.org/wpml-hook/wpml_translate_single_string/
|
||||
//$translation_to_check = apply_filters( 'wpml_translate_single_string', $translation_to_check, 'Item Calendar', 'opsd-' . tag_escape( $translation_to_check ) );
|
||||
$language_code = $locale;
|
||||
$translation_to_check = apply_filters( 'wpml_translate_single_string', $translation_to_check, 'Item Calendar', 'opsd-' . tag_escape( $translation_to_check ), $language_code );
|
||||
|
||||
}
|
||||
}
|
||||
$text = str_replace( $text_to_replace, $translation_to_check, $text );
|
||||
}
|
||||
}
|
||||
|
||||
return $text;
|
||||
}
|
||||
|
||||
|
||||
function opsd_check_qtranslate( $text, $locale='' ){
|
||||
|
||||
if ($locale == '') {
|
||||
$locale = opsd_get_locale();
|
||||
}
|
||||
if (strlen($locale)>2) {
|
||||
$locale = substr($locale, 0 ,2);
|
||||
}
|
||||
|
||||
$is_tranlsation_exist = strpos($text, '<!--:'.$locale.'-->');
|
||||
|
||||
if ($is_tranlsation_exist !== false) {
|
||||
$tranlsation_end = strpos($text, '<!--:-->', $is_tranlsation_exist);
|
||||
|
||||
$text = substr($text, $is_tranlsation_exist , ($tranlsation_end - $is_tranlsation_exist ) );
|
||||
}
|
||||
|
||||
return $text;
|
||||
}
|
||||
|
||||
|
||||
function opsd_load_translation(){
|
||||
|
||||
//$locale = 'fr_FR'; opsd_load_locale( $locale );
|
||||
|
||||
if ( ! opsd_load_locale() ) {
|
||||
opsd_load_locale('en_US');
|
||||
}
|
||||
|
||||
$locale = opsd_get_locale();
|
||||
}
|
||||
|
||||
|
||||
/** Overload loading of plugin transaltion files from "wp-content/plugins/languages" -> "wp-content/plugins/plugin_name/languages"
|
||||
*
|
||||
* W:\home\beta\www/wp-content/languages/plugins/secure-downloads-it_IT.mo -> W:\home\beta\www\wp-content\plugins\secure-downloads/languages/secure-downloads-it_IT.mo
|
||||
*
|
||||
* @param string $mofile
|
||||
* @param type $domain
|
||||
* @return string
|
||||
*/
|
||||
function opsd_load_custom_plugin_translation_file( $mofile, $domain ) {
|
||||
|
||||
if ( $domain == 'secure-downloads' ) {
|
||||
|
||||
$mofile = OPSD_PLUGIN_DIR . '/languages/' . basename( $mofile );
|
||||
}
|
||||
|
||||
return $mofile;
|
||||
}
|
||||
add_filter( 'load_textdomain_mofile', 'opsd_load_custom_plugin_translation_file' , 10, 2 );
|
||||
|
||||
|
||||
function opsd_load_locale( $locale = '' ) {
|
||||
|
||||
if ( empty( $locale ) )
|
||||
$locale = opsd_get_locale();
|
||||
|
||||
if ( ! empty( $locale ) ) {
|
||||
|
||||
$domain = 'secure-downloads';
|
||||
$mofile = OPSD_PLUGIN_DIR . '/languages/' . $domain . '-' . $locale . '.mo';
|
||||
|
||||
if ( file_exists( $mofile ) ) {
|
||||
|
||||
$plugin_rel_path = OPSD_PLUGIN_DIRNAME . '/languages' ;
|
||||
return load_plugin_textdomain( $domain, false, $plugin_rel_path ) ;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
function opsd_get_locale() {
|
||||
|
||||
if ( defined( 'OPSD_RELOAD' ) )
|
||||
return OPSD_RELOAD;
|
||||
else
|
||||
define( 'OPSD_RELOAD', get_locale() );
|
||||
|
||||
return get_locale();
|
||||
}
|
||||
|
||||
|
||||
function opsd_recheck_plugin_locale( $locale, $plugin_domain = '' ) { //FixIn: 1.1.2.2
|
||||
|
||||
if ( $plugin_domain == 'item' )
|
||||
if ( defined('OPSD_RELOAD') )
|
||||
return OPSD_RELOAD;
|
||||
|
||||
return $locale;
|
||||
}
|
||||
add_filter( 'plugin_locale', 'opsd_recheck_plugin_locale', 100, 2 ); // When load_plugin_text_domain is work, its get def locale and not that, we send to it so need to reupdate it
|
||||
|
||||
/** Get help rows about configuration in_several languges
|
||||
*
|
||||
* @return array - each item of array is text row for showing.
|
||||
*/
|
||||
function opsd_get_help_rows_about_config_in_several_languges() {
|
||||
|
||||
$field_options = array();
|
||||
$field_options[] = '<strong>' . __('Configuration in several languages' , 'secure-downloads') . '</strong>';
|
||||
$field_options[] = sprintf(__('%s - start new translation section, where %s - locale of translation' , 'secure-downloads'),'<code>[lang=LOCALE]</code>','<code>LOCALE</code>');
|
||||
$field_options[] = sprintf(__('Example #1: %s - start French translation section' , 'secure-downloads'),'<code>[lang=fr_FR]</code>');
|
||||
$field_options[] = sprintf(__('Example #2: "%s" - English and French translation of some message' , 'secure-downloads'),'<code>Thank you for your item.[lang=fr_FR]Je vous remercie de votre reservation.</code>');
|
||||
|
||||
return $field_options;
|
||||
}
|
||||
|
||||
|
||||
704
wp-content/plugins/secure-downloads/core/opsd-upload.php
Normal file
704
wp-content/plugins/secure-downloads/core/opsd-upload.php
Normal file
@@ -0,0 +1,704 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package File Upload
|
||||
* @subpackage Support Upload Functions
|
||||
* @category Functions
|
||||
*
|
||||
* @author wpdevelop
|
||||
* @link https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2017-04-14
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
/** Code usage in other places for Upload, Selection and Insertion of file URL
|
||||
*
|
||||
<div>
|
||||
<input type="text" value="" wrap="off" placeholder="..." class="opsd_file_urls" name="opsd_file_urls" />
|
||||
<a href="javascript:void(0)" class="button opsd_btn_upload"
|
||||
data-modal_title="<?php echo esc_attr( __( 'Choose file', 'secure-downloads' ) ); ?>"
|
||||
data-btn_title="<?php echo esc_attr( __( 'Insert file URL', 'secure-downloads' ) ); ?>"
|
||||
><?php _e( 'Upload File', 'secure-downloads' ); ?></a>
|
||||
</div>
|
||||
<?php
|
||||
|
||||
$opsd_upload = opsd_upload(); // Get OPSD_Upload obj instance
|
||||
|
||||
$opsd_upload->set_upload_button( '.opsd_btn_upload' );
|
||||
|
||||
$opsd_upload->set_element_insert_url( '.opsd_file_urls' );
|
||||
?>
|
||||
*
|
||||
*/
|
||||
|
||||
// General Init Class
|
||||
final class OPSD_Upload {
|
||||
|
||||
public $settings = array(
|
||||
'upload_button' => ''
|
||||
, 'element_insert_url' => ''
|
||||
, 'wp_media_uploader_params' => array( 'key' => 'opsd_type', 'value' => 'opsd_upload' ) // Required for setting OUR Dir for uploading and set it PROTECTED
|
||||
);
|
||||
|
||||
// Define only one instance of this class
|
||||
static private $instance = NULL;
|
||||
|
||||
public static function init() {
|
||||
|
||||
if ( ! isset( self::$instance ) && ! ( self::$instance instanceof OPSD_Upload ) ) {
|
||||
|
||||
self::$instance = new OPSD_Upload;
|
||||
|
||||
add_filter( 'upload_dir', array( self::$instance, 'filter_upload_dir' ) );
|
||||
|
||||
add_action( 'admin_footer', array( self::$instance, 'js' ), 50 ); // Load JavaScript Code at the footer of the Admin Panel page. Executed in ALL Admin Menu Pages
|
||||
|
||||
//TODO: remove this
|
||||
// add_filter( 'posts_where', array( self::$instance, 'opsd_filter_posts_where' ) );
|
||||
// add_action('pre_get_posts', array( self::$instance, 'opsd_pre_get_posts' ) );
|
||||
|
||||
self::$instance->protect_upload_dir();
|
||||
}
|
||||
return self::$instance;
|
||||
}
|
||||
|
||||
|
||||
/** Get Name of protected DIR name, like opsd_XXXXX
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function get_protected_dir_name() {
|
||||
|
||||
$get_protected_dir_name = get_opsd_option( 'opsd_protected_directory_name_level1' );
|
||||
|
||||
if ( empty( $get_protected_dir_name ) ) {
|
||||
$get_protected_dir_name = 'opsd_' . wp_generate_password( 20, false, false );
|
||||
update_opsd_option( 'opsd_protected_directory_name_level1', $get_protected_dir_name );
|
||||
}
|
||||
|
||||
$get_protected_dir_name = untrailingslashit($get_protected_dir_name);
|
||||
|
||||
return $get_protected_dir_name;
|
||||
}
|
||||
|
||||
|
||||
/** Get all settings or specific setting option
|
||||
*
|
||||
* @param string $key
|
||||
* @return mixed
|
||||
*/
|
||||
public function get_settings( $key = '' ) {
|
||||
|
||||
if ( '' === $key )
|
||||
return $this->settings;
|
||||
|
||||
if ( isset( $this->settings[ $key ] ) )
|
||||
return $this->settings[ $key ];
|
||||
else
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
//TODO: remove this
|
||||
/*
|
||||
function opsd_pre_get_posts( $query ) {
|
||||
debuge_log( $_POST );
|
||||
if ( is_admin() || ! $query->is_main_query() ) {
|
||||
return;
|
||||
}
|
||||
|
||||
$discount = $query->get( 'discount' );
|
||||
|
||||
if ( ! empty( $discount ) ) {
|
||||
|
||||
// unset ref var from $wp_query
|
||||
$query->set( 'discount', null );
|
||||
|
||||
global $wp;
|
||||
|
||||
// unset ref var from $wp
|
||||
unset( $wp->query_vars[ 'discount' ] );
|
||||
|
||||
// if in home (because $wp->query_vars is empty) and 'show_on_front' is page
|
||||
if ( empty( $wp->query_vars ) && get_option( 'show_on_front' ) === 'page' ) {
|
||||
|
||||
// reset and re-parse query vars
|
||||
$wp->query_vars['page_id'] = get_option( 'page_on_front' );
|
||||
$query->parse_query( $wp->query_vars );
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
*/
|
||||
|
||||
//TODO: remove this
|
||||
/**
|
||||
* @param string $where Where clause
|
||||
* @return string $where Modified where clause
|
||||
*/
|
||||
/*
|
||||
function opsd_filter_posts_where( $where = '' ) {
|
||||
|
||||
debuge_log( $_POST );
|
||||
return $where;
|
||||
//debuge( maybe_unserialize( 'a:3:{s:6:"action";s:17:"query-attachments";s:7:"post_id";s:1:"0";s:5:"query";a:4:{s:7:"orderby";s:4:"date";s:5:"order";s:4:"DESC";s:14:"posts_per_page";s:2:"40";s:5:"paged";s:1:"1";}}' ));
|
||||
|
||||
$media_uploader_params = $this->get_settings( 'wp_media_uploader_params' );
|
||||
if ( ( isset( $_POST['query'] ) )
|
||||
&& ( isset( $_POST['query'][ $media_uploader_params[ 'key' ] ] ) )
|
||||
&& ( $media_uploader_params[ 'value' ] === $_POST['query'][ $media_uploader_params[ 'key' ] ] )
|
||||
) {
|
||||
|
||||
global $wpdb;
|
||||
$where .= " AND guid LIKE '%".$wpdb->esc_like( untrailingslashit( get_opsd_option( 'opsd_protected_directory_name_level1' ) ) )."%'";
|
||||
}
|
||||
return $where;
|
||||
}
|
||||
*/
|
||||
|
||||
/** Filters the uploads directory array,
|
||||
* after CLICKING on our Upload Button and USE our wp.media thanks to 'wp_media_uploader_params'
|
||||
*
|
||||
* @param array $uploads Array of upload directory data:
|
||||
array (
|
||||
[path] => Z:\home\new\www/wp-content/uploads/opsd_lSJacOT1yVLFnrkqt2xR/2017/04
|
||||
[url] => http://new/wp-content/uploads/opsd_lSJacOT1yVLFnrkqt2xR/2017/04
|
||||
|
||||
[subdir] => /opsd_lSJacOT1yVLFnrkqt2xR/2017/04
|
||||
[basedir] => Z:\home\new\www/wp-content/uploads
|
||||
|
||||
[baseurl] => http://new/wp-content/uploads
|
||||
[error] =>
|
||||
)
|
||||
|
||||
*$uploads = apply_filters( 'upload_dir', $cache[ $key ] );
|
||||
*
|
||||
* @param type $param
|
||||
*/
|
||||
public function filter_upload_dir( $param ) {
|
||||
|
||||
//TODO: here we can create own TAGs and Versioning directory structure in some way.
|
||||
|
||||
$media_uploader_params = $this->get_settings( 'wp_media_uploader_params' );
|
||||
|
||||
if ( isset( $_POST[ $media_uploader_params[ 'key' ] ] ) && $media_uploader_params[ 'value' ] === $_POST[ $media_uploader_params[ 'key' ] ] ) {
|
||||
|
||||
$protected_dir_name = $this->get_protected_dir_name();
|
||||
|
||||
if ( empty( $param['subdir'] ) ) {
|
||||
|
||||
$param['path'] = $param['path'] . '/' . $protected_dir_name;
|
||||
$param['url'] = $param['url'] . '/' . $protected_dir_name;
|
||||
$param['subdir'] = '/' . $protected_dir_name;
|
||||
|
||||
} else {
|
||||
$new_subdir = '/' . $protected_dir_name . $param['subdir'];
|
||||
|
||||
$param['path'] = str_replace( $param['subdir'], $new_subdir, $param['path'] );
|
||||
$param['url'] = str_replace( $param['subdir'], $new_subdir, $param['url'] );
|
||||
$param['subdir'] = str_replace( $param['subdir'], $new_subdir, $param['subdir'] );
|
||||
}
|
||||
}
|
||||
|
||||
return $param;
|
||||
}
|
||||
|
||||
|
||||
/** Get path to protected dir.
|
||||
*
|
||||
* @return type
|
||||
*/
|
||||
public function get_protected_dir() {
|
||||
|
||||
// Protected secret name LEVEL 1
|
||||
$dir_level1 = $this->get_protected_dir_name();
|
||||
|
||||
// Install files and folders for uploading files and prevent hotlinking
|
||||
$upload_dir = wp_upload_dir();
|
||||
|
||||
return $upload_dir['basedir'] . '/' . $dir_level1;
|
||||
}
|
||||
|
||||
|
||||
/** Check and Protect upload folder each time
|
||||
*
|
||||
* May be we need to have 2 folders, like /opsd_xxxxx/XXXXXXXXXXXXX
|
||||
* for prevent of dir listing at previous stage /opsd_xxxxx with .htaccess file
|
||||
*
|
||||
* Typical Directory structure
|
||||
* /wp-content/uploads/
|
||||
* /opsd_xxxxx {main dir}
|
||||
* /.htaccess (Deny access and deny dir listing)
|
||||
* /.index.php (Silence is golden)
|
||||
* /XXXXXXXXXXXXX (Secret dir for store files)
|
||||
*/
|
||||
function protect_upload_dir() {
|
||||
|
||||
// Protected secret name LEVEL 1
|
||||
$dir_level1 = $this->get_protected_dir_name();
|
||||
|
||||
// Install files and folders for uploading files and prevent hotlinking
|
||||
$upload_dir = wp_upload_dir();
|
||||
|
||||
$files = array(
|
||||
array(
|
||||
'base' => $upload_dir['basedir'] . '/' . $dir_level1,
|
||||
'file' => '.htaccess',
|
||||
'content' => 'Options -Indexes' . "\n"
|
||||
. 'deny from all'
|
||||
)
|
||||
, array(
|
||||
'base' => $upload_dir['basedir'] . '/' . $dir_level1,
|
||||
'file' => 'index.php',
|
||||
'content' => '<?php ' . "\n"
|
||||
. '// Silence is golden.'
|
||||
|
||||
)
|
||||
);
|
||||
|
||||
foreach ( $files as $file ) {
|
||||
|
||||
if ( ( wp_mkdir_p( $file['base'] ) ) // Recursive directory creation based on full path.
|
||||
&& ( ! file_exists( trailingslashit( $file['base'] ) . $file['file'] ) ) // If file not exist
|
||||
) {
|
||||
|
||||
if ( $file_handle = @fopen( trailingslashit( $file['base'] ) . $file['file'], 'w' ) ) {
|
||||
|
||||
fwrite( $file_handle, $file['content'] );
|
||||
fclose( $file_handle );
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** Define element for opening wp media after clicking
|
||||
*
|
||||
* @param string $jq_selector
|
||||
*/
|
||||
public function set_upload_button( $jq_selector ) {
|
||||
$this->settings['upload_button'] = $jq_selector;
|
||||
}
|
||||
|
||||
|
||||
/** Define element for inserting URL of file from wp media
|
||||
*
|
||||
* @param type $jq_selector
|
||||
*/
|
||||
public function set_element_insert_url( $jq_selector ) {
|
||||
$this->settings['element_insert_url'] = $jq_selector;
|
||||
}
|
||||
|
||||
|
||||
public function js() {
|
||||
|
||||
//set JavaScript only if we set upload button
|
||||
$jq_sel_upload_button = $this->get_settings( 'upload_button' );
|
||||
|
||||
if ( empty( $jq_sel_upload_button ) )
|
||||
return;
|
||||
|
||||
|
||||
?>
|
||||
<!-- OPSD JavaScript -->
|
||||
<script type="text/javascript">
|
||||
var opsd_file_frame;
|
||||
(function($){
|
||||
//'use strict';
|
||||
<?php $media_uploader_params = $this->get_settings( 'wp_media_uploader_params' ); ?>
|
||||
// Our wp media frame
|
||||
|
||||
|
||||
jQuery( '<?php echo $this->get_settings('upload_button'); ?>' ).on( 'click', function( event ) {
|
||||
|
||||
var j_btn = jQuery( this );
|
||||
var is_multi_selection = true;
|
||||
|
||||
var insert_field_separator = '<?php $opsd_csv_separator = get_opsd_option( 'opsd_csv_separator' ); echo empty( $opsd_csv_separator ) ? ',' : $opsd_csv_separator; ?>';
|
||||
|
||||
// Stop the anchor's default behavior
|
||||
event.preventDefault();
|
||||
|
||||
// If frame exist close it
|
||||
if ( opsd_file_frame ) {
|
||||
opsd_file_frame.close();
|
||||
}
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////////////
|
||||
// Create Media Frame
|
||||
///////////////////////////////////////////////////////////////////////
|
||||
opsd_file_frame = wp.media.frames.opsd_upload_file_frame = wp.media( { // Check here ../wp-includes/js/media-views.js
|
||||
// Set the title of the modal.
|
||||
title: j_btn.data( 'modal_title' ),
|
||||
library: {
|
||||
type: ''
|
||||
},
|
||||
button: {
|
||||
text: j_btn.data( 'btn_title' ),
|
||||
},
|
||||
multiple: is_multi_selection,
|
||||
states: [
|
||||
new wp.media.controller.Library( {
|
||||
<?php
|
||||
// Add to this libaray custom post parameter: $_POST['query'][ $media_uploader_params['key'] ] = $media_uploader_params['value']
|
||||
// We are checking in functon opsd_filter_posts_where media files that only relative to this medi Frame opening
|
||||
// And filtering posts (in WHERE) relative custom path to our files.
|
||||
// echo '{' . $media_uploader_params['key'] . ": '" . $media_uploader_params['value'] . "' }";
|
||||
?>
|
||||
library: wp.media.query(),
|
||||
multiple: is_multi_selection,
|
||||
title: j_btn.data( 'modal_title' ),
|
||||
priority: 15,
|
||||
filterable: 'uploaded',
|
||||
//idealColumnWidth: 125
|
||||
} )
|
||||
]
|
||||
} );
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////////////
|
||||
// Set custom parameters for uploader -> $_POST['opsd_type'] - checking in "upload_dir", when filter_upload_dir
|
||||
///////////////////////////////////////////////////////////////////////
|
||||
opsd_file_frame.on( 'ready', function () {
|
||||
opsd_file_frame.uploader.options.uploader.params = {
|
||||
type: 'opsd_download',
|
||||
<?php
|
||||
echo $media_uploader_params['key'] . ": '" . $media_uploader_params['value'] . "'";
|
||||
?>
|
||||
};
|
||||
} );
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////////////
|
||||
// When File have selected, do this
|
||||
///////////////////////////////////////////////////////////////////////
|
||||
opsd_file_frame.on( 'select', function () {
|
||||
|
||||
if ( ! is_multi_selection ) { // Single file
|
||||
|
||||
var attachment = opsd_file_frame.state().get('selection').first().toJSON();
|
||||
|
||||
// Put URL of file to text field
|
||||
j_btn.parent().find('<?php echo $this->get_settings('element_insert_url'); ?>').val( attachment.url );
|
||||
|
||||
} else { // Multiple files.
|
||||
|
||||
var file_paths = '';
|
||||
var csv_data_line = '';
|
||||
opsd_file_frame.state().get('selection').map( function ( attachment ) {
|
||||
|
||||
// Request new data
|
||||
//attachment.fetch().then(function (data) {
|
||||
// console.log(data);
|
||||
// // preloading finished
|
||||
// // after this you can use your attachment normally
|
||||
// //wp.media.attachment( attachment.id ).get('url');
|
||||
//});
|
||||
|
||||
attachment = attachment.toJSON();
|
||||
//console.log( attachment );
|
||||
|
||||
if ( attachment.url ) {
|
||||
// Insert info from selected files
|
||||
csv_data_line = attachment.id + insert_field_separator + attachment.title + insert_field_separator + attachment.opsd_version_num + insert_field_separator + attachment.description + insert_field_separator + attachment.url
|
||||
file_paths = file_paths ? file_paths + "\n" + csv_data_line : csv_data_line;
|
||||
}
|
||||
|
||||
// file_paths = file_paths ? file_paths + "\n" + attachment.url : attachment.url;
|
||||
});
|
||||
|
||||
//j_btn.parent().find('<?php echo $this->get_settings('element_insert_url'); ?>').val( file_paths );
|
||||
jQuery( '#opsd_products_csv_text' ).val( file_paths + "\n\n" + jQuery( '#opsd_products_csv_text' ).val() );
|
||||
}
|
||||
|
||||
} );
|
||||
|
||||
if (0) {
|
||||
/** Remove Dom element of Media element from Media browser, if the URL not from our settings.
|
||||
*
|
||||
* @param {type} my_model_obj
|
||||
* @returns {undefined}
|
||||
*/
|
||||
function opsd_remove_media_element_from_container( my_model_obj , delay_time ) {
|
||||
|
||||
/** Attributes:
|
||||
'id': 112
|
||||
'title': __71
|
||||
'filename': 71.zip
|
||||
'url': http://server.com/wp-content/uploads/opsd_lSJacOT1yVLFnrkqt2xR/2017/04/71.zip'
|
||||
'link': http://server.com/__71/'
|
||||
'alt':
|
||||
'author': 1
|
||||
'description':
|
||||
'caption':
|
||||
'name': __71
|
||||
'status': inherit
|
||||
'uploadedTo': 0
|
||||
'date': Mon Apr 17 2017 14:30:32
|
||||
'modified': Mon Apr 17 2017 14:30:32
|
||||
'menuOrder': 0
|
||||
'mime': application/zip
|
||||
'type': application
|
||||
'subtype': zip
|
||||
'icon': http://server.com/wp-includes/images/media/archive.png
|
||||
'dateFormatted': April 17, 2017
|
||||
'nonces': [object Object]
|
||||
'editLink': http://server.com/wp-admin/post.php?post=112&action=edit
|
||||
'meta': false
|
||||
'authorName': admin_name
|
||||
'filesizeInBytes': 324104
|
||||
'filesizeHumanReadable': 317 KB
|
||||
'compat': [object Object]
|
||||
*/
|
||||
|
||||
// Sometimes need some delay
|
||||
_.delay( function() {
|
||||
|
||||
if ( my_model_obj.attributes.url != undefined ) {
|
||||
if ( my_model_obj.attributes.url.indexOf('/<?php echo $this->get_protected_dir_name(); ?>/') === -1 ) {
|
||||
//console.log( my_model_obj.attributes.url );
|
||||
//wp.media.model.Attachment.get("collection").collection.remove( my_model_obj );
|
||||
|
||||
jQuery( "li[data-id='" + my_model_obj.attributes.id + "']" ).remove();
|
||||
}
|
||||
}
|
||||
|
||||
}, delay_time );
|
||||
|
||||
}
|
||||
|
||||
wp.media.model.Attachment.get("collection").collection.on( 'change', function( my_model_obj ) {
|
||||
opsd_remove_media_element_from_container( my_model_obj , 1);
|
||||
});
|
||||
|
||||
// Fires, when Content redraw
|
||||
opsd_file_frame.on( 'content:activate:browse', function(){
|
||||
|
||||
var opsd_models = wp.media.model.Attachment.get("collection").collection.models;
|
||||
|
||||
_.each( opsd_models, function( my_model_obj, ind) {
|
||||
|
||||
opsd_remove_media_element_from_container( my_model_obj , 1 );
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
/*
|
||||
// Fires when a state activates.
|
||||
opsd_file_frame.on( 'activate', function() { alert('activate'); } );
|
||||
|
||||
// Fires after the frame markup has been built, but not appended to the DOM.
|
||||
// @see wp.media.view.Modal.attach()
|
||||
opsd_file_frame.on( 'ready', function() { alert('ready'); } );
|
||||
|
||||
// Fires when the frame's $el is appended to its DOM container.
|
||||
// @see media.view.Modal.attach()
|
||||
opsd_file_frame.on( 'attach', function() { alert('attach'); } );
|
||||
|
||||
// Fires when the modal opens (becomes visible).
|
||||
// @see media.view.Modal.open()
|
||||
opsd_file_frame.on( 'open', function() { alert('open'); } );
|
||||
|
||||
// Fires when the modal closes via the escape key.
|
||||
// @see media.view.Modal.close()
|
||||
opsd_file_frame.on( 'escape', function() { alert('escape'); } );
|
||||
|
||||
// Fires when the modal closes.
|
||||
// @see media.view.Modal.close()
|
||||
opsd_file_frame.on( 'close', function() { alert('close'); } );
|
||||
|
||||
// Fires when a user has selected attachment(s) and clicked the select button.
|
||||
// @see media.view.MediaFrame.Post.mainInsertToolbar()
|
||||
opsd_file_frame.on( 'select', function() {
|
||||
var selectionCollection = opsd_file_frame.state().get('select');
|
||||
} );
|
||||
|
||||
// Fires when a mode is deactivated on a region { 'menu' | title | content | toolbar | router }
|
||||
opsd_file_frame.on( 'content:deactivate', function() { alert('{region}:deactivate'); } );
|
||||
// and a more specific event including the mode.
|
||||
opsd_file_frame.on( 'content:deactivate:{mode}', function() { alert('{region}:deactivate{mode}'); } );
|
||||
|
||||
// Fires when a region is ready for its view to be created.
|
||||
opsd_file_frame.on( 'content:create', function() { alert('{region}:create'); } );
|
||||
// and a more specific event including the mode.
|
||||
opsd_file_frame.on( 'content:create:{mode}', function() { alert('{region}:create{mode}'); } );
|
||||
|
||||
// Fires when a region is ready for its view to be rendered.
|
||||
opsd_file_frame.on( 'content:render', function() { alert('{region}:render'); } );
|
||||
// and a more specific event including the mode.
|
||||
opsd_file_frame.on( 'content:render:{mode}', function() { alert('{region}:render{mode}'); } );
|
||||
|
||||
// Fires when a new mode is activated (after it has been rendered) on a region.
|
||||
opsd_file_frame.on( 'content:activate', function() { alert('{region}:activate'); } );
|
||||
// and a more specific event including the mode.
|
||||
opsd_file_frame.on( 'content:activate:{mode}', function() { alert('{region}:activate{mode}'); } );
|
||||
|
||||
// Get an object representing the current state.
|
||||
//opsd_file_frame.state();
|
||||
|
||||
// Get an object representing the previous state.
|
||||
//opsd_file_frame.lastState();
|
||||
*/
|
||||
|
||||
if(0) {
|
||||
// Debuge all events from media Frame!
|
||||
opsd_file_frame.on("all", function(eventName) {
|
||||
console.log('Frame Event: ' + eventName);
|
||||
});
|
||||
|
||||
// Debuge all events from media Frame!
|
||||
wp.media.model.Attachment.get("collection").collection.on("all", function(eventName) {
|
||||
console.log('[Collection] Event: ' + eventName);
|
||||
});
|
||||
wp.media.model.Attachment.get("models").collection.on( "all", function(eventName) {
|
||||
console.log('[models] Event: ' + eventName);
|
||||
});
|
||||
wp.media.model.Attachment.get("views").collection.on( "all", function(eventName) {
|
||||
console.log('[views] Event: ' + eventName);
|
||||
});
|
||||
}
|
||||
// Open the modal.
|
||||
opsd_file_frame.open();
|
||||
});
|
||||
|
||||
})(jQuery);
|
||||
|
||||
</script>
|
||||
<!-- End OPSD JavaScript -->
|
||||
<?php
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* The main function responsible for returning the one true Instance to functions everywhere.
|
||||
*
|
||||
* Example: <?php $opsd_upload = opsd_upload(); ?>
|
||||
*/
|
||||
function opsd_upload() {
|
||||
return OPSD_Upload::init();
|
||||
}
|
||||
opsd_upload(); // Start
|
||||
|
||||
|
||||
/** Add Version Number Field to Attachment Section of Media Window
|
||||
*
|
||||
* @param array $form_fields
|
||||
* @param obj $post
|
||||
* @return array
|
||||
*/
|
||||
function opsd_add_attachment_version_num_field( $form_fields, $post ) {
|
||||
|
||||
$field_value = get_post_meta( $post->ID, 'opsd_version_num', true );
|
||||
|
||||
$form_fields[ 'opsd_version_num' ] = array(
|
||||
'value' => $field_value ? $field_value : '',
|
||||
'label' => __( 'Vesion' ),
|
||||
//'helps' => __( 'Set version number' )
|
||||
);
|
||||
return $form_fields;
|
||||
}
|
||||
add_filter( 'attachment_fields_to_edit', 'opsd_add_attachment_version_num_field', 10, 2 );
|
||||
|
||||
|
||||
/** Save Version Number as meta key relative specific attachment.
|
||||
*
|
||||
* @param type $attachment_id
|
||||
*/
|
||||
function opsd_save_attachment_version_num( $attachment_id ) {
|
||||
|
||||
if ( isset( $_REQUEST[ 'attachments' ][ $attachment_id ][ 'opsd_version_num' ] ) ) {
|
||||
$version_num = wp_kses_post( trim( stripslashes( $_REQUEST[ 'attachments' ][ $attachment_id ][ 'opsd_version_num' ] ) ) );
|
||||
update_post_meta( $attachment_id, 'opsd_version_num', $version_num );
|
||||
}
|
||||
}
|
||||
add_action( 'edit_attachment', 'opsd_save_attachment_version_num' );
|
||||
|
||||
|
||||
/** Get Meta key "Version Number" e.g. 'opsd_version_num' when fetching data about attachment
|
||||
*
|
||||
* Filters the attachment data prepared for JavaScript.
|
||||
*
|
||||
* @since 3.5.0
|
||||
*
|
||||
* @param array $response Array of prepared attachment data.
|
||||
* @param int|object $attachment Attachment ID or object.
|
||||
* @param array $meta Array of attachment meta data.
|
||||
*/
|
||||
function opsd_wp_prepare_attachment_for_js( $response, $attachment, $meta ){
|
||||
|
||||
if ( is_object( $attachment ) )
|
||||
$attachment_id = $attachment->ID;
|
||||
else
|
||||
$attachment_id = $attachment;
|
||||
|
||||
$field_value = get_post_meta( $attachment_id, 'opsd_version_num', true );
|
||||
|
||||
$response[ 'opsd_version_num' ] = $field_value;
|
||||
|
||||
return $response;
|
||||
}
|
||||
add_filter('wp_prepare_attachment_for_js', 'opsd_wp_prepare_attachment_for_js' , 10, 3 );
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/* we have in WP function
|
||||
sanitize_file_name( $filename )
|
||||
*
|
||||
filename altering:
|
||||
*
|
||||
* so product.bl.zip become product.bl_.zip
|
||||
*
|
||||
*
|
||||
*
|
||||
* Loop over any intermediate extensions. Postfix them with a trailing underscore
|
||||
* if they are a 2 - 5 character long alpha string not in the extension whitelist.
|
||||
|
||||
foreach ( (array) $parts as $part) {
|
||||
$filename .= '.' . $part;
|
||||
|
||||
if ( preg_match("/^[a-zA-Z]{2,5}\d?$/", $part) ) {
|
||||
$allowed = false;
|
||||
foreach ( $mimes as $ext_preg => $mime_match ) {
|
||||
$ext_preg = '!^(' . $ext_preg . ')$!i';
|
||||
if ( preg_match( $ext_preg, $part ) ) {
|
||||
$allowed = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if ( !$allowed )
|
||||
$filename .= '_';
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
function opsd_sanitize_file_name( $filename, $filename_raw ) {
|
||||
|
||||
/* $filename, $filename_raw, $_REQUEST
|
||||
[0] => product.bl_.zip
|
||||
[1] => secure-downloads.bl.zip
|
||||
[2] => Array
|
||||
(
|
||||
[name] => secure-downloads.bl.zip
|
||||
[post_id] => 0
|
||||
[_wpnonce] => 90049ce803
|
||||
[type] =>
|
||||
[tab] =>
|
||||
[short] => 1
|
||||
)
|
||||
*/
|
||||
return $filename;
|
||||
}
|
||||
// add_filter( 'sanitize_file_name', 'opsd_sanitize_file_name', 10, 2 );
|
||||
417
wp-content/plugins/secure-downloads/core/opsd.php
Normal file
417
wp-content/plugins/secure-downloads/core/opsd.php
Normal file
@@ -0,0 +1,417 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @subpackage Core
|
||||
* @category Items
|
||||
*
|
||||
* @author wpdevelop
|
||||
* @link https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2014.07.29
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
|
||||
|
||||
|
||||
if ( ! class_exists( 'OPSD_Init' ) ) :
|
||||
|
||||
|
||||
// General Init Class
|
||||
final class OPSD_Init {
|
||||
|
||||
static private $instance = NULL;
|
||||
|
||||
public $cron;
|
||||
public $notice;
|
||||
public $opsd_obj;
|
||||
|
||||
|
||||
public $admin_menu;
|
||||
public $js;
|
||||
public $css;
|
||||
|
||||
|
||||
/** Get Single Instance of this Class and Init Plugin */
|
||||
public static function init() {
|
||||
|
||||
if ( ! isset( self::$instance ) && ! ( self::$instance instanceof OPSD_Init ) ) {
|
||||
|
||||
global $opsd_settings;
|
||||
$opsd_settings = array();
|
||||
|
||||
self::$instance = new OPSD_Init;
|
||||
self::$instance->constants();
|
||||
self::$instance->includes();
|
||||
self::$instance->define_version();
|
||||
|
||||
|
||||
if ( class_exists( 'OPSD_ItemInstall' ) ) { // Check if we need to run Install / Uninstal process.
|
||||
new OPSD_ItemInstall();
|
||||
}
|
||||
|
||||
// TODO: Finish here
|
||||
//add_action('plugins_loaded', array(self::$instance, 'load_textdomain') ); // T r a n s l a t i o n
|
||||
|
||||
|
||||
$is_continue = self::$instance->start(); // Make Ajax, Response or Define item ClASS
|
||||
|
||||
make_opsd_action( 'opsd_calendar_started' );
|
||||
do_action( 'opsd_calendar_started' );
|
||||
|
||||
//TODO: NEW
|
||||
if ( $is_continue ) { // Possible Load Admin or Front-End page
|
||||
|
||||
self::$instance->js = new OPSD_JS;
|
||||
self::$instance->css = new OPSD_CSS;
|
||||
|
||||
if( is_admin() ) {
|
||||
|
||||
// Define Menu
|
||||
add_action( '_admin_menu', array( self::$instance, 'define_admin_menu') ); // _admin_menu - Fires before the administration menu loads in the admin.
|
||||
|
||||
add_action( 'admin_footer', 'opsd_print_js', 50 ); // Load my Queued JavaScript Code at the footer of the Admin Panel page. Executed in ALL Admin Menu Pages
|
||||
|
||||
} else {
|
||||
|
||||
if ( function_exists( 'opsd_br_cache' ) ) $br_cache = opsd_br_cache(); // Init item resources cache
|
||||
|
||||
add_action( 'wp_enqueue_scripts', array(self::$instance->css, 'load'), 1000000001 ); // Load CSS at front-end side // Enqueue Scripts to All Client pages
|
||||
add_action( 'wp_enqueue_scripts', array(self::$instance->js, 'load'), 1000000001 ); // Load JavaScript files and define JS varibales at forn-end side
|
||||
add_action( 'wp_footer', 'opsd_print_js', 50 ); // Load my Queued JavaScript Code at the footer of the page, if executed "wp_footer" hook at the Theme.
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
return self::$instance;
|
||||
}
|
||||
|
||||
|
||||
/** Define Admin Menu items */
|
||||
public function define_admin_menu(){
|
||||
|
||||
$update_count = opsd_get_number_new_items();
|
||||
|
||||
$title = 'Secure Downloads'; //'ß<span style="font-size:0.75em;">ΘΘ</span>ĸıŋ';
|
||||
|
||||
if ( $update_count > 0 ){
|
||||
$update_count_title = "<span class='update-plugins count-$update_count' title=''><span class='update-count bk-update-count'>" . number_format_i18n($update_count) . "</span></span>" ;
|
||||
$title .= $update_count_title;
|
||||
}
|
||||
|
||||
|
||||
//global $menu;
|
||||
//if ( current_user_can( ) ) {
|
||||
//$menu[] = array( '', 'read', 'separator-opsd', '', 'wp-menu-separator opsd' );
|
||||
//}
|
||||
// debuge($menu);
|
||||
|
||||
$opsd_menu_position = get_opsd_option( 'opsd_menu_position' );
|
||||
switch ( $opsd_menu_position ) {
|
||||
case 'top':
|
||||
$opsd_menu_position = 3.13;
|
||||
break;
|
||||
case 'middle':
|
||||
global $_wp_last_object_menu; // The index of the last top-level menu in the object menu group
|
||||
$_wp_last_object_menu++;
|
||||
$opsd_menu_position = $_wp_last_object_menu; // 58.9;
|
||||
break;
|
||||
case 'bottom':
|
||||
$opsd_menu_position = 99.919;
|
||||
break;
|
||||
default:
|
||||
$opsd_menu_position = 3.13;
|
||||
break;
|
||||
}
|
||||
|
||||
// calendar3-range https://icons.getbootstrap.com/icons/calendar3-range/
|
||||
// $svg_icon_integarted = '<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" class="bi bi-calendar3-range" viewBox="-2 -1 20 20">'
|
||||
// . '<path d="M14 0H2a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V2a2 2 0 0 0-2-2zM1 3.857C1 3.384 1.448 3 2 3h12c.552 0 1 .384 1 .857v10.286c0 .473-.448.857-1 .857H2c-.552 0-1-.384-1-.857V3.857z"/>'
|
||||
// . '<path d="M7 10a1 1 0 0 0 0-2H1v2h6zm2-3h6V5H9a1 1 0 0 0 0 2z"/>'
|
||||
// . '</svg>';
|
||||
|
||||
$svg_icon_integarted = '<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" class="opsd-upload" viewBox="-2 -3 20 20" >'
|
||||
//.'<g transform="rotate(90 8 8)">' // Rotate on 90 degree where center x =8, y = 8
|
||||
. '<path d="M.5 9.9a.5.5 0 0 1 .5.5v2.5a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-2.5a.5.5 0 0 1 1 0v2.5a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2v-2.5a.5.5 0 0 1 .5-.5z"/>'
|
||||
. '<path d="M7.646 1.146a.5.5 0 0 1 .708 0l3 3a.5.5 0 0 1-.708.708L8.5 2.707V11.5a.5.5 0 0 1-1 0V2.707L5.354 4.854a.5.5 0 1 1-.708-.708l3-3z"/>'
|
||||
//.'</g>'
|
||||
. '</svg>';
|
||||
self::$instance->admin_menu['master'] = new OPSD_Admin_Menus(
|
||||
'opsd' , array (
|
||||
'in_menu' => 'root'
|
||||
// , 'mune_icon_url' => '/assets/img/icon-16x16.png'
|
||||
, 'mune_icon_url' => $svg_icon_integarted //FixIn: 2.0.1.2
|
||||
, 'menu_title' => $title
|
||||
, 'menu_title_second' => __('Secure Links', 'secure-downloads')
|
||||
, 'page_header' => __('Secure Downlods - Generate and Send Secure Links', 'secure-downloads')
|
||||
, 'browser_header' => __('Secure Downlods - Links', 'secure-downloads')
|
||||
, 'user_role' => get_opsd_option( 'opsd_user_role_master' )
|
||||
, 'position' => $opsd_menu_position // 3.3 - top //( 58.9 ) // - middle
|
||||
/*
|
||||
(Optional). Positions for Core Menu Items
|
||||
2 Dashboard
|
||||
4 Separator
|
||||
5 Posts
|
||||
10 Media
|
||||
15 Links
|
||||
20 Pages
|
||||
25 Comments
|
||||
59 Separator
|
||||
60 Appearance
|
||||
65 Plugins
|
||||
70 Users
|
||||
75 Tools
|
||||
80 Settings
|
||||
99 Separator
|
||||
*/
|
||||
)
|
||||
|
||||
);
|
||||
|
||||
self::$instance->admin_menu['files'] = new OPSD_Admin_Menus(
|
||||
'opsd-files' , array (
|
||||
'in_menu' => 'opsd'
|
||||
, 'menu_title' => ucwords( __('Files', 'secure-downloads') )
|
||||
, 'page_header' => ucwords( __('Add New', 'secure-downloads') )
|
||||
, 'browser_header'=> ucwords( __('Files', 'secure-downloads') )
|
||||
, 'user_role' => get_opsd_option( 'opsd_user_role_addnew' )
|
||||
)
|
||||
);
|
||||
|
||||
|
||||
self::$instance->admin_menu['settings'] = new OPSD_Admin_Menus(
|
||||
'opsd-settings' , array (
|
||||
'in_menu' => 'opsd'
|
||||
, 'menu_title' => __('Settings', 'secure-downloads')
|
||||
, 'page_header' => __('General Settings', 'secure-downloads')
|
||||
, 'browser_header'=> __('Settings', 'secure-downloads')
|
||||
, 'user_role' => get_opsd_option( 'opsd_user_role_settings' )
|
||||
)
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** Get Menu Object
|
||||
*
|
||||
* @param type - menu type
|
||||
* @return boolean
|
||||
*/
|
||||
public function get_menu_object( $type ) {
|
||||
|
||||
if ( isset( self::$instance->admin_menu[ $type ] ) )
|
||||
return self::$instance->admin_menu[ $type ];
|
||||
else
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
// Define constants
|
||||
private function constants() {
|
||||
require_once OPSD_PLUGIN_DIR . '/core/opsd-constants.php' ;
|
||||
}
|
||||
|
||||
|
||||
// Include Files
|
||||
private function includes() {
|
||||
require_once OPSD_PLUGIN_DIR . '/core/opsd-include.php' ;
|
||||
}
|
||||
|
||||
|
||||
private function define_version() {
|
||||
|
||||
// GET VERSION NUMBER
|
||||
$plugin_data = get_file_data_wpdev( OPSD_FILE , array( 'Name' => 'Plugin Name', 'PluginURI' => 'Plugin URI', 'Version' => 'Version', 'Description' => 'Description', 'Author' => 'Author', 'AuthorURI' => 'Author URI', 'TextDomain' => 'Text Domain', 'DomainPath' => 'Domain Path' ) , 'plugin' );
|
||||
if (!defined('OPSD_VERSION')) define('OPSD_VERSION', $plugin_data['Version'] );
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Load Plugin Locale.
|
||||
* Look firstly in Global folder: /wp-content/languages/plugin_name
|
||||
* then in Local folder: /wp-content/plugins/plugin_name/languages/
|
||||
* and afterwards load default : load_plugin_textdomain( ...
|
||||
*/
|
||||
public function load_textdomain() {
|
||||
// Set filter for plugin's languages directory
|
||||
$plugin_lang_dir = OPSD_PLUGIN_DIR . '/languages/';
|
||||
$plugin_lang_dir = apply_filters( 'opsd~languages_directory', $plugin_lang_dir );
|
||||
|
||||
// Plugin locale filter
|
||||
$locale = apply_filters( 'plugin_locale', get_locale() , 'secure-downloads');
|
||||
$mofile = sprintf( '%1$s-%2$s.mo', 'secure-downloads', $locale );
|
||||
|
||||
// Setup paths to current locale file
|
||||
$mofile_local = $plugin_lang_dir . $mofile;
|
||||
$mofile_global = WP_LANG_DIR . '/secure-downloads/' . $mofile;
|
||||
|
||||
if ( file_exists( $mofile_global ) ) {
|
||||
// Look in global /wp-content/languages/plugin_name folder
|
||||
load_textdomain( 'secure-downloads', $mofile_global );
|
||||
|
||||
} elseif ( file_exists( $mofile_local ) ) {
|
||||
// Look in local /wp-content/plugins/plugin_name/languages/ folder
|
||||
load_textdomain( 'secure-downloads', $mofile_local );
|
||||
|
||||
} else {
|
||||
// Load the default language files
|
||||
load_plugin_textdomain( 'secure-downloads', false, $plugin_lang_dir );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Cloning instances of the class is forbidden
|
||||
public function __clone() {
|
||||
|
||||
_doing_it_wrong( __FUNCTION__, __( 'Action is not allowed!' ), '1.0' );
|
||||
}
|
||||
|
||||
|
||||
// Unserializing instances of the class is forbidden
|
||||
public function __wakeup() {
|
||||
|
||||
_doing_it_wrong( __FUNCTION__, __( 'Action is not allowed!' ), '1.0' );
|
||||
}
|
||||
|
||||
|
||||
// Initialization
|
||||
private function start(){
|
||||
|
||||
if ( ( defined( 'DOING_AJAX' ) ) && ( DOING_AJAX ) ){ // New A J A X R e s p o n d e r
|
||||
|
||||
|
||||
|
||||
require_once OPSD_PLUGIN_DIR . '/core/opsd-ajax.php'; // Ajax
|
||||
|
||||
return false;
|
||||
} else { // Usual Loading of plugin
|
||||
|
||||
// We are having Response, its executed in other file: opsd-response.php
|
||||
if ( OPSD_RESPONSE )
|
||||
return false;
|
||||
|
||||
////////////////////////////////////////////////////////////////////
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
else: // Its seems that some instance of Secure Downloads still activted!!!
|
||||
|
||||
|
||||
function opsd_show_activation_error() {
|
||||
|
||||
$message_type = 'error';
|
||||
$title = __( 'Error' , 'secure-downloads') . '!';
|
||||
$message = __( 'Please deactivate previous old version of' , 'secure-downloads') . ' ' . 'Item Calendar';
|
||||
|
||||
$opsd_version_num = get_option( 'opsd_version_num');
|
||||
if ( ! empty( $opsd_version_num ) )
|
||||
$message .= ' <strong>' . $opsd_version_num . '</strong>';
|
||||
|
||||
|
||||
$is_delete_if_deactive = get_opsd_option( 'opsd_is_delete_if_deactive' ); // check
|
||||
|
||||
if ( $is_delete_if_deactive == 'On' ) {
|
||||
|
||||
$message .= '<br/><br/> <strong>Warning!</strong> ' . 'All plugin data will be deleted when plugin had deactivated.' . ' '
|
||||
. sprintf( 'If you want to save your plugin data, please uncheck the %s"Delete plugin data"%s at the', '<strong>', '</strong>') . ' ' . __( 'Settings' , 'secure-downloads') . '.';
|
||||
}
|
||||
|
||||
$message_content = '';
|
||||
|
||||
$message_content .= '<div class="clear"></div>';
|
||||
|
||||
$message_content .= '<div class="updated opsd-settings-notice notice-' . $message_type . ' ' . $message_type . '" style="text-align:left;padding:10px;">';
|
||||
|
||||
if ( ! empty( $title ) )
|
||||
$message_content .= '<strong>' . esc_js( $title ) . '</strong> ';
|
||||
|
||||
$message_content .= html_entity_decode( esc_js( $message ) ,ENT_QUOTES) ;
|
||||
|
||||
$message_content .= '</div>';
|
||||
|
||||
$message_content .= '<div class="clear"></div>';
|
||||
|
||||
echo $message_content;
|
||||
}
|
||||
|
||||
add_action('admin_notices', 'opsd_show_activation_error');
|
||||
|
||||
return; // Exit
|
||||
|
||||
endif;
|
||||
|
||||
|
||||
/**
|
||||
* The main function responsible for returning the one true Instance to functions everywhere.
|
||||
*
|
||||
* Example: <?php $opsd = OPSD(); ?>
|
||||
*/
|
||||
function OPSD() {
|
||||
return OPSD_Init::init();
|
||||
}
|
||||
|
||||
|
||||
|
||||
// Start
|
||||
OPSD();
|
||||
|
||||
|
||||
|
||||
//if ( ! defined( 'SAVEQUERIES') ) define('SAVEQUERIES', true);
|
||||
|
||||
//add_action( 'admin_footer', 'opsd_show_debug_info', 130 );
|
||||
function opsd_show_debug_info() {
|
||||
|
||||
$request_uri = $_SERVER['REQUEST_URI']; // FixIn:5.4.1
|
||||
if ( strpos( $request_uri, 'page=opsd') === false ) {
|
||||
return;
|
||||
}
|
||||
echo '<div style="width:800px;margin:10px auto;"><style type="text/css"> a:link{background: inherit !important; } pre { white-space: pre-wrap; }</style>';
|
||||
|
||||
phpinfo(); echo '</div>'; return;
|
||||
|
||||
?><div style="width:auto;margin:0 0 0 215px;font-size:11px; "><?php
|
||||
|
||||
// SYSTEM INFO SHOWING ////////////////////////////////////////////////////////
|
||||
|
||||
//Note firstly need to define this in functions.php file: define('SAVEQUERIES', true);
|
||||
global $wpdb;
|
||||
echo '<div class="clear"></div>START SYSTEM<pre>';
|
||||
$qq_kk = 0;
|
||||
$total_time = 0;
|
||||
$total_num = 0;
|
||||
foreach ( $wpdb->queries as $qq_k => $qq ) {
|
||||
if (
|
||||
( strpos( $qq[0], 'secure-downloads') !== false )
|
||||
|
||||
) {
|
||||
if ( $qq[1] > 0.002 ) { echo '<div style="color:#A77;font-weight:bold;">'; }
|
||||
debuge($qq_kk++, $qq);
|
||||
$total_time += $qq[1];
|
||||
$total_num++;
|
||||
if ( $qq[1] > 0.002 ) { echo '</div>'; }
|
||||
}
|
||||
}
|
||||
|
||||
echo '<div><pre class="prettyprint linenums" style="font-size:18px;">[' . $total_num . '/' . $total_time . '] OPSD Requests TOTAL TIME</pre></div>';
|
||||
|
||||
echo '<div class="clear"></div>';
|
||||
|
||||
echo '<div><pre class="prettyprint linenums" style="font-size:18px;">' . get_num_queries(). '/' . timer_stop(0, 3) . 'qps</pre></div>';
|
||||
|
||||
echo '<div class="clear"></div>';
|
||||
|
||||
echo "</pre>";
|
||||
?><br/><br/><br/><br/><br/><br/><?php
|
||||
echo '<div class="clear"></div>';
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
?></div><?php
|
||||
|
||||
echo '</div>';
|
||||
}
|
||||
145
wp-content/plugins/secure-downloads/css/admin.css
Normal file
145
wp-content/plugins/secure-downloads/css/admin.css
Normal file
@@ -0,0 +1,145 @@
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package: Secure Downloads
|
||||
* @category: Admin Pages only
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-04-11
|
||||
*/
|
||||
|
||||
#opsd-admin-page.opsd_page {} /* item Listing */
|
||||
#opsd-new-admin-page.opsd_page {} /* Add New item */
|
||||
#opsd-resources-admin-page.opsd_page {} * /* Resources */
|
||||
#opsd-settings-admin-page.opsd_page {} /* Settings */
|
||||
|
||||
/* Form elements - add new client */
|
||||
#opsd-new-admin-page label.opsd-form-checkbox {
|
||||
margin: 7px 10px 7px 0;
|
||||
vertical-align: middle;
|
||||
line-height: 1.2em;
|
||||
height: 1.2em;
|
||||
}
|
||||
#opsd-new-admin-page label.opsd-form-checkbox input[type=checkbox] {
|
||||
margin:-3px 5px 0 0;
|
||||
vertical-align: middle;
|
||||
}
|
||||
#opsd-new-admin-page label.opsd-form-radio {
|
||||
margin: 7px 10px 7px 0;
|
||||
vertical-align: middle;
|
||||
line-height: 1.5em;
|
||||
height: 1.5em;
|
||||
}
|
||||
#opsd-new-admin-page label.opsd-form-radio input[type=radio] {
|
||||
margin:-3px 5px 0 0;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
/* Selection of item resources */
|
||||
.visibility_container select option.opsd_single_resource,
|
||||
select option.opsd_single_resource{
|
||||
padding:3px;
|
||||
font-weight:600;
|
||||
}
|
||||
.visibility_container select option.opsd_parent_resource,
|
||||
select option.opsd_parent_resource{
|
||||
font-weight:600;
|
||||
padding:3px;
|
||||
}
|
||||
.visibility_container select option.opsd_child_resource,
|
||||
select option.opsd_child_resource{
|
||||
padding:3px 0 3px 20px;
|
||||
font-weight: 400
|
||||
}
|
||||
|
||||
/* General item Settings page */
|
||||
#opsd-settings-admin-page .form-table .description {
|
||||
font-size: 14px;
|
||||
line-height: 2em;
|
||||
}
|
||||
#opsd-settings-admin-page .form-table span.description{
|
||||
padding: 0 10px;
|
||||
}
|
||||
#opsd-settings-admin-page .opsd_sub_settings_grayed{
|
||||
background-color: #f3f3f3;
|
||||
}
|
||||
#opsd-settings-admin-page .opsd_sub_settings_grayed th{
|
||||
padding: 10px 0 0 20px;
|
||||
}
|
||||
#opsd-settings-admin-page .opsd_sub_settings_grayed td fieldset{
|
||||
padding: 0 20px;
|
||||
}
|
||||
#opsd-settings-admin-page .opsd_tr_set_gen_opsd_range_selection_days_count,
|
||||
#opsd-settings-admin-page .opsd_tr_set_gen_opsd_range_selection_days_count_dynamic{
|
||||
border-top: 2px dashed #d5d5d5;
|
||||
}
|
||||
#opsd-settings-admin-page .opsd_tr_set_gen_opsd_range_start_day_week td{
|
||||
padding-top:0;
|
||||
}
|
||||
#opsd-settings-admin-page .opsd_tr_set_gen_opsd_range_start_day_week th {
|
||||
padding:0;
|
||||
height: 1px;
|
||||
}
|
||||
#opsd-settings-admin-page .opsd_expand_section_link,
|
||||
#opsd-settings-admin-page a.opsd_expand_section_link:hover,
|
||||
#opsd-settings-admin-page a.opsd_expand_section_link:focus {
|
||||
color:#21759b;
|
||||
cursor: pointer;
|
||||
outline: 0;
|
||||
border:none;
|
||||
border-bottom:1px dashed #21759B;
|
||||
text-decoration: none;
|
||||
}
|
||||
/* Warning message in Demo version */
|
||||
.opsd_demo_test_version_warning {
|
||||
background: #fee;
|
||||
border: none;
|
||||
border-left: 3px solid #c77 !important;
|
||||
border-radius: 2px;
|
||||
font-size: 0.85em;
|
||||
margin: 0;
|
||||
text-align: left;
|
||||
color: #AA4400;
|
||||
text-shadow: 0 -1px 0 #FFEEEE;
|
||||
}
|
||||
|
||||
/* Remove shadow at button of ajax loading upgrade section at Settings > Upgrade page */
|
||||
#bk_news_section td a {
|
||||
color: #555 !important;
|
||||
text-shadow: 0 0 0 !important;
|
||||
box-shadow: none;
|
||||
}
|
||||
#bk_news_section .opsd-listing-header {
|
||||
background: #dfdfdf none repeat scroll 0 0;
|
||||
border-color: #d5d5d5 #d5d5d5 -moz-use-text-color;
|
||||
}
|
||||
#bk_news_section .opsd-feature-table {
|
||||
border: 2px solid #dfdfdf;
|
||||
}
|
||||
#bk_news_section .version-name-row {
|
||||
background: #789 none repeat scroll 0 0 !important;
|
||||
color: #fff !important;
|
||||
font-weight: 400;
|
||||
line-height: 1.5em;
|
||||
text-shadow: 0 1px 1px #89a;
|
||||
vertical-align: middle;
|
||||
}
|
||||
#bk_news_section .opsd-feature-table td.section-header {
|
||||
background: #feb !important;
|
||||
}
|
||||
/* Message: Thank you for registrations. */
|
||||
#bk_registration_info {
|
||||
font-size: 1em;
|
||||
font-weight: 600;
|
||||
margin: 10px 0;
|
||||
opacity: 1;
|
||||
}
|
||||
/*#bk_registration_info_reload, */
|
||||
#bk_errror_loading .info_message {
|
||||
font-size: 1.1em;
|
||||
font-weight: 600;
|
||||
margin: 10px 0;
|
||||
opacity: 1;
|
||||
}
|
||||
474
wp-content/plugins/secure-downloads/css/calendar.css
Normal file
474
wp-content/plugins/secure-downloads/css/calendar.css
Normal file
@@ -0,0 +1,474 @@
|
||||
/*******************************************************************************/
|
||||
/* Secure Downloads Respondive CSS *******************************************/
|
||||
/*******************************************************************************/
|
||||
|
||||
/*******************************************************************************/
|
||||
/* C O N F I G */
|
||||
/*******************************************************************************/
|
||||
/* WIDTH: of CALENDARs - its FULL width of Month(s) ROW (its NOT only one month) */
|
||||
.datepick-inline {
|
||||
width:100% !important; /* Overrride the width of the calendar, which is set datepicker JS */
|
||||
z-index: 10000;
|
||||
}
|
||||
/* HEIGHT: of C E L L S */
|
||||
.datepick-inline .datepick-title-row th,
|
||||
.datepick-inline .datepick-days-cell{
|
||||
height: 40px;
|
||||
}
|
||||
/* HEIGHT: of C E L L S in POPUP calendar */
|
||||
#datepick-div.datepick-inline .datepick-title-row th,
|
||||
#datepick-div.datepick-inline .datepick-days-cell{
|
||||
height: 25px;
|
||||
}
|
||||
|
||||
/*******************************************************************************/
|
||||
/* S T R U C T U R E & S i z e s ****************************************/
|
||||
/*******************************************************************************/
|
||||
/*RESET: Width, margin, padding */
|
||||
div.check-out-div,
|
||||
div.check-in-div,
|
||||
div.date-content-top,
|
||||
div.date-content-bottom{
|
||||
width: 0;
|
||||
height: 0;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
/* RESET: Font sizes, padding, margin */
|
||||
.datepick-inline .datepick, /* Month table */
|
||||
.datepick-inline .datepick-header, /* Month header */
|
||||
.datepick-inline .datepick-header span, /* Header span */
|
||||
.datepick-inline .calendar-links, /* Prev Next months */
|
||||
.datepick-inline .calendar-links a, /* Prev Next links */
|
||||
.datepick-inline .datepick-days-cell, /* Date cell */
|
||||
.datepick-inline .datepick-days-cell a, /* Active date cell */
|
||||
.datepick-inline .datepick-days-cell div, /* Cehck in/out */
|
||||
.datepick-inline .datepick-title-row, /* Week row */
|
||||
.datepick-inline .datepick-title-row th { /* Week cell */
|
||||
padding: 0px;
|
||||
margin: 0px;
|
||||
font-size:12px;
|
||||
border: 0 none;
|
||||
vertical-align: baseline;
|
||||
}
|
||||
#content .datepick-days-cell, /* Reset the padding in TD and TH elements of calendar to prevent conflict with some WP themes */
|
||||
#content .datepick-title-row th{
|
||||
padding: 0px;
|
||||
margin: 0px;
|
||||
}
|
||||
/* RESET: width to 100% */
|
||||
.datepick-inline .datepick,
|
||||
.datepick-inline .datepick-header{
|
||||
width:100%;
|
||||
}
|
||||
/* SIZE: Set width of calendar with several months */
|
||||
.datepick-one-month {
|
||||
width:100%;
|
||||
float:left;
|
||||
}
|
||||
.cal_month_num_2 .datepick-one-month {
|
||||
width:50%;
|
||||
float:left;
|
||||
}
|
||||
.cal_month_num_3 .datepick-one-month {
|
||||
width:33.333333333333333%;
|
||||
float:left;
|
||||
}
|
||||
.cal_month_num_4 .datepick-one-month {
|
||||
width:25%;
|
||||
float:left;
|
||||
}
|
||||
.cal_month_num_5 .datepick-one-month {
|
||||
width:20%;
|
||||
float:left;
|
||||
}
|
||||
.cal_month_num_6 .datepick-one-month {
|
||||
width:16.6666666666666%;
|
||||
float:left;
|
||||
}
|
||||
.cal_month_num_7 .datepick-one-month {
|
||||
width:14.28571429%;
|
||||
float:left;
|
||||
}
|
||||
.cal_month_num_8 .datepick-one-month {
|
||||
width:12.5%;
|
||||
float:left;
|
||||
}
|
||||
.cal_month_num_9 .datepick-one-month {
|
||||
width:11.11111111%;
|
||||
float:left;
|
||||
}
|
||||
.cal_month_num_10 .datepick-one-month {
|
||||
width:10%;
|
||||
float:left;
|
||||
}
|
||||
.cal_month_num_11 .datepick-one-month {
|
||||
width:9.0909090909090909%;
|
||||
float:left;
|
||||
}
|
||||
.cal_month_num_12 .datepick-one-month {
|
||||
width:8.333333333333333%;
|
||||
float:left;
|
||||
}
|
||||
|
||||
/* CLASS: for setting specific number of months in a row. Please check more in FAQ.*/
|
||||
.months_num_in_row_1 .datepick-one-month {
|
||||
width:100%;
|
||||
float:left;
|
||||
}
|
||||
.months_num_in_row_2 .datepick-one-month {
|
||||
width:50%;
|
||||
float:left;
|
||||
}
|
||||
.months_num_in_row_3 .datepick-one-month {
|
||||
width:33.333333333333333%;
|
||||
float:left;
|
||||
}
|
||||
.months_num_in_row_4 .datepick-one-month {
|
||||
width:25%;
|
||||
float:left;
|
||||
}
|
||||
.months_num_in_row_5 .datepick-one-month {
|
||||
width:20%;
|
||||
float:left;
|
||||
}
|
||||
.months_num_in_row_6 .datepick-one-month {
|
||||
width:16.6666666666666%;
|
||||
float:left;
|
||||
}
|
||||
|
||||
/* STRUCTURE: Previous & Next month links */
|
||||
.datepick-inline .calendar-links{
|
||||
float: left;
|
||||
width: 100%;
|
||||
height: auto;
|
||||
margin-bottom: -2.4em;
|
||||
padding: 0.4em 0;
|
||||
position: relative;
|
||||
text-decoration: none;
|
||||
}
|
||||
.datepick-inline .calendar-links .datepick-prev{
|
||||
float: left;
|
||||
width: 49%;
|
||||
text-align: left;
|
||||
padding-left:1%;
|
||||
z-index:99;
|
||||
position: relative;
|
||||
line-height: 1.5em;
|
||||
}
|
||||
.datepick-inline .calendar-links .datepick-next{
|
||||
float: right;
|
||||
text-align: right;
|
||||
width: 49%;
|
||||
padding-right:1%;
|
||||
z-index:99;
|
||||
position: relative;
|
||||
line-height: 1.5em;
|
||||
}
|
||||
.datepick-inline .calendar-links .datepick-prev a,
|
||||
.datepick-inline .calendar-links .datepick-next a{
|
||||
font-size: 2em;
|
||||
}
|
||||
|
||||
/* Week Titles height */
|
||||
div.datepick-inline .datepick-title-row th{
|
||||
height: auto !important;
|
||||
line-height: 2.18182;
|
||||
}
|
||||
/* Links: NO UNDERLINE, Cursor - Pointer */
|
||||
.datepick-inline .calendar-links .datepick-prev a,
|
||||
.datepick-inline .calendar-links .datepick-next a,
|
||||
.datepick-inline .calendar-links .datepick-prev a:hover,
|
||||
.datepick-inline .calendar-links .datepick-next a:hover,
|
||||
.datepick-inline .datepick-days-cell,
|
||||
.datepick-inline .datepick-days-cell.timespartly.date_approved,
|
||||
.datepick-inline .datepick-days-cell.timespartly.date2approve,
|
||||
.datepick-inline .datepick-days-cell a,
|
||||
.datepick-inline .datepick-days-cell a:hover, /* FixIn: 5.4.5.9 */
|
||||
.block_hints .block_free a,
|
||||
.block_hints .block_free a:hover,
|
||||
.block_hints .block_time a,
|
||||
.block_hints .block_time a:hover {
|
||||
text-decoration: none;
|
||||
cursor: pointer;
|
||||
box-shadow: none; /* FixIn: 5.4.5.9 */
|
||||
}
|
||||
.datepick-inline .datepick-days-cell.datepick-unselectable, /* Default cursor for the unvailbale dates */
|
||||
.datepick-inline .datepick-days-cell.datepick-unselectable a,
|
||||
.datepick-inline .datepick-days-cell.datepick-unselectable a:hover,
|
||||
.datepick-inline .datepick-days-cell.date_approved,
|
||||
.datepick-inline .datepick-days-cell.date2approve{
|
||||
cursor: default;
|
||||
}
|
||||
/* ALIGN: Header */
|
||||
.datepick-inline .datepick-header{
|
||||
text-align: center;
|
||||
position: relative;
|
||||
line-height: 1.71429em;
|
||||
padding: 0.3em 0;
|
||||
}
|
||||
/* ALIGN: Cells and set standard width */
|
||||
.datepick-inline .datepick-title-row th,
|
||||
.datepick-inline .datepick-days-cell{
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
width: 14.28571429%;
|
||||
overflow: hidden;
|
||||
}
|
||||
.datepick-inline .datepick-days-cell a,
|
||||
.datepick-inline .datepick-days-cell span{ /* FixIn: 6.0.1.2 */
|
||||
position:relative;
|
||||
z-index: 99;
|
||||
}
|
||||
|
||||
|
||||
/*******************************************************************************/
|
||||
/* Check In / Out Times ************************************************/
|
||||
/*******************************************************************************/
|
||||
.block_hints .block_check_in_out.check_in_time, /* Item for the LEGEND */
|
||||
.datepick-inline .timespartly.check_in_time, /* If we are using the Check in/out time, so hide the CLOCK icon */
|
||||
.datepick-inline .timespartly.check_out_time {
|
||||
background-image: none;
|
||||
}
|
||||
/*Backgorounds*/
|
||||
.block_hints .block_check_in_out.check_in_time div.check-in-div, /* Item for the LEGEND */
|
||||
.block_hints .block_check_in_out.check_out_time div.check-out-div, /* Item for the LEGEND */
|
||||
td.timespartly.check_in_time div.check-in-div, /* Define the check in/out time BACKGRUND */
|
||||
td.timespartly.check_out_time div.check-out-div {
|
||||
border: 0px none;
|
||||
float: left;
|
||||
height: 200%;
|
||||
margin-bottom: -400%;
|
||||
position: relative;
|
||||
top: -50%;
|
||||
vertical-align: bottom;
|
||||
width: 20%;
|
||||
z-index: 0;
|
||||
}
|
||||
.block_hints .block_check_in_out.check_out_time div.check-out-div, /* Item for the LEGEND */
|
||||
td.timespartly.check_out_time div.check-out-div { /* Define the check out position */
|
||||
float: right;
|
||||
}
|
||||
|
||||
td.timespartly.check_in_time.check_out_time div.check-in-div, /* If we are have Together the check in and check out times, so this date is booked.*/
|
||||
td.timespartly.check_in_time.check_out_time div.check-out-div {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* HIDE check in/out elements, when: CELL OVER | DATE SELECTED | CHECK IN Date Selected */
|
||||
.datepick-inline .datepick .datepick-unselectable.check_in_time div.check-in-div,
|
||||
.datepick-inline .datepick .datepick-unselectable.check_out_time div.check-out-div,
|
||||
.datepick-inline .datepick .datepick-days-cell-over.check_in_time div.check-in-div,
|
||||
.datepick-inline .datepick .datepick-days-cell-over.check_out_time div.check-out-div,
|
||||
.datepick-inline .datepick .datepick-current-day.check_in_time div.check-in-div,
|
||||
.datepick-inline .datepick .datepick-current-day.check_out_time div.check-out-div{
|
||||
display: none;
|
||||
visibility: hidden;
|
||||
}
|
||||
/* Check In Pending & Check Out Approved || Check Out Pending & Check In Approved || dates //FixIn: 6.0.1.2 */
|
||||
td.timespartly.check_in_time.check_out_time.check_in_time_date_approved.check_out_time_date2approve div.check-in-div,
|
||||
td.timespartly.check_in_time.check_out_time.check_out_time_date_approved.check_in_time_date2approve div.check-out-div,
|
||||
td.timespartly.check_in_time.check_out_time.check_in_time_date2approve.check_out_time_date_approved div.check-in-div,
|
||||
td.timespartly.check_in_time.check_out_time.check_out_time_date2approve.check_in_time_date_approved div.check-out-div {
|
||||
display: block;
|
||||
visibility: visible;
|
||||
width: 50%;
|
||||
float: left;
|
||||
}
|
||||
td.timespartly.check_in_time.check_out_time.check_out_time_date_approved.check_in_time_date2approve div.check-out-div,
|
||||
td.timespartly.check_in_time.check_out_time.check_out_time_date2approve.check_in_time_date_approved div.check-out-div {
|
||||
float: right;
|
||||
}
|
||||
td.timespartly.check_in_time.check_out_time.check_in_time_date_approved.check_out_time_date2approve span,
|
||||
td.timespartly.check_in_time.check_out_time.check_out_time_date_approved.check_in_time_date2approve span,
|
||||
td.timespartly.check_in_time.check_out_time.check_in_time_date_approved.check_out_time_date2approve div,
|
||||
td.timespartly.check_in_time.check_out_time.check_out_time_date_approved.check_in_time_date2approve div {
|
||||
cursor: default;
|
||||
}
|
||||
/*******************************************************************************/
|
||||
|
||||
|
||||
/*******************************************************************************/
|
||||
/* Set correct FONT of unselectable elements, when the check in date is selected */
|
||||
/*******************************************************************************/
|
||||
.datepick-inline .datepick .datepick-unselectable.check_in_time.date_approved,
|
||||
.datepick-inline .datepick .datepick-unselectable.check_out_time.date_approved,
|
||||
.datepick-inline .datepick .datepick-unselectable.check_in_time.date2approve,
|
||||
.datepick-inline .datepick .datepick-unselectable.check_out_time.date2approve {
|
||||
background-color: transparent;
|
||||
font-weight: 400;
|
||||
}
|
||||
/*******************************************************************************/
|
||||
|
||||
|
||||
/*******************************************************************************/
|
||||
/* W I D G E T **************************************************/
|
||||
/*******************************************************************************/
|
||||
/* Set HEIGHT of the CELLs in the Widget */
|
||||
.widget_opsd_item .hasDatepick .datepick-inline .datepick-title-row th,
|
||||
.widget_opsd_item .hasDatepick .datepick-inline .datepick-days-cell{
|
||||
height: 30px;
|
||||
}
|
||||
/* Set calendar WIDTH and MARGIN in Widget */
|
||||
.widget_opsd_item .bk_calendar_frame{
|
||||
margin: 0 2%;
|
||||
width: 96% !important;
|
||||
}
|
||||
/* LEGEND items show in 2 rows in Widget */
|
||||
.widget_opsd_item .opsd_hint_with_text{
|
||||
float: left;
|
||||
margin: 0;
|
||||
width: 50% !important;
|
||||
}
|
||||
/* Set the WIDTH and MARGIN of the form FIELDS in Widget */
|
||||
.widget_opsd_item input,
|
||||
.widget_opsd_item select,
|
||||
.widget_opsd_item textarea,
|
||||
.widget_opsd_item .wpdevelop input,
|
||||
.widget_opsd_item .wpdevelop select,
|
||||
.widget_opsd_item .wpdevelop textarea,
|
||||
div#datepick-div input,
|
||||
div#datepick-div select,
|
||||
div#datepick-div textarea {
|
||||
width: 96%;
|
||||
margin: auto;
|
||||
}
|
||||
/* SELECT BUTTON and CHECKBOX fields have the Auto Width in Widget */
|
||||
/*.widget_opsd_item select,*/
|
||||
.widget_opsd_item input[type=button],
|
||||
.widget_opsd_item input[type=checkbox]{
|
||||
width:auto;
|
||||
}
|
||||
|
||||
|
||||
/*******************************************************************************/
|
||||
/* Legend of days, which is shown under calendar *******************************/
|
||||
/*******************************************************************************/
|
||||
/* Full Legend Frame */
|
||||
.block_hints {
|
||||
width: 100%;
|
||||
clear: both;
|
||||
margin: 10px 0px 30px 0px !important;
|
||||
border: none;
|
||||
height: 30px;
|
||||
}
|
||||
/* Date CELL with TEXT description */
|
||||
.opsd_hint_with_text {
|
||||
float:left;
|
||||
width:auto;
|
||||
}
|
||||
/* Text Labels of Legend */
|
||||
.block_text {
|
||||
float: none;
|
||||
height: 30px;
|
||||
line-height: 32px;
|
||||
margin: 0 0 10px;
|
||||
padding: 0 10px 0 35px;
|
||||
|
||||
font-size: 0.9em;
|
||||
white-space: nowrap;
|
||||
word-wrap: normal;
|
||||
}
|
||||
/* Dates CELL of Legend */
|
||||
.block_check_in_out,
|
||||
.block_pending,
|
||||
.block_time,
|
||||
.block_booked,
|
||||
.block_free {
|
||||
float: left;
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
line-height: 28px;
|
||||
border: 1px solid #FEA;
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
overflow: hidden;
|
||||
}
|
||||
/* Font size for the TEXT in CELLa of Legend */
|
||||
.block_pending a,
|
||||
.block_time a,
|
||||
.block_booked a,
|
||||
.block_free a,
|
||||
.block_pending,
|
||||
.block_time,
|
||||
.block_booked,
|
||||
.block_free ,
|
||||
.opsd_hint_with_text .block_check_in_out {
|
||||
font-size: 13px;
|
||||
font-weight: 400;
|
||||
}
|
||||
/* Clear Line */
|
||||
.opsd_clear_hint{
|
||||
height:1px;
|
||||
width:100%;
|
||||
clear:both;
|
||||
}
|
||||
/* Day Rates. Additional info at the top and bottom of the day cell. */
|
||||
.datepick-inline .datepick-days-cell div.date-content-bottom,
|
||||
.datepick-inline .datepick-days-cell div.date-content-top {
|
||||
font-size:0.7em;
|
||||
font-style: italic;
|
||||
line-height: 0.72em;
|
||||
text-align: center;
|
||||
padding:0;
|
||||
width:100%;
|
||||
text-shadow:none;
|
||||
}
|
||||
/*******************************************************************************/
|
||||
/* Respondive Design For Mobile Devices ****************************************/
|
||||
/*******************************************************************************/
|
||||
@media (max-width: 480px) {
|
||||
}
|
||||
@media (max-width: 768px) { /* iPad mini and all iPhones and other Mobile Devices */
|
||||
.bk_calendar_frame { /* Define the width of calendar to the 100% of the device screen*/
|
||||
width:100% !important;
|
||||
}
|
||||
.datepick-inline .datepick-one-month { /* Show Only 1 month in a row */
|
||||
width:100%;
|
||||
float:left;
|
||||
}
|
||||
.opsd_form_div input[type="text"],
|
||||
.opsd_form_div select,
|
||||
.opsd_form_div textarea {
|
||||
width: 96% !important;
|
||||
margin: auto !important;
|
||||
}
|
||||
.opsd_form_div input[type=button]{
|
||||
width:auto !important;
|
||||
}
|
||||
.opsd_form_div input[type=button]{
|
||||
font-size: 1.1em;
|
||||
font-weight: 600;
|
||||
padding: 5px 20px !important;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
/* Declaration of resolutions for some future usage... *************************/
|
||||
@media (min-width: 768px) and (max-width: 980px) {
|
||||
}
|
||||
@media (max-width: 980px) {
|
||||
}
|
||||
@media (min-width: 980px){
|
||||
}
|
||||
@media (min-width: 1200px){
|
||||
}
|
||||
@media screen and (max-width:380px) {
|
||||
}
|
||||
/* iPhone 2G-4S in portrait & landscape */
|
||||
@media only screen and (min-device-width : 320px) and (max-device-width : 480px) {
|
||||
}
|
||||
/* iPhone 5 in portrait & landscape */
|
||||
@media only screen and (min-device-width : 320px) and (max-device-width : 568px) {
|
||||
}
|
||||
/* iPad in portrait & landscape */
|
||||
@media only screen and (min-device-width : 768px) and (max-device-width : 1024px) {
|
||||
}
|
||||
/* iPad mini and iPad 1 & 2 in portrait & landscape */
|
||||
@media only screen and (min-device-width : 768px) and (max-device-width : 1024px) and (-webkit-min-device-pixel-ratio: 1) {
|
||||
}
|
||||
/* iPad 3 & 4 Media Queries - Retina iPads */
|
||||
@media only screen and (min-device-width : 768px) and (max-device-width : 1024px) and (-webkit-min-device-pixel-ratio: 2) {
|
||||
}
|
||||
/*******************************************************************************/
|
||||
402
wp-content/plugins/secure-downloads/css/client.css
Normal file
402
wp-content/plugins/secure-downloads/css/client.css
Normal file
@@ -0,0 +1,402 @@
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package: Secure Downloads
|
||||
* @category: Front-End
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2016-02-14
|
||||
*/
|
||||
|
||||
/* item form General structure */
|
||||
form.opsd_form {
|
||||
text-align: left;
|
||||
}
|
||||
.opsd_form .opsd_form_div {
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
}
|
||||
.opsd_form .form-group {
|
||||
margin:15px 0px;
|
||||
}
|
||||
|
||||
/* TEXT, SELECT, TEXTAREA *****************************************************/
|
||||
.opsd_form_div textarea,
|
||||
.opsd_form_div input[type="text"],
|
||||
.opsd_form_div select {
|
||||
border-color: #DFDFDF;
|
||||
-moz-border-radius: 4px;
|
||||
-webkit-border-radius: 4px;
|
||||
border-radius: 4px;
|
||||
border-style: solid;
|
||||
border-width: 1px;
|
||||
vertical-align: baseline;
|
||||
}
|
||||
.opsd_form_div textarea,
|
||||
.opsd_form_div input[type="text"] {
|
||||
box-sizing: padding-box;
|
||||
-mox-box-sizing: padding-box;
|
||||
-webkit-box-sizing: padding-box;
|
||||
height:28px;
|
||||
padding:4px;
|
||||
}
|
||||
/* Height */
|
||||
.opsd_form_div textarea,
|
||||
.opsd_form_div select[multiple],
|
||||
.opsd_form_div select[size]{
|
||||
height:auto;
|
||||
}
|
||||
/* Width */
|
||||
.opsd_form .form-group .controls select,
|
||||
.opsd_form textarea,
|
||||
.opsd_form input[type="text"]{
|
||||
width:250px;
|
||||
}
|
||||
/* Time inputs at the form */
|
||||
.opsd_form input.opsd-validates-as-time {
|
||||
width: 50px;
|
||||
}
|
||||
.opsd_form input[type="button"],
|
||||
.opsd_form input[type="submit"] {
|
||||
width:auto;
|
||||
vertical-align: middle;
|
||||
}
|
||||
/* Checkbox, Radio */
|
||||
.opsd_form .opsd-checkbox .opsd-list-item,
|
||||
.opsd_form .opsd-radio .opsd-list-item{
|
||||
padding: 0 15px 0 0;
|
||||
vertical-align: bottom;
|
||||
}
|
||||
.opsd_form .opsd-checkbox .opsd-list-item input[type="radio"],
|
||||
.opsd_form .opsd-checkbox .opsd-list-item input[type="checkbox"],
|
||||
.opsd_form .opsd-radio .opsd-list-item input[type="radio"],
|
||||
.opsd_form .opsd-radio .opsd-list-item input[type="checkbox"] {
|
||||
margin: 1px 0 0;
|
||||
padding: 0;
|
||||
vertical-align: middle;
|
||||
}
|
||||
.opsd_form label.opsd-list-item-label,
|
||||
.opsd_form label.opsd-list-item-label:hover {
|
||||
display: inline;
|
||||
cursor: pointer;
|
||||
vertical-align: middle;
|
||||
font-weight: 400;
|
||||
}
|
||||
/* Disabled option in selectbox */
|
||||
.opsd_form_div select option.booked,
|
||||
.opsd_form_div select option:disabled{
|
||||
color:#ddd;
|
||||
}
|
||||
/* Visitors selection - small selectboxes */
|
||||
.opsd_form_div select.col-md-1 {
|
||||
float: none;
|
||||
padding: 0 6px;
|
||||
height: 29px;
|
||||
}
|
||||
|
||||
/* item Form Buttons *******************************************************/
|
||||
.opsd-payment-form .btn,
|
||||
.opsd-payment-form .button,
|
||||
.opsd_form_div .btn,
|
||||
.opsd_form_div .button,
|
||||
.opsd_form_div .submit,
|
||||
.opsd_form_div .button-secondary {
|
||||
-moz-background-clip: border;
|
||||
-moz-background-inline-policy: continuous;
|
||||
-moz-background-origin: padding;
|
||||
background: #f7f7f7 none repeat scroll 0 0;
|
||||
border-color: #ccc;
|
||||
box-shadow: 0 1px 0 #eee;
|
||||
color: #555;
|
||||
vertical-align: top;
|
||||
}
|
||||
.opsd_form_div .submit,
|
||||
.opsd_form_div .button,
|
||||
.opsd_form_div .button-primary,
|
||||
.opsd_form_div .button-secondary,
|
||||
.opsd_form_div .button-highlighted,
|
||||
.opsd_form_div #postcustomstuff .submit input {
|
||||
-moz-border-radius: 11px;
|
||||
-webkit-border-radius: 11px;
|
||||
-moz-box-sizing: content-box;
|
||||
border-style: solid;
|
||||
border-width: 1px;
|
||||
cursor: pointer;
|
||||
font-size: 11px !important;
|
||||
line-height: 16px;
|
||||
padding: 2px 8px;
|
||||
text-decoration: none;
|
||||
font-weight: 600;
|
||||
margin: 10px 0px;
|
||||
float: right;
|
||||
}
|
||||
/* Fix Overwrite issue by theme */
|
||||
.opsd_form_div input.btn-primary:hover {
|
||||
background: #0044CC !important;
|
||||
}
|
||||
/* Pointer */
|
||||
.opsd_form_div input[type="button"]:hover,
|
||||
.opsd-payment-form input[type="button"]:hover {
|
||||
cursor: pointer !important;
|
||||
}
|
||||
|
||||
/* CAPTCHA ********************************************************************/
|
||||
.opsd_form_div img.captcha_img {
|
||||
vertical-align: middle;
|
||||
box-shadow: none;
|
||||
}
|
||||
.opsd_form_div .captachinput {
|
||||
width: 120px;
|
||||
}
|
||||
|
||||
/* Widget container */
|
||||
.widget_opsd_item {
|
||||
width:100%;
|
||||
float:left;
|
||||
margin:5px 0px;
|
||||
}
|
||||
.widget_opsd_item .opsd_form input[type="radio"],
|
||||
.widget_opsd_item .opsd_form input[type="checkbox"] {
|
||||
width:auto;
|
||||
}
|
||||
/* Under calendar */
|
||||
.widget_opsd_item .opsd_form .opsd-help-message.opsd-element-message {
|
||||
font-size: 0.85em;
|
||||
margin: 10px 4px 4px !important;
|
||||
}
|
||||
/* Under fields */
|
||||
.widget_opsd_item .opsd_form .opsd-form-control-wrap .opsd-help-message {
|
||||
font-size: 0.85em;
|
||||
margin: 2px 8px 2px 0 !important;
|
||||
}
|
||||
/* Messages in Ajax request after making item *****************************/
|
||||
.submiting_content {
|
||||
border: 1px solid #5C5;
|
||||
font-size: 15px;
|
||||
font-weight: 600;
|
||||
height: 45px;
|
||||
margin: 15px auto;
|
||||
padding: 15px 10px;
|
||||
text-align: center;
|
||||
|
||||
width: 80%;
|
||||
line-height: 1.5em;
|
||||
padding: 10px 10% 14px !important;
|
||||
}
|
||||
/* Warning Messages */
|
||||
.opsd-help-message.alert.alert-warning,
|
||||
.opsd-help-message .alert.alert-warning {
|
||||
background-image: none;
|
||||
background-color: #fcf8e3;
|
||||
font-size: 0.85em;
|
||||
box-shadow: none;
|
||||
}
|
||||
.opsd_form .opsd-checkbox .opsd-help-message.alert.alert-warning {
|
||||
line-height: inherit !important;
|
||||
}
|
||||
.opsd-help-message.opsd-element-message {
|
||||
padding :5px 5px 4px;
|
||||
margin: 10px 2px;
|
||||
vertical-align: middle;
|
||||
display:inline-block;
|
||||
}
|
||||
/* Thank you Messages */
|
||||
.submiting_content.opsd-help-message.alert.alert-warning.alert-success {
|
||||
border-color: #b2dba1;
|
||||
background-color: #dff0d8;
|
||||
color:#083;
|
||||
height: auto;
|
||||
font-size: 1em;
|
||||
background-image: none;
|
||||
font-weight: 100;
|
||||
}
|
||||
.form_opsd_messages {
|
||||
display: none;
|
||||
float: left;
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
border: 1px solid #9DA;
|
||||
padding: 3px 10px;
|
||||
margin: 2px 5px;
|
||||
background: #FEF9ED;
|
||||
color: #555;
|
||||
margin: 15px auto;
|
||||
padding: 5px 10px;
|
||||
text-align: center;
|
||||
width: 100%;
|
||||
clear: both;
|
||||
}
|
||||
|
||||
/* Times Title in tooltip */
|
||||
.opsd_times_word {
|
||||
font-weight: 600;
|
||||
}
|
||||
/* Garbage */
|
||||
.opsd_form_garbage {
|
||||
display:none;
|
||||
}
|
||||
/* Help block */
|
||||
.wpdevelop .opsd_form .help-block {
|
||||
margin-bottom: 0;
|
||||
margin-top: 0;
|
||||
}
|
||||
/* Admin bar count */
|
||||
#wp-admin-bar-opsd_options a span#opsd-count {
|
||||
background: none repeat scroll 0 0 #EEE;
|
||||
border-radius: 10px 10px 10px 10px;
|
||||
color: #333;
|
||||
display: inline;
|
||||
font-size: 10px;
|
||||
font-weight: 600;
|
||||
padding: 2px 5px;
|
||||
text-shadow: none;
|
||||
}
|
||||
#wp-admin-bar-opsd_options a:hover span#opsd-count {
|
||||
background: none repeat scroll 0 0 #FFF;
|
||||
color: #000;
|
||||
}
|
||||
|
||||
/* Pop Over Styles ************************************************************/
|
||||
.wpdevelop.popover {
|
||||
background: none repeat scroll 0 0 transparent;
|
||||
border: medium none;
|
||||
box-shadow: none;
|
||||
width: auto !important;
|
||||
z-index: 2147483647 !important;
|
||||
|
||||
}
|
||||
.wpdevelop.popover.top .arrow {
|
||||
border-top: 5px solid rgba(140, 140, 140, 0.8) !important;
|
||||
}
|
||||
.wpdevelop.popover.bottom .arrow {
|
||||
border-bottom: 5px solid rgba(140, 140, 140, 0.8) !important;
|
||||
}
|
||||
.wpdevelop.popover.left .arrow {
|
||||
border-left: 5px solid rgba(140, 140, 140, 0.8) !important;
|
||||
}
|
||||
.wpdevelop.popover.right .arrow {
|
||||
border-right: 5px solid rgba(140, 140, 140, 0.8) !important;
|
||||
}
|
||||
.wpdevelop .popover-inner {
|
||||
background: none repeat scroll 0 0 rgba(140, 140, 140, 0.8);
|
||||
border-radius: 6px 6px 6px 6px;
|
||||
box-shadow: 0 3px 7px rgba(0, 0, 0, 0.3);
|
||||
overflow: hidden;
|
||||
padding: 3px;
|
||||
width: 150px;
|
||||
color: #111;
|
||||
}
|
||||
.wpdevelop .popover-inner .popover-title {
|
||||
background-color: #FFF;
|
||||
border-bottom: 0px solid #EEE;
|
||||
border-radius: 3px 3px 0 0;
|
||||
line-height: 1;
|
||||
padding: 0px; /*9px 15px;*/
|
||||
font-size: 13px;
|
||||
}
|
||||
.wpdevelop .popover-inner .popover-content {
|
||||
background-clip: padding-box;
|
||||
background-color: #FFF;
|
||||
border-radius: 0 0 3px 3px;
|
||||
padding: 14px;
|
||||
}
|
||||
.wpdevelop .popover-content,
|
||||
.wpdevelop .popover-content p,
|
||||
.wpdevelop .popover-content ul,
|
||||
.wpdevelop .popover-content ol {
|
||||
color: #111;
|
||||
}
|
||||
|
||||
/* Rotate Icons for Loading ***********************************************/
|
||||
.opsd_spin {
|
||||
-webkit-animation: spin 2s infinite linear;
|
||||
-moz-animation: spin 2s infinite linear;
|
||||
-o-animation: spin 2s infinite linear;
|
||||
animation: spin 2s infinite linear;
|
||||
}
|
||||
@-moz-keyframes spin {
|
||||
0% {
|
||||
-moz-transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-moz-transform: rotate(359deg);
|
||||
}
|
||||
}
|
||||
@-webkit-keyframes spin {
|
||||
0% {
|
||||
-webkit-transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-webkit-transform: rotate(359deg);
|
||||
}
|
||||
}
|
||||
@-o-keyframes spin {
|
||||
0% {
|
||||
-o-transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-o-transform: rotate(359deg);
|
||||
}
|
||||
}
|
||||
@keyframes spin {
|
||||
0% {
|
||||
-webkit-transform: rotate(0deg);
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
-webkit-transform: rotate(359deg);
|
||||
transform: rotate(359deg);
|
||||
}
|
||||
}
|
||||
.opsd_rotate-90 {
|
||||
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=1);
|
||||
-webkit-transform: rotate(90deg);
|
||||
-moz-transform: rotate(90deg);
|
||||
-ms-transform: rotate(90deg);
|
||||
-o-transform: rotate(90deg);
|
||||
transform: rotate(90deg);
|
||||
}
|
||||
.opsd_rotate-180 {
|
||||
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=2);
|
||||
-webkit-transform: rotate(180deg);
|
||||
-moz-transform: rotate(180deg);
|
||||
-ms-transform: rotate(180deg);
|
||||
-o-transform: rotate(180deg);
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
.opsd_rotate-270 {
|
||||
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=3);
|
||||
-webkit-transform: rotate(270deg);
|
||||
-moz-transform: rotate(270deg);
|
||||
-ms-transform: rotate(270deg);
|
||||
-o-transform: rotate(270deg);
|
||||
transform: rotate(270deg);
|
||||
}
|
||||
.opsd_flip-horizontal {
|
||||
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1);
|
||||
-webkit-transform: scale(-1, 1);
|
||||
-moz-transform: scale(-1, 1);
|
||||
-ms-transform: scale(-1, 1);
|
||||
-o-transform: scale(-1, 1);
|
||||
transform: scale(-1, 1);
|
||||
}
|
||||
.opsd_flip-vertical {
|
||||
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1);
|
||||
-webkit-transform: scale(1, -1);
|
||||
-moz-transform: scale(1, -1);
|
||||
-ms-transform: scale(1, -1);
|
||||
-o-transform: scale(1, -1);
|
||||
transform: scale(1, -1);
|
||||
}
|
||||
|
||||
/* Mobile *********************************************************************/
|
||||
@media (max-width: 782px) {
|
||||
.wpdevelop input[type="text"],
|
||||
.wpdevelop select{
|
||||
font-size: 1.1em;
|
||||
height: 28px;
|
||||
padding: 4px 8px;
|
||||
}
|
||||
}
|
||||
286
wp-content/plugins/secure-downloads/css/modal.css
Normal file
286
wp-content/plugins/secure-downloads/css/modal.css
Normal file
@@ -0,0 +1,286 @@
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package: Admin Panel
|
||||
* @category: Admin UI
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2016-01-10
|
||||
*/
|
||||
|
||||
/* M o d a l s **************************************************************/
|
||||
.wpdevelop .modal.opsd_popup_modal {
|
||||
z-index: 50000;
|
||||
}
|
||||
.wpdevelop .modal-header {
|
||||
background: none repeat scroll 0 0 #F5F5F5;
|
||||
text-shadow: 0 0 2px #FFF;
|
||||
}
|
||||
|
||||
/* Payment request Modal */
|
||||
#opsd_payment_request_modal .modal-header h3 {
|
||||
color: #333;
|
||||
}
|
||||
#opsd_payment_request_modal .modal-body textarea {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
/* Print Loyout Modal */
|
||||
#opsd_print_modal .modal-header {
|
||||
background: none repeat scroll 0 0 #F5F5F5;
|
||||
text-shadow: 0 0 2px #FFF;
|
||||
}
|
||||
#opsd_print_modal .modal-header h3 {
|
||||
color: #333;
|
||||
}
|
||||
#opsd_print_modal .modal-header {
|
||||
text-shadow: none;
|
||||
}
|
||||
|
||||
/* Modal Google Calendar Events Import */
|
||||
#opsd_gcal_import_events_modal span.description {
|
||||
display:none;
|
||||
}
|
||||
#opsd_gcal_import_events_modal #opsd_gcal_events_until,
|
||||
#opsd_gcal_import_events_modal .opsd_gcal_events_until_offset,
|
||||
#opsd_gcal_import_events_modal #opsd_gcal_events_from,
|
||||
#opsd_gcal_import_events_modal .opsd_gcal_events_from_offset {
|
||||
float:left;
|
||||
margin:5px 0 0 0 !important;
|
||||
}
|
||||
#opsd_gcal_import_events_modal .opsd_gcal_events_from_offset label,
|
||||
#opsd_gcal_import_events_modal .opsd_gcal_events_until_offset label {
|
||||
margin: 0 10px;
|
||||
float:left;
|
||||
line-height: 29px;
|
||||
}
|
||||
#opsd_gcal_import_events_modal input[type=text],
|
||||
#opsd_gcal_import_events_modal select {
|
||||
height:28px;
|
||||
}
|
||||
#opsd_gcal_import_events_modal th {
|
||||
vertical-align: middle;
|
||||
}
|
||||
#opsd_gcal_import_events_modal th,
|
||||
#opsd_gcal_import_events_modal td {
|
||||
border:none;
|
||||
}
|
||||
#opsd_gcal_import_events_modal label {
|
||||
line-height: 28px;
|
||||
margin: 0;
|
||||
vertical-align: middle;
|
||||
}
|
||||
#opsd_gcal_import_events_modal #opsd_gcal_events_from_offset_type,
|
||||
#opsd_gcal_import_events_modal #opsd_gcal_events_until_offset_type {
|
||||
vertical-align: initial;
|
||||
}
|
||||
|
||||
/* Export */
|
||||
#opsd_export_csv_modal {
|
||||
}
|
||||
@media (max-width: 782px) {
|
||||
.wpdevelop .modal-dialog{
|
||||
margin: 60px 10px 10px;
|
||||
}
|
||||
|
||||
/* Import Google Events Dialog*/
|
||||
#opsd_gcal_import_events_modal .modal-dialog.modal-lg {
|
||||
width: auto;
|
||||
}
|
||||
#opsd_gcal_import_events_modal label{
|
||||
font-weight: 600;
|
||||
font-size: 1.1em;
|
||||
width:100%;
|
||||
display:block;
|
||||
float:none;
|
||||
}
|
||||
#opsd_gcal_import_events_modal input[type=text],
|
||||
#opsd_gcal_import_events_modal select {
|
||||
display:block;
|
||||
width:100%;
|
||||
clear:both;
|
||||
height:34px;
|
||||
float:none !important;
|
||||
}
|
||||
#opsd_gcal_import_events_modal th,
|
||||
#opsd_gcal_import_events_modal td {
|
||||
display:block;
|
||||
padding:0;
|
||||
}
|
||||
#opsd_gcal_import_events_modal td {
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
#opsd_gcal_import_events_modal #opsd_gcal_events_until,
|
||||
#opsd_gcal_import_events_modal .opsd_gcal_events_until_offset,
|
||||
#opsd_gcal_import_events_modal #opsd_gcal_events_from,
|
||||
#opsd_gcal_import_events_modal .opsd_gcal_events_from_offset {
|
||||
float:none;
|
||||
margin:0 !important;
|
||||
}
|
||||
#opsd_gcal_import_events_modal .opsd_gcal_events_from_offset label,
|
||||
#opsd_gcal_import_events_modal .opsd_gcal_events_until_offset label {
|
||||
float:none;
|
||||
margin:10px 0 0!important;
|
||||
}
|
||||
#opsd_gcal_import_events_modal #opsd_gcal_events_from_offset,
|
||||
#opsd_gcal_import_events_modal #opsd_gcal_events_from_offset_type,
|
||||
#opsd_gcal_import_events_modal #opsd_gcal_events_until_offset,
|
||||
#opsd_gcal_import_events_modal #opsd_gcal_events_until_offset_type {
|
||||
width:100% !important;
|
||||
float:none;
|
||||
}
|
||||
#opsd_gcal_import_events_modal .opsd_gcal_events_from_offset > span.opsd_offset_value select,
|
||||
#opsd_gcal_import_events_modal .opsd_gcal_events_until_offset > span.opsd_offset_value select {
|
||||
margin-top:10px !important;
|
||||
}
|
||||
|
||||
/* M o d a l TinyMCE t o o l b a r ****************************/
|
||||
#opsd_tiny_modal .form-table td select {
|
||||
height: 40px;
|
||||
}
|
||||
#opsd_tiny_modal .wpdvlp-top-tabs .nav-tab {
|
||||
-moz-border-radius:0;
|
||||
-webkit-border-radius:0;
|
||||
border-radius:0;
|
||||
border: 1px solid #cccccc;
|
||||
padding: 10px;
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
/* Fix position of modal window, that depend from sidebar in admin panel */
|
||||
@media (min-width: 992px) and (max-width: 1300px) {
|
||||
.wpdevelop .modal-dialog {
|
||||
margin: 30px 170px auto;
|
||||
}
|
||||
.wpdevelop .modal-dialog.modal-lg {
|
||||
width: 815px;
|
||||
}
|
||||
#opsd_gcal_import_events_modal th {
|
||||
width:140px;
|
||||
}
|
||||
}
|
||||
|
||||
/* M o d a l TinyMCE t o o l b a r ****************************************/
|
||||
|
||||
#opsd_tiny_modal .modal-dialog.modal-lg {
|
||||
width:94%;
|
||||
}
|
||||
/* Scrollbar for modal */
|
||||
#opsd_tiny_modal {
|
||||
overflow-y: auto !important;
|
||||
}
|
||||
/* this pasrt for having scrollbar inside of the modal window with fixed height */
|
||||
#opsd_tiny_modal_NO .modal-dialog{
|
||||
overflow-y: initial !important;
|
||||
}
|
||||
#opsd_tiny_modal_NO .modal-body{
|
||||
height: 250px;
|
||||
overflow-y: auto;
|
||||
}
|
||||
.wp-admin .modal-backdrop {
|
||||
background-color: #000000;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
position: fixed;
|
||||
right: 0;
|
||||
top: 0;
|
||||
z-index: 1040;
|
||||
}
|
||||
.wp-admin .modal-backdrop.fade {
|
||||
opacity: 0;
|
||||
}
|
||||
.wp-admin .modal-backdrop.in {
|
||||
opacity: 0.5;
|
||||
}
|
||||
#opsd_tiny_modal strong,
|
||||
#opsd_tiny_modal label {
|
||||
font-weight: 600;
|
||||
}
|
||||
#opsd_tiny_modal .form-table th {
|
||||
font-weight: 600;
|
||||
line-height: 1.3;
|
||||
padding-bottom: 10px;
|
||||
padding-left: 0;
|
||||
padding-right: 10px;
|
||||
padding-top: 10px;
|
||||
vertical-align: top;
|
||||
width: 200px;
|
||||
}
|
||||
#opsd_tiny_modal .form-table td {
|
||||
line-height: 1.3;
|
||||
margin-bottom: 9px;
|
||||
padding-bottom: 5px;
|
||||
padding-left: 10px;
|
||||
padding-right: 10px;
|
||||
padding-top: 5px;
|
||||
vertical-align: middle;
|
||||
}
|
||||
#opsd_tiny_modal .modal-footer a.button,
|
||||
#opsd_tiny_modal .modal-footer a.button:hover,
|
||||
#opsd_tiny_modal .modal-footer a.button:active,
|
||||
#opsd_tiny_modal .modal-footer a.button:focus {
|
||||
text-decoration: none;
|
||||
outline: 0;
|
||||
}
|
||||
#opsd_tiny_modal .opsd_expand_section_link,
|
||||
#opsd_tiny_modal a.opsd_expand_section_link:hover,
|
||||
#opsd_tiny_modal a.opsd_expand_section_link:focus {
|
||||
color:#21759b;
|
||||
cursor: pointer;
|
||||
outline: 0;
|
||||
border:none;
|
||||
border-bottom:1px dashed #21759B;
|
||||
text-decoration: none;
|
||||
}
|
||||
#opsd_tiny_modal .opsd_advanced_section,
|
||||
#opsd_tiny_modal .itemcalendar_advanced_section,
|
||||
#opsd_tiny_modal .itemselect_advanced_section {
|
||||
display:none;
|
||||
}
|
||||
#opsd_tiny_modal .put-in {
|
||||
cursor: pointer;
|
||||
font-weight: 600;
|
||||
background: none repeat scroll 0 0 #E9E9E9;
|
||||
border: 1px solid #BBBBBB;
|
||||
width:100%;
|
||||
}
|
||||
#opsd_tiny_modal input[type="checkbox"],
|
||||
#opsd_tiny_modal input[type="radio"] {
|
||||
margin: 0 10px 2px 0;
|
||||
vertical-align: middle;
|
||||
outline: 0;
|
||||
}
|
||||
#opsd_tiny_modal .opsd_sub_settings_grayed {
|
||||
background-color: #f3f3f3;
|
||||
}
|
||||
#opsd_tiny_modal .opsd_sub_settings_grayed th {
|
||||
padding: 10px 0 0 20px;
|
||||
}
|
||||
/* Placeholders */
|
||||
#opsd_tiny_modal ::-webkit-input-placeholder { /* Chrome/Opera/Safari */
|
||||
color: #999;
|
||||
}
|
||||
#opsd_tiny_modal ::-moz-placeholder { /* Firefox 19+ */
|
||||
color: #999;
|
||||
}
|
||||
#opsd_tiny_modal :-ms-input-placeholder { /* IE 10+ */
|
||||
color: #999;
|
||||
}
|
||||
#opsd_tiny_modal :-moz-placeholder {
|
||||
color: #999;
|
||||
}
|
||||
#opsd_tiny_modal .itemsearch_search_results{
|
||||
display:none;
|
||||
}
|
||||
#opsd_tiny_modal .itemsearch_search_form.opsd_sub_settings_grayed{
|
||||
display:none;
|
||||
}
|
||||
#opsd_tiny_modal .opsd_shortcode_itemresource {
|
||||
display:none;
|
||||
}
|
||||
#opsd_tiny_modal select option:disabled {
|
||||
color: #ccc;
|
||||
display: none;
|
||||
}
|
||||
204
wp-content/plugins/secure-downloads/css/popover.css
Normal file
204
wp-content/plugins/secure-downloads/css/popover.css
Normal file
@@ -0,0 +1,204 @@
|
||||
/* P O P O V E R ************************************************************/
|
||||
.wpdevelop .popover {
|
||||
/* width:400px;
|
||||
max-width:400px;*/
|
||||
border: 2px solid #555;
|
||||
font-size: 12px;
|
||||
}
|
||||
.wpdevelop .popover .popover-title {
|
||||
padding:2px 14px 0;
|
||||
line-height: 30px;
|
||||
}
|
||||
.wpdevelop .popover .popover-title .popover-title-id {
|
||||
display: inline-block;
|
||||
margin: 0 5px 0 0;
|
||||
/* FrontEnd */
|
||||
line-height: 35px;
|
||||
}
|
||||
.wpdevelop .popover .popover-title .control-group {
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
margin:2px 0;
|
||||
}
|
||||
.wpdevelop .popover .popover-title .control-group a.button{
|
||||
margin: 0 0 0 5px;
|
||||
line-height: 28px;
|
||||
|
||||
margin: 0 5px 5px 0;
|
||||
}
|
||||
.wpdevelop .popover .popover-title .control-group .opsd-buttons-separator {
|
||||
margin-right: 10px;
|
||||
}
|
||||
.wpdevelop .popover .popover-content {
|
||||
border-top: 1px solid #aaa;
|
||||
}
|
||||
.wpdevelop .popover-inner {
|
||||
width: 350px;
|
||||
}
|
||||
.wpdevelop.popover.left .arrow {
|
||||
left:auto;
|
||||
}
|
||||
.wpdevelop.tooltip {
|
||||
z-index:9999;
|
||||
}
|
||||
.wpdevelop .popover a,
|
||||
.wpdevelop .popover a:hover,
|
||||
.wpdevelop .popover a:focus {
|
||||
box-shadow: none;
|
||||
outline: none;
|
||||
}
|
||||
.wpdevelop .popover .popover-close,
|
||||
.wpdevelop .popover .popover-close:hover {
|
||||
font-size: 20px;
|
||||
position: absolute;
|
||||
right: 10px;
|
||||
top: 8px;
|
||||
|
||||
padding: 5px 6px;
|
||||
right: 0;
|
||||
top: 0;
|
||||
}
|
||||
.wpdevelop .popover .popover-close a,
|
||||
.wpdevelop .popover .popover-close a:hover,
|
||||
.wpdevelop .popover .popover-close a:active,
|
||||
.wpdevelop .popover .popover-close a:focus {
|
||||
text-decoration: none;
|
||||
color:#444;
|
||||
border-style: none;
|
||||
outline: 0;
|
||||
}
|
||||
.wpdevelop .popover_calendar_hover,
|
||||
.wpdevelop .popover_calendar_hover .popover-content{
|
||||
border: none;
|
||||
}
|
||||
.wpdevelop .popover-content .opsd_tl_popover_opsd_separator {
|
||||
margin: 10px 0;
|
||||
}
|
||||
/* PopOver Content Data *******************************************************/
|
||||
.wpdevelop .popover-title,
|
||||
.wpdevelop .popover-content .opsd-popover-content-data {
|
||||
color:#000;
|
||||
}
|
||||
.wpdevelop .popover-content .opsd-popover-content-data {
|
||||
font-size: 13px;
|
||||
color:#000;
|
||||
}
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .opsd-popover-labels-bar,
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .opsd-popover-cost-bar {
|
||||
float: left;
|
||||
margin: 0px;
|
||||
padding: 0px;
|
||||
width: auto;
|
||||
}
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .opsd-popover-cost-bar {
|
||||
float: right;
|
||||
}
|
||||
/* ID, Labels ... */
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .field-id,
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .field-labels {
|
||||
float:left;
|
||||
margin: 0 10px 2px 0;
|
||||
font-size: 1em;
|
||||
}
|
||||
/* ID */
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .field-id span.label {
|
||||
line-height:1.5em;
|
||||
padding: 2px 5px;
|
||||
|
||||
font-weight: 600;
|
||||
border:none;
|
||||
border-radius: 10px;
|
||||
-moz-border-radius: 10px;
|
||||
-webkit-border-radius: 10px;
|
||||
color: #fff;
|
||||
background: #888;
|
||||
}
|
||||
/* Labels */
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .field-labels span.label{
|
||||
line-height: 1.5em;
|
||||
padding: 2px 5px;
|
||||
font-weight: 600;
|
||||
|
||||
border: 1px solid #eeeeee;
|
||||
box-shadow: 0 0 1px #cccccc;
|
||||
}
|
||||
/* Payment status*/
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .field-labels span.label .label-payment-status-prefix {
|
||||
font-size: 0.8em;
|
||||
font-weight: 400;
|
||||
}
|
||||
/* Cost */
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .opsd-popover-cost {
|
||||
font-size: 1em;
|
||||
font-weight: 600;
|
||||
line-height: 1.5em;
|
||||
padding: 0;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
}
|
||||
/*Data*/
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .opsd-popover-opsd-data,
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .opsd-popover-opsd-data > div {
|
||||
line-height: 1.7em;
|
||||
text-align: left;
|
||||
word-wrap: break-word;
|
||||
margin:5px 0 10px;
|
||||
}
|
||||
/* Notes */
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .opsd-popover-opsd-notes {
|
||||
font-size: 0.9em;
|
||||
font-style: italic;
|
||||
margin: 0 0 10px;
|
||||
}
|
||||
/*Dates*/
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .field-dates .field-opsd-date,
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .field-dates .field-opsd-date:hover {
|
||||
background: none repeat scroll 0 0 #FFBB45;
|
||||
border: 1px solid #EEE;
|
||||
border-radius: 5px 5px 5px 5px;
|
||||
box-shadow: 0 0 1px #CCC;
|
||||
color: #FFF;
|
||||
font-weight: 600;
|
||||
padding: 4px 10px 3px;
|
||||
text-decoration: none;
|
||||
text-shadow: 0 -1px 0 #CCC;
|
||||
white-space: nowrap;
|
||||
font-size: 0.85em;
|
||||
line-height: 2.5em;
|
||||
}
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .field-dates .field-opsd-date.approved,
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .field-dates .field-opsd-date.approved:hover {
|
||||
background: none repeat scroll 0 0 #9BE;
|
||||
}
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .field-dates .field-opsd-time {
|
||||
color: #555;
|
||||
text-decoration: none;
|
||||
text-shadow: 0 0 1px #AAA;
|
||||
}
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .field-dates .date_tire {
|
||||
font-size: 17px;
|
||||
font-weight: 600;
|
||||
}
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .field-dates .opsd_dates_small,
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .field-dates .opsd_dates_full {
|
||||
line-height: 24px;
|
||||
}
|
||||
.wpdevelop .popover-content .opsd-popover-content-data .field-dates .date_from_dif_type {
|
||||
color: #FFF;
|
||||
text-shadow: 0 -1px 0 #BBB;
|
||||
}
|
||||
|
||||
/* M O B I L E ************************************************************/
|
||||
@media (max-width: 782px) {
|
||||
|
||||
/* PopOver */
|
||||
.wpdevelop .popover .popover-title .control-group {
|
||||
display: block;
|
||||
margin: 0 0 0 -5px;
|
||||
vertical-align: middle;
|
||||
}
|
||||
.wpdevelop .popover .popover-title .control-group a.button{
|
||||
height: 34px;
|
||||
line-height: 1.5em;
|
||||
}
|
||||
}
|
||||
60
wp-content/plugins/secure-downloads/css/print.css
Normal file
60
wp-content/plugins/secure-downloads/css/print.css
Normal file
@@ -0,0 +1,60 @@
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package: item Listing - Print view
|
||||
* @category: Admin Pages only
|
||||
* @author wpdevelop
|
||||
*
|
||||
* @web-site https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2015-04-11
|
||||
*/
|
||||
#print_loyout_content tr.opsd-listing-row td .fieldvalue,
|
||||
#print_loyout_content tr.opsd-listing-row td .label.label-default {
|
||||
background: none repeat scroll 0 0 transparent !important;
|
||||
border: none;
|
||||
color: #333;
|
||||
font-size: 10px;
|
||||
font-weight: 400;
|
||||
padding: 0 4px !important;
|
||||
text-shadow: none !important;
|
||||
line-height: 2em;
|
||||
}
|
||||
#print_loyout_content tr.opsd-listing-row td .label.label-default{
|
||||
font-weight: 600;
|
||||
}
|
||||
#print_loyout_content tr.opsd-listing-row td .label.label-default {
|
||||
white-space: nowrap;
|
||||
}
|
||||
#print_loyout_content tr.opsd-listing-header th,
|
||||
#print_loyout_content tr.opsd-listing-row td,
|
||||
#print_loyout_content .opsd-listing-header {
|
||||
text-shadow: none !important;
|
||||
}
|
||||
#print_loyout_content tr.opsd-listing-header th {
|
||||
padding: 7px 10px;
|
||||
font-size: 12px;
|
||||
|
||||
}
|
||||
#print_loyout_content tr.opsd-listing-row td {
|
||||
padding: 5px 10px;
|
||||
font-size: 11px;
|
||||
}
|
||||
#print_loyout_content tr.opsd-listing-row td strong {
|
||||
font-size: 11px;
|
||||
}
|
||||
#print_loyout_content .opsd-listing-header {
|
||||
background: #e4e4e4;
|
||||
border: 1px solid #C6C6C6;
|
||||
border-bottom-color: #CCC;
|
||||
border-radius: 5px 5px 0 0;
|
||||
-moz-border-radius: 5px 5px 0 0;
|
||||
-webkit-border-radius: 5px 5px 0 0;
|
||||
-ms-border-radius: 5px 5px 0 0;
|
||||
color: #333;
|
||||
font-size: 12px;
|
||||
font-weight: 600;
|
||||
margin: 0;
|
||||
padding: 2px 0px;
|
||||
text-shadow: 0 1px 1px #F5F5F5;
|
||||
}
|
||||
67
wp-content/plugins/secure-downloads/index.php
Normal file
67
wp-content/plugins/secure-downloads/index.php
Normal file
@@ -0,0 +1,67 @@
|
||||
<?php
|
||||
/*
|
||||
Plugin Name: Secure Downloads
|
||||
Plugin URI: https://oplugins.com/plugins/secure-downloads
|
||||
Description: Easy generate and send secure expiring links for file downloads
|
||||
Author: wpdevelop, oplugins
|
||||
Author URI: https://oplugins.com/
|
||||
Text Domain: secure-downloads
|
||||
Domain Path: /languages/
|
||||
Version: 1.2.2
|
||||
*/
|
||||
|
||||
/* Copyright 2018 - 2023 www.oplugins.com (email: info@oplugins.com),
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>
|
||||
*/
|
||||
|
||||
// Exit if accessed directly
|
||||
if ( ! defined( 'ABSPATH' ) ) die('<h3>Direct access to this file do not allow!</h3>');
|
||||
|
||||
if ( ! defined( 'OPSD_VERSION_NUM' ) ) define( 'OPSD_VERSION_NUM', '1.2.2' );
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// PRIMARY URL CONSTANTS //////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
// ..\home\siteurl\www\wp-content\plugins\plugin-name\opsd-item.php
|
||||
if ( ! defined( 'OPSD_FILE' ) ) define( 'OPSD_FILE', __FILE__ );
|
||||
|
||||
// opsd-item.php
|
||||
if ( ! defined('OPSD_PLUGIN_FILENAME' ) ) define('OPSD_PLUGIN_FILENAME', basename( __FILE__ ) );
|
||||
|
||||
// plugin-name
|
||||
if ( ! defined('OPSD_PLUGIN_DIRNAME' ) ) define('OPSD_PLUGIN_DIRNAME', plugin_basename( dirname( __FILE__ ) ) );
|
||||
|
||||
// ..\home\siteurl\www\wp-content\plugins\plugin-name
|
||||
if ( ! defined('OPSD_PLUGIN_DIR' ) ) define('OPSD_PLUGIN_DIR', untrailingslashit( plugin_dir_path( OPSD_FILE ) ) );
|
||||
|
||||
// http: //website.com/wp-content/plugins/plugin-name
|
||||
if ( ! defined('OPSD_PLUGIN_URL' ) ) define('OPSD_PLUGIN_URL', untrailingslashit( plugins_url( '', OPSD_FILE ) ) );
|
||||
|
||||
require_once OPSD_PLUGIN_DIR . '/core/opsd.php';
|
||||
|
||||
/**
|
||||
* 1) Rename all files in plugin directory starting from opsd -> prefix
|
||||
*
|
||||
* 2) Replace Instruction:
|
||||
*
|
||||
, 'secure-downloads') -> , 'pluginnamelocale')
|
||||
_opsd_ -> _bk_ (...) in get_opsd_option ....
|
||||
OPSD -> PREFIX
|
||||
opsd -> prefix
|
||||
securedownloads -> booking ???
|
||||
Secure Downloads -> NEW_PLUGIN_NAME
|
||||
*
|
||||
*/
|
||||
321
wp-content/plugins/secure-downloads/js/admin.js
Normal file
321
wp-content/plugins/secure-downloads/js/admin.js
Normal file
@@ -0,0 +1,321 @@
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @subpackage BackEnd Main Script Lib
|
||||
* @category Scripts
|
||||
*
|
||||
* @author wpdevelop
|
||||
* @link https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2014.09.10
|
||||
*/
|
||||
|
||||
|
||||
/** Set item listing row as R e a d
|
||||
*
|
||||
* @param {type} opsd_id
|
||||
* @returns {undefined}
|
||||
*/
|
||||
function set_opsd_row_read(opsd_id){
|
||||
if (opsd_id == 0) {
|
||||
jQuery('.new-label').addClass('hidden_items');
|
||||
jQuery('.bk-update-count').html( '0' );
|
||||
} else {
|
||||
jQuery('#opsd_mark_'+opsd_id + '').addClass('hidden_items');
|
||||
decrese_new_counter();
|
||||
}
|
||||
}
|
||||
|
||||
/** Set item listing row as U n R e a d
|
||||
*
|
||||
* @param {type} opsd_id
|
||||
* @returns {undefined}
|
||||
*/
|
||||
function set_opsd_row_unread(opsd_id){
|
||||
jQuery('#opsd_mark_'+opsd_id + '').removeClass('hidden_items');
|
||||
increase_new_counter();
|
||||
}
|
||||
|
||||
|
||||
/** Increase counter about new items
|
||||
*
|
||||
* @returns {undefined}
|
||||
*/
|
||||
function increase_new_counter () {
|
||||
var my_num = parseInt(jQuery('.bk-update-count').html());
|
||||
my_num = my_num + 1;
|
||||
jQuery('.bk-update-count').html(my_num);
|
||||
}
|
||||
|
||||
/** Decrease counter about new items
|
||||
*
|
||||
* @returns {undefined}
|
||||
*/
|
||||
function decrese_new_counter () {
|
||||
var my_num = parseInt(jQuery('.bk-update-count').html());
|
||||
if (my_num>0){
|
||||
my_num = my_num - 1;
|
||||
jQuery('.bk-update-count').html(my_num);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Set item listing R O W Approved
|
||||
function set_opsd_row_approved(opsd_id){
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-labels .label-approved').removeClass('hidden_items');
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-labels .label-pending').addClass('hidden_items');
|
||||
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-dates .field-opsd-date').addClass('approved');
|
||||
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-actions .approve_opsd_link').addClass('hidden_items');
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-actions .pending_opsd_link').removeClass('hidden_items');
|
||||
|
||||
}
|
||||
|
||||
// Set item listing R O W Pending
|
||||
function set_opsd_row_pending(opsd_id){
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-labels .label-approved').addClass('hidden_items');
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-labels .label-pending').removeClass('hidden_items');
|
||||
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-dates .field-opsd-date').removeClass('approved');
|
||||
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-actions .approve_opsd_link').removeClass('hidden_items');
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-actions .pending_opsd_link').addClass('hidden_items');
|
||||
|
||||
}
|
||||
|
||||
// Remove item listing R O W
|
||||
function set_opsd_row_deleted(opsd_id){
|
||||
jQuery('#opsd_row_'+opsd_id).fadeOut(1000);
|
||||
jQuery('#gcal_imported_events_id_'+opsd_id).remove();
|
||||
}
|
||||
|
||||
// Set in item listing R O W Resource title
|
||||
function set_opsd_row_resource_name(opsd_id, resourcename){
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-labels .label-resource').html(resourcename);
|
||||
}
|
||||
|
||||
// Set in item listing R O W new Remark in hint
|
||||
function set_opsd_row_remark_in_hint( opsd_id, new_remark ){
|
||||
|
||||
jQuery('#opsd_row_' + opsd_id + ' .opsd-actions .remark_opsd_link').attr( 'data-original-title', new_remark );
|
||||
|
||||
if ( new_remark != '' )
|
||||
jQuery('#opsd_row_' + opsd_id + ' .opsd-actions .remark_opsd_link i.glyphicon-comment').addClass('red_icon_color');
|
||||
else
|
||||
jQuery('#opsd_row_' + opsd_id + ' .opsd-actions .remark_opsd_link i.glyphicon-comment').removeClass('red_icon_color');
|
||||
}
|
||||
|
||||
// Set in item listing R O W new Remark in hint
|
||||
function set_opsd_row_payment_status(opsd_id, payment_status, payment_status_show){
|
||||
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-labels .label-payment-status').removeClass('label-danger');
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-labels .label-payment-status').removeClass('label-success');
|
||||
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-labels .label-payment-status').html(payment_status_show);
|
||||
|
||||
if (payment_status == 'OK') {
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-labels .label-payment-status').addClass('label-success');
|
||||
} else if (payment_status == '') {
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-labels .label-payment-status').addClass('label-danger');
|
||||
} else {
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-labels .label-payment-status').addClass('label-danger');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
// Interface Element
|
||||
function showSelectedInDropdown(selector_id, title, value){
|
||||
jQuery('#' + selector_id + '_selector .opsd_selected_in_dropdown').html( title );
|
||||
jQuery('#' + selector_id ).val( value );
|
||||
jQuery('#' + selector_id + '_container').hide();
|
||||
}
|
||||
|
||||
//Admin function s for checking all checkbos in one time
|
||||
function setCheckBoxInTable(el_stutus, el_class){
|
||||
jQuery('.'+el_class).attr('checked', el_stutus);
|
||||
|
||||
if ( el_stutus ) {
|
||||
jQuery('.'+el_class).parent().parent().addClass('row_selected_color');
|
||||
} else {
|
||||
jQuery('.'+el_class).parent().parent().removeClass('row_selected_color');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// FixIn: 5.4.5
|
||||
function opsd_get_selected_locale( opsd_id, opsd_active_locale ) {
|
||||
|
||||
var id_to_check = "" + opsd_id;
|
||||
if ( id_to_check.indexOf('|') == -1 ) {
|
||||
var selected_locale = jQuery('#locale_for_item' + opsd_id).val();
|
||||
|
||||
if ( ( selected_locale != '' ) && ( typeof(selected_locale) !== 'undefined' ) ) {
|
||||
opsd_active_locale = selected_locale;
|
||||
}
|
||||
}
|
||||
return opsd_active_locale;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
//FixIn: 6.1.1.10
|
||||
// Set item listing R O W Trash
|
||||
function set_opsd_row_trash( opsd_id ){
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-labels .label-trash').removeClass('hidden_items');
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-actions .trash_opsd_link').addClass('hidden_items');
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-actions .restore_opsd_link').removeClass('hidden_items');
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-actions .delete_opsd_link').removeClass('hidden_items');
|
||||
|
||||
|
||||
jQuery('#opsd-id-'+opsd_id + ' .label-trash').removeClass('hidden_items');
|
||||
}
|
||||
|
||||
//FixIn: 6.1.1.10
|
||||
// Set item listing R O W Restore
|
||||
function set_opsd_row_restore( opsd_id ){
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-labels .label-trash').addClass('hidden_items');
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-actions .trash_opsd_link').removeClass('hidden_items');
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-actions .restore_opsd_link').addClass('hidden_items');
|
||||
jQuery('#opsd_row_'+opsd_id + ' .opsd-actions .delete_opsd_link').addClass('hidden_items');
|
||||
|
||||
jQuery('#opsd-id-'+opsd_id + ' .label-trash').addClass('hidden_items');
|
||||
}
|
||||
|
||||
|
||||
|
||||
// Get Selected rows in imported Events list
|
||||
function get_selected_items_id_in_this_list( list_tag, skip_id_length ) {
|
||||
|
||||
var checkedd = jQuery( list_tag + ":checked" );
|
||||
var id_for_approve = "";
|
||||
|
||||
// get all IDs
|
||||
checkedd.each(function(){
|
||||
var id_c = jQuery(this).attr('id');
|
||||
id_c = id_c.substr(skip_id_length,id_c.length-skip_id_length);
|
||||
id_for_approve += id_c + "|";
|
||||
});
|
||||
|
||||
if ( id_for_approve.length > 1 )
|
||||
id_for_approve = id_for_approve.substr(0,id_for_approve.length-1); //delete last "|"
|
||||
|
||||
return id_for_approve ;
|
||||
|
||||
}
|
||||
|
||||
// Get the list of ID in selected items from item listing
|
||||
function get_selected_items_id_in_opsd_listing(){
|
||||
|
||||
var checkedd = jQuery(".opsd_list_item_checkbox:checked");
|
||||
var id_for_approve = "";
|
||||
|
||||
// get all IDs
|
||||
checkedd.each(function(){
|
||||
var id_c = jQuery(this).attr('id');
|
||||
id_c = id_c.substr(20,id_c.length-20);
|
||||
id_for_approve += id_c + "|";
|
||||
});
|
||||
|
||||
if ( id_for_approve.length > 1 )
|
||||
id_for_approve = id_for_approve.substr(0,id_for_approve.length-1); //delete last "|"
|
||||
|
||||
return id_for_approve ;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/** Selections of several checkboxes like in gMail with shift :)
|
||||
* Need to have this structure:
|
||||
* .opsd_selectable_table
|
||||
* .opsd_selectable_head
|
||||
* .check-column
|
||||
* :checkbox
|
||||
* .opsd_selectable_body
|
||||
* .opsd_row
|
||||
* .check-column
|
||||
* :checkbox
|
||||
* .opsd_selectable_foot
|
||||
* .check-column
|
||||
* :checkbox
|
||||
*/
|
||||
( function( $ ){
|
||||
$( document ).ready(function(){
|
||||
|
||||
var checks, first, last, checked, sliced, lastClicked = false;
|
||||
|
||||
// check all checkboxes
|
||||
$('.opsd_selectable_body').find('.check-column').find(':checkbox').on( 'click', function(e) {
|
||||
//$('.opsd_selectable_body').children().children('.check-column').find(':checkbox').on( 'click', function(e) {
|
||||
if ( 'undefined' == e.shiftKey ) { return true; }
|
||||
if ( e.shiftKey ) {
|
||||
if ( !lastClicked ) { return true; }
|
||||
//checks = $( lastClicked ).closest( 'form' ).find( ':checkbox' ).filter( ':visible:enabled' );
|
||||
checks = $( lastClicked ).closest( '.opsd_selectable_body' ).find( ':checkbox' ).filter( ':visible:enabled' );
|
||||
first = checks.index( lastClicked );
|
||||
last = checks.index( this );
|
||||
checked = $(this).prop('checked');
|
||||
if ( 0 < first && 0 < last && first != last ) {
|
||||
sliced = ( last > first ) ? checks.slice( first, last ) : checks.slice( last, first );
|
||||
sliced.prop( 'checked', function() {
|
||||
if ( $(this).closest('.opsd_row').is(':visible') )
|
||||
return checked;
|
||||
|
||||
return false;
|
||||
});
|
||||
}
|
||||
}
|
||||
lastClicked = this;
|
||||
|
||||
// toggle "check all" checkboxes
|
||||
var unchecked = $(this).closest('.opsd_selectable_body').find(':checkbox').filter(':visible:enabled').not(':checked');
|
||||
$(this).closest('.opsd_selectable_table').children('.opsd_selectable_head, .opsd_selectable_foot').find(':checkbox').prop('checked', function() {
|
||||
return ( 0 === unchecked.length );
|
||||
});
|
||||
|
||||
return true;
|
||||
});
|
||||
|
||||
$('.opsd_selectable_head, .opsd_selectable_foot').find('.check-column :checkbox').on( 'click.wp-toggle-checkboxes', function( event ) {
|
||||
var $this = $(this),
|
||||
$table = $this.closest( '.opsd_selectable_table' ),
|
||||
controlChecked = $this.prop('checked'),
|
||||
toggle = event.shiftKey || $this.data('wp-toggle');
|
||||
|
||||
$table.children( '.opsd_selectable_body' ).filter(':visible')
|
||||
.find('.check-column').find(':checkbox')
|
||||
//.children().children('.check-column').find(':checkbox')
|
||||
.prop('checked', function() {
|
||||
if ( $(this).is(':hidden,:disabled') ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if ( toggle ) {
|
||||
return ! $(this).prop( 'checked' );
|
||||
} else if ( controlChecked ) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
});
|
||||
|
||||
$table.children('.opsd_selectable_head, .opsd_selectable_foot').filter(':visible')
|
||||
.find('.check-column').find(':checkbox')
|
||||
//.children().children('.check-column').find(':checkbox')
|
||||
.prop('checked', function() {
|
||||
if ( toggle ) {
|
||||
return false;
|
||||
} else if ( controlChecked ) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
});
|
||||
});
|
||||
});
|
||||
}( jQuery ) );
|
||||
3
wp-content/plugins/secure-downloads/js/index.php
Normal file
3
wp-content/plugins/secure-downloads/js/index.php
Normal file
@@ -0,0 +1,3 @@
|
||||
<?php
|
||||
// Silence is golden.
|
||||
?>
|
||||
@@ -0,0 +1,2 @@
|
||||
var opsd_modal = jQuery.fn.modal.noConflict();
|
||||
jQuery.fn.opsd_modal = opsd_modal;
|
||||
39
wp-content/plugins/secure-downloads/js/opsd_vars.js
Normal file
39
wp-content/plugins/secure-downloads/js/opsd_vars.js
Normal file
@@ -0,0 +1,39 @@
|
||||
/**
|
||||
* @version 1.0
|
||||
* @package Secure Downloads
|
||||
* @subpackage JS Variables
|
||||
* @category Scripts
|
||||
*
|
||||
* @author wpdevelop
|
||||
* @link https://oplugins.com/
|
||||
* @email info@oplugins.com
|
||||
*
|
||||
* @modified 2014.05.20
|
||||
*/
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Eval specific variable value (integer, bool, arrays, etc...)
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
function opsd_define_var( opsd_global_var ) {
|
||||
if (opsd_global_var === undefined) { return null; }
|
||||
else { return JSON.parse(opsd_global_var); } //FixIn:6.1 //FixIn: 1.2.1
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Define global Secure Downloads Varibales based on Localization
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
var opsd_ajaxurl = opsd_global1.opsd_ajaxurl;
|
||||
var opsd_plugin_url = opsd_global1.opsd_plugin_url;
|
||||
var opsd_today = opsd_define_var( opsd_global1.opsd_today );
|
||||
var opsd_plugin_filename = opsd_global1.opsd_plugin_filename;
|
||||
var message_verif_requred = opsd_global1.message_verif_requred;
|
||||
var message_verif_requred_for_check_box = opsd_global1.message_verif_requred_for_check_box;
|
||||
var message_verif_requred_for_radio_box = opsd_global1.message_verif_requred_for_radio_box;
|
||||
var message_verif_emeil = opsd_global1.message_verif_emeil;
|
||||
var message_verif_same_emeil = opsd_global1.message_verif_same_emeil;
|
||||
var opsd_active_locale = opsd_global1.opsd_active_locale;
|
||||
var opsd_message_processing = opsd_global1.opsd_message_processing;
|
||||
var opsd_message_deleting = opsd_global1.opsd_message_deleting;
|
||||
var opsd_message_updating = opsd_global1.opsd_message_updating;
|
||||
var opsd_message_saving = opsd_global1.opsd_message_saving;
|
||||
2
wp-content/plugins/secure-downloads/languages/index.php
Normal file
2
wp-content/plugins/secure-downloads/languages/index.php
Normal file
@@ -0,0 +1,2 @@
|
||||
<?php
|
||||
// Silence is golden.
|
||||
7553
wp-content/plugins/secure-downloads/languages/secure-downloads.pot
Normal file
7553
wp-content/plugins/secure-downloads/languages/secure-downloads.pot
Normal file
File diff suppressed because it is too large
Load Diff
165
wp-content/plugins/secure-downloads/readme.txt
Normal file
165
wp-content/plugins/secure-downloads/readme.txt
Normal file
@@ -0,0 +1,165 @@
|
||||
=== Secure Downloads ===
|
||||
Contributors: wpdevelop, oplugins
|
||||
Donate link: https://oplugins.com/plugins/secure-downloads
|
||||
Tags: file downloads, downloads, links, send link, secure downloads, protected links, digital downloads, expiring link, monitor download, email link, eshop, ecommerce
|
||||
Requires at least: 4.0
|
||||
Requires PHP: 5.2.4
|
||||
Tested up to: 6.4
|
||||
Stable tag: 1.2.2
|
||||
License: GPLv2 or later
|
||||
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
||||
|
||||
Easy generate and distribute secure links for file downloads, that can expire, and track every download.
|
||||
|
||||
== Description ==
|
||||
|
||||
Secure Downloads plugin generate **secure download links** for protected files and can **send emails** to your clients for downloading.
|
||||
**Links can expire** after a predefined time and you can set **IP lock** for specific download. Download links does not show real location of files at your server.
|
||||
You can track every download of files by receiving email about file download with detailed info about download.
|
||||
|
||||
>[Plugin Homepage](https://oplugins.com/plugins/secure-downloads/ "Secure Downloads Homepage") | [Support](https://oplugins.com/plugins/secure-downloads/#support "Support")
|
||||
|
||||
= FEATURES =
|
||||
|
||||
* Securely distribute your files and track every download.
|
||||
* Upload your files via familiar WP interface.
|
||||
* Define Title, Description and **Version Number** at "Attachment details" for your protected files
|
||||
* Plugin upload files into secure, protected folder. Website visitors will not have direct access to such files.
|
||||
* Generate secure links to your protected files, which does not show real location of file.
|
||||
* Links can expire after specific time.
|
||||
* Links can be locked to specific IP or IP mask (network).
|
||||
* Configure email template with different parameters.
|
||||
* Send emails to your customers with secure links for download your protected files.
|
||||
* Monitor downloading of each files, by receiving email notification about file download with detailed info about download.
|
||||
* Fast configure your protected files via CSV form. Useful for saving or editing list of files in one form.
|
||||
* Easy reorder list of files via drag and drop interface.
|
||||
* Configure URLs for pages with warning, like "link expired notice".
|
||||
* Mobile friendly.
|
||||
|
||||
= SECURE DOWNLOADS IS GREAT FOR =
|
||||
|
||||
* Distribute you files after purchase
|
||||
* Delivery updates of your products to your customers
|
||||
|
||||
== Installation ==
|
||||
|
||||
= Automatic installation =
|
||||
|
||||
To do an automatic install, log in to your WordPress admin panel, navigate to the Plugins menu and click Add New.
|
||||
In the search field type "Secure Downloads" and click Search Plugins.
|
||||
Once you've found the plugin you can view details about it such as the the point release, rating and description.
|
||||
Now, you can install it by clicking "Install Now".
|
||||
|
||||
= Manual installation via WordPress admin panel =
|
||||
|
||||
* Download plugin zip file to your computer
|
||||
* In your WordPress admin panel, navigate to the Plugins menu and click Add New.
|
||||
* Click "Upload Plugin" button and hit "Choose File" button
|
||||
* When the popup appears select your downloaded zip file of plugin
|
||||
* Follow the on-screen instructions and wait as the upload completes.
|
||||
* When it's finished, activate the plugin via the prompt. A message will show confirming activation was successful.
|
||||
|
||||
= Manual installation via FTP =
|
||||
|
||||
* Download plugin zip file to your computer and unzip it
|
||||
* Using an FTP application, or your hosting control panel, upload the unzipped plugin folder to your WordPress installation's `wp-content/plugins/` directory.
|
||||
* In your WordPress admin panel, navigate to the Plugins menu and find your uploaded plugin
|
||||
* Click on Activate link under the plugin. A message will show confirming activation was successful.
|
||||
|
||||
That's it!
|
||||
|
||||
== Frequently Asked Questions ==
|
||||
|
||||
= Adding New Files =
|
||||
|
||||
* Open Secure Downloads > Files menu page in WordPress admin panel
|
||||
* Click on "Add New" button and upload your files. Please note, you must to upload new files via menu of plugin, for saving these files secure. Do not use previously uploaded files via standard media/pages/posts uploader.
|
||||
* Enter Title, Version Number and Description at "Attachment details" section.
|
||||
* Select one or multiple files, click insert button and Save changes.
|
||||
|
||||
= Configure Settings =
|
||||
|
||||
* Open Secure Downloads > Settings menu page in WordPress admin panel
|
||||
* Configure different settings, like secret key for hash generating, warning URLs, default options, etc...
|
||||
* At Secure Downloads > Settings > Emails menu page you can configure email templates that are sending to your customers and administrator
|
||||
|
||||
= Secure Links for File Downloads =
|
||||
|
||||
* Open Secure Downloads menu page in WordPress admin panel
|
||||
* Select specific file in selectbox
|
||||
* Optionally enter email, if you need to send protected link to your customer
|
||||
* Configure link expire time, optionally configure IP loc for file download, and activate option to send copy of email to administrator
|
||||
* Click on Generate or Send button for generation or sending email with secure link to your protected file
|
||||
* Check status of action
|
||||
|
||||
= Languages =
|
||||
|
||||
Plugin supports following languages:
|
||||
|
||||
- English
|
||||
|
||||
= Requirements =
|
||||
|
||||
- PHP 5.2.4 or newer,
|
||||
- MySQL version 5.0 or newer,
|
||||
- WordPress 4.0 or newer,
|
||||
- jQuery 1.7.1 or newer
|
||||
|
||||
== Screenshots ==
|
||||
|
||||
1. **Send** or simply generate **secure download links** to your protected files.
|
||||
2. **Sortable List of your files** - edit and sort (drag and drop) list of your protected files.
|
||||
3. **CSV List of your files** - upload files to protected folder, edit file title, description, and version number.
|
||||
4. **Settings** - configure different options.
|
||||
5. **Emails** - activate and configure email template for sending to your customers and download notification email.
|
||||
6. **Email Delivery** - confirmation of email sending.
|
||||
|
||||
== Changelog ==
|
||||
= 1.2.2 =
|
||||
* Added never expire products option (1.2.2.2)
|
||||
* Load some CSS files only at admin panel (1.2.2.1)
|
||||
|
||||
= 1.2.1 =
|
||||
* **New**. Icon for WordPress side menu. (2.0.1.2)
|
||||
|
||||
= 1.2 =
|
||||
* **Compatibility**. Support **WordPress 5.7** - update of admin panel styles. (1.2.1)
|
||||
* **Fix** Warning Deprecated: The each() function is deprecated. (1.2.2)
|
||||
* **Fix** Deprecated: Function get_magic_quotes_runtime() is deprecated(1.2.3)
|
||||
|
||||
= 1.1.5 =
|
||||
* **Compatibility**. Support **WordPress 5.5** - update of admin panel styles. (1.1.5.1)
|
||||
|
||||
= 1.1.4 =
|
||||
* **Compatibility**. Support **WordPress 5.3** - update of admin panel styles. (2.0.13.1)
|
||||
* **Under Hub** Added hook: " add_filter( 'opsd_define_ip_mask', 'my_opsd_define_ip_mask', 10, 1 ); function my_opsd_define_ip_mask ( $ip_mask ){ return $ip_mask } " for ability to override mask for IP (1.1.4.2)
|
||||
* **Fix** Checking of saving closing window state (nonce of window) in Ajax request only for current plugin (1.1.4.1)
|
||||
|
||||
= 1.1.3 =
|
||||
* **Fix** Notice: Array to string conversion in ..\secure-downloads\core\any\api-emails.php (1.1.3.1)
|
||||
* **Under Hub** Ability to use action for programmatically send secure email. (1.1.3.2) Example: do_action( 'opsd_send_secure_download_email_to_user', array( 'opsd_email_to' => 'email@server.com', 'send_copy_to_admin' => 'Off', 'opsd_product_selection' => 1, 'opsd_product_expire' => '+ 24 hours', 'continue_without_product' => false ) );
|
||||
|
||||
= 1.1.2 =
|
||||
* **Fix** conflict issue with Booking Calendar plugin (1.1.2.1)
|
||||
* **Fix** Fatal error: Uncaught ArgumentCountError: Too few arguments to function opsd_recheck_plugin_locale()… in PHP 7.2 (1.1.2.2)
|
||||
* **Fix** Notice: A non well formed numeric value encountered in ... in PHP 7.2 (1.1.2.3)
|
||||
* **Fix** Possible Fatal error: Cannot redeclare debuge_log(), if used with some other new plugins. (1.1.2.4)
|
||||
* **Fix** Error "404 Not found" "../assets/libs/chosen/chosen.css" (1.1.2.5)
|
||||
* **Fix** Notice: A non well formed numeric value encountered in ../opsd-class-notices.php in PHP 7.2 (1.1.2.6)
|
||||
|
||||
= 1.1.1 =
|
||||
* **Fix** issue of checkboxes and radio buttons height in new Firefox updates in admin panel, otherwise sometimes, there exist weird artefact (1.1.1.1)
|
||||
|
||||
= 1.1 =
|
||||
* Add additional warning text about ngnix servers. (1.1.1)
|
||||
* Load JavaScript variables only for admin panel (1.1.2)
|
||||
* Fix. Issue Fatal error: Uncaught Error: [] operator not supported for strings in ..\wp-content\plugins\secure-downloads\core\admin\api-settings.php:552 (1.1.3)
|
||||
* Fix. Issue ( ! ) Notice: Array to string conversion in ...\class-admin-settings-api.php:929 (1.1.4)
|
||||
* **Improvement** Updated all links from http to https of plugin website.
|
||||
* **Improvement** Auto select product based on 'product_name' parameter in URL (1.1.5)
|
||||
* **Improvement** Auto select product based on 'product_id' parameter in URL (1.1.5)
|
||||
* **Improvement** Auto insert email based on 'email' parameter in URL Example: www.server.com?page=opsd&email=someemail%40server.com&product_name=text_file (1.1.5)
|
||||
|
||||
== Upgrade Notice ==
|
||||
= 1.1 =
|
||||
Latest WordPress version support. Minor fixes and improvements.
|
||||
Reference in New Issue
Block a user