Version Description
Download this release
Release Info
Developer | niteo |
Plugin | CMP – Coming Soon & Maintenance Plugin by NiteoThemes |
Version | 3.5.2 |
Comparing to | |
See all releases |
Code changes from version 3.5.1 to 3.5.2
- css/preview-iframe.css +0 -563
- inc/class-cmp-render_html.php +16 -407
- js/preview-iframe.js +0 -260
- niteo-cmp.php +2 -2
- readme.txt +8 -2
css/preview-iframe.css
DELETED
@@ -1,563 +0,0 @@
|
|
1 |
-
html, body {
|
2 |
-
height: 100%;
|
3 |
-
margin: 0; /* Reset default margin on the body element */
|
4 |
-
font-family: 'Open Sans', 'Times New Roman', Georgia, Serif;
|
5 |
-
}
|
6 |
-
|
7 |
-
iframe {
|
8 |
-
display: block; /* iframes are inline by default */
|
9 |
-
border: none; /* Reset default border */
|
10 |
-
height: 100vh;
|
11 |
-
width:100%;
|
12 |
-
min-height: 100%;
|
13 |
-
background-color: rgba(0, 0, 0, 0.5);
|
14 |
-
opacity: 0;
|
15 |
-
-o-transition: opacity 300ms ease-in-out, width 300ms;
|
16 |
-
transition: opacity 300ms ease-in-out, width 300ms;
|
17 |
-
}
|
18 |
-
|
19 |
-
.open iframe {
|
20 |
-
width: calc(100% - 350px);
|
21 |
-
}
|
22 |
-
|
23 |
-
iframe.loaded {
|
24 |
-
opacity: 1;
|
25 |
-
}
|
26 |
-
|
27 |
-
h3 {
|
28 |
-
text-transform: uppercase;
|
29 |
-
font-size: 1em;
|
30 |
-
text-align: center;
|
31 |
-
}
|
32 |
-
|
33 |
-
/* scrollbar */
|
34 |
-
::-webkit-scrollbar {
|
35 |
-
width:9px;
|
36 |
-
}
|
37 |
-
::-webkit-scrollbar-thumb {
|
38 |
-
background:rgba(0,0,0,0.8);
|
39 |
-
border:none;
|
40 |
-
border-bottom-left-radius:0;
|
41 |
-
border-bottom-right-radius:0;
|
42 |
-
border-top-left-radius:0;
|
43 |
-
border-top-right-radius:0;
|
44 |
-
}
|
45 |
-
::-webkit-scrollbar-track {
|
46 |
-
background:rgba(170,170,170,0.8);
|
47 |
-
}
|
48 |
-
|
49 |
-
.background-wrap {
|
50 |
-
position: fixed;
|
51 |
-
top: 0;
|
52 |
-
right: 0;
|
53 |
-
bottom: 0;
|
54 |
-
left: 0;
|
55 |
-
-webkit-animation: fadeOut 600ms forwards;
|
56 |
-
animation: fadeOut 600ms forwards;
|
57 |
-
}
|
58 |
-
|
59 |
-
.open .background-wrap {
|
60 |
-
-webkit-animation: fadeIn 600ms forwards;
|
61 |
-
animation: fadeIn 600ms forwards;
|
62 |
-
}
|
63 |
-
|
64 |
-
|
65 |
-
.button {
|
66 |
-
display: inline-block;
|
67 |
-
margin: 2em 0;
|
68 |
-
padding: 1em 4em;
|
69 |
-
text-decoration: none;
|
70 |
-
color: #fff;
|
71 |
-
background: #3d0080;
|
72 |
-
border-radius: 37px;
|
73 |
-
font-weight: 700;
|
74 |
-
box-shadow: 0px 16px 30px -16px rgba(0,0,0,0.75);
|
75 |
-
-o-transition: background-color 250ms ease-in-out;
|
76 |
-
transition: background-color 250ms ease-in-out;
|
77 |
-
}
|
78 |
-
|
79 |
-
.button:hover {
|
80 |
-
background-color: #7B6FE4;
|
81 |
-
}
|
82 |
-
|
83 |
-
.buy-theme {
|
84 |
-
background-color: #ff3284;
|
85 |
-
}
|
86 |
-
.buy-theme:hover {
|
87 |
-
background-color: #E1729F;
|
88 |
-
}
|
89 |
-
|
90 |
-
#preview-customize {
|
91 |
-
position: fixed;
|
92 |
-
z-index: 11000;
|
93 |
-
width: 350px;
|
94 |
-
max-width: 100%;
|
95 |
-
height: 100vh;
|
96 |
-
overflow-y: auto;
|
97 |
-
left: 100%;
|
98 |
-
top: 0;
|
99 |
-
background-color: #fff;
|
100 |
-
text-align: center;
|
101 |
-
-webkit-transform: translate3d(0,0,0);
|
102 |
-
transform: translate3d(0,0,0);
|
103 |
-
transition: -webkit-transform 300ms;
|
104 |
-
-o-transition: transform 300ms;
|
105 |
-
-o-transition: transform 300ms;
|
106 |
-
transition: transform 300ms;
|
107 |
-
transition: transform 300ms, -webkit-transform 300ms;
|
108 |
-
}
|
109 |
-
|
110 |
-
.open #preview-customize {
|
111 |
-
-webkit-transform: translate3d(-100%,0,0);
|
112 |
-
transform: translate3d(-100%,0,0);
|
113 |
-
box-shadow: -10px 0px 25px -1px rgba(0, 0, 0, 0.05);
|
114 |
-
}
|
115 |
-
|
116 |
-
.hamburger {
|
117 |
-
padding: 15px 15px 10px 15px;
|
118 |
-
cursor: pointer;
|
119 |
-
}
|
120 |
-
|
121 |
-
.hamburger-box {
|
122 |
-
position: relative;
|
123 |
-
display: inline-block;
|
124 |
-
width: 40px;
|
125 |
-
height: 40px;
|
126 |
-
}
|
127 |
-
|
128 |
-
.hamburger-inner {
|
129 |
-
top: 50%;
|
130 |
-
display: block;
|
131 |
-
margin-top: -2px;
|
132 |
-
}
|
133 |
-
|
134 |
-
.hamburger-inner, .hamburger-inner:after, .hamburger-inner:before {
|
135 |
-
position: absolute;
|
136 |
-
width: 40px;
|
137 |
-
height: 4px;
|
138 |
-
-o-transition-timing-function: ease;
|
139 |
-
transition-timing-function: ease;
|
140 |
-
-o-transition-duration: .15s;
|
141 |
-
transition-duration: .15s;
|
142 |
-
transition-property: -webkit-transform;
|
143 |
-
-o-transition-property: transform;
|
144 |
-
transition-property: transform;
|
145 |
-
transition-property: transform, -webkit-transform;
|
146 |
-
border-radius: 4px;
|
147 |
-
background-color: #000000;
|
148 |
-
}
|
149 |
-
|
150 |
-
.open .hamburger .hamburger-inner, .open .hamburger .hamburger-inner:after, .open .hamburger .hamburger-inner:before {
|
151 |
-
background-color: #000000;
|
152 |
-
}
|
153 |
-
|
154 |
-
.open .hamburger--arrowturn .hamburger-inner {
|
155 |
-
-webkit-transform: rotate(-180deg);
|
156 |
-
-ms-transform: rotate(-180deg);
|
157 |
-
transform: rotate(-180deg);
|
158 |
-
}
|
159 |
-
|
160 |
-
.customize-content {
|
161 |
-
display: flex;
|
162 |
-
flex-direction: column;
|
163 |
-
min-height: calc(100vh - 3em);
|
164 |
-
}
|
165 |
-
|
166 |
-
.hamburger-inner, .hamburger-inner:after, .hamburger-inner:before {
|
167 |
-
position: absolute;
|
168 |
-
width: 40px;
|
169 |
-
height: 4px;
|
170 |
-
-o-transition-timing-function: ease;
|
171 |
-
transition-timing-function: ease;
|
172 |
-
-o-transition-duration: 300ms;
|
173 |
-
transition-duration: 300ms;
|
174 |
-
transition-property: -webkit-transform;
|
175 |
-
-o-transition-property: transform;
|
176 |
-
transition-property: transform;
|
177 |
-
transition-property: transform, -webkit-transform;
|
178 |
-
border-radius: 4px;
|
179 |
-
background-color: #000000;
|
180 |
-
}
|
181 |
-
|
182 |
-
.hamburger-inner:after, .hamburger-inner:before {
|
183 |
-
display: block;
|
184 |
-
content: "";
|
185 |
-
}
|
186 |
-
|
187 |
-
.hamburger-inner:before {
|
188 |
-
top: -10px;
|
189 |
-
}
|
190 |
-
|
191 |
-
.hamburger-inner:after {
|
192 |
-
bottom: -10px;
|
193 |
-
}
|
194 |
-
|
195 |
-
.open .hamburger .hamburger-inner, .open .hamburger .hamburger-inner:after, .open .hamburger .hamburger-inner:before {
|
196 |
-
background-color: #000000;
|
197 |
-
}
|
198 |
-
|
199 |
-
.open .hamburger--arrowturn .hamburger-inner:before {
|
200 |
-
-webkit-transform: translate3d(-8px,0,0) rotate(-45deg) scaleX(.7);
|
201 |
-
transform: translate3d(-8px,0,0) rotate(-45deg) scaleX(.7);
|
202 |
-
}
|
203 |
-
|
204 |
-
.open .hamburger--arrowturn .hamburger-inner:after {
|
205 |
-
-webkit-transform: translate3d(-8px,0,0) rotate(45deg) scaleX(.7);
|
206 |
-
transform: translate3d(-8px,0,0) rotate(45deg) scaleX(.7);
|
207 |
-
}
|
208 |
-
|
209 |
-
#slider {
|
210 |
-
position: relative;
|
211 |
-
overflow: hidden;
|
212 |
-
margin: 0;
|
213 |
-
width: 350px;
|
214 |
-
max-width: 100%;
|
215 |
-
}
|
216 |
-
|
217 |
-
#slider ul {
|
218 |
-
position: relative;
|
219 |
-
margin: 0;
|
220 |
-
padding: 0;
|
221 |
-
height: auto;
|
222 |
-
list-style: none;
|
223 |
-
}
|
224 |
-
|
225 |
-
#slider ul li {
|
226 |
-
position: relative;
|
227 |
-
display: block;
|
228 |
-
float: left;
|
229 |
-
margin: 0;
|
230 |
-
padding: 0;
|
231 |
-
max-width: 100vw;
|
232 |
-
width: 350px;
|
233 |
-
height: auto;
|
234 |
-
background: #ccc;
|
235 |
-
text-align: center;
|
236 |
-
}
|
237 |
-
|
238 |
-
.slider-controls {
|
239 |
-
text-align: center;
|
240 |
-
line-height: 35px;
|
241 |
-
font-weight: 700;
|
242 |
-
margin-top: 1em;
|
243 |
-
}
|
244 |
-
|
245 |
-
.control_prev {
|
246 |
-
float: left;
|
247 |
-
margin-left: 1em;
|
248 |
-
}
|
249 |
-
|
250 |
-
.control_next {
|
251 |
-
float: right;
|
252 |
-
margin-right: 1em;
|
253 |
-
}
|
254 |
-
|
255 |
-
.thumbnail {
|
256 |
-
padding: 5px;
|
257 |
-
display: inline-block;
|
258 |
-
margin-bottom: 6px;
|
259 |
-
text-align: center;
|
260 |
-
text-transform: uppercase;
|
261 |
-
font-weight: 600;
|
262 |
-
font-size: 0.8em;
|
263 |
-
}
|
264 |
-
|
265 |
-
.thumbnail p {
|
266 |
-
margin: 0;
|
267 |
-
}
|
268 |
-
|
269 |
-
.bundle {
|
270 |
-
position: absolute;
|
271 |
-
right: 20px;
|
272 |
-
top: 20px;
|
273 |
-
background: #3ac33a;
|
274 |
-
color: white;
|
275 |
-
padding: 0.5em 1em;
|
276 |
-
border-radius: 20px;
|
277 |
-
}
|
278 |
-
|
279 |
-
.theme-customizer {
|
280 |
-
width: 100%;
|
281 |
-
padding: 1em;
|
282 |
-
background: #f1f1f1;
|
283 |
-
border-top: 1px solid #e4e4e4;
|
284 |
-
border-bottom: 1px solid #e4e4e4;
|
285 |
-
box-sizing: border-box;
|
286 |
-
-moz-box-sizing: border-box;
|
287 |
-
-webkit-box-sizing: border-box;
|
288 |
-
}
|
289 |
-
|
290 |
-
#submit-wrapper {
|
291 |
-
display: block;
|
292 |
-
overflow: auto;
|
293 |
-
}
|
294 |
-
|
295 |
-
.theme-customizer .thumbnail {
|
296 |
-
min-width: 15%;
|
297 |
-
}
|
298 |
-
|
299 |
-
.customize-content img {
|
300 |
-
max-width: 100%;
|
301 |
-
vertical-align: top;
|
302 |
-
}
|
303 |
-
|
304 |
-
.settings-section {
|
305 |
-
overflow: hidden;
|
306 |
-
/*margin-bottom: 2em;*/
|
307 |
-
}
|
308 |
-
|
309 |
-
.settings-section:not(:first-of-type) h3 {
|
310 |
-
margin-top: 3em;
|
311 |
-
}
|
312 |
-
|
313 |
-
.settings-section.not-active {
|
314 |
-
visibility: hidden;
|
315 |
-
height: 0;
|
316 |
-
}
|
317 |
-
|
318 |
-
.panel-wrapper {
|
319 |
-
position: absolute;
|
320 |
-
top: 135px;
|
321 |
-
right: 0;
|
322 |
-
cursor: pointer;
|
323 |
-
background: white;
|
324 |
-
box-shadow: -10px 0px 25px -1px rgba(0, 0, 0, 0.05);
|
325 |
-
-webkit-transform: translate3d(0,0,0);
|
326 |
-
transform: translate3d(0,0,0);
|
327 |
-
transition: -webkit-transform 300ms;
|
328 |
-
-o-transition: transform 300ms;
|
329 |
-
-o-transition: transform 300ms;
|
330 |
-
transition: transform 300ms;
|
331 |
-
transition: transform 300ms, -webkit-transform 300ms;
|
332 |
-
}
|
333 |
-
|
334 |
-
.open .panel-wrapper {
|
335 |
-
-webkit-transform: translate3d(-350px,0,0);
|
336 |
-
transform: translate3d(-350px,0,0);
|
337 |
-
box-shadow: -10px 0px 25px -1px rgba(0, 0, 0, 0.05);
|
338 |
-
}
|
339 |
-
|
340 |
-
|
341 |
-
.purchase.free {
|
342 |
-
display: none;
|
343 |
-
}
|
344 |
-
|
345 |
-
.theme-customizer {
|
346 |
-
overflow: hidden;
|
347 |
-
}
|
348 |
-
|
349 |
-
.theme-customizer a,
|
350 |
-
.theme-customizer a:visited {
|
351 |
-
color: #777;
|
352 |
-
text-decoration: none;
|
353 |
-
}
|
354 |
-
|
355 |
-
.theme-customizer svg,
|
356 |
-
.slider-controls svg {
|
357 |
-
opacity: 0.4;
|
358 |
-
-webkit-transform: scale(0.6);
|
359 |
-
-ms-transform: scale(0.6);
|
360 |
-
transform: scale(0.6);
|
361 |
-
transition: -webkit-transform 300ms ease-in-out;
|
362 |
-
-o-transition: all 300ms ease-in-out;
|
363 |
-
transition: all 300ms ease-in-out;
|
364 |
-
transition: all 300ms ease-in-out;
|
365 |
-
}
|
366 |
-
|
367 |
-
.theme-customizer a:hover svg,
|
368 |
-
.theme-customizer .selected svg,
|
369 |
-
.control_prev:hover svg,
|
370 |
-
.control_next:hover svg {
|
371 |
-
opacity: 1;
|
372 |
-
-webkit-transform: scale(0.8);
|
373 |
-
-ms-transform: scale(0.8);
|
374 |
-
transform: scale(0.8);
|
375 |
-
}
|
376 |
-
|
377 |
-
.theme-customizer i {
|
378 |
-
display: block;
|
379 |
-
font-size: 4em;
|
380 |
-
}
|
381 |
-
|
382 |
-
.svg-container {
|
383 |
-
position: relative;
|
384 |
-
height: 70px;
|
385 |
-
}
|
386 |
-
|
387 |
-
.svg-container svg {
|
388 |
-
position: absolute;
|
389 |
-
width: 64px;
|
390 |
-
height: 59px;
|
391 |
-
left: 0;
|
392 |
-
}
|
393 |
-
|
394 |
-
.backlink {
|
395 |
-
color: #777;
|
396 |
-
font-weight: 600;
|
397 |
-
padding-bottom: 1em;
|
398 |
-
}
|
399 |
-
|
400 |
-
.animate {
|
401 |
-
-webkit-animation-duration: 1s;
|
402 |
-
animation-duration: 1s;
|
403 |
-
-webkit-animation-fill-mode: both;
|
404 |
-
animation-fill-mode: both;
|
405 |
-
}
|
406 |
-
|
407 |
-
@-webkit-keyframes zoomIn {
|
408 |
-
from {
|
409 |
-
opacity: 0;
|
410 |
-
-webkit-transform: scale3d(0.3, 0.3, 0.3);
|
411 |
-
transform: scale3d(0.3, 0.3, 0.3);
|
412 |
-
|
413 |
-
}
|
414 |
-
|
415 |
-
50% {
|
416 |
-
opacity: 1;
|
417 |
-
}
|
418 |
-
}
|
419 |
-
|
420 |
-
@keyframes zoomIn {
|
421 |
-
from {
|
422 |
-
opacity: 0;
|
423 |
-
-webkit-transform: scale3d(0.3, 0.3, 0.3);
|
424 |
-
transform: scale3d(0.3, 0.3, 0.3);
|
425 |
-
|
426 |
-
}
|
427 |
-
|
428 |
-
50% {
|
429 |
-
opacity: 1;
|
430 |
-
}
|
431 |
-
}
|
432 |
-
|
433 |
-
.zoomIn,
|
434 |
-
.settings-section.not-active.zoomIn {
|
435 |
-
-webkit-animation-name: zoomIn;
|
436 |
-
animation-name: zoomIn;
|
437 |
-
}
|
438 |
-
|
439 |
-
@-webkit-keyframes zoomOut {
|
440 |
-
from {
|
441 |
-
opacity: 1;
|
442 |
-
visibility: visible;
|
443 |
-
}
|
444 |
-
|
445 |
-
50% {
|
446 |
-
opacity: 0;
|
447 |
-
-webkit-transform: scale3d(0.3, 0.3, 0.3);
|
448 |
-
transform: scale3d(0.3, 0.3, 0.3);
|
449 |
-
}
|
450 |
-
|
451 |
-
99% {
|
452 |
-
height: 0;
|
453 |
-
}
|
454 |
-
|
455 |
-
to {
|
456 |
-
opacity: 0;
|
457 |
-
height: 0;
|
458 |
-
visibility: hidden;
|
459 |
-
}
|
460 |
-
}
|
461 |
-
|
462 |
-
@keyframes zoomOut {
|
463 |
-
from {
|
464 |
-
opacity: 1;
|
465 |
-
visibility: visible;
|
466 |
-
}
|
467 |
-
|
468 |
-
50% {
|
469 |
-
opacity: 0;
|
470 |
-
-webkit-transform: scale3d(0.3, 0.3, 0.3);
|
471 |
-
transform: scale3d(0.3, 0.3, 0.3);
|
472 |
-
}
|
473 |
-
|
474 |
-
99% {
|
475 |
-
height: 0;
|
476 |
-
}
|
477 |
-
|
478 |
-
to {
|
479 |
-
opacity: 0;
|
480 |
-
height: 0;
|
481 |
-
visibility: hidden;
|
482 |
-
}
|
483 |
-
}
|
484 |
-
|
485 |
-
.zoomOut {
|
486 |
-
-webkit-animation-name: zoomOut;
|
487 |
-
animation-name: zoomOut;
|
488 |
-
}
|
489 |
-
|
490 |
-
@-webkit-keyframes slide-panel{
|
491 |
-
from{left:0px}to{left:-70px}
|
492 |
-
}
|
493 |
-
|
494 |
-
@keyframes slide-panel{
|
495 |
-
from{left:0px}to{left:-70px}
|
496 |
-
}
|
497 |
-
|
498 |
-
@-webkit-keyframes fadeOut {
|
499 |
-
0% {
|
500 |
-
background-color: rgba(0,0,0,0.4);
|
501 |
-
z-index: 1;
|
502 |
-
}
|
503 |
-
99% {
|
504 |
-
background-color: rgba(0,0,0,0);
|
505 |
-
z-index: 1;
|
506 |
-
}
|
507 |
-
100% {
|
508 |
-
background-color: rgba(0,0,0,0);
|
509 |
-
z-index: -1;
|
510 |
-
}
|
511 |
-
}
|
512 |
-
|
513 |
-
|
514 |
-
@keyframes fadeOut {
|
515 |
-
0% {
|
516 |
-
background-color: rgba(0,0,0,0.4);
|
517 |
-
z-index: 1;
|
518 |
-
}
|
519 |
-
99% {
|
520 |
-
background-color: rgba(0,0,0,0);
|
521 |
-
z-index: 1;
|
522 |
-
}
|
523 |
-
100% {
|
524 |
-
background-color: rgba(0,0,0,0);
|
525 |
-
z-index: -1;
|
526 |
-
}
|
527 |
-
}
|
528 |
-
|
529 |
-
|
530 |
-
@-webkit-keyframes fadeIn {
|
531 |
-
0% {
|
532 |
-
background-color: rgba(0,0,0,0);
|
533 |
-
z-index: 1;
|
534 |
-
}
|
535 |
-
99% {
|
536 |
-
background-color: rgba(0,0,0,0.4);
|
537 |
-
z-index: 1;
|
538 |
-
}
|
539 |
-
100% {
|
540 |
-
background-color: rgba(0,0,0,0.4);
|
541 |
-
z-index: 1;
|
542 |
-
}
|
543 |
-
}
|
544 |
-
|
545 |
-
|
546 |
-
@keyframes fadeIn {
|
547 |
-
0% {
|
548 |
-
background-color: rgba(0,0,0,0);
|
549 |
-
z-index: 1;
|
550 |
-
}
|
551 |
-
99% {
|
552 |
-
background-color: rgba(0,0,0,0.4);
|
553 |
-
z-index: 1;
|
554 |
-
}
|
555 |
-
100% {
|
556 |
-
background-color: rgba(0,0,0,0.4);
|
557 |
-
z-index: 1;
|
558 |
-
}
|
559 |
-
}
|
560 |
-
|
561 |
-
|
562 |
-
@media screen and (max-width:780px) {
|
563 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
inc/class-cmp-render_html.php
CHANGED
@@ -9,25 +9,6 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
9 |
// Render Background
|
10 |
public function cmp_background( $niteoCS_banner, $themeslug ) {
|
11 |
|
12 |
-
// change to slider, if theme preview specific themes
|
13 |
-
if ( isset($_GET['theme']) && !empty($_GET['theme']) && isset($_GET['background']) && $_GET['background'] == 1 ) {
|
14 |
-
|
15 |
-
$theme = esc_attr( $_GET['theme'] );
|
16 |
-
|
17 |
-
switch ( $theme ) {
|
18 |
-
case 'fifty':
|
19 |
-
case 'stylo':
|
20 |
-
case 'apollo':
|
21 |
-
case 'hardwork_premium':
|
22 |
-
case 'ares':
|
23 |
-
$this->cmp_slider( $theme );
|
24 |
-
return;
|
25 |
-
|
26 |
-
default:
|
27 |
-
break;
|
28 |
-
}
|
29 |
-
}
|
30 |
-
|
31 |
$size = $this->isMobile() ? 'large' : 'full';
|
32 |
$html = '';
|
33 |
|
@@ -36,26 +17,6 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
36 |
$niteoCS_banner = esc_attr( $_GET['background'] );
|
37 |
}
|
38 |
|
39 |
-
// change image background to default media
|
40 |
-
if ( isset( $_GET['background'] ) && $_GET['background'] == 1 ) {
|
41 |
-
$niteoCS_banner = '2';
|
42 |
-
}
|
43 |
-
|
44 |
-
// change image background to default media
|
45 |
-
if ( !isset( $_GET['background'] ) && isset($_GET['theme']) ) {
|
46 |
-
$niteoCS_banner = '2';
|
47 |
-
}
|
48 |
-
|
49 |
-
// pluto specific - change default image to chameleon
|
50 |
-
if ( $themeslug === 'pluto' && $niteoCS_banner === '2' && !isset($_GET['theme']) ) {
|
51 |
-
$niteoCS_banner = '7';
|
52 |
-
}
|
53 |
-
|
54 |
-
// pluto specific theme preview
|
55 |
-
if ( (isset($_GET['theme']) && $_GET['theme'] === 'pluto') && isset( $_GET['background'] ) && $_GET['background'] == '4' ) {
|
56 |
-
$niteoCS_banner = '7';
|
57 |
-
}
|
58 |
-
|
59 |
switch ( $niteoCS_banner ) {
|
60 |
// custom media
|
61 |
case '0':
|
@@ -116,6 +77,7 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
116 |
foreach ( $body as $item ) {
|
117 |
$unsplash_download = $item['links']['download_location'];
|
118 |
}
|
|
|
119 |
} else {
|
120 |
$unsplash_download = $body['links']['download_location'];
|
121 |
}
|
@@ -215,25 +177,6 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
215 |
// Color
|
216 |
$color = get_option('niteoCS_banner_color', '#e5e5e5');
|
217 |
|
218 |
-
// override color settings for theme preview
|
219 |
-
if ( isset($_GET['theme']) && !empty($_GET['theme']) ) {
|
220 |
-
|
221 |
-
$theme = esc_attr( $_GET['theme'] );
|
222 |
-
switch ( $theme ) {
|
223 |
-
case 'mercury':
|
224 |
-
case 'hardwork':
|
225 |
-
case 'hardwork_premium':
|
226 |
-
$color = '#2e4057';
|
227 |
-
break;
|
228 |
-
case 'timex':
|
229 |
-
$color = '#d5416a';
|
230 |
-
break;
|
231 |
-
|
232 |
-
default:
|
233 |
-
break;
|
234 |
-
}
|
235 |
-
}
|
236 |
-
|
237 |
$html ='<div id="background-image" class="color loaded" style="background-color:'.esc_url( $color ).'"></div>';
|
238 |
break;
|
239 |
|
@@ -283,54 +226,18 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
283 |
// render slider
|
284 |
public function cmp_slider( $themeslug ) {
|
285 |
|
286 |
-
// change to background, if theme preview specific themes
|
287 |
-
if ( isset($_GET['background']) && $_GET['background'] !== '1' ) {
|
288 |
-
echo $this->cmp_background( $_GET['background'], $themeslug );
|
289 |
-
return;
|
290 |
-
}
|
291 |
-
|
292 |
$niteoCS_banner = get_option('niteoCS_banner', '1');
|
293 |
$slider_count = get_option('niteoCS_slider_count', '3');
|
294 |
$slider_effect = get_option('niteoCS_slider_effect', 'true');
|
295 |
$slider_autoplay = get_option('niteoCS_slider_auto', '1');
|
296 |
$size = $this->isMobile() ? 'large' : 'full';
|
297 |
$banner_ids = $this->cmp_get_banner_ids();
|
298 |
-
|
299 |
-
|
300 |
-
// change slider images for theme preview
|
301 |
-
if ( isset($_GET['theme']) && !empty($_GET['theme']) ) {
|
302 |
-
$theme = esc_attr( $_GET['theme'] );
|
303 |
-
$slider_autoplay = '1';
|
304 |
-
switch ( $theme ) {
|
305 |
-
case 'fifty':
|
306 |
-
$niteoCS_banner = '0';
|
307 |
-
$slider_effect = 'slice';
|
308 |
-
break;
|
309 |
-
case 'stylo':
|
310 |
-
$niteoCS_banner = '0';
|
311 |
-
$slider_effect = 'true';
|
312 |
-
break;
|
313 |
-
case 'apollo':
|
314 |
-
case 'ares':
|
315 |
-
$niteoCS_banner = '0';
|
316 |
-
$slider_effect = 'mask-transition';
|
317 |
-
break;
|
318 |
-
case 'hardwork_premium':
|
319 |
-
$niteoCS_banner = '0';
|
320 |
-
$slider_effect = 'true';
|
321 |
-
break;
|
322 |
-
default:
|
323 |
-
$slider_effect = 'true';
|
324 |
-
break;
|
325 |
-
}
|
326 |
-
}
|
327 |
|
328 |
// break slider if only one custom image uploaded
|
329 |
if ( $niteoCS_banner == '0' && isset( $banner_ids ) && count( $banner_ids ) < 2 ) {
|
330 |
echo $this->cmp_background( '0', $themeslug ) ;
|
331 |
return false;
|
332 |
-
}
|
333 |
-
?>
|
334 |
|
335 |
<div id="slider-wrapper">
|
336 |
|
@@ -501,35 +408,13 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
501 |
$color = get_option('niteoCS_overlay[color]', '#0a0a0a');
|
502 |
$html = '';
|
503 |
|
504 |
-
// change saved settings for CMP preview
|
505 |
-
if ( isset($_GET['theme']) && !empty($_GET['theme']) ) {
|
506 |
-
$theme = esc_attr( $_GET['theme'] );
|
507 |
-
|
508 |
-
switch ( $theme ) {
|
509 |
-
case 'apollo':
|
510 |
-
case 'element':
|
511 |
-
$overlay = 'solid-color';
|
512 |
-
$opacity = '0.5';
|
513 |
-
$color = '#ffffff';
|
514 |
-
break;
|
515 |
-
|
516 |
-
case 'hardwork_premium':
|
517 |
-
$overlay = 'solid-color';
|
518 |
-
$opacity = '0.3';
|
519 |
-
$color = '#000000';
|
520 |
-
break;
|
521 |
-
default:
|
522 |
-
break;
|
523 |
-
}
|
524 |
-
}
|
525 |
-
|
526 |
switch ( $overlay ) {
|
527 |
case 'solid-color':
|
528 |
$html = '<div class="background-overlay solid-color" style="background-color:'.esc_attr( $color ).';opacity:'.esc_attr( $opacity ).'"></div>';
|
529 |
break;
|
530 |
|
531 |
case 'gradient':
|
532 |
-
$overlay_gradient
|
533 |
|
534 |
if ( $overlay_gradient == 'custom' ) {
|
535 |
$gradient_one = get_option('niteoCS_overlay[gradient_one]', '#e5e5e5');
|
@@ -635,7 +520,6 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
635 |
|
636 |
if ( $social_list != '' ) {
|
637 |
return $html.$social_list.'</ul>';
|
638 |
-
|
639 |
}
|
640 |
}
|
641 |
|
@@ -648,38 +532,6 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
648 |
|
649 |
$logo_type = get_option('niteoCS_logo_type', 'text');
|
650 |
|
651 |
-
if ( isset($_GET['theme']) && !empty($_GET['theme']) ) {
|
652 |
-
$theme = esc_attr( $_GET['theme'] );
|
653 |
-
switch ( $theme ) {
|
654 |
-
case 'construct':
|
655 |
-
case 'hardwork':
|
656 |
-
case 'eclipse':
|
657 |
-
case 'frame':
|
658 |
-
case 'postery':
|
659 |
-
case 'agency':
|
660 |
-
case 'mercury':
|
661 |
-
case 'stylo':
|
662 |
-
case 'countdown':
|
663 |
-
$logo_type = 'text';
|
664 |
-
break;
|
665 |
-
|
666 |
-
case 'hardwork_premium':
|
667 |
-
case 'fifty':
|
668 |
-
case 'element':
|
669 |
-
case 'pluto':
|
670 |
-
case 'juno':
|
671 |
-
case 'apollo':
|
672 |
-
case 'ares':
|
673 |
-
case 'timex':
|
674 |
-
$logo_type = 'graphic';
|
675 |
-
break;
|
676 |
-
|
677 |
-
default:
|
678 |
-
$logo_type = 'disabled';
|
679 |
-
break;
|
680 |
-
}
|
681 |
-
}
|
682 |
-
|
683 |
$html = '';
|
684 |
$class = ( $class != '' ) ? ' ' . $class : $class;
|
685 |
|
@@ -688,37 +540,6 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
688 |
// get logo id
|
689 |
$logo_id = get_option('niteoCS_logo_id');
|
690 |
|
691 |
-
if ( isset($_GET['theme']) && !empty($_GET['theme']) ) {
|
692 |
-
$theme = esc_attr( $_GET['theme'] );
|
693 |
-
switch ( $theme ) {
|
694 |
-
case 'fifty':
|
695 |
-
$logo_id = '33';
|
696 |
-
break;
|
697 |
-
|
698 |
-
case 'juno':
|
699 |
-
$logo_id = '72';
|
700 |
-
break;
|
701 |
-
|
702 |
-
case 'hardwork_premium':
|
703 |
-
$logo_id = '15';
|
704 |
-
break;
|
705 |
-
|
706 |
-
case 'pluto':
|
707 |
-
$logo_id = '17';
|
708 |
-
break;
|
709 |
-
|
710 |
-
case 'ares':
|
711 |
-
$logo_id = '101';
|
712 |
-
break;
|
713 |
-
|
714 |
-
case 'timex':
|
715 |
-
$logo_id = '104';
|
716 |
-
break;
|
717 |
-
|
718 |
-
default:
|
719 |
-
break;
|
720 |
-
}
|
721 |
-
}
|
722 |
// get logo
|
723 |
if ( $logo_id != '' ) {
|
724 |
$logo_url = wp_get_attachment_image_src( $logo_id, 'full' );
|
@@ -731,17 +552,7 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
731 |
|
732 |
case 'text':
|
733 |
$text_logo = stripslashes(get_option('niteoCS_text_logo', get_bloginfo( 'name', 'display' )));
|
734 |
-
if ( isset($_GET['theme']) && !empty($_GET['theme']) ) {
|
735 |
-
$theme = esc_attr( $_GET['theme'] );
|
736 |
-
switch ( $theme ) {
|
737 |
-
case 'mercury':
|
738 |
-
$text_logo = 'NITEOTHEMES';
|
739 |
-
break;
|
740 |
|
741 |
-
default:
|
742 |
-
break;
|
743 |
-
}
|
744 |
-
}
|
745 |
$html = '<div class="logo-wrapper text text-logo-wrapper' . esc_attr( $class ) . '"><a href="'. esc_url( get_site_url() ) .'" style="text-decoration:none;color:inherit"><h1 class="text-logo">'.esc_html( $text_logo ).'</h1></a></div>';
|
746 |
break;
|
747 |
|
@@ -762,7 +573,7 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
762 |
$html = '';
|
763 |
|
764 |
// get current theme
|
765 |
-
$theme =
|
766 |
|
767 |
// get type of susbscribe
|
768 |
$subscribe = get_option('niteoCS_subscribe_type', '2');
|
@@ -785,48 +596,21 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
785 |
$placeholder_lastname = isset($translation[11]['translation']) ? stripslashes( $translation[11]['translation'] ) : 'Last Name';
|
786 |
$submit = isset($translation[8]['translation']) ? stripslashes( $translation[8]['translation'] ) : 'Submit';
|
787 |
|
788 |
-
// override label if in Theme preview
|
789 |
-
if ( isset( $_GET['theme'] ) ) {
|
790 |
-
switch ( $_GET['theme'] ) {
|
791 |
-
case 'apollo':
|
792 |
-
$niteoCS_subscribe_label = 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.';
|
793 |
-
break;
|
794 |
-
case 'element':
|
795 |
-
$placeholder = 'SUBSCRIBE US';
|
796 |
-
$niteoCS_subscribe_label = 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.';
|
797 |
-
break;
|
798 |
-
case 'hardwork_premium':
|
799 |
-
$submit = 'Subscribe';
|
800 |
-
$niteoCS_subscribe_label = 'Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.';
|
801 |
-
break;
|
802 |
-
case 'agency':
|
803 |
-
$niteoCS_subscribe_label = 'Lorem Ipsum is simply dummy text of the printing and typesetting industry.';
|
804 |
-
break;
|
805 |
-
case 'mercury':
|
806 |
-
case 'juno':
|
807 |
-
case 'ares':
|
808 |
-
$niteoCS_subscribe_label = 'Yes, take me there. We HATE spam!';
|
809 |
-
break;
|
810 |
-
default:
|
811 |
-
break;
|
812 |
-
}
|
813 |
-
|
814 |
-
}
|
815 |
// overwrite it with theme specific requirements
|
816 |
-
if (
|
817 |
$placeholder = ' ' . $placeholder;
|
818 |
$placeholder_firstname = ' ' . $placeholder_firstname;
|
819 |
$placeholder_lastname = ' ' . $placeholder_lastname;
|
820 |
}
|
821 |
|
822 |
// overwrite it with theme specific requirements
|
823 |
-
if (
|
824 |
$placeholder = ' ' . $placeholder;
|
825 |
}
|
826 |
|
827 |
-
$submit = (
|
828 |
-
$submit = (
|
829 |
-
$submit = (
|
830 |
|
831 |
?>
|
832 |
|
@@ -879,7 +663,7 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
879 |
break;
|
880 |
}
|
881 |
|
882 |
-
if (
|
883 |
<button type="submit" id="submit-subscribe" value="<?php echo esc_attr( $submit );?>"><?php echo esc_attr( $submit );?></button>
|
884 |
<?php
|
885 |
} else { ?>
|
@@ -995,64 +779,11 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
995 |
* @return HTML
|
996 |
**/
|
997 |
public function cmp_get_body() {
|
998 |
-
if ( isset($_GET['theme']) && !empty($_GET['theme']) ) {
|
999 |
-
$theme_preview = esc_attr($_GET['theme']);
|
1000 |
-
|
1001 |
-
switch ( $theme_preview ) {
|
1002 |
-
case 'hardwork':
|
1003 |
-
case 'hardwork_premium':
|
1004 |
-
$body = '<p>Everti labores cu sea, ea eam choro semper, usu an quot vocibus euripidis. An vis porro insolens, ea graeci vulputate qui. Qui vidisse evertitur et, ea vis habemus fabellas. Everti labores cu sea, ea eam choro semper, usu an quot vocibus euripidis. An vis porro insolens, ea graeci vulputate qui. Qui vidisse evertitur et, ea vis habemus fabellas.</p>';
|
1005 |
-
break;
|
1006 |
-
|
1007 |
-
case 'eclipse':
|
1008 |
-
case 'apollo':
|
1009 |
-
case 'vega':
|
1010 |
-
case 'mercury':
|
1011 |
-
$body = '<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Tincidunt augue interdum velit euismod in pellentesque massa placerat.</p>';
|
1012 |
-
break;
|
1013 |
|
1014 |
-
|
1015 |
-
$body = '<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Nulla posuere sollicitudin aliquam ultrices sagittis.</p>';
|
1016 |
-
break;
|
1017 |
-
|
1018 |
-
case 'frame':
|
1019 |
-
$body = '<p>Stay tuned for new features!</p>';
|
1020 |
-
break;
|
1021 |
|
1022 |
-
|
1023 |
-
|
1024 |
-
break;
|
1025 |
-
|
1026 |
-
case 'fifty':
|
1027 |
-
case 'element':
|
1028 |
-
case 'ares':
|
1029 |
-
$body = '<p>Everti labores cu sea, ea eam choro semper, usu an quot vocibus euripidis. An vis porro insolens, ea graeci vulputate qui. Qui vidisse evertitur et, ea vis habemus fabellas.</p>';
|
1030 |
-
break;
|
1031 |
-
|
1032 |
-
case 'stylo':
|
1033 |
-
$body = '<p>You can use <a href="https://niteothemes.com/projects/cmp-stylo-theme/">Stylo</a> as a landing page, maintenance or coming soon page. It supports both subscriber and contact form, all CMP background options and big beautiful counter.</p>';
|
1034 |
-
break;
|
1035 |
-
|
1036 |
-
case 'agency':
|
1037 |
-
case 'pluto':
|
1038 |
-
$body = '<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ipsum a arcu cursus vitae congue mauris. Eros in cursus turpis massa tincidunt.</p>';
|
1039 |
-
break;
|
1040 |
-
|
1041 |
-
case 'timex':
|
1042 |
-
$body = '<p>Never lose touch with your fans, clients, even when you are in the process of creating new websites or maintenance. Enjoy!</p>';
|
1043 |
-
break;
|
1044 |
-
|
1045 |
-
default:
|
1046 |
-
$body = wpautop( stripslashes( get_option('niteoCS_body', '') ) );
|
1047 |
-
break;
|
1048 |
-
}
|
1049 |
-
|
1050 |
-
} else {
|
1051 |
-
$body = stripslashes( get_option('niteoCS_body', '') );
|
1052 |
-
|
1053 |
-
if ( isset($GLOBALS['wp_embed']) ) {
|
1054 |
-
$body = $GLOBALS['wp_embed']->autoembed( $body );
|
1055 |
-
}
|
1056 |
}
|
1057 |
|
1058 |
$body = wpautop( do_shortcode( $body ) );
|
@@ -1068,71 +799,8 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
1068 |
**/
|
1069 |
public function cmp_get_title( $class = '' ) {
|
1070 |
global $allowedposttags;
|
1071 |
-
$title = stripslashes( get_option('niteoCS_body_title', 'SOMETHING IS HAPPENING!') );
|
1072 |
-
|
1073 |
-
// rewrite title if required for theme preview
|
1074 |
-
if ( isset($_GET['theme']) && !empty($_GET['theme']) ) {
|
1075 |
-
$themeslug = esc_attr( $_GET['theme'] );
|
1076 |
-
|
1077 |
-
switch ( $themeslug ) {
|
1078 |
-
case 'hardwork':
|
1079 |
-
case 'hardwork_premium':
|
1080 |
-
case 'fifty':
|
1081 |
-
$title = 'We will be back soon!';
|
1082 |
-
break;
|
1083 |
-
case 'countdown':
|
1084 |
-
case 'frame':
|
1085 |
-
$title = 'NEW WEBSITE WILL BE ONLINE SOON!';
|
1086 |
-
break;
|
1087 |
-
|
1088 |
-
case 'eclipse':
|
1089 |
-
$title = 'CMP Theme for our <a href="https://wordpress.org/plugins/cmp-coming-soon-maintenance/" target="_blank">Coming Soon WordPress plugin.</a>';
|
1090 |
-
break;
|
1091 |
-
|
1092 |
-
case 'orbit':
|
1093 |
-
$title = 'WE ARE IN ORBIT ! STAY TUNED ...';
|
1094 |
-
break;
|
1095 |
-
|
1096 |
-
case 'stylo':
|
1097 |
-
$title = 'Something Awesome is Coming!';
|
1098 |
-
break;
|
1099 |
-
|
1100 |
-
case 'element':
|
1101 |
-
$title = 'Coming Soon';
|
1102 |
-
break;
|
1103 |
-
|
1104 |
-
case 'apollo':
|
1105 |
-
$title = 'UNDER CONSTRUCTION!';
|
1106 |
-
break;
|
1107 |
|
1108 |
-
|
1109 |
-
$title = 'NITEOTHEMES IS *COMING SOON!*';
|
1110 |
-
break;
|
1111 |
-
|
1112 |
-
case 'agency':
|
1113 |
-
$title = 'NEW WEBSITE ON THE WAY!';
|
1114 |
-
break;
|
1115 |
-
|
1116 |
-
case 'mercury':
|
1117 |
-
$title = 'NEW COLLECTION ON THE WAY!';
|
1118 |
-
break;
|
1119 |
-
|
1120 |
-
case 'mercury':
|
1121 |
-
$title = 'WE WILL BE ONINE AS SOON AS POSSIBLE!';
|
1122 |
-
break;
|
1123 |
-
|
1124 |
-
case 'ares':
|
1125 |
-
$title = '';
|
1126 |
-
break;
|
1127 |
-
case 'timex':
|
1128 |
-
$title = 'This is TimeX by NiteoThemes';
|
1129 |
-
break;
|
1130 |
-
|
1131 |
-
default:
|
1132 |
-
break;
|
1133 |
-
}
|
1134 |
-
|
1135 |
-
}
|
1136 |
|
1137 |
// wrap text between stars in title in span for future formatting
|
1138 |
$title_array = explode('*', $title);
|
@@ -1250,7 +918,6 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
1250 |
$ext = pathinfo($url, PATHINFO_EXTENSION);
|
1251 |
$new_src = '';
|
1252 |
|
1253 |
-
|
1254 |
switch ($ext) {
|
1255 |
case 'eot':
|
1256 |
$eot = 'src: url("'.esc_url($url).'");' . PHP_EOL;
|
@@ -1530,7 +1197,7 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
1530 |
// theme stylesheet
|
1531 |
echo '<link rel="stylesheet" href="' . $this->cmp_themeURL( $themeslug ) . $themeslug.'/style.css?v='.$ver . '" type="text/css" media="all">' . PHP_EOL;
|
1532 |
|
1533 |
-
if ( $font_ani !== false ) {
|
1534 |
echo '<link rel="stylesheet" href="'. esc_url( $this->cmp_asset_url('/css/animate.min.css') ) . '">' . PHP_EOL;
|
1535 |
}
|
1536 |
|
@@ -1604,7 +1271,6 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
1604 |
$niteoCS_analytics_other = get_option('niteoCS_analytics_other', ''); ?>
|
1605 |
<script>
|
1606 |
<?php echo stripslashes( esc_js( $niteoCS_analytics_other ) );?>
|
1607 |
-
|
1608 |
</script>
|
1609 |
<?php
|
1610 |
}
|
@@ -1755,44 +1421,11 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
1755 |
case '0':
|
1756 |
case '1':
|
1757 |
$slider = get_option('niteoCS_slider', '0');
|
1758 |
-
|
1759 |
-
if ( isset($_GET['theme']) && !empty($_GET['theme']) && isset($_GET['background']) && $_GET['background'] == 1 ) {
|
1760 |
-
|
1761 |
-
$theme = esc_attr( $_GET['theme'] );
|
1762 |
-
switch ( $theme ) {
|
1763 |
-
case 'fifty':
|
1764 |
-
case 'stylo':
|
1765 |
-
case 'apollo':
|
1766 |
-
case 'hardwork_premium':
|
1767 |
-
case 'ares':
|
1768 |
-
$slider = '1';
|
1769 |
-
break;
|
1770 |
-
default:
|
1771 |
-
break;
|
1772 |
-
}
|
1773 |
-
}
|
1774 |
if ( $slider == '1' ) {
|
1775 |
$slider_effect = get_option('niteoCS_slider_effect', 'true');
|
1776 |
$slider_autoplay = get_option('niteoCS_slider_auto', '1');
|
1777 |
|
1778 |
-
// change slider images for theme preview
|
1779 |
-
if ( isset($_GET['theme']) && !empty($_GET['theme']) ) {
|
1780 |
-
$theme = esc_attr( $_GET['theme'] );
|
1781 |
-
$slider_autoplay = '1';
|
1782 |
-
switch ( $theme ) {
|
1783 |
-
case 'fifty':
|
1784 |
-
$slider_effect = 'slice';
|
1785 |
-
break;
|
1786 |
-
case 'apollo':
|
1787 |
-
case 'ares':
|
1788 |
-
$slider_effect = 'mask-transition';
|
1789 |
-
break;
|
1790 |
-
default:
|
1791 |
-
$slider_effect = 'true';
|
1792 |
-
break;
|
1793 |
-
}
|
1794 |
-
}
|
1795 |
-
|
1796 |
switch ( $slider_effect ) {
|
1797 |
// slice effect scripts
|
1798 |
case 'slice':
|
@@ -2076,30 +1709,6 @@ class CMP_Coming_Soon_and_Maintenance_Render_HTML extends CMP_Coming_Soon_and_Ma
|
|
2076 |
$banner_ids = explode(',', $banner_id);
|
2077 |
}
|
2078 |
|
2079 |
-
if ( isset($_GET['theme']) && !empty($_GET['theme']) ) {
|
2080 |
-
$theme = esc_attr( $_GET['theme'] );
|
2081 |
-
switch ( $theme ) {
|
2082 |
-
case 'fifty':
|
2083 |
-
$banner_ids = array(21, 22, 23);
|
2084 |
-
break;
|
2085 |
-
case 'stylo':
|
2086 |
-
$banner_ids = array(28, 29, 30, 31, 32);
|
2087 |
-
break;
|
2088 |
-
case 'apollo':
|
2089 |
-
$banner_ids = array(35, 36, 37);
|
2090 |
-
break;
|
2091 |
-
case 'hardwork_premium':
|
2092 |
-
$banner_ids = array(63, 64, 65);
|
2093 |
-
break;
|
2094 |
-
case 'ares':
|
2095 |
-
$banner_ids = array(98, 99, 100);
|
2096 |
-
break;
|
2097 |
-
default:
|
2098 |
-
break;
|
2099 |
-
}
|
2100 |
-
}
|
2101 |
return $banner_ids;
|
2102 |
}
|
2103 |
-
|
2104 |
-
|
2105 |
}
|
9 |
// Render Background
|
10 |
public function cmp_background( $niteoCS_banner, $themeslug ) {
|
11 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
12 |
$size = $this->isMobile() ? 'large' : 'full';
|
13 |
$html = '';
|
14 |
|
17 |
$niteoCS_banner = esc_attr( $_GET['background'] );
|
18 |
}
|
19 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
20 |
switch ( $niteoCS_banner ) {
|
21 |
// custom media
|
22 |
case '0':
|
77 |
foreach ( $body as $item ) {
|
78 |
$unsplash_download = $item['links']['download_location'];
|
79 |
}
|
80 |
+
|
81 |
} else {
|
82 |
$unsplash_download = $body['links']['download_location'];
|
83 |
}
|
177 |
// Color
|
178 |
$color = get_option('niteoCS_banner_color', '#e5e5e5');
|
179 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
180 |
$html ='<div id="background-image" class="color loaded" style="background-color:'.esc_url( $color ).'"></div>';
|
181 |
break;
|
182 |
|
226 |
// render slider
|
227 |
public function cmp_slider( $themeslug ) {
|
228 |
|
|
|
|
|
|
|
|
|
|
|
|
|
229 |
$niteoCS_banner = get_option('niteoCS_banner', '1');
|
230 |
$slider_count = get_option('niteoCS_slider_count', '3');
|
231 |
$slider_effect = get_option('niteoCS_slider_effect', 'true');
|
232 |
$slider_autoplay = get_option('niteoCS_slider_auto', '1');
|
233 |
$size = $this->isMobile() ? 'large' : 'full';
|
234 |
$banner_ids = $this->cmp_get_banner_ids();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
235 |
|
236 |
// break slider if only one custom image uploaded
|
237 |
if ( $niteoCS_banner == '0' && isset( $banner_ids ) && count( $banner_ids ) < 2 ) {
|
238 |
echo $this->cmp_background( '0', $themeslug ) ;
|
239 |
return false;
|
240 |
+
} ?>
|
|
|
241 |
|
242 |
<div id="slider-wrapper">
|
243 |
|
408 |
$color = get_option('niteoCS_overlay[color]', '#0a0a0a');
|
409 |
$html = '';
|
410 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
411 |
switch ( $overlay ) {
|
412 |
case 'solid-color':
|
413 |
$html = '<div class="background-overlay solid-color" style="background-color:'.esc_attr( $color ).';opacity:'.esc_attr( $opacity ).'"></div>';
|
414 |
break;
|
415 |
|
416 |
case 'gradient':
|
417 |
+
$overlay_gradient = get_option('niteoCS_overlay[gradient]', '#d53369:#cbad6d');
|
418 |
|
419 |
if ( $overlay_gradient == 'custom' ) {
|
420 |
$gradient_one = get_option('niteoCS_overlay[gradient_one]', '#e5e5e5');
|
520 |
|
521 |
if ( $social_list != '' ) {
|
522 |
return $html.$social_list.'</ul>';
|
|
|
523 |
}
|
524 |
}
|
525 |
|
532 |
|
533 |
$logo_type = get_option('niteoCS_logo_type', 'text');
|
534 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
535 |
$html = '';
|
536 |
$class = ( $class != '' ) ? ' ' . $class : $class;
|
537 |
|
540 |
// get logo id
|
541 |
$logo_id = get_option('niteoCS_logo_id');
|
542 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
543 |
// get logo
|
544 |
if ( $logo_id != '' ) {
|
545 |
$logo_url = wp_get_attachment_image_src( $logo_id, 'full' );
|
552 |
|
553 |
case 'text':
|
554 |
$text_logo = stripslashes(get_option('niteoCS_text_logo', get_bloginfo( 'name', 'display' )));
|
|
|
|
|
|
|
|
|
|
|
|
|
555 |
|
|
|
|
|
|
|
|
|
556 |
$html = '<div class="logo-wrapper text text-logo-wrapper' . esc_attr( $class ) . '"><a href="'. esc_url( get_site_url() ) .'" style="text-decoration:none;color:inherit"><h1 class="text-logo">'.esc_html( $text_logo ).'</h1></a></div>';
|
557 |
break;
|
558 |
|
573 |
$html = '';
|
574 |
|
575 |
// get current theme
|
576 |
+
$theme = $this->cmp_selectedTheme();
|
577 |
|
578 |
// get type of susbscribe
|
579 |
$subscribe = get_option('niteoCS_subscribe_type', '2');
|
596 |
$placeholder_lastname = isset($translation[11]['translation']) ? stripslashes( $translation[11]['translation'] ) : 'Last Name';
|
597 |
$submit = isset($translation[8]['translation']) ? stripslashes( $translation[8]['translation'] ) : 'Submit';
|
598 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
599 |
// overwrite it with theme specific requirements
|
600 |
+
if ( $this->cmp_selectedTheme() == 'stylo' ) {
|
601 |
$placeholder = ' ' . $placeholder;
|
602 |
$placeholder_firstname = ' ' . $placeholder_firstname;
|
603 |
$placeholder_lastname = ' ' . $placeholder_lastname;
|
604 |
}
|
605 |
|
606 |
// overwrite it with theme specific requirements
|
607 |
+
if ( $this->cmp_selectedTheme() == 'pluto' ) {
|
608 |
$placeholder = ' ' . $placeholder;
|
609 |
}
|
610 |
|
611 |
+
$submit = ( $this->cmp_selectedTheme() == 'postery' ) ? '' : $submit;
|
612 |
+
$submit = ( $this->cmp_selectedTheme() == 'juno' ) ? '' : $submit;
|
613 |
+
$submit = ( $this->cmp_selectedTheme() == 'agency' ) ? '' : $submit;
|
614 |
|
615 |
?>
|
616 |
|
663 |
break;
|
664 |
}
|
665 |
|
666 |
+
if ( $this->cmp_selectedTheme() == 'mercury' ) { ?>
|
667 |
<button type="submit" id="submit-subscribe" value="<?php echo esc_attr( $submit );?>"><?php echo esc_attr( $submit );?></button>
|
668 |
<?php
|
669 |
} else { ?>
|
779 |
* @return HTML
|
780 |
**/
|
781 |
public function cmp_get_body() {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
782 |
|
783 |
+
$body = stripslashes( get_option('niteoCS_body', '') );
|
|
|
|
|
|
|
|
|
|
|
|
|
784 |
|
785 |
+
if ( isset($GLOBALS['wp_embed']) ) {
|
786 |
+
$body = $GLOBALS['wp_embed']->autoembed( $body );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
787 |
}
|
788 |
|
789 |
$body = wpautop( do_shortcode( $body ) );
|
799 |
**/
|
800 |
public function cmp_get_title( $class = '' ) {
|
801 |
global $allowedposttags;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
802 |
|
803 |
+
$title = stripslashes( get_option('niteoCS_body_title', 'SOMETHING IS HAPPENING!') );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
804 |
|
805 |
// wrap text between stars in title in span for future formatting
|
806 |
$title_array = explode('*', $title);
|
918 |
$ext = pathinfo($url, PATHINFO_EXTENSION);
|
919 |
$new_src = '';
|
920 |
|
|
|
921 |
switch ($ext) {
|
922 |
case 'eot':
|
923 |
$eot = 'src: url("'.esc_url($url).'");' . PHP_EOL;
|
1197 |
// theme stylesheet
|
1198 |
echo '<link rel="stylesheet" href="' . $this->cmp_themeURL( $themeslug ) . $themeslug.'/style.css?v='.$ver . '" type="text/css" media="all">' . PHP_EOL;
|
1199 |
|
1200 |
+
if ( $font_ani !== false || $font_ani !== 'none' ) {
|
1201 |
echo '<link rel="stylesheet" href="'. esc_url( $this->cmp_asset_url('/css/animate.min.css') ) . '">' . PHP_EOL;
|
1202 |
}
|
1203 |
|
1271 |
$niteoCS_analytics_other = get_option('niteoCS_analytics_other', ''); ?>
|
1272 |
<script>
|
1273 |
<?php echo stripslashes( esc_js( $niteoCS_analytics_other ) );?>
|
|
|
1274 |
</script>
|
1275 |
<?php
|
1276 |
}
|
1421 |
case '0':
|
1422 |
case '1':
|
1423 |
$slider = get_option('niteoCS_slider', '0');
|
1424 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1425 |
if ( $slider == '1' ) {
|
1426 |
$slider_effect = get_option('niteoCS_slider_effect', 'true');
|
1427 |
$slider_autoplay = get_option('niteoCS_slider_auto', '1');
|
1428 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1429 |
switch ( $slider_effect ) {
|
1430 |
// slice effect scripts
|
1431 |
case 'slice':
|
1709 |
$banner_ids = explode(',', $banner_id);
|
1710 |
}
|
1711 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1712 |
return $banner_ids;
|
1713 |
}
|
|
|
|
|
1714 |
}
|
js/preview-iframe.js
DELETED
@@ -1,260 +0,0 @@
|
|
1 |
-
|
2 |
-
$( document ).ready(function() {
|
3 |
-
var autoslide;
|
4 |
-
if ( typeof ga === 'undefined' ) {
|
5 |
-
ga = function() {
|
6 |
-
return false;
|
7 |
-
}
|
8 |
-
}
|
9 |
-
|
10 |
-
var defaultBackground = {
|
11 |
-
"construct" : '1',
|
12 |
-
"countdown" : '6',
|
13 |
-
"hardwork" : '1',
|
14 |
-
"agency" : '1',
|
15 |
-
"apollo" : '1',
|
16 |
-
"eclipse" : '1',
|
17 |
-
"element" : '1',
|
18 |
-
"fifty" : '1',
|
19 |
-
"frame" : '1',
|
20 |
-
"hardwork_premium" : '1',
|
21 |
-
"mercury" : '1',
|
22 |
-
"orbit" : '1',
|
23 |
-
"postery" : '1',
|
24 |
-
"stylo" : '1',
|
25 |
-
"vega" : '1',
|
26 |
-
"juno" : '1',
|
27 |
-
"pluto" : '4',
|
28 |
-
"ares" : '1',
|
29 |
-
"timex" : '1'
|
30 |
-
}
|
31 |
-
|
32 |
-
slider(defaultBackground);
|
33 |
-
|
34 |
-
$('iframe').one('load', function() {
|
35 |
-
$('body').addClass('loaded');
|
36 |
-
});
|
37 |
-
|
38 |
-
$('iframe').on('load', function() {
|
39 |
-
// resizeIframe(this);
|
40 |
-
$(this).addClass('loaded');
|
41 |
-
});
|
42 |
-
|
43 |
-
$('.panel-wrapper').click(function(e){
|
44 |
-
e.preventDefault();
|
45 |
-
ga('send', 'event', 'Close or Open Selector', 'Close or Open Selector');
|
46 |
-
$('body').toggleClass('open');
|
47 |
-
});
|
48 |
-
|
49 |
-
|
50 |
-
$('.theme-customizer a').click(function(e){
|
51 |
-
e.preventDefault();
|
52 |
-
var new_url = $(this).attr('href');
|
53 |
-
iframe_url = new_url.replace('&selector=true', '');
|
54 |
-
|
55 |
-
var param = $(this).data('param');
|
56 |
-
var old_value = getUrlParameter(param);
|
57 |
-
var new_value = $(this).data(param);
|
58 |
-
|
59 |
-
$('#theme-preview').removeClass('loaded');
|
60 |
-
|
61 |
-
$(this).siblings().removeClass('selected');
|
62 |
-
$(this).addClass('selected');
|
63 |
-
|
64 |
-
ga('send', 'event', 'Change ' + param, 'Change '+ param +' to: ' + new_value);
|
65 |
-
|
66 |
-
// // reload iframe and change browser URL history
|
67 |
-
$('#theme-preview').attr('src', iframe_url);
|
68 |
-
|
69 |
-
ChangeUrl(new_url, new_url);
|
70 |
-
|
71 |
-
// change customizers href src to new params
|
72 |
-
$('.settings-section:not(.'+ param +') a').each(function(){
|
73 |
-
var old_href = $(this).attr('href');
|
74 |
-
if ( param != '' ) {
|
75 |
-
var new_href = old_href.replace( param + '=' + old_value, param + '=' + new_value );
|
76 |
-
} else {
|
77 |
-
var new_href = old_href + '&'+ param + '=' + new_value;
|
78 |
-
}
|
79 |
-
$(this).attr('href', new_href)
|
80 |
-
});
|
81 |
-
|
82 |
-
});
|
83 |
-
|
84 |
-
function resizeIframe(obj) {
|
85 |
-
obj.style.height = 0;
|
86 |
-
obj.style.height = obj.contentWindow.document.body.scrollHeight + 'px';
|
87 |
-
}
|
88 |
-
|
89 |
-
function ChangeUrl(page, url) {
|
90 |
-
if (typeof (window.parent.history.pushState) != "undefined") {
|
91 |
-
var obj = { Page: page, Url: url };
|
92 |
-
window.parent.history.pushState(obj, obj.Page, obj.Url);
|
93 |
-
} else {
|
94 |
-
return;
|
95 |
-
}
|
96 |
-
}
|
97 |
-
|
98 |
-
function slider(defaultBackground) {
|
99 |
-
var slideCount = $('#slider ul li').length;
|
100 |
-
var slideWidth = $('#slider ul li').width();
|
101 |
-
var slideHeight = 200;
|
102 |
-
var sliderUlWidth = slideCount * slideWidth;
|
103 |
-
|
104 |
-
$('#slider').css({ width: slideWidth, height: slideHeight });
|
105 |
-
|
106 |
-
$('#slider ul').css({ width: sliderUlWidth, marginLeft: - slideWidth });
|
107 |
-
|
108 |
-
$('#slider ul li:last-child').prependTo('#slider ul');
|
109 |
-
|
110 |
-
function moveLeft() {
|
111 |
-
$('#slider ul').animate({
|
112 |
-
left: + slideWidth
|
113 |
-
}, 200, function () {
|
114 |
-
$('#slider ul li:last-child').prependTo('#slider ul');
|
115 |
-
$('#slider ul').css('left', '');
|
116 |
-
changeSlide();
|
117 |
-
});
|
118 |
-
};
|
119 |
-
|
120 |
-
function moveRight() {
|
121 |
-
$('#slider ul').animate({
|
122 |
-
left: - slideWidth
|
123 |
-
}, 200, function () {
|
124 |
-
$('#slider ul li:first-child').appendTo('#slider ul');
|
125 |
-
$('#slider ul').css('left', '');
|
126 |
-
changeSlide();
|
127 |
-
});
|
128 |
-
};
|
129 |
-
|
130 |
-
function changeSlide() {
|
131 |
-
var title = $('#slider ul li:nth-child(2)').data('title');
|
132 |
-
var position = $('#slider ul li:nth-child(2)').data('position');
|
133 |
-
var slug = $('#slider ul li:nth-child(2)').data('slug');
|
134 |
-
var currentSubmitUrl = $('#submit-change').attr('href');
|
135 |
-
var currentSlug = getUrlStringParameter('theme', currentSubmitUrl);
|
136 |
-
var currentBckgr = getUrlStringParameter('background', currentSubmitUrl);
|
137 |
-
var newSubmitUrl = '';
|
138 |
-
|
139 |
-
$('.theme-title').text(title);
|
140 |
-
$('.theme-count').text(position);
|
141 |
-
|
142 |
-
newSubmitUrl = currentSubmitUrl.replace('theme=' + currentSlug, 'theme=' + slug);
|
143 |
-
newSubmitUrl = newSubmitUrl.replace('background=' + currentBckgr, 'background=' + defaultBackground[slug]);
|
144 |
-
|
145 |
-
// change submit button theme attr in href
|
146 |
-
$('#submit-change').attr('href', newSubmitUrl);
|
147 |
-
}
|
148 |
-
|
149 |
-
$('a.control_prev').click(function (e) {
|
150 |
-
e.preventDefault();
|
151 |
-
moveLeft();
|
152 |
-
clearTimeout(autoslide);
|
153 |
-
});
|
154 |
-
|
155 |
-
$('a.control_next').click(function (e) {
|
156 |
-
e.preventDefault();
|
157 |
-
moveRight();
|
158 |
-
clearTimeout(autoslide);
|
159 |
-
});
|
160 |
-
|
161 |
-
autoslide = setInterval(function () {
|
162 |
-
moveRight();
|
163 |
-
}, 7000);
|
164 |
-
}
|
165 |
-
|
166 |
-
$('#submit-change').click(function (e) {
|
167 |
-
e.preventDefault();
|
168 |
-
var newUrl = $(this).attr('href');
|
169 |
-
var newSlug = getUrlStringParameter('theme', newUrl);
|
170 |
-
var newBckgr = getUrlStringParameter('background', newUrl);
|
171 |
-
var premiumThemes = $('.buy-theme').data('premium');
|
172 |
-
var customize = $(this).data('customize');
|
173 |
-
clearTimeout(autoslide);
|
174 |
-
// get buy url
|
175 |
-
for (var i = 0, len = premiumThemes.length; i < len; i++) {
|
176 |
-
if ( premiumThemes[i].name === newSlug) {
|
177 |
-
var buyUrl = premiumThemes[i].url;
|
178 |
-
break;
|
179 |
-
}
|
180 |
-
}
|
181 |
-
|
182 |
-
// get customize sections supported
|
183 |
-
for (var i = 0, len = customize.length; i < len; i++) {
|
184 |
-
if ( customize[i].theme === newSlug) {
|
185 |
-
var section = customize[i].section;
|
186 |
-
break;
|
187 |
-
}
|
188 |
-
}
|
189 |
-
|
190 |
-
$('.settings-section').removeClass('zoomIn').addClass('zoomOut');
|
191 |
-
|
192 |
-
$.each(section, function( index, value ) {
|
193 |
-
$('.settings-section.' + value ).removeClass('zoomOut').removeClass('not-active').addClass('zoomIn');
|
194 |
-
|
195 |
-
});
|
196 |
-
|
197 |
-
// change browser url history
|
198 |
-
ChangeUrl(newUrl, newUrl);
|
199 |
-
|
200 |
-
// change customizers href src to new theme
|
201 |
-
$('.settings-section a').each(function(){
|
202 |
-
const oldUrl = $(this).attr('href');
|
203 |
-
const currentSlug = getUrlStringParameter('theme', oldUrl);
|
204 |
-
const new_href = oldUrl.replace( 'theme=' + currentSlug, 'theme=' + newSlug );
|
205 |
-
$(this).attr('href', new_href);
|
206 |
-
});
|
207 |
-
|
208 |
-
$('.settings-section.effect a').each(function(){
|
209 |
-
const oldUrl = $(this).attr('href');
|
210 |
-
const currentBckgr = getUrlStringParameter('background', oldUrl);
|
211 |
-
const new_href = oldUrl.replace( 'background=' + currentBckgr, 'background=' + newBckgr );
|
212 |
-
$(this).attr('href', new_href);
|
213 |
-
});
|
214 |
-
|
215 |
-
// change select preview button url
|
216 |
-
$('#theme-preview').attr('src', $(this).attr('href').replace('&selector=true', ''));
|
217 |
-
|
218 |
-
$('.settings-section.background a').removeClass('selected');
|
219 |
-
|
220 |
-
$('.settings-section.background a[data-background="'+ defaultBackground[newSlug] +'"]').addClass('selected');
|
221 |
-
|
222 |
-
$('.buy-theme').attr('href', buyUrl);
|
223 |
-
|
224 |
-
ga('send', 'event', 'Change Theme', 'Change Theme to: ' + newSlug);
|
225 |
-
});
|
226 |
-
|
227 |
-
|
228 |
-
var getUrlParameter = function getUrlParameter(sParam) {
|
229 |
-
var sPageURL = window.location.search.substring(1),
|
230 |
-
sURLVariables = sPageURL.split('&'),
|
231 |
-
sParameterName,
|
232 |
-
i;
|
233 |
-
|
234 |
-
for (i = 0; i < sURLVariables.length; i++) {
|
235 |
-
sParameterName = sURLVariables[i].split('=');
|
236 |
-
|
237 |
-
if (sParameterName[0] === sParam) {
|
238 |
-
return sParameterName[1] === undefined ? true : decodeURIComponent(sParameterName[1]);
|
239 |
-
}
|
240 |
-
}
|
241 |
-
};
|
242 |
-
|
243 |
-
var getUrlStringParameter = function getUrlStringParameter(sParam, urlString) {
|
244 |
-
var sPageURL = urlString.substring(1),
|
245 |
-
sURLVariables = sPageURL.split('&'),
|
246 |
-
sParameterName,
|
247 |
-
i;
|
248 |
-
|
249 |
-
for (i = 0; i < sURLVariables.length; i++) {
|
250 |
-
sParameterName = sURLVariables[i].split('=');
|
251 |
-
|
252 |
-
if (sParameterName[0] === sParam) {
|
253 |
-
return sParameterName[1] === undefined ? true : decodeURIComponent(sParameterName[1]);
|
254 |
-
}
|
255 |
-
}
|
256 |
-
};
|
257 |
-
|
258 |
-
|
259 |
-
});
|
260 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
niteo-cmp.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: CMP - Coming Soon & Maintenance Plugin
|
4 |
Plugin URI: https://wordpress.org/plugins/cmp-coming-soon-maintenance/
|
5 |
Description: Display customizable landing page for Coming Soon, Maintenance & Under Construction page.
|
6 |
-
Version: 3.5.
|
7 |
Author: NiteoThemes
|
8 |
Author URI: https://www.niteothemes.com
|
9 |
Text Domain: cmp-coming-soon-maintenance
|
@@ -64,7 +64,7 @@ if ( ! class_exists( 'CMP_Coming_Soon_and_Maintenance' ) ) :
|
|
64 |
|
65 |
private function constants() {
|
66 |
// define constants
|
67 |
-
$this->define( 'CMP_VERSION', '3.5.
|
68 |
$this->define( 'CMP_DEBUG', FALSE );
|
69 |
$this->define( 'CMP_AUTHOR', 'NiteoThemes' );
|
70 |
$this->define( 'CMP_AUTHOR_HOMEPAGE', 'https://niteothemes.com' );
|
3 |
Plugin Name: CMP - Coming Soon & Maintenance Plugin
|
4 |
Plugin URI: https://wordpress.org/plugins/cmp-coming-soon-maintenance/
|
5 |
Description: Display customizable landing page for Coming Soon, Maintenance & Under Construction page.
|
6 |
+
Version: 3.5.2
|
7 |
Author: NiteoThemes
|
8 |
Author URI: https://www.niteothemes.com
|
9 |
Text Domain: cmp-coming-soon-maintenance
|
64 |
|
65 |
private function constants() {
|
66 |
// define constants
|
67 |
+
$this->define( 'CMP_VERSION', '3.5.2' );
|
68 |
$this->define( 'CMP_DEBUG', FALSE );
|
69 |
$this->define( 'CMP_AUTHOR', 'NiteoThemes' );
|
70 |
$this->define( 'CMP_AUTHOR_HOMEPAGE', 'https://niteothemes.com' );
|
readme.txt
CHANGED
@@ -5,7 +5,7 @@ Tags: coming soon, landing page, launch page, maintenance mode, under constructi
|
|
5 |
Requires at least: 3.0
|
6 |
Requires PHP: 5.3
|
7 |
Tested up to: 5.2
|
8 |
-
Stable tag: 3.5.
|
9 |
License: GPLv2 or later
|
10 |
License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
11 |
|
@@ -17,7 +17,7 @@ CMP – Coming Soon & Maintenance plugin has all premium features you ever wishe
|
|
17 |
Packed with functions like Whitelist/Blacklist to enable CMP only on specific pages, User Roles Management, custom URL Bypass, Translation strings, custom Subscribers option and many more you would not believe it is free. No ADS too, guaranteed!
|
18 |
|
19 |
<h3>Live Preview</h3>
|
20 |
-
<a href="https://
|
21 |
|
22 |
<p>TIP! You can change to different CMP Theme or change the background in the right sidebar by clicking on "settings icon".</p>
|
23 |
|
@@ -135,6 +135,12 @@ https://www.youtube.com/watch?v=uxuJfHzwdtE
|
|
135 |
<p>Nothing is better than a good feedback! Please go to <a href="https://wordpress.org/support/plugin/cmp-coming-soon-maintenance/reviews/">Plugin reviews</a> and rate it! Alternatively you can click on a Donate button too!:)</p>
|
136 |
|
137 |
== Changelog ==
|
|
|
|
|
|
|
|
|
|
|
|
|
138 |
<h4>CMP 3.5.1 - 30-May-19</h4>
|
139 |
<ul>
|
140 |
<li>Added mimes filter to alllow custom fonts to upload via media library.</li>
|
5 |
Requires at least: 3.0
|
6 |
Requires PHP: 5.3
|
7 |
Tested up to: 5.2
|
8 |
+
Stable tag: 3.5.2
|
9 |
License: GPLv2 or later
|
10 |
License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
11 |
|
17 |
Packed with functions like Whitelist/Blacklist to enable CMP only on specific pages, User Roles Management, custom URL Bypass, Translation strings, custom Subscribers option and many more you would not believe it is free. No ADS too, guaranteed!
|
18 |
|
19 |
<h3>Live Preview</h3>
|
20 |
+
<a href="https://niteothemes.com/cmp-coming-soon-maintenance/?utm_source=wordpress.org&utm_medium=referral" target="_blank">Click for CMP preview>></a>
|
21 |
|
22 |
<p>TIP! You can change to different CMP Theme or change the background in the right sidebar by clicking on "settings icon".</p>
|
23 |
|
135 |
<p>Nothing is better than a good feedback! Please go to <a href="https://wordpress.org/support/plugin/cmp-coming-soon-maintenance/reviews/">Plugin reviews</a> and rate it! Alternatively you can click on a Donate button too!:)</p>
|
136 |
|
137 |
== Changelog ==
|
138 |
+
<h4>CMP 3.5.2 - 05-Jun-19</h4>
|
139 |
+
<ul>
|
140 |
+
<li>Minor internal changes..</li>
|
141 |
+
</ul>
|
142 |
+
|
143 |
+
|
144 |
<h4>CMP 3.5.1 - 30-May-19</h4>
|
145 |
<ul>
|
146 |
<li>Added mimes filter to alllow custom fonts to upload via media library.</li>
|