Version Description
- Fixed: Security issues with SVG files.
Download this release
Release Info
Developer | 10web |
Plugin | Photo Gallery by WD – Responsive Photo Gallery |
Version | 1.5.75 |
Comparing to | |
See all releases |
Code changes from version 1.5.74 to 1.5.75
- admin/views/AdminView.php +6 -0
- css/bwg_tables.css +17 -9
- css/free_trial_banner.css +219 -0
- css/images/free_trial_banner.png +0 -0
- css/images/tenweb_icon.svg +1 -0
- filemanager/UploadHandler.php +10 -3
- filemanager/controller.php +19 -19
- filemanager/view.php +9 -9
- framework/WDWLibrary.php +35 -2
- images/gallery_list_img_black.png +0 -0
- images/{gallery_list_img.png → gallery_list_img_green.png} +0 -0
- js/free_trial_banner.js +18 -0
- photo-gallery.php +30 -7
- readme.txt +4 -1
- wd/wd.php +1 -1
admin/views/AdminView.php
CHANGED
@@ -37,6 +37,12 @@ class AdminView_bwg {
|
|
37 |
$message_id = WDWLibrary::get('message', 0);
|
38 |
$message = WDWLibrary::get('msg', '');
|
39 |
echo WDWLibrary::message_id($message_id, $message);
|
|
|
|
|
|
|
|
|
|
|
|
|
40 |
?>
|
41 |
<form
|
42 |
<?php echo $action ? 'action="' . $action . '"' : ''; ?>
|
37 |
$message_id = WDWLibrary::get('message', 0);
|
38 |
$message = WDWLibrary::get('msg', '');
|
39 |
echo WDWLibrary::message_id($message_id, $message);
|
40 |
+
|
41 |
+
/* Free Trial Banner for 2 weeks */
|
42 |
+
$wd_bwg_free_trial_banner = get_option('wd_bwg_free_trial_banner');
|
43 |
+
if ( !BWG()->is_pro && !$wd_bwg_free_trial_banner) {
|
44 |
+
WDWLibrary::free_trial_banner_section();
|
45 |
+
}
|
46 |
?>
|
47 |
<form
|
48 |
<?php echo $action ? 'action="' . $action . '"' : ''; ?>
|
css/bwg_tables.css
CHANGED
@@ -2419,7 +2419,7 @@ input.search_in_options:focus {
|
|
2419 |
}
|
2420 |
form.bwg_form {
|
2421 |
display: block !important;
|
2422 |
-
margin: 40px 2px 0
|
2423 |
padding: 0 22px 7px 22px;
|
2424 |
background: white;
|
2425 |
}
|
@@ -2501,8 +2501,8 @@ form.bwg_form {
|
|
2501 |
}
|
2502 |
|
2503 |
.wd-list-view-header .wd-list-view-header-free-right {
|
2504 |
-
width:
|
2505 |
-
background-image: url(../images/
|
2506 |
background-position: top right;
|
2507 |
background-size: cover;
|
2508 |
border-bottom-left-radius: 7px;
|
@@ -2512,9 +2512,10 @@ form.bwg_form {
|
|
2512 |
font-family: "Open Sans";
|
2513 |
}
|
2514 |
|
2515 |
-
.wd-list-view-header .wd-list-view-header-free-right .upgrade-header,
|
2516 |
-
|
2517 |
-
|
|
|
2518 |
font-weight: 800;
|
2519 |
line-height: 20px;
|
2520 |
letter-spacing: 0.12px;
|
@@ -2522,11 +2523,11 @@ form.bwg_form {
|
|
2522 |
}
|
2523 |
|
2524 |
.wd-list-view-header .wd-list-view-header-free-right .upgrade-text {
|
2525 |
-
margin:
|
2526 |
}
|
2527 |
|
2528 |
.wd-list-view-header .wd-list-view-header-free-right .upgrade-button {
|
2529 |
-
padding:
|
2530 |
font-size: 14px;
|
2531 |
letter-spacing: 0.12px;
|
2532 |
font-weight: 800;
|
@@ -2537,7 +2538,7 @@ form.bwg_form {
|
|
2537 |
border-radius: 14px;
|
2538 |
text-decoration: none;
|
2539 |
display: inline-block;
|
2540 |
-
margin: 0px 0 12px
|
2541 |
}
|
2542 |
.wd-list-view-header .wd-list-view-header-free-right .upgrade-button:hover {
|
2543 |
background-color: #FFFFFF57;
|
@@ -3074,6 +3075,11 @@ bwg-gallery-ul {
|
|
3074 |
|
3075 |
}
|
3076 |
/* style for 1280 */
|
|
|
|
|
|
|
|
|
|
|
3077 |
@media screen and (max-width: 1365px) {
|
3078 |
#bwg_tab_gallery_content > .bwg-section > .wd-box-content,
|
3079 |
#bwg_tab_gallery_group_content > .bwg-section > .wd-box-content{
|
@@ -3592,9 +3598,11 @@ bwg-gallery-ul {
|
|
3592 |
}
|
3593 |
.wd-list-view-header .wd-list-view-header-left {
|
3594 |
display: flex;
|
|
|
3595 |
}
|
3596 |
.wd-list-view-header .wd-list-view-header-left .wd-page-title.wd-header {
|
3597 |
display: inline-block;
|
|
|
3598 |
}
|
3599 |
.wd-list-view-header .wd-list-view-header-left .wd-page-title.wd-header h1.wd-heading-inline {
|
3600 |
font-size: 18px;
|
2419 |
}
|
2420 |
form.bwg_form {
|
2421 |
display: block !important;
|
2422 |
+
margin: 40px 2px 0 0px;
|
2423 |
padding: 0 22px 7px 22px;
|
2424 |
background: white;
|
2425 |
}
|
2501 |
}
|
2502 |
|
2503 |
.wd-list-view-header .wd-list-view-header-free-right {
|
2504 |
+
width: 412px;
|
2505 |
+
background-image: url(../images/gallery_list_img_black.png);
|
2506 |
background-position: top right;
|
2507 |
background-size: cover;
|
2508 |
border-bottom-left-radius: 7px;
|
2512 |
font-family: "Open Sans";
|
2513 |
}
|
2514 |
|
2515 |
+
.wd-list-view-header .wd-list-view-header-free-right .upgrade-header,
|
2516 |
+
.wd-list-view-header .wd-list-view-header-free-right .upgrade-text {
|
2517 |
+
margin: 12px 0 0 16px;
|
2518 |
+
font-size: 14px;
|
2519 |
font-weight: 800;
|
2520 |
line-height: 20px;
|
2521 |
letter-spacing: 0.12px;
|
2523 |
}
|
2524 |
|
2525 |
.wd-list-view-header .wd-list-view-header-free-right .upgrade-text {
|
2526 |
+
margin: 0px 0 12px 16px;
|
2527 |
}
|
2528 |
|
2529 |
.wd-list-view-header .wd-list-view-header-free-right .upgrade-button {
|
2530 |
+
padding: 4px 20px;
|
2531 |
font-size: 14px;
|
2532 |
letter-spacing: 0.12px;
|
2533 |
font-weight: 800;
|
2538 |
border-radius: 14px;
|
2539 |
text-decoration: none;
|
2540 |
display: inline-block;
|
2541 |
+
margin: 0px 0 12px 16px;
|
2542 |
}
|
2543 |
.wd-list-view-header .wd-list-view-header-free-right .upgrade-button:hover {
|
2544 |
background-color: #FFFFFF57;
|
3075 |
|
3076 |
}
|
3077 |
/* style for 1280 */
|
3078 |
+
@media screen and (max-width: 1280px) {
|
3079 |
+
.wd-list-view-header .wd-list-view-header-free-right {
|
3080 |
+
margin-left: 10px;
|
3081 |
+
}
|
3082 |
+
}
|
3083 |
@media screen and (max-width: 1365px) {
|
3084 |
#bwg_tab_gallery_content > .bwg-section > .wd-box-content,
|
3085 |
#bwg_tab_gallery_group_content > .bwg-section > .wd-box-content{
|
3598 |
}
|
3599 |
.wd-list-view-header .wd-list-view-header-left {
|
3600 |
display: flex;
|
3601 |
+
flex-wrap: wrap;
|
3602 |
}
|
3603 |
.wd-list-view-header .wd-list-view-header-left .wd-page-title.wd-header {
|
3604 |
display: inline-block;
|
3605 |
+
margin-bottom: 15px;
|
3606 |
}
|
3607 |
.wd-list-view-header .wd-list-view-header-left .wd-page-title.wd-header h1.wd-heading-inline {
|
3608 |
font-size: 18px;
|
css/free_trial_banner.css
ADDED
@@ -0,0 +1,219 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
.tenweb_free_trial_banner {
|
2 |
+
background: transparent linear-gradient(99deg, #008A62 0%, #23B536 100%) 0% 0% no-repeat padding-box;
|
3 |
+
margin: 40px 0px -20px 0px;
|
4 |
+
position: relative;
|
5 |
+
width:100%;
|
6 |
+
}
|
7 |
+
|
8 |
+
#tenweb_free_trial_banner_close:before {
|
9 |
+
content: "\2715";
|
10 |
+
position: absolute;
|
11 |
+
top: 12px; right: 15px;
|
12 |
+
cursor: pointer;
|
13 |
+
font-size: 13px;
|
14 |
+
color: #fff;
|
15 |
+
}
|
16 |
+
#tenweb_free_trial_banner_close:hover:before {
|
17 |
+
opacity: 70%;
|
18 |
+
}
|
19 |
+
|
20 |
+
.tenweb_free_trial_banner_container {
|
21 |
+
width: 60%;
|
22 |
+
display: flex;
|
23 |
+
flex-direction: row;
|
24 |
+
justify-content: space-between;
|
25 |
+
align-items: center;
|
26 |
+
margin:10px auto;
|
27 |
+
}
|
28 |
+
|
29 |
+
.tenweb_free_trial_banner_img {
|
30 |
+
flex-basis: 19%;
|
31 |
+
height: 117px;
|
32 |
+
background-image: url(images/free_trial_banner.png);
|
33 |
+
background-repeat: no-repeat;
|
34 |
+
background-position: center;
|
35 |
+
background-size: contain;
|
36 |
+
}
|
37 |
+
|
38 |
+
.tenweb_free_trial_banner_info {
|
39 |
+
flex-basis: 62%;
|
40 |
+
}
|
41 |
+
|
42 |
+
.tenweb_free_trial_banner_info .tenweb_icon {
|
43 |
+
background-image: url(images/tenweb_icon.svg);
|
44 |
+
background-repeat: no-repeat;
|
45 |
+
background-position: center;
|
46 |
+
background-size: contain;
|
47 |
+
margin: 0 0 8px;
|
48 |
+
width: 80px;
|
49 |
+
height: 22px;
|
50 |
+
}
|
51 |
+
|
52 |
+
.tenweb_free_trial_banner_info p {
|
53 |
+
letter-spacing: 0.13px;
|
54 |
+
line-height: normal;
|
55 |
+
font-size: 16px;
|
56 |
+
font-weight: 700;
|
57 |
+
margin:0 0 10px 0;
|
58 |
+
color: #fff;
|
59 |
+
}
|
60 |
+
|
61 |
+
.tenweb_free_trial_banner_info > div span {
|
62 |
+
font-size: 14px;
|
63 |
+
letter-spacing: 0px;
|
64 |
+
line-height: normal;
|
65 |
+
font-weight: 500;
|
66 |
+
margin-right: 10px;
|
67 |
+
color: #fff;
|
68 |
+
}
|
69 |
+
|
70 |
+
.tenweb_free_trial_banner_info > div span:before {
|
71 |
+
content: "\2022";
|
72 |
+
width: 5px;
|
73 |
+
height: 5px;
|
74 |
+
color:#DB9D2D;
|
75 |
+
margin-right: 5px;
|
76 |
+
}
|
77 |
+
|
78 |
+
.tenweb_free_trial_banner_button {
|
79 |
+
flex-basis: 23%;
|
80 |
+
}
|
81 |
+
|
82 |
+
.tenweb_free_trial_banner_button .ftb-button {
|
83 |
+
color: #fff;
|
84 |
+
border-radius: 25px;
|
85 |
+
font-size: 14px;
|
86 |
+
letter-spacing: 0.12px;
|
87 |
+
font-weight: 500;
|
88 |
+
line-height: 19px;
|
89 |
+
padding: 11px 45px;
|
90 |
+
text-decoration: none;
|
91 |
+
display: inline-block;
|
92 |
+
text-transform: uppercase;
|
93 |
+
border: 1px solid #F8C332;
|
94 |
+
background-color: #F8C332;
|
95 |
+
}
|
96 |
+
|
97 |
+
.tenweb_free_trial_banner_button .ftb-button:hover,
|
98 |
+
.tenweb_free_trial_banner_button .ftb-button:focus {
|
99 |
+
background-color: #f9bb11;
|
100 |
+
border: 1px solid #f9bb11;
|
101 |
+
box-shadow: none;
|
102 |
+
outline:none;
|
103 |
+
}
|
104 |
+
|
105 |
+
@media screen and (max-width: 1640px) {
|
106 |
+
.tenweb_free_trial_banner_container {
|
107 |
+
width: 80%;
|
108 |
+
}
|
109 |
+
}
|
110 |
+
@media screen and (max-width: 1380px) {
|
111 |
+
.tenweb_free_trial_banner_container {
|
112 |
+
width: 90%;
|
113 |
+
}
|
114 |
+
}
|
115 |
+
@media screen and (max-width: 1280px) {
|
116 |
+
.tenweb_free_trial_banner {
|
117 |
+
max-width: 1062px;
|
118 |
+
margin: 40px 0px -20px 0px;
|
119 |
+
}
|
120 |
+
.tenweb_free_trial_banner_container {
|
121 |
+
width: 99%;
|
122 |
+
}
|
123 |
+
.tenweb_free_trial_banner_img {
|
124 |
+
flex-basis: 20%;
|
125 |
+
}
|
126 |
+
.tenweb_free_trial_banner_info {
|
127 |
+
flex-basis: 65%;
|
128 |
+
}
|
129 |
+
.tenweb_free_trial_banner_button {
|
130 |
+
flex-basis: 23%;
|
131 |
+
}
|
132 |
+
}
|
133 |
+
@media screen and (max-width: 1170px) {
|
134 |
+
.tenweb_free_trial_banner_img {
|
135 |
+
flex-basis: 19%;
|
136 |
+
}
|
137 |
+
.tenweb_free_trial_banner_info {
|
138 |
+
flex-basis: 72%;
|
139 |
+
}
|
140 |
+
.tenweb_free_trial_banner_info p {
|
141 |
+
font-size: 13px;
|
142 |
+
}
|
143 |
+
.tenweb_free_trial_banner_info > div span {
|
144 |
+
font-size: 12px;
|
145 |
+
}
|
146 |
+
.tenweb_free_trial_banner_button .ftb-button {
|
147 |
+
padding: 8px 30px;
|
148 |
+
}
|
149 |
+
}
|
150 |
+
|
151 |
+
@media screen and (max-width: 1023px) {
|
152 |
+
.tenweb_free_trial_banner_container {
|
153 |
+
padding: 18px 22px;
|
154 |
+
}
|
155 |
+
.tenweb_free_trial_banner_img {
|
156 |
+
display: none;
|
157 |
+
}
|
158 |
+
.tenweb_free_trial_banner_info {
|
159 |
+
flex-basis: 75%;
|
160 |
+
}
|
161 |
+
.tenweb_free_trial_banner_info p {
|
162 |
+
letter-spacing: 0.11px;
|
163 |
+
font-size: 13px;
|
164 |
+
}
|
165 |
+
.tenweb_free_trial_banner_info > div span {
|
166 |
+
font-size: 12px;
|
167 |
+
}
|
168 |
+
.tenweb_free_trial_banner_button {
|
169 |
+
flex-basis: 27%;
|
170 |
+
}
|
171 |
+
}
|
172 |
+
|
173 |
+
@media screen and (max-width: 730px) {
|
174 |
+
.tenweb_free_trial_banner_container {
|
175 |
+
flex-direction: column;
|
176 |
+
text-align: center;
|
177 |
+
padding: 0 15px;
|
178 |
+
width: 90%;
|
179 |
+
}
|
180 |
+
.tenweb_free_trial_banner_container > div {
|
181 |
+
flex-basis: 100%;
|
182 |
+
}
|
183 |
+
.tenweb_free_trial_banner_info .tenweb_icon {
|
184 |
+
margin: 0 auto 5px;
|
185 |
+
}
|
186 |
+
.tenweb_free_trial_banner_container>div.tenweb_free_trial_banner_info {
|
187 |
+
margin: 15px auto;
|
188 |
+
}
|
189 |
+
.tenweb_free_trial_banner_info p {
|
190 |
+
font-size: 14px;
|
191 |
+
}
|
192 |
+
.tenweb_free_trial_banner_info .tenweb_info_sec {
|
193 |
+
display:flex;
|
194 |
+
flex-wrap: wrap;
|
195 |
+
justify-content: center;
|
196 |
+
}
|
197 |
+
.tenweb_free_trial_banner_info .tenweb_info_sec span:nth-child(1) {
|
198 |
+
order: 1;
|
199 |
+
}
|
200 |
+
.tenweb_free_trial_banner_info .tenweb_info_sec span:nth-child(2) {
|
201 |
+
order: 4;
|
202 |
+
}
|
203 |
+
.tenweb_free_trial_banner_info .tenweb_info_sec span:nth-child(3) {
|
204 |
+
order: 3;
|
205 |
+
}
|
206 |
+
.tenweb_free_trial_banner_info .tenweb_info_sec span:nth-child(4) {
|
207 |
+
order: 2;
|
208 |
+
}
|
209 |
+
.tenweb_free_trial_banner_info > div span {
|
210 |
+
margin-right: 7px;
|
211 |
+
margin-bottom: 5px;
|
212 |
+
}
|
213 |
+
.tenweb_free_trial_banner_info > div span:before {
|
214 |
+
margin-right: 4px;
|
215 |
+
}
|
216 |
+
.tenweb_free_trial_banner_container>div.tenweb_free_trial_banner_button {
|
217 |
+
margin: 0 auto 15px;
|
218 |
+
}
|
219 |
+
}
|
css/images/free_trial_banner.png
ADDED
Binary file
|
css/images/tenweb_icon.svg
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
<svg xmlns="http://www.w3.org/2000/svg" width="80.46" height="22" viewBox="0 0 80.46 22"><defs><style>.a{fill:#fff;}</style></defs><g transform="translate(-259.999 -328)"><path class="a" d="M10.892,21.861.142,11.111a.494.494,0,0,1,0-.693,2.281,2.281,0,0,1,3.207,0L10.83,17.9a.49.49,0,0,0,.689,0l4.213-4.213a2.281,2.281,0,0,1,3.207,0,.519.519,0,0,1,.062.755l-7.419,7.419a.49.49,0,0,1-.343.139A.5.5,0,0,1,10.892,21.861Zm53.413-5.376A4.287,4.287,0,0,1,62.8,15.48a4.035,4.035,0,0,1-.879-1.509,6.464,6.464,0,0,1-.252-1.887,5.147,5.147,0,0,1,.376-2.074A5.2,5.2,0,0,1,62.986,8.5a3.952,3.952,0,0,1,1.384-.878,4.634,4.634,0,0,1,1.571-.317,3.891,3.891,0,0,1,3.017,1.2,4.775,4.775,0,0,1,1.13,3.458v.5a1.413,1.413,0,0,1-.062.5H64.243A1.781,1.781,0,0,0,65,14.223a2.928,2.928,0,0,0,1.76.438,10.481,10.481,0,0,0,1.384-.124,4.934,4.934,0,0,0,1.13-.314l.314,2.074a3.075,3.075,0,0,1-.565.189l-.754.186a3.578,3.578,0,0,1-.878.127,4.8,4.8,0,0,1-.944.063A5.652,5.652,0,0,1,64.305,16.486Zm.882-6.979a3.7,3.7,0,0,0-.5.376,1.629,1.629,0,0,0-.314.568c-.065.252-.127.44-.19.627h3.458a2.28,2.28,0,0,0-.127-.627,2.587,2.587,0,0,0-.314-.568,1,1,0,0,0-.5-.376,1.385,1.385,0,0,0-.754-.124A2.748,2.748,0,0,0,65.187,9.507ZM74.8,16.672c-.313-.062-.692-.062-1.006-.124l-.944-.19c-.314-.062-.565-.124-.816-.186V3.6l2.577-.44V7.623a4.833,4.833,0,0,1,.882-.317A4.945,4.945,0,0,1,76.5,7.183a4.783,4.783,0,0,1,1.7.313,4.623,4.623,0,0,1,1.254.944,4.8,4.8,0,0,1,.758,1.508,7.6,7.6,0,0,1,.248,2.074,6.308,6.308,0,0,1-.314,1.949,3.865,3.865,0,0,1-.941,1.509,3.624,3.624,0,0,1-1.447.941,6.435,6.435,0,0,1-2.012.316A4.589,4.589,0,0,1,74.8,16.672Zm.5-7.037a1.893,1.893,0,0,0-.627.248v4.654c.124,0,.313.062.5.062h.63a1.947,1.947,0,0,0,1.571-.692,3.873,3.873,0,0,0,.5-1.947c0-1.635-.627-2.453-1.822-2.453A3.08,3.08,0,0,0,75.307,9.635ZM37.214,15.1a7.841,7.841,0,0,1-1.133-4.587A10.819,10.819,0,0,1,36.4,7.872a6.117,6.117,0,0,1,.879-1.947,3.606,3.606,0,0,1,1.384-1.2,4.04,4.04,0,0,1,1.76-.441,3.628,3.628,0,0,1,3.141,1.575,8.217,8.217,0,0,1,1.068,4.65A7.842,7.842,0,0,1,43.5,15.1a3.924,3.924,0,0,1-6.286,0Zm2.325-8.3a2.035,2.035,0,0,0-.5.82,3.748,3.748,0,0,0-.251,1.258,13.234,13.234,0,0,0-.062,1.633,13.286,13.286,0,0,0,.062,1.633,5.6,5.6,0,0,0,.251,1.26,2.038,2.038,0,0,0,.5.816,1.2,1.2,0,0,0,.816.314,1.334,1.334,0,0,0,.819-.314,2.072,2.072,0,0,0,.5-.816,6.666,6.666,0,0,0,.252-1.26,12.8,12.8,0,0,0,.062-1.633,13.829,13.829,0,0,0-.062-1.633,6.574,6.574,0,0,0-.252-1.258,2.069,2.069,0,0,0-.5-.82,1.208,1.208,0,0,0-.819-.313A1.336,1.336,0,0,0,39.539,6.8ZM55.5,16.548c-.376-1.068-.816-2.264-1.192-3.458s-.754-2.387-1.133-3.645c-.376,1.2-.754,2.387-1.068,3.645s-.754,2.328-1.13,3.458H48.529q-.945-2.734-1.7-5.846c-.5-2.074-1.006-4.086-1.381-6.035h2.89c.124.692.251,1.381.378,2.074.124.755.252,1.447.438,2.2.127.755.316,1.444.441,2.135a13.7,13.7,0,0,0,.5,1.888c.19-.565.379-1.133.627-1.76.189-.63.379-1.258.568-1.888s.376-1.257.5-1.822.314-1.13.438-1.571h2.328c.124.441.314,1.005.438,1.571.189.565.316,1.194.5,1.822s.379,1.258.568,1.888.376,1.2.565,1.76c.124-.565.314-1.2.441-1.888s.314-1.38.441-2.135.248-1.447.376-2.2.252-1.447.376-2.074h2.766c-.376,2.012-.879,4.023-1.381,6.035-.5,2.073-1.068,3.958-1.7,5.846Zm-25.458,0V7.937a6.289,6.289,0,0,1-1.13.627,9.8,9.8,0,0,1-1.257.5L26.9,7.119c.313-.127.692-.316,1.006-.44.376-.19.692-.379,1.068-.566a9.356,9.356,0,0,0,1.006-.692,9.657,9.657,0,0,0,.819-.755h1.822V16.548ZM10.327,15.057a1.328,1.328,0,0,1,0-1.95l1.7-1.7a.488.488,0,0,0-.062-.631L10.138,8.957a1.447,1.447,0,0,1,0-1.949l.062-.063a1.333,1.333,0,0,1,1.949,0l3.772,3.771a.5.5,0,0,1,0,.693l-3.648,3.647a1.33,1.33,0,0,1-1.946,0ZM7.12,11.913a1.449,1.449,0,0,1,0-1.951,1.331,1.331,0,0,1,1.946,0l.63.631a.493.493,0,0,1,0,.692l-.63.628a1.326,1.326,0,0,1-1.946,0Zm11.818-.27L11.395,4.1a.492.492,0,0,0-.692,0L6.49,8.313a2.272,2.272,0,0,1-3.2,0,.791.791,0,0,1,.124-.752L10.83.142a.488.488,0,0,1,.689,0L22.207,10.892a.5.5,0,0,1,0,.693l-.065.058a2.266,2.266,0,0,1-3.2,0Z" transform="translate(259.999 328)"/></g></svg>
|
filemanager/UploadHandler.php
CHANGED
@@ -21,7 +21,7 @@ else {
|
|
21 |
require_once(BWG()->plugin_dir . '/filemanager/controller.php');
|
22 |
$controller = new FilemanagerController();
|
23 |
$upload_handler = new bwg_UploadHandler(array(
|
24 |
-
'upload_dir' => $controller->uploads_dir . (isset($_GET['dir']) ? str_replace('\\', '',
|
25 |
'upload_url' => $controller->uploads_url,
|
26 |
'accept_file_types' => '/\.(gif|jpe?g|png|svg|aac|m4a|f4a|oga|ogg|mp3|zip)$/i',
|
27 |
));
|
@@ -765,6 +765,11 @@ class bwg_UploadHandler {
|
|
765 |
}
|
766 |
else {
|
767 |
move_uploaded_file($uploaded_file, $file_path);
|
|
|
|
|
|
|
|
|
|
|
768 |
}
|
769 |
}
|
770 |
else {
|
@@ -773,7 +778,9 @@ class bwg_UploadHandler {
|
|
773 |
}
|
774 |
|
775 |
$file_size = $this->get_file_size($file_path, $append_file);
|
776 |
-
|
|
|
|
|
777 |
if ( $this->options['max_width'] && $this->options['max_height'] ) {
|
778 |
// Upload.
|
779 |
$this->create_scaled_image($file->name, 'main', $this->options);
|
@@ -963,7 +970,7 @@ class bwg_UploadHandler {
|
|
963 |
|
964 |
public function post( $print_response = TRUE ) {
|
965 |
global $wpdb;
|
966 |
-
$path = isset($_REQUEST['dir']) ? str_replace('\\', '',
|
967 |
if ( isset($_REQUEST['import']) && WDWLibrary::get('import',0,'intval','REQUEST') == 1 ) {
|
968 |
$files = array();
|
969 |
$file_names = json_decode(isset($_REQUEST['file_namesML']) ? stripslashes(WDWLibrary::get('file_namesML','','sanitize_text_field','REQUEST')) : array());
|
21 |
require_once(BWG()->plugin_dir . '/filemanager/controller.php');
|
22 |
$controller = new FilemanagerController();
|
23 |
$upload_handler = new bwg_UploadHandler(array(
|
24 |
+
'upload_dir' => $controller->uploads_dir . (isset($_GET['dir']) ? str_replace(array('\\', '../'), '', WDWLibrary::get('dir', '', 'sanitize_text_field', 'GET')) : '/'),
|
25 |
'upload_url' => $controller->uploads_url,
|
26 |
'accept_file_types' => '/\.(gif|jpe?g|png|svg|aac|m4a|f4a|oga|ogg|mp3|zip)$/i',
|
27 |
));
|
765 |
}
|
766 |
else {
|
767 |
move_uploaded_file($uploaded_file, $file_path);
|
768 |
+
if ( strpos($type, 'svg') ) {
|
769 |
+
// Remove scripts from SVG files for security reasons.
|
770 |
+
$file_content = file_get_contents($file_path);
|
771 |
+
file_put_contents($file_path, preg_replace('#<script(.*?)>(.*?)</script>#is', '', $file_content));
|
772 |
+
}
|
773 |
}
|
774 |
}
|
775 |
else {
|
778 |
}
|
779 |
|
780 |
$file_size = $this->get_file_size($file_path, $append_file);
|
781 |
+
|
782 |
+
if (strpos($type, 'svg') || $file_size === $file->size ) {
|
783 |
+
// Do not compare size if the file is svg (for the reason when script is deleted from file).
|
784 |
if ( $this->options['max_width'] && $this->options['max_height'] ) {
|
785 |
// Upload.
|
786 |
$this->create_scaled_image($file->name, 'main', $this->options);
|
970 |
|
971 |
public function post( $print_response = TRUE ) {
|
972 |
global $wpdb;
|
973 |
+
$path = isset($_REQUEST['dir']) ? str_replace(array('\\', '../'), '', WDWLibrary::get('dir', '', 'sanitize_text_field', 'REQUEST')) . '/' : '/';
|
974 |
if ( isset($_REQUEST['import']) && WDWLibrary::get('import',0,'intval','REQUEST') == 1 ) {
|
975 |
$files = array();
|
976 |
$file_names = json_decode(isset($_REQUEST['file_namesML']) ? stripslashes(WDWLibrary::get('file_namesML','','sanitize_text_field','REQUEST')) : array());
|
filemanager/controller.php
CHANGED
@@ -41,8 +41,8 @@ class FilemanagerController {
|
|
41 |
}
|
42 |
|
43 |
public function display() {
|
44 |
-
|
45 |
-
|
46 |
$search = $this->model->get_from_session('search', '');
|
47 |
$page_num = $this->model->get_from_session('paged', 0);
|
48 |
$callback = $this->model->get_from_session('callback', '');
|
@@ -98,14 +98,14 @@ class FilemanagerController {
|
|
98 |
}
|
99 |
|
100 |
function pagination() {
|
101 |
-
|
102 |
-
|
103 |
-
|
104 |
-
|
105 |
-
|
106 |
-
|
107 |
-
|
108 |
-
|
109 |
array(
|
110 |
'dir' => $dir,
|
111 |
'order' => $order,
|
@@ -154,7 +154,7 @@ class FilemanagerController {
|
|
154 |
public function make_dir() {
|
155 |
|
156 |
global $wpdb;
|
157 |
-
$input_dir = (isset($_REQUEST['dir']) ? str_replace('\\', '', WDWLibrary::get('dir','','sanitize_text_field','REQUEST')) : '');
|
158 |
$input_dir = htmlspecialchars_decode($input_dir, ENT_COMPAT | ENT_QUOTES);
|
159 |
$input_dir = $this->esc_dir($input_dir);
|
160 |
|
@@ -220,9 +220,9 @@ class FilemanagerController {
|
|
220 |
}
|
221 |
|
222 |
public function parsing_items() {
|
223 |
-
$dir = $this->model->get_from_session('dir', '');
|
224 |
$dir = ($dir == '' || $dir == '/') ? '/' : $dir .'/';
|
225 |
-
$input_dir = (isset($_REQUEST['dir']) ? str_replace('\\', '', WDWLibrary::get('dir','','sanitize_text_field','REQUEST')) : '');
|
226 |
$valid_types = explode(',', 'jpg,jpeg,png,gif,svg');
|
227 |
$parsing = $this->model->files_parsing_db(array(
|
228 |
'refresh' => true,
|
@@ -249,8 +249,8 @@ class FilemanagerController {
|
|
249 |
}
|
250 |
|
251 |
public function rename_item() {
|
252 |
-
|
253 |
-
$input_dir = (isset($_REQUEST['dir']) ? str_replace('\\', '', WDWLibrary::get('dir','','sanitize_text_field','REQUEST')) : '');
|
254 |
$input_dir = htmlspecialchars_decode($input_dir, ENT_COMPAT | ENT_QUOTES);
|
255 |
$input_dir = $this->esc_dir($input_dir);
|
256 |
|
@@ -397,7 +397,7 @@ class FilemanagerController {
|
|
397 |
|
398 |
public function remove_items() {
|
399 |
global $wpdb;
|
400 |
-
$input_dir = (isset($_REQUEST['dir']) ? str_replace('\\', '',
|
401 |
$input_dir = htmlspecialchars_decode($input_dir, ENT_COMPAT | ENT_QUOTES);
|
402 |
$input_dir = $this->esc_dir($input_dir);
|
403 |
|
@@ -458,7 +458,7 @@ class FilemanagerController {
|
|
458 |
|
459 |
public function paste_items() {
|
460 |
global $wpdb;
|
461 |
-
$input_dir = (isset($_REQUEST['dir']) ? str_replace('\\', '',
|
462 |
$input_dir = htmlspecialchars_decode($input_dir, ENT_COMPAT | ENT_QUOTES);
|
463 |
$input_dir = $this->esc_dir($input_dir);
|
464 |
|
@@ -691,8 +691,8 @@ class FilemanagerController {
|
|
691 |
'importer_img_width' => WDWLibrary::get('importer_img_width','','intval','REQUEST'),
|
692 |
'importer_img_height' => WDWLibrary::get('importer_img_height','','intval','REQUEST'),
|
693 |
'import' => 'true',
|
694 |
-
'redir' => WDWLibrary::get('dir','','sanitize_text_field','REQUEST'),
|
695 |
-
'dir' => WDWLibrary::get('dir','','sanitize_text_field','REQUEST') . '/',
|
696 |
);
|
697 |
|
698 |
$query_url = wp_nonce_url( admin_url('admin-ajax.php'), 'bwg_UploadHandler', 'bwg_nonce' );
|
41 |
}
|
42 |
|
43 |
public function display() {
|
44 |
+
$params = array();
|
45 |
+
$dir = str_replace(array('\\', '../'), '', $this->model->get_from_session('dir', ''));
|
46 |
$search = $this->model->get_from_session('search', '');
|
47 |
$page_num = $this->model->get_from_session('paged', 0);
|
48 |
$callback = $this->model->get_from_session('callback', '');
|
98 |
}
|
99 |
|
100 |
function pagination() {
|
101 |
+
$dir = str_replace(array('\\', '../'), '', $this->model->get_from_session('dir', ''));
|
102 |
+
$dir = ($dir == '') ? '/' : $dir .'/';
|
103 |
+
$order = $this->model->get_from_session('order', 'desc');
|
104 |
+
$orderby = $this->model->get_from_session('orderby', 'date_modified');
|
105 |
+
$search = $this->model->get_from_session('search', '');
|
106 |
+
$paged = $this->model->get_from_session('paged', 0);
|
107 |
+
$page_per = $this->page_per;
|
108 |
+
$data = $this->model->get_file_lists(
|
109 |
array(
|
110 |
'dir' => $dir,
|
111 |
'order' => $order,
|
154 |
public function make_dir() {
|
155 |
|
156 |
global $wpdb;
|
157 |
+
$input_dir = (isset($_REQUEST['dir']) ? str_replace(array('\\', '../'), '', WDWLibrary::get('dir','','sanitize_text_field','REQUEST')) : '');
|
158 |
$input_dir = htmlspecialchars_decode($input_dir, ENT_COMPAT | ENT_QUOTES);
|
159 |
$input_dir = $this->esc_dir($input_dir);
|
160 |
|
220 |
}
|
221 |
|
222 |
public function parsing_items() {
|
223 |
+
$dir = str_replace(array('\\', '../'), '', $this->model->get_from_session('dir', ''));
|
224 |
$dir = ($dir == '' || $dir == '/') ? '/' : $dir .'/';
|
225 |
+
$input_dir = (isset($_REQUEST['dir']) ? str_replace(array('\\', '../'), '', WDWLibrary::get('dir', '', 'sanitize_text_field', 'REQUEST')) : '');
|
226 |
$valid_types = explode(',', 'jpg,jpeg,png,gif,svg');
|
227 |
$parsing = $this->model->files_parsing_db(array(
|
228 |
'refresh' => true,
|
249 |
}
|
250 |
|
251 |
public function rename_item() {
|
252 |
+
global $wpdb;
|
253 |
+
$input_dir = (isset($_REQUEST['dir']) ? str_replace(array('\\', '../'), '', WDWLibrary::get('dir', '', 'sanitize_text_field', 'REQUEST')) : '');
|
254 |
$input_dir = htmlspecialchars_decode($input_dir, ENT_COMPAT | ENT_QUOTES);
|
255 |
$input_dir = $this->esc_dir($input_dir);
|
256 |
|
397 |
|
398 |
public function remove_items() {
|
399 |
global $wpdb;
|
400 |
+
$input_dir = (isset($_REQUEST['dir']) ? str_replace(array('\\', '../'), '', WDWLibrary::get('dir', '', 'sanitize_text_field', 'REQUEST')) : '');
|
401 |
$input_dir = htmlspecialchars_decode($input_dir, ENT_COMPAT | ENT_QUOTES);
|
402 |
$input_dir = $this->esc_dir($input_dir);
|
403 |
|
458 |
|
459 |
public function paste_items() {
|
460 |
global $wpdb;
|
461 |
+
$input_dir = (isset($_REQUEST['dir']) ? str_replace(array('\\', '../'), '', WDWLibrary::get('dir', '', 'sanitize_text_field', 'REQUEST')) : '');
|
462 |
$input_dir = htmlspecialchars_decode($input_dir, ENT_COMPAT | ENT_QUOTES);
|
463 |
$input_dir = $this->esc_dir($input_dir);
|
464 |
|
691 |
'importer_img_width' => WDWLibrary::get('importer_img_width','','intval','REQUEST'),
|
692 |
'importer_img_height' => WDWLibrary::get('importer_img_height','','intval','REQUEST'),
|
693 |
'import' => 'true',
|
694 |
+
'redir' => str_replace(array('\\', '../'), '', WDWLibrary::get('dir', '', 'sanitize_text_field', 'REQUEST')),
|
695 |
+
'dir' => str_replace(array('\\', '../'), '', WDWLibrary::get('dir', '', 'sanitize_text_field', 'REQUEST')) . '/',
|
696 |
);
|
697 |
|
698 |
$query_url = wp_nonce_url( admin_url('admin-ajax.php'), 'bwg_UploadHandler', 'bwg_nonce' );
|
filemanager/view.php
CHANGED
@@ -62,11 +62,11 @@ class FilemanagerView {
|
|
62 |
<script src="<?php echo BWG()->plugin_url; ?>/filemanager/js/jq_uploader/jquery.iframe-transport.js?v=10.0.0"></script>
|
63 |
<script src="<?php echo BWG()->plugin_url; ?>/filemanager/js/jq_uploader/jquery.fileupload.js?v=10.0.0"></script>
|
64 |
<script>
|
65 |
-
|
66 |
var demo_message = "<?php echo addslashes(__('This option is disabled in demo.', BWG()->prefix)); ?>";
|
67 |
var ajaxurl = "<?php echo wp_nonce_url( admin_url('admin-ajax.php'), 'addImages', 'bwg_nonce' ); ?>";
|
68 |
var ajax_pagination_url = "<?php echo $ajax_pagination_url; ?>";
|
69 |
-
|
70 |
var errorLoadingFile = "<?php echo __('File loading failed', BWG()->prefix); ?>";
|
71 |
var warningRemoveItems = "<?php echo __('Are you sure you want to permanently remove selected items?', BWG()->prefix); ?>";
|
72 |
var warningCancelUploads = "<?php echo __('This will cancel uploads. Continue?', BWG()->prefix); ?>";
|
@@ -74,8 +74,8 @@ class FilemanagerView {
|
|
74 |
var messageEnterNewName = "<?php echo __('Enter new name', BWG()->prefix); ?>";
|
75 |
var messageFilesUploadComplete = "<?php echo __('Processing uploaded files...', BWG()->prefix); ?>";
|
76 |
var root = "<?php echo addslashes($this->controller->get_uploads_dir()); ?>";
|
77 |
-
var dir = "<?php echo
|
78 |
-
var dirUrl = "<?php echo $this->controller->get_uploads_url() . (isset($_REQUEST['dir']) ? WDWLibrary::get('dir','','sanitize_text_field','REQUEST') . '/' : ''); ?>";
|
79 |
var callback = "<?php echo (isset($_REQUEST['callback']) ? WDWLibrary::get('callback','','esc_js','REQUEST') : ''); ?>";
|
80 |
var sortBy = "<?php echo $sort_by; ?>";
|
81 |
var sortOrder = "<?php echo $sort_order; ?>";
|
@@ -86,11 +86,11 @@ class FilemanagerView {
|
|
86 |
do_action( 'bwg_filemanager_scripts_after' );
|
87 |
?>
|
88 |
<link href="<?php echo BWG()->plugin_url; ?>/filemanager/css/default.css?ver=<?php echo BWG()->plugin_version; ?>" type="text/css" rel="stylesheet">
|
89 |
-
|
90 |
-
|
91 |
<?php wp_nonce_field( '', 'bwg_nonce' ); ?>
|
92 |
<div id="wrapper">
|
93 |
-
|
94 |
<div class="ctrls_bar ctrls_bar_header">
|
95 |
<div class="ctrls_left header_bar">
|
96 |
<span class="dashicons dashicons-arrow-up-alt ctrl_bar_btn" onclick="onBtnUpClick(event, this);" title="<?php echo __('Up', BWG()->prefix); ?>"></span>
|
@@ -249,7 +249,7 @@ class FilemanagerView {
|
|
249 |
<div class="bwg-select-file-text"><?php _e('Drag files here', BWG()->prefix); ?><br><?php _e('or', BWG()->prefix); ?><br><span class="button"><?php _e('Select Files', BWG()->prefix); ?></span></div>
|
250 |
<?php
|
251 |
$query_url = wp_nonce_url( admin_url('admin-ajax.php'), 'bwg_UploadHandler', 'bwg_nonce' );
|
252 |
-
$query_url = add_query_arg(array('action' => 'bwg_UploadHandler', 'dir' => (isset($_REQUEST['dir']) ? WDWLibrary::get('dir','','sanitize_text_field','REQUEST') : '') . '/'), $query_url);
|
253 |
?>
|
254 |
<input id="jQueryUploader" type="file" name="files[]"
|
255 |
data-url="<?php echo $query_url; ?>"
|
@@ -276,7 +276,7 @@ class FilemanagerView {
|
|
276 |
<input type="hidden" name="sort_by" value="<?php echo $sort_by; ?>" />
|
277 |
<input type="hidden" name="sort_order" value="<?php echo $sort_order; ?>" />
|
278 |
<input type="hidden" name="items_view" value="<?php echo $items_view; ?>" />
|
279 |
-
<input type="hidden" name="dir" value="<?php echo (isset($_REQUEST['dir']) ? str_replace('\\', '',
|
280 |
<input type="hidden" name="file_names" value="" />
|
281 |
<input type="hidden" name="file_namesML" value="" />
|
282 |
<input type="hidden" name="file_new_name" value="" />
|
62 |
<script src="<?php echo BWG()->plugin_url; ?>/filemanager/js/jq_uploader/jquery.iframe-transport.js?v=10.0.0"></script>
|
63 |
<script src="<?php echo BWG()->plugin_url; ?>/filemanager/js/jq_uploader/jquery.fileupload.js?v=10.0.0"></script>
|
64 |
<script>
|
65 |
+
var DS = "<?php echo addslashes('/'); ?>";
|
66 |
var demo_message = "<?php echo addslashes(__('This option is disabled in demo.', BWG()->prefix)); ?>";
|
67 |
var ajaxurl = "<?php echo wp_nonce_url( admin_url('admin-ajax.php'), 'addImages', 'bwg_nonce' ); ?>";
|
68 |
var ajax_pagination_url = "<?php echo $ajax_pagination_url; ?>";
|
69 |
+
var ajax_get_all_select_url = "<?php echo $ajax_get_all_select_url; ?>";
|
70 |
var errorLoadingFile = "<?php echo __('File loading failed', BWG()->prefix); ?>";
|
71 |
var warningRemoveItems = "<?php echo __('Are you sure you want to permanently remove selected items?', BWG()->prefix); ?>";
|
72 |
var warningCancelUploads = "<?php echo __('This will cancel uploads. Continue?', BWG()->prefix); ?>";
|
74 |
var messageEnterNewName = "<?php echo __('Enter new name', BWG()->prefix); ?>";
|
75 |
var messageFilesUploadComplete = "<?php echo __('Processing uploaded files...', BWG()->prefix); ?>";
|
76 |
var root = "<?php echo addslashes($this->controller->get_uploads_dir()); ?>";
|
77 |
+
var dir = "<?php echo(isset($_REQUEST['dir']) ? str_replace(array('\\', '../'), '', WDWLibrary::get('dir', '', 'sanitize_text_field', 'REQUEST')) : ''); ?>";
|
78 |
+
var dirUrl = "<?php echo $this->controller->get_uploads_url() . (isset($_REQUEST['dir']) ? str_replace(array('\\', '../'), '', WDWLibrary::get('dir', '', 'sanitize_text_field', 'REQUEST')) . '/' : ''); ?>";
|
79 |
var callback = "<?php echo (isset($_REQUEST['callback']) ? WDWLibrary::get('callback','','esc_js','REQUEST') : ''); ?>";
|
80 |
var sortBy = "<?php echo $sort_by; ?>";
|
81 |
var sortOrder = "<?php echo $sort_order; ?>";
|
86 |
do_action( 'bwg_filemanager_scripts_after' );
|
87 |
?>
|
88 |
<link href="<?php echo BWG()->plugin_url; ?>/filemanager/css/default.css?ver=<?php echo BWG()->plugin_version; ?>" type="text/css" rel="stylesheet">
|
89 |
+
<link href="<?php echo BWG()->plugin_url; ?>/filemanager/css/default_view_<?php echo $items_view; ?>.css?ver=<?php echo BWG()->plugin_version; ?>" type="text/css" rel="stylesheet">
|
90 |
+
<form id="adminForm" name="adminForm" action="" method="post" class="wp-core-ui">
|
91 |
<?php wp_nonce_field( '', 'bwg_nonce' ); ?>
|
92 |
<div id="wrapper">
|
93 |
+
<div id="file_manager">
|
94 |
<div class="ctrls_bar ctrls_bar_header">
|
95 |
<div class="ctrls_left header_bar">
|
96 |
<span class="dashicons dashicons-arrow-up-alt ctrl_bar_btn" onclick="onBtnUpClick(event, this);" title="<?php echo __('Up', BWG()->prefix); ?>"></span>
|
249 |
<div class="bwg-select-file-text"><?php _e('Drag files here', BWG()->prefix); ?><br><?php _e('or', BWG()->prefix); ?><br><span class="button"><?php _e('Select Files', BWG()->prefix); ?></span></div>
|
250 |
<?php
|
251 |
$query_url = wp_nonce_url( admin_url('admin-ajax.php'), 'bwg_UploadHandler', 'bwg_nonce' );
|
252 |
+
$query_url = add_query_arg(array('action' => 'bwg_UploadHandler', 'dir' => (isset($_REQUEST['dir']) ? str_replace(array('\\', '../'), '', WDWLibrary::get('dir', '', 'sanitize_text_field', 'REQUEST')) : '') . '/'), $query_url);
|
253 |
?>
|
254 |
<input id="jQueryUploader" type="file" name="files[]"
|
255 |
data-url="<?php echo $query_url; ?>"
|
276 |
<input type="hidden" name="sort_by" value="<?php echo $sort_by; ?>" />
|
277 |
<input type="hidden" name="sort_order" value="<?php echo $sort_order; ?>" />
|
278 |
<input type="hidden" name="items_view" value="<?php echo $items_view; ?>" />
|
279 |
+
<input type="hidden" name="dir" value="<?php echo (isset($_REQUEST['dir']) ? str_replace(array('\\', '../'), '', WDWLibrary::get('dir', '', 'sanitize_text_field', 'REQUEST')) : ''); ?>" />
|
280 |
<input type="hidden" name="file_names" value="" />
|
281 |
<input type="hidden" name="file_namesML" value="" />
|
282 |
<input type="hidden" name="file_new_name" value="" />
|
framework/WDWLibrary.php
CHANGED
@@ -2913,8 +2913,8 @@ class WDWLibrary {
|
|
2913 |
ob_start();
|
2914 |
?>
|
2915 |
<div class="wd-list-view-header-free-right">
|
2916 |
-
<p class="upgrade-header"><?php _e('Unleash the full benefits
|
2917 |
-
<p class="upgrade-text"><?php _e('of the Premium Plugin', BWG()->prefix); ?></p>
|
2918 |
<a class="upgrade-button" href="<?php echo $premium_link; ?>" target="_blank"><?php _e( 'Upgrade Now', BWG()->prefix ); ?></a>
|
2919 |
</div>
|
2920 |
<a class="wd-list-view-ask-question" href="<?php echo $support_forum_link; ?>" target="_blank"><?php _e('Ask a question', BWG()->prefix); ?></a>
|
@@ -2922,6 +2922,39 @@ class WDWLibrary {
|
|
2922 |
echo ob_get_clean();
|
2923 |
}
|
2924 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2925 |
/**
|
2926 |
* Generate ask question static fixed button.
|
2927 |
*
|
2913 |
ob_start();
|
2914 |
?>
|
2915 |
<div class="wd-list-view-header-free-right">
|
2916 |
+
<p class="upgrade-header"><?php _e('Unleash the full benefits & ', BWG()->prefix); ?></p>
|
2917 |
+
<p class="upgrade-text"><?php _e('features of the Premium Plugin', BWG()->prefix); ?></p>
|
2918 |
<a class="upgrade-button" href="<?php echo $premium_link; ?>" target="_blank"><?php _e( 'Upgrade Now', BWG()->prefix ); ?></a>
|
2919 |
</div>
|
2920 |
<a class="wd-list-view-ask-question" href="<?php echo $support_forum_link; ?>" target="_blank"><?php _e('Ask a question', BWG()->prefix); ?></a>
|
2922 |
echo ob_get_clean();
|
2923 |
}
|
2924 |
|
2925 |
+
/**
|
2926 |
+
* Generate free trial banner section. - for 2 weeks
|
2927 |
+
*
|
2928 |
+
*/
|
2929 |
+
public static function free_trial_banner_section() {
|
2930 |
+
$free_trial_plugin_link = 'https://10web.io/?utm_source=in%20plugin&utm_medium=banner&utm_campaign=photo%20gallery';
|
2931 |
+
wp_enqueue_style(BWG()->prefix . '-free_trial_banner_css');
|
2932 |
+
wp_enqueue_script(BWG()->prefix . '-free_trial_banner_js');
|
2933 |
+
ob_start();
|
2934 |
+
?>
|
2935 |
+
<div class="tenweb_free_trial_banner tenweb-<?php echo BWG()->prefix; ?>-free_trial_banner">
|
2936 |
+
<span id="tenweb_free_trial_banner_close" onclick="tenweb_free_trial_banner_close();"></span>
|
2937 |
+
<div class="tenweb_free_trial_banner_container">
|
2938 |
+
<div class="tenweb_free_trial_banner_img"></div>
|
2939 |
+
<div class="tenweb_free_trial_banner_info">
|
2940 |
+
<div class="tenweb_icon"></div>
|
2941 |
+
<p><?php _e('Sign up for a 14-day Free Trial of Automated WordPress Platform', BWG()->prefix); ?></p>
|
2942 |
+
<div class="tenweb_info_sec">
|
2943 |
+
<span><?php _e('Hosting on Google Cloud', BWG()->prefix); ?></span>
|
2944 |
+
<span><?php _e('90+ PageSpeed Score', BWG()->prefix); ?></span>
|
2945 |
+
<span><?php _e('AI Builder', BWG()->prefix); ?></span>
|
2946 |
+
<span><?php _e('1 Click Migration', BWG()->prefix); ?></span>
|
2947 |
+
</div>
|
2948 |
+
</div>
|
2949 |
+
<div class="tenweb_free_trial_banner_button">
|
2950 |
+
<a class="ftb-button" href="<?php echo $free_trial_plugin_link; ?>" target="_blank"><?php _e( 'learn more', BWG()->prefix ); ?></a>
|
2951 |
+
</div>
|
2952 |
+
</div>
|
2953 |
+
</div>
|
2954 |
+
<?php
|
2955 |
+
echo ob_get_clean();
|
2956 |
+
}
|
2957 |
+
|
2958 |
/**
|
2959 |
* Generate ask question static fixed button.
|
2960 |
*
|
images/gallery_list_img_black.png
ADDED
Binary file
|
images/{gallery_list_img.png → gallery_list_img_green.png}
RENAMED
File without changes
|
js/free_trial_banner.js
ADDED
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
function tenweb_free_trial_banner_close() {
|
2 |
+
jQuery.ajax( {
|
3 |
+
type: "POST",
|
4 |
+
url: ajaxurl,
|
5 |
+
data: { action:"bwg_free_trial_banner" },
|
6 |
+
success: function ( response ) {
|
7 |
+
if ( response == "True" ) {
|
8 |
+
jQuery(".tenweb_free_trial_banner").remove();
|
9 |
+
}
|
10 |
+
},
|
11 |
+
} );
|
12 |
+
}
|
13 |
+
/* Hide Banner on fix date */
|
14 |
+
var current = new Date();
|
15 |
+
var banner_expiry = new Date("May 28 2021 00:00:00");
|
16 |
+
if ( current.getTime() > banner_expiry.getTime() ) {
|
17 |
+
tenweb_free_trial_banner_close();
|
18 |
+
}
|
photo-gallery.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Plugin Name: Photo Gallery
|
4 |
* Plugin URI: https://10web.io/plugins/wordpress-photo-gallery/?utm_source=photo_gallery&utm_medium=free_plugin
|
5 |
* Description: This plugin is a fully responsive gallery plugin with advanced functionality. It allows having different image galleries for your posts and pages. You can create unlimited number of galleries, combine them into albums, and provide descriptions and tags.
|
6 |
-
* Version: 1.5.
|
7 |
* Author: Photo Gallery Team
|
8 |
* Author URI: https://10web.io/plugins/?utm_source=photo_gallery&utm_medium=free_plugin
|
9 |
* License: GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
|
@@ -105,8 +105,8 @@ final class BWG {
|
|
105 |
$this->plugin_url = plugins_url(plugin_basename(dirname(__FILE__)));
|
106 |
$this->front_url = $this->plugin_url;
|
107 |
$this->main_file = plugin_basename(__FILE__);
|
108 |
-
$this->plugin_version = '1.5.
|
109 |
-
$this->db_version = '1.5.
|
110 |
$this->prefix = 'bwg';
|
111 |
$this->nicename = __('Photo Gallery', $this->prefix);
|
112 |
require_once($this->plugin_dir . '/framework/WDWLibrary.php');
|
@@ -272,6 +272,10 @@ final class BWG {
|
|
272 |
/* Add wordpress.org support custom link in plugin page */
|
273 |
add_filter('plugin_action_links_' . plugin_basename(__FILE__), array( $this, 'add_ask_question_links' ));
|
274 |
}
|
|
|
|
|
|
|
|
|
275 |
}
|
276 |
|
277 |
/**
|
@@ -686,8 +690,12 @@ final class BWG {
|
|
686 |
}
|
687 |
|
688 |
// Roboto font for top bar.
|
689 |
-
wp_register_style($this->prefix . '-roboto', 'https://fonts.googleapis.com/css?family=Roboto:300,400,500,700&display=swap');
|
690 |
wp_register_style($this->prefix . '-pricing', $this->plugin_url . '/css/pricing.css', array(), $this->plugin_version);
|
|
|
|
|
|
|
|
|
|
|
691 |
|
692 |
// For drag and drop on mobiles.
|
693 |
wp_register_script($this->prefix . '_jquery.ui.touch-punch.min', $this->plugin_url . '/js/jquery.ui.touch-punch.min.js', array(), '0.2.3');
|
@@ -698,6 +706,20 @@ final class BWG {
|
|
698 |
}
|
699 |
}
|
700 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
701 |
/**
|
702 |
* Frontend AJAX actions.
|
703 |
*/
|
@@ -1178,6 +1200,7 @@ final class BWG {
|
|
1178 |
add_option("wd_bwg_theme_version", '1.0.0', '', 'no');
|
1179 |
}
|
1180 |
}
|
|
|
1181 |
$this->create_post_types();
|
1182 |
// Using this insted of flush_rewrite_rule() for better performance with multisite.
|
1183 |
global $wp_rewrite;
|
@@ -1484,8 +1507,8 @@ final class BWG {
|
|
1484 |
* Overview.
|
1485 |
*/
|
1486 |
public function overview() {
|
1487 |
-
if (is_admin() && !isset($_REQUEST['ajax'])) {
|
1488 |
-
if (!class_exists("TenWebLibNew")) {
|
1489 |
$plugin_dir = apply_filters('tenweb_new_free_users_lib_path', array('version' => '1.1.3', 'path' => $this->plugin_dir));
|
1490 |
require_once($plugin_dir['path'] . '/wd/start.php');
|
1491 |
}
|
@@ -1711,7 +1734,7 @@ final class BWG {
|
|
1711 |
"plugin_wd_demo_link" => "https://demo.10web.io/photo-gallery/" . BWG()->utm_source,
|
1712 |
"plugin_wd_addons_link" => BWG()->plugin_link . BWG()->utm_source,
|
1713 |
"plugin_wd_docs_link" => "https://help.10web.io/hc/en-us/sections/360002159111-Photo-Gallery/" . BWG()->utm_source,
|
1714 |
-
"after_subscribe" => admin_url('admin.php?page=galleries_bwg'), // this can be
|
1715 |
"plugin_wizard_link" => '',
|
1716 |
"plugin_menu_title" => $this->nicename,
|
1717 |
"plugin_menu_icon" => BWG()->plugin_url . '/images/icons/icon.png',
|
3 |
* Plugin Name: Photo Gallery
|
4 |
* Plugin URI: https://10web.io/plugins/wordpress-photo-gallery/?utm_source=photo_gallery&utm_medium=free_plugin
|
5 |
* Description: This plugin is a fully responsive gallery plugin with advanced functionality. It allows having different image galleries for your posts and pages. You can create unlimited number of galleries, combine them into albums, and provide descriptions and tags.
|
6 |
+
* Version: 1.5.75
|
7 |
* Author: Photo Gallery Team
|
8 |
* Author URI: https://10web.io/plugins/?utm_source=photo_gallery&utm_medium=free_plugin
|
9 |
* License: GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
|
105 |
$this->plugin_url = plugins_url(plugin_basename(dirname(__FILE__)));
|
106 |
$this->front_url = $this->plugin_url;
|
107 |
$this->main_file = plugin_basename(__FILE__);
|
108 |
+
$this->plugin_version = '1.5.75';
|
109 |
+
$this->db_version = '1.5.75';
|
110 |
$this->prefix = 'bwg';
|
111 |
$this->nicename = __('Photo Gallery', $this->prefix);
|
112 |
require_once($this->plugin_dir . '/framework/WDWLibrary.php');
|
272 |
/* Add wordpress.org support custom link in plugin page */
|
273 |
add_filter('plugin_action_links_' . plugin_basename(__FILE__), array( $this, 'add_ask_question_links' ));
|
274 |
}
|
275 |
+
|
276 |
+
/* Free Trial Banner for 2 weeks */
|
277 |
+
add_action('wp_ajax_bwg_free_trial_banner', array($this, 'free_trial_banner_update_status'));
|
278 |
+
add_action('wp_ajax_nopriv_bwg_free_trial_banner', array($this, 'free_trial_banner_update_status'));
|
279 |
}
|
280 |
|
281 |
/**
|
690 |
}
|
691 |
|
692 |
// Roboto font for top bar.
|
|
|
693 |
wp_register_style($this->prefix . '-pricing', $this->plugin_url . '/css/pricing.css', array(), $this->plugin_version);
|
694 |
+
wp_register_style($this->prefix . '-roboto', 'https://fonts.googleapis.com/css?family=Roboto:300,400,500,700&display=swap');
|
695 |
+
|
696 |
+
/* Free Trial Banner - for 2 weeks */
|
697 |
+
wp_register_style($this->prefix . '-free_trial_banner_css', $this->plugin_url . '/css/free_trial_banner.css', array(), $this->plugin_version);
|
698 |
+
wp_register_script($this->prefix . '-free_trial_banner_js', $this->plugin_url . '/js/free_trial_banner.js', array(), $this->plugin_version);
|
699 |
|
700 |
// For drag and drop on mobiles.
|
701 |
wp_register_script($this->prefix . '_jquery.ui.touch-punch.min', $this->plugin_url . '/js/jquery.ui.touch-punch.min.js', array(), '0.2.3');
|
706 |
}
|
707 |
}
|
708 |
|
709 |
+
/**
|
710 |
+
* Free Trial Banner for 2 weeks
|
711 |
+
*
|
712 |
+
*/
|
713 |
+
public function free_trial_banner_update_status() {
|
714 |
+
$free_trial_banner_status = add_option('wd_bwg_free_trial_banner', '1', '', 'no');
|
715 |
+
if ( $free_trial_banner_status ) {
|
716 |
+
echo "True";
|
717 |
+
} else {
|
718 |
+
echo "False";
|
719 |
+
}
|
720 |
+
die();
|
721 |
+
}
|
722 |
+
|
723 |
/**
|
724 |
* Frontend AJAX actions.
|
725 |
*/
|
1200 |
add_option("wd_bwg_theme_version", '1.0.0', '', 'no');
|
1201 |
}
|
1202 |
}
|
1203 |
+
|
1204 |
$this->create_post_types();
|
1205 |
// Using this insted of flush_rewrite_rule() for better performance with multisite.
|
1206 |
global $wp_rewrite;
|
1507 |
* Overview.
|
1508 |
*/
|
1509 |
public function overview() {
|
1510 |
+
if ( is_admin() && !isset($_REQUEST['ajax']) ) {
|
1511 |
+
if ( !class_exists("TenWebLibNew") ) {
|
1512 |
$plugin_dir = apply_filters('tenweb_new_free_users_lib_path', array('version' => '1.1.3', 'path' => $this->plugin_dir));
|
1513 |
require_once($plugin_dir['path'] . '/wd/start.php');
|
1514 |
}
|
1734 |
"plugin_wd_demo_link" => "https://demo.10web.io/photo-gallery/" . BWG()->utm_source,
|
1735 |
"plugin_wd_addons_link" => BWG()->plugin_link . BWG()->utm_source,
|
1736 |
"plugin_wd_docs_link" => "https://help.10web.io/hc/en-us/sections/360002159111-Photo-Gallery/" . BWG()->utm_source,
|
1737 |
+
"after_subscribe" => admin_url('admin.php?page=galleries_bwg'), // this can be plugin overview page or set up page
|
1738 |
"plugin_wizard_link" => '',
|
1739 |
"plugin_menu_title" => $this->nicename,
|
1740 |
"plugin_menu_icon" => BWG()->plugin_url . '/images/icons/icon.png',
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: webdorado,wdsupport,photogallerysupport,10web
|
|
3 |
Tags: gallery, photo gallery, image gallery, responsive gallery, wordpress gallery plugin, photo albums, gallery slider, gallery lightbox, wordpress photo gallery plugin, fullscreen gallery, watermarking, video gallery
|
4 |
Requires at least: 4.6
|
5 |
Tested up to: 5.7
|
6 |
-
Stable tag: 1.5.
|
7 |
License: GPLv2 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
9 |
|
@@ -282,6 +282,9 @@ Choose whether to display random or the first/last specific number of images.
|
|
282 |
|
283 |
== Changelog ==
|
284 |
|
|
|
|
|
|
|
285 |
= 1.5.74 =
|
286 |
* Fixed: XSS vulnerability.
|
287 |
|
3 |
Tags: gallery, photo gallery, image gallery, responsive gallery, wordpress gallery plugin, photo albums, gallery slider, gallery lightbox, wordpress photo gallery plugin, fullscreen gallery, watermarking, video gallery
|
4 |
Requires at least: 4.6
|
5 |
Tested up to: 5.7
|
6 |
+
Stable tag: 1.5.75
|
7 |
License: GPLv2 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
9 |
|
282 |
|
283 |
== Changelog ==
|
284 |
|
285 |
+
= 1.5.75 =
|
286 |
+
* Fixed: Security issues with SVG files.
|
287 |
+
|
288 |
= 1.5.74 =
|
289 |
* Fixed: XSS vulnerability.
|
290 |
|
wd/wd.php
CHANGED
@@ -74,7 +74,7 @@ class TenWebLibNew {
|
|
74 |
$this->overview_instance->display_overview_page();
|
75 |
}
|
76 |
|
77 |
-
//
|
78 |
public function wd_includes() {
|
79 |
$wd_options = $this->config;
|
80 |
require_once $wd_options->wd_dir_includes . '/deactivate.php';
|
74 |
$this->overview_instance->display_overview_page();
|
75 |
}
|
76 |
|
77 |
+
// Includes
|
78 |
public function wd_includes() {
|
79 |
$wd_options = $this->config;
|
80 |
require_once $wd_options->wd_dir_includes . '/deactivate.php';
|