Version Description
- Aviser Theme Functionality Added
Download this release
Release Info
Developer | nayrathemes |
Plugin | Clever Fox |
Version | 9.9 |
Comparing to | |
See all releases |
Code changes from version 9.8 to 9.9
- clever-fox.php +5 -1
- inc/assets/js/jquery.counterup.js +7 -356
- inc/assets/js/jquery.counterup.min.js +11 -8
- inc/aviser/aviser.php +37 -0
- inc/aviser/default-pages/home-page.php +24 -0
- inc/aviser/default-pages/upload-media.php +32 -0
- inc/aviser/default-widgets/default-widget.php +38 -0
- inc/aviser/extras.php +73 -0
- inc/aviser/features/avril-header.php +721 -0
- inc/aviser/images/logo-2.png +0 -0
- inc/aviser/images/logo.png +0 -0
- inc/aviser/sections/above-header.php +78 -0
- inc/aviser/sections/section-cta-2.php +51 -0
- inc/aviser/sections/section-features.php +66 -0
- inc/avril/dynamic-style.php +20 -0
- inc/cleverfox-activator.php +6 -0
- readme.txt +4 -1
clever-fox.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: Clever Fox
|
4 |
Plugin URI:
|
5 |
Description: Clever Fox plugin to enhance the functionality of free themes made by Nayra Themes. More than 50000+ trusted websites with Nayra Themes. It provides intuitive features to your website. 20+ Themes compatible with Clever Fox. See below free themes listed here. Avril is one of Popular themes in our collections.
|
6 |
-
Version: 9.
|
7 |
Author: nayrathemes
|
8 |
Author URI: https://nayrathemes.com
|
9 |
Text Domain: clever-fox
|
@@ -116,6 +116,10 @@ function cleverfox_activate() {
|
|
116 |
require_once('inc/gradiant/gradiant.php');
|
117 |
}
|
118 |
|
|
|
|
|
|
|
|
|
119 |
}
|
120 |
add_action( 'init', 'cleverfox_activate' );
|
121 |
|
3 |
Plugin Name: Clever Fox
|
4 |
Plugin URI:
|
5 |
Description: Clever Fox plugin to enhance the functionality of free themes made by Nayra Themes. More than 50000+ trusted websites with Nayra Themes. It provides intuitive features to your website. 20+ Themes compatible with Clever Fox. See below free themes listed here. Avril is one of Popular themes in our collections.
|
6 |
+
Version: 9.9
|
7 |
Author: nayrathemes
|
8 |
Author URI: https://nayrathemes.com
|
9 |
Text Domain: clever-fox
|
116 |
require_once('inc/gradiant/gradiant.php');
|
117 |
}
|
118 |
|
119 |
+
if( 'Aviser' == $theme->name){
|
120 |
+
require_once('inc/aviser/aviser.php');
|
121 |
+
}
|
122 |
+
|
123 |
}
|
124 |
add_action( 'init', 'cleverfox_activate' );
|
125 |
|
inc/assets/js/jquery.counterup.js
CHANGED
@@ -2,368 +2,19 @@
|
|
2 |
Waypoints - 4.0.0
|
3 |
Copyright © 2011-2015 Caleb Troughton
|
4 |
Licensed under the MIT license.
|
5 |
-
https://github.com/imakewebthings/waypoints/
|
6 |
*/
|
7 |
-
! function() {
|
8 |
-
"use strict";
|
9 |
-
|
10 |
-
function t(o) {
|
11 |
-
if (!o) throw new Error("No options passed to Waypoint constructor");
|
12 |
-
if (!o.element) throw new Error("No element option passed to Waypoint constructor");
|
13 |
-
if (!o.handler) throw new Error("No handler option passed to Waypoint constructor");
|
14 |
-
this.key = "waypoint-" + e, this.options = t.Adapter.extend({}, t.defaults, o), this.element = this.options.element, this.adapter = new t.Adapter(this.element), this.callback = o.handler, this.axis = this.options.horizontal ? "horizontal" : "vertical", this.enabled = this.options.enabled, this.triggerPoint = null, this.group = t.Group.findOrCreate({
|
15 |
-
name: this.options.group,
|
16 |
-
axis: this.axis
|
17 |
-
}), this.context = t.Context.findOrCreateByElement(this.options.context), t.offsetAliases[this.options.offset] && (this.options.offset = t.offsetAliases[this.options.offset]), this.group.add(this), this.context.add(this), i[this.key] = this, e += 1
|
18 |
-
}
|
19 |
-
var e = 0,
|
20 |
-
i = {};
|
21 |
-
t.prototype.queueTrigger = function(t) {
|
22 |
-
this.group.queueTrigger(this, t)
|
23 |
-
}, t.prototype.trigger = function(t) {
|
24 |
-
this.enabled && this.callback && this.callback.apply(this, t)
|
25 |
-
}, t.prototype.destroy = function() {
|
26 |
-
this.context.remove(this), this.group.remove(this), delete i[this.key]
|
27 |
-
}, t.prototype.disable = function() {
|
28 |
-
return this.enabled = !1, this
|
29 |
-
}, t.prototype.enable = function() {
|
30 |
-
return this.context.refresh(), this.enabled = !0, this
|
31 |
-
}, t.prototype.next = function() {
|
32 |
-
return this.group.next(this)
|
33 |
-
}, t.prototype.previous = function() {
|
34 |
-
return this.group.previous(this)
|
35 |
-
}, t.invokeAll = function(t) {
|
36 |
-
var e = [];
|
37 |
-
for (var o in i) e.push(i[o]);
|
38 |
-
for (var n = 0, r = e.length; r > n; n++) e[n][t]()
|
39 |
-
}, t.destroyAll = function() {
|
40 |
-
t.invokeAll("destroy")
|
41 |
-
}, t.disableAll = function() {
|
42 |
-
t.invokeAll("disable")
|
43 |
-
}, t.enableAll = function() {
|
44 |
-
t.invokeAll("enable")
|
45 |
-
}, t.refreshAll = function() {
|
46 |
-
t.Context.refreshAll()
|
47 |
-
}, t.viewportHeight = function() {
|
48 |
-
return window.innerHeight || document.documentElement.clientHeight
|
49 |
-
}, t.viewportWidth = function() {
|
50 |
-
return document.documentElement.clientWidth
|
51 |
-
}, t.adapters = [], t.defaults = {
|
52 |
-
context: window,
|
53 |
-
continuous: !0,
|
54 |
-
enabled: !0,
|
55 |
-
group: "default",
|
56 |
-
horizontal: !1,
|
57 |
-
offset: 0
|
58 |
-
}, t.offsetAliases = {
|
59 |
-
"bottom-in-view": function() {
|
60 |
-
return this.context.innerHeight() - this.adapter.outerHeight()
|
61 |
-
},
|
62 |
-
"right-in-view": function() {
|
63 |
-
return this.context.innerWidth() - this.adapter.outerWidth()
|
64 |
-
}
|
65 |
-
}, window.Waypoint = t
|
66 |
-
}(),
|
67 |
-
function() {
|
68 |
-
"use strict";
|
69 |
-
|
70 |
-
function t(t) {
|
71 |
-
window.setTimeout(t, 1e3 / 60)
|
72 |
-
}
|
73 |
-
|
74 |
-
function e(t) {
|
75 |
-
this.element = t, this.Adapter = n.Adapter, this.adapter = new this.Adapter(t), this.key = "waypoint-context-" + i, this.didScroll = !1, this.didResize = !1, this.oldScroll = {
|
76 |
-
x: this.adapter.scrollLeft(),
|
77 |
-
y: this.adapter.scrollTop()
|
78 |
-
}, this.waypoints = {
|
79 |
-
vertical: {},
|
80 |
-
horizontal: {}
|
81 |
-
}, t.waypointContextKey = this.key, o[t.waypointContextKey] = this, i += 1, this.createThrottledScrollHandler(), this.createThrottledResizeHandler()
|
82 |
-
}
|
83 |
-
var i = 0,
|
84 |
-
o = {},
|
85 |
-
n = window.Waypoint,
|
86 |
-
r = window.onload;
|
87 |
-
e.prototype.add = function(t) {
|
88 |
-
var e = t.options.horizontal ? "horizontal" : "vertical";
|
89 |
-
this.waypoints[e][t.key] = t, this.refresh()
|
90 |
-
}, e.prototype.checkEmpty = function() {
|
91 |
-
var t = this.Adapter.isEmptyObject(this.waypoints.horizontal),
|
92 |
-
e = this.Adapter.isEmptyObject(this.waypoints.vertical);
|
93 |
-
t && e && (this.adapter.off(".waypoints"), delete o[this.key])
|
94 |
-
}, e.prototype.createThrottledResizeHandler = function() {
|
95 |
-
function t() {
|
96 |
-
e.handleResize(), e.didResize = !1
|
97 |
-
}
|
98 |
-
var e = this;
|
99 |
-
this.adapter.on("resize.waypoints", function() {
|
100 |
-
e.didResize || (e.didResize = !0, n.requestAnimationFrame(t))
|
101 |
-
})
|
102 |
-
}, e.prototype.createThrottledScrollHandler = function() {
|
103 |
-
function t() {
|
104 |
-
e.handleScroll(), e.didScroll = !1
|
105 |
-
}
|
106 |
-
var e = this;
|
107 |
-
this.adapter.on("scroll.waypoints", function() {
|
108 |
-
(!e.didScroll || n.isTouch) && (e.didScroll = !0, n.requestAnimationFrame(t))
|
109 |
-
})
|
110 |
-
}, e.prototype.handleResize = function() {
|
111 |
-
n.Context.refreshAll()
|
112 |
-
}, e.prototype.handleScroll = function() {
|
113 |
-
var t = {},
|
114 |
-
e = {
|
115 |
-
horizontal: {
|
116 |
-
newScroll: this.adapter.scrollLeft(),
|
117 |
-
oldScroll: this.oldScroll.x,
|
118 |
-
forward: "right",
|
119 |
-
backward: "left"
|
120 |
-
},
|
121 |
-
vertical: {
|
122 |
-
newScroll: this.adapter.scrollTop(),
|
123 |
-
oldScroll: this.oldScroll.y,
|
124 |
-
forward: "down",
|
125 |
-
backward: "up"
|
126 |
-
}
|
127 |
-
};
|
128 |
-
for (var i in e) {
|
129 |
-
var o = e[i],
|
130 |
-
n = o.newScroll > o.oldScroll,
|
131 |
-
r = n ? o.forward : o.backward;
|
132 |
-
for (var s in this.waypoints[i]) {
|
133 |
-
var a = this.waypoints[i][s],
|
134 |
-
l = o.oldScroll < a.triggerPoint,
|
135 |
-
h = o.newScroll >= a.triggerPoint,
|
136 |
-
p = l && h,
|
137 |
-
u = !l && !h;
|
138 |
-
(p || u) && (a.queueTrigger(r), t[a.group.id] = a.group)
|
139 |
-
}
|
140 |
-
}
|
141 |
-
for (var c in t) t[c].flushTriggers();
|
142 |
-
this.oldScroll = {
|
143 |
-
x: e.horizontal.newScroll,
|
144 |
-
y: e.vertical.newScroll
|
145 |
-
}
|
146 |
-
}, e.prototype.innerHeight = function() {
|
147 |
-
return this.element == this.element.window ? n.viewportHeight() : this.adapter.innerHeight()
|
148 |
-
}, e.prototype.remove = function(t) {
|
149 |
-
delete this.waypoints[t.axis][t.key], this.checkEmpty()
|
150 |
-
}, e.prototype.innerWidth = function() {
|
151 |
-
return this.element == this.element.window ? n.viewportWidth() : this.adapter.innerWidth()
|
152 |
-
}, e.prototype.destroy = function() {
|
153 |
-
var t = [];
|
154 |
-
for (var e in this.waypoints)
|
155 |
-
for (var i in this.waypoints[e]) t.push(this.waypoints[e][i]);
|
156 |
-
for (var o = 0, n = t.length; n > o; o++) t[o].destroy()
|
157 |
-
}, e.prototype.refresh = function() {
|
158 |
-
var t, e = this.element == this.element.window,
|
159 |
-
i = e ? void 0 : this.adapter.offset(),
|
160 |
-
o = {};
|
161 |
-
this.handleScroll(), t = {
|
162 |
-
horizontal: {
|
163 |
-
contextOffset: e ? 0 : i.left,
|
164 |
-
contextScroll: e ? 0 : this.oldScroll.x,
|
165 |
-
contextDimension: this.innerWidth(),
|
166 |
-
oldScroll: this.oldScroll.x,
|
167 |
-
forward: "right",
|
168 |
-
backward: "left",
|
169 |
-
offsetProp: "left"
|
170 |
-
},
|
171 |
-
vertical: {
|
172 |
-
contextOffset: e ? 0 : i.top,
|
173 |
-
contextScroll: e ? 0 : this.oldScroll.y,
|
174 |
-
contextDimension: this.innerHeight(),
|
175 |
-
oldScroll: this.oldScroll.y,
|
176 |
-
forward: "down",
|
177 |
-
backward: "up",
|
178 |
-
offsetProp: "top"
|
179 |
-
}
|
180 |
-
};
|
181 |
-
for (var r in t) {
|
182 |
-
var s = t[r];
|
183 |
-
for (var a in this.waypoints[r]) {
|
184 |
-
var l, h, p, u, c, d = this.waypoints[r][a],
|
185 |
-
f = d.options.offset,
|
186 |
-
w = d.triggerPoint,
|
187 |
-
y = 0,
|
188 |
-
g = null == w;
|
189 |
-
d.element !== d.element.window && (y = d.adapter.offset()[s.offsetProp]), "function" == typeof f ? f = f.apply(d) : "string" == typeof f && (f = parseFloat(f), d.options.offset.indexOf("%") > -1 && (f = Math.ceil(s.contextDimension * f / 100))), l = s.contextScroll - s.contextOffset, d.triggerPoint = y + l - f, h = w < s.oldScroll, p = d.triggerPoint >= s.oldScroll, u = h && p, c = !h && !p, !g && u ? (d.queueTrigger(s.backward), o[d.group.id] = d.group) : !g && c ? (d.queueTrigger(s.forward), o[d.group.id] = d.group) : g && s.oldScroll >= d.triggerPoint && (d.queueTrigger(s.forward), o[d.group.id] = d.group)
|
190 |
-
}
|
191 |
-
}
|
192 |
-
return n.requestAnimationFrame(function() {
|
193 |
-
for (var t in o) o[t].flushTriggers()
|
194 |
-
}), this
|
195 |
-
}, e.findOrCreateByElement = function(t) {
|
196 |
-
return e.findByElement(t) || new e(t)
|
197 |
-
}, e.refreshAll = function() {
|
198 |
-
for (var t in o) o[t].refresh()
|
199 |
-
}, e.findByElement = function(t) {
|
200 |
-
return o[t.waypointContextKey]
|
201 |
-
}, window.onload = function() {
|
202 |
-
r && r(), e.refreshAll()
|
203 |
-
}, n.requestAnimationFrame = function(e) {
|
204 |
-
var i = window.requestAnimationFrame || window.mozRequestAnimationFrame || window.webkitRequestAnimationFrame || t;
|
205 |
-
i.call(window, e)
|
206 |
-
}, n.Context = e
|
207 |
-
}(),
|
208 |
-
function() {
|
209 |
-
"use strict";
|
210 |
-
|
211 |
-
function t(t, e) {
|
212 |
-
return t.triggerPoint - e.triggerPoint
|
213 |
-
}
|
214 |
-
|
215 |
-
function e(t, e) {
|
216 |
-
return e.triggerPoint - t.triggerPoint
|
217 |
-
}
|
218 |
-
|
219 |
-
function i(t) {
|
220 |
-
this.name = t.name, this.axis = t.axis, this.id = this.name + "-" + this.axis, this.waypoints = [], this.clearTriggerQueues(), o[this.axis][this.name] = this
|
221 |
-
}
|
222 |
-
var o = {
|
223 |
-
vertical: {},
|
224 |
-
horizontal: {}
|
225 |
-
},
|
226 |
-
n = window.Waypoint;
|
227 |
-
i.prototype.add = function(t) {
|
228 |
-
this.waypoints.push(t)
|
229 |
-
}, i.prototype.clearTriggerQueues = function() {
|
230 |
-
this.triggerQueues = {
|
231 |
-
up: [],
|
232 |
-
down: [],
|
233 |
-
left: [],
|
234 |
-
right: []
|
235 |
-
}
|
236 |
-
}, i.prototype.flushTriggers = function() {
|
237 |
-
for (var i in this.triggerQueues) {
|
238 |
-
var o = this.triggerQueues[i],
|
239 |
-
n = "up" === i || "left" === i;
|
240 |
-
o.sort(n ? e : t);
|
241 |
-
for (var r = 0, s = o.length; s > r; r += 1) {
|
242 |
-
var a = o[r];
|
243 |
-
(a.options.continuous || r === o.length - 1) && a.trigger([i])
|
244 |
-
}
|
245 |
-
}
|
246 |
-
this.clearTriggerQueues()
|
247 |
-
}, i.prototype.next = function(e) {
|
248 |
-
this.waypoints.sort(t);
|
249 |
-
var i = n.Adapter.inArray(e, this.waypoints),
|
250 |
-
o = i === this.waypoints.length - 1;
|
251 |
-
return o ? null : this.waypoints[i + 1]
|
252 |
-
}, i.prototype.previous = function(e) {
|
253 |
-
this.waypoints.sort(t);
|
254 |
-
var i = n.Adapter.inArray(e, this.waypoints);
|
255 |
-
return i ? this.waypoints[i - 1] : null
|
256 |
-
}, i.prototype.queueTrigger = function(t, e) {
|
257 |
-
this.triggerQueues[e].push(t)
|
258 |
-
}, i.prototype.remove = function(t) {
|
259 |
-
var e = n.Adapter.inArray(t, this.waypoints);
|
260 |
-
e > -1 && this.waypoints.splice(e, 1)
|
261 |
-
}, i.prototype.first = function() {
|
262 |
-
return this.waypoints[0]
|
263 |
-
}, i.prototype.last = function() {
|
264 |
-
return this.waypoints[this.waypoints.length - 1]
|
265 |
-
}, i.findOrCreate = function(t) {
|
266 |
-
return o[t.axis][t.name] || new i(t)
|
267 |
-
}, n.Group = i
|
268 |
-
}(),
|
269 |
-
function() {
|
270 |
-
"use strict";
|
271 |
-
|
272 |
-
function t(t) {
|
273 |
-
this.$element = e(t)
|
274 |
-
}
|
275 |
-
var e = window.jQuery,
|
276 |
-
i = window.Waypoint;
|
277 |
-
e.each(["innerHeight", "innerWidth", "off", "offset", "on", "outerHeight", "outerWidth", "scrollLeft", "scrollTop"], function(e, i) {
|
278 |
-
t.prototype[i] = function() {
|
279 |
-
var t = Array.prototype.slice.call(arguments);
|
280 |
-
return this.$element[i].apply(this.$element, t)
|
281 |
-
}
|
282 |
-
}), e.each(["extend", "inArray", "isEmptyObject"], function(i, o) {
|
283 |
-
t[o] = e[o]
|
284 |
-
}), i.adapters.push({
|
285 |
-
name: "jquery",
|
286 |
-
Adapter: t
|
287 |
-
}), i.Adapter = t
|
288 |
-
}(),
|
289 |
-
function() {
|
290 |
-
"use strict";
|
291 |
-
|
292 |
-
function t(t) {
|
293 |
-
return function() {
|
294 |
-
var i = [],
|
295 |
-
o = arguments[0];
|
296 |
-
return t.isFunction(arguments[0]) && (o = t.extend({}, arguments[1]), o.handler = arguments[0]), this.each(function() {
|
297 |
-
var n = t.extend({}, o, {
|
298 |
-
element: this
|
299 |
-
});
|
300 |
-
"string" == typeof n.context && (n.context = t(this).closest(n.context)[0]), i.push(new e(n))
|
301 |
-
}), i
|
302 |
-
}
|
303 |
-
}
|
304 |
-
var e = window.Waypoint;
|
305 |
-
window.jQuery && (window.jQuery.fn.waypoint = t(window.jQuery)), window.Zepto && (window.Zepto.fn.waypoint = t(window.Zepto))
|
306 |
-
}();
|
307 |
|
308 |
/*!
|
309 |
-
* jquery.counterup.js
|
310 |
*
|
311 |
* Copyright 2013, Benjamin Intal http://gambit.ph @bfintal
|
312 |
* Released under the GPL v2 License
|
313 |
*
|
314 |
-
*
|
|
|
|
|
315 |
*/
|
316 |
-
(function(e) {
|
317 |
-
"use strict";
|
318 |
-
e.fn.counterUp = function(t) {
|
319 |
-
var n = e.extend({
|
320 |
-
time: 400,
|
321 |
-
delay: 10
|
322 |
-
}, t);
|
323 |
-
return this.each(function() {
|
324 |
-
var t = e(this),
|
325 |
-
r = n,
|
326 |
-
i = function() {
|
327 |
-
var e = [],
|
328 |
-
n = r.time / r.delay,
|
329 |
-
i = t.text(),
|
330 |
-
s = /[0-9]+,[0-9]+/.test(i);
|
331 |
-
i = i.replace(/,/g, "");
|
332 |
-
var o = /^[0-9]+$/.test(i),
|
333 |
-
u = /^[0-9]+\.[0-9]+$/.test(i),
|
334 |
-
a = u ? (i.split(".")[1] || []).length : 0;
|
335 |
-
for (var f = n; f >= 1; f--) {
|
336 |
-
var l = parseInt(i / n * f);
|
337 |
-
u && (l = parseFloat(i / n * f).toFixed(a));
|
338 |
-
if (s)
|
339 |
-
while (/(\d+)(\d{3})/.test(l.toString())) l = l.toString().replace(/(\d+)(\d{3})/, "$1,$2");
|
340 |
-
e.unshift(l)
|
341 |
-
}
|
342 |
-
t.data("counterup-nums", e);
|
343 |
-
t.text("0");
|
344 |
-
var c = function() {
|
345 |
-
t.text(t.data("counterup-nums").shift());
|
346 |
-
if (t.data("counterup-nums").length) setTimeout(t.data("counterup-func"), r.delay);
|
347 |
-
else {
|
348 |
-
delete t.data("counterup-nums");
|
349 |
-
t.data("counterup-nums", null);
|
350 |
-
t.data("counterup-func", null)
|
351 |
-
}
|
352 |
-
};
|
353 |
-
t.data("counterup-func", c);
|
354 |
-
setTimeout(t.data("counterup-func"), r.delay)
|
355 |
-
};
|
356 |
-
t.waypoint(i, {
|
357 |
-
offset: "100%",
|
358 |
-
triggerOnce: !0
|
359 |
-
})
|
360 |
-
})
|
361 |
-
}
|
362 |
-
})(jQuery);
|
363 |
-
|
364 |
-
// counter up
|
365 |
|
366 |
-
jQuery('.counter').counterUp({
|
367 |
-
delay: 10,
|
368 |
-
time: 1000
|
369 |
-
});
|
2 |
Waypoints - 4.0.0
|
3 |
Copyright © 2011-2015 Caleb Troughton
|
4 |
Licensed under the MIT license.
|
5 |
+
https://github.com/imakewebthings/waypoints/blog/master/licenses.txt
|
6 |
*/
|
7 |
+
!function(){"use strict";function t(o){if(!o)throw new Error("No options passed to Waypoint constructor");if(!o.element)throw new Error("No element option passed to Waypoint constructor");if(!o.handler)throw new Error("No handler option passed to Waypoint constructor");this.key="waypoint-"+e,this.options=t.Adapter.extend({},t.defaults,o),this.element=this.options.element,this.adapter=new t.Adapter(this.element),this.callback=o.handler,this.axis=this.options.horizontal?"horizontal":"vertical",this.enabled=this.options.enabled,this.triggerPoint=null,this.group=t.Group.findOrCreate({name:this.options.group,axis:this.axis}),this.context=t.Context.findOrCreateByElement(this.options.context),t.offsetAliases[this.options.offset]&&(this.options.offset=t.offsetAliases[this.options.offset]),this.group.add(this),this.context.add(this),i[this.key]=this,e+=1}var e=0,i={};t.prototype.queueTrigger=function(t){this.group.queueTrigger(this,t)},t.prototype.trigger=function(t){this.enabled&&this.callback&&this.callback.apply(this,t)},t.prototype.destroy=function(){this.context.remove(this),this.group.remove(this),delete i[this.key]},t.prototype.disable=function(){return this.enabled=!1,this},t.prototype.enable=function(){return this.context.refresh(),this.enabled=!0,this},t.prototype.next=function(){return this.group.next(this)},t.prototype.previous=function(){return this.group.previous(this)},t.invokeAll=function(t){var e=[];for(var o in i)e.push(i[o]);for(var n=0,r=e.length;r>n;n++)e[n][t]()},t.destroyAll=function(){t.invokeAll("destroy")},t.disableAll=function(){t.invokeAll("disable")},t.enableAll=function(){t.invokeAll("enable")},t.refreshAll=function(){t.Context.refreshAll()},t.viewportHeight=function(){return window.innerHeight||document.documentElement.clientHeight},t.viewportWidth=function(){return document.documentElement.clientWidth},t.adapters=[],t.defaults={context:window,continuous:!0,enabled:!0,group:"default",horizontal:!1,offset:0},t.offsetAliases={"bottom-in-view":function(){return this.context.innerHeight()-this.adapter.outerHeight()},"right-in-view":function(){return this.context.innerWidth()-this.adapter.outerWidth()}},window.Waypoint=t}(),function(){"use strict";function t(t){window.setTimeout(t,1e3/60)}function e(t){this.element=t,this.Adapter=n.Adapter,this.adapter=new this.Adapter(t),this.key="waypoint-context-"+i,this.didScroll=!1,this.didResize=!1,this.oldScroll={x:this.adapter.scrollLeft(),y:this.adapter.scrollTop()},this.waypoints={vertical:{},horizontal:{}},t.waypointContextKey=this.key,o[t.waypointContextKey]=this,i+=1,this.createThrottledScrollHandler(),this.createThrottledResizeHandler()}var i=0,o={},n=window.Waypoint,r=window.onload;e.prototype.add=function(t){var e=t.options.horizontal?"horizontal":"vertical";this.waypoints[e][t.key]=t,this.refresh()},e.prototype.checkEmpty=function(){var t=this.Adapter.isEmptyObject(this.waypoints.horizontal),e=this.Adapter.isEmptyObject(this.waypoints.vertical);t&&e&&(this.adapter.off(".waypoints"),delete o[this.key])},e.prototype.createThrottledResizeHandler=function(){function t(){e.handleResize(),e.didResize=!1}var e=this;this.adapter.on("resize.waypoints",function(){e.didResize||(e.didResize=!0,n.requestAnimationFrame(t))})},e.prototype.createThrottledScrollHandler=function(){function t(){e.handleScroll(),e.didScroll=!1}var e=this;this.adapter.on("scroll.waypoints",function(){(!e.didScroll||n.isTouch)&&(e.didScroll=!0,n.requestAnimationFrame(t))})},e.prototype.handleResize=function(){n.Context.refreshAll()},e.prototype.handleScroll=function(){var t={},e={horizontal:{newScroll:this.adapter.scrollLeft(),oldScroll:this.oldScroll.x,forward:"right",backward:"left"},vertical:{newScroll:this.adapter.scrollTop(),oldScroll:this.oldScroll.y,forward:"down",backward:"up"}};for(var i in e){var o=e[i],n=o.newScroll>o.oldScroll,r=n?o.forward:o.backward;for(var s in this.waypoints[i]){var a=this.waypoints[i][s],l=o.oldScroll<a.triggerPoint,h=o.newScroll>=a.triggerPoint,p=l&&h,u=!l&&!h;(p||u)&&(a.queueTrigger(r),t[a.group.id]=a.group)}}for(var c in t)t[c].flushTriggers();this.oldScroll={x:e.horizontal.newScroll,y:e.vertical.newScroll}},e.prototype.innerHeight=function(){return this.element==this.element.window?n.viewportHeight():this.adapter.innerHeight()},e.prototype.remove=function(t){delete this.waypoints[t.axis][t.key],this.checkEmpty()},e.prototype.innerWidth=function(){return this.element==this.element.window?n.viewportWidth():this.adapter.innerWidth()},e.prototype.destroy=function(){var t=[];for(var e in this.waypoints)for(var i in this.waypoints[e])t.push(this.waypoints[e][i]);for(var o=0,n=t.length;n>o;o++)t[o].destroy()},e.prototype.refresh=function(){var t,e=this.element==this.element.window,i=e?void 0:this.adapter.offset(),o={};this.handleScroll(),t={horizontal:{contextOffset:e?0:i.left,contextScroll:e?0:this.oldScroll.x,contextDimension:this.innerWidth(),oldScroll:this.oldScroll.x,forward:"right",backward:"left",offsetProp:"left"},vertical:{contextOffset:e?0:i.top,contextScroll:e?0:this.oldScroll.y,contextDimension:this.innerHeight(),oldScroll:this.oldScroll.y,forward:"down",backward:"up",offsetProp:"top"}};for(var r in t){var s=t[r];for(var a in this.waypoints[r]){var l,h,p,u,c,d=this.waypoints[r][a],f=d.options.offset,w=d.triggerPoint,y=0,g=null==w;d.element!==d.element.window&&(y=d.adapter.offset()[s.offsetProp]),"function"==typeof f?f=f.apply(d):"string"==typeof f&&(f=parseFloat(f),d.options.offset.indexOf("%")>-1&&(f=Math.ceil(s.contextDimension*f/100))),l=s.contextScroll-s.contextOffset,d.triggerPoint=y+l-f,h=w<s.oldScroll,p=d.triggerPoint>=s.oldScroll,u=h&&p,c=!h&&!p,!g&&u?(d.queueTrigger(s.backward),o[d.group.id]=d.group):!g&&c?(d.queueTrigger(s.forward),o[d.group.id]=d.group):g&&s.oldScroll>=d.triggerPoint&&(d.queueTrigger(s.forward),o[d.group.id]=d.group)}}return n.requestAnimationFrame(function(){for(var t in o)o[t].flushTriggers()}),this},e.findOrCreateByElement=function(t){return e.findByElement(t)||new e(t)},e.refreshAll=function(){for(var t in o)o[t].refresh()},e.findByElement=function(t){return o[t.waypointContextKey]},window.onload=function(){r&&r(),e.refreshAll()},n.requestAnimationFrame=function(e){var i=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||t;i.call(window,e)},n.Context=e}(),function(){"use strict";function t(t,e){return t.triggerPoint-e.triggerPoint}function e(t,e){return e.triggerPoint-t.triggerPoint}function i(t){this.name=t.name,this.axis=t.axis,this.id=this.name+"-"+this.axis,this.waypoints=[],this.clearTriggerQueues(),o[this.axis][this.name]=this}var o={vertical:{},horizontal:{}},n=window.Waypoint;i.prototype.add=function(t){this.waypoints.push(t)},i.prototype.clearTriggerQueues=function(){this.triggerQueues={up:[],down:[],left:[],right:[]}},i.prototype.flushTriggers=function(){for(var i in this.triggerQueues){var o=this.triggerQueues[i],n="up"===i||"left"===i;o.sort(n?e:t);for(var r=0,s=o.length;s>r;r+=1){var a=o[r];(a.options.continuous||r===o.length-1)&&a.trigger([i])}}this.clearTriggerQueues()},i.prototype.next=function(e){this.waypoints.sort(t);var i=n.Adapter.inArray(e,this.waypoints),o=i===this.waypoints.length-1;return o?null:this.waypoints[i+1]},i.prototype.previous=function(e){this.waypoints.sort(t);var i=n.Adapter.inArray(e,this.waypoints);return i?this.waypoints[i-1]:null},i.prototype.queueTrigger=function(t,e){this.triggerQueues[e].push(t)},i.prototype.remove=function(t){var e=n.Adapter.inArray(t,this.waypoints);e>-1&&this.waypoints.splice(e,1)},i.prototype.first=function(){return this.waypoints[0]},i.prototype.last=function(){return this.waypoints[this.waypoints.length-1]},i.findOrCreate=function(t){return o[t.axis][t.name]||new i(t)},n.Group=i}(),function(){"use strict";function t(t){this.$element=e(t)}var e=window.jQuery,i=window.Waypoint;e.each(["innerHeight","innerWidth","off","offset","on","outerHeight","outerWidth","scrollLeft","scrollTop"],function(e,i){t.prototype[i]=function(){var t=Array.prototype.slice.call(arguments);return this.$element[i].apply(this.$element,t)}}),e.each(["extend","inArray","isEmptyObject"],function(i,o){t[o]=e[o]}),i.adapters.push({name:"jquery",Adapter:t}),i.Adapter=t}(),function(){"use strict";function t(t){return function(){var i=[],o=arguments[0];return t.isFunction(arguments[0])&&(o=t.extend({},arguments[1]),o.handler=arguments[0]),this.each(function(){var n=t.extend({},o,{element:this});"string"==typeof n.context&&(n.context=t(this).closest(n.context)[0]),i.push(new e(n))}),i}}var e=window.Waypoint;window.jQuery&&(window.jQuery.fn.waypoint=t(window.jQuery)),window.Zepto&&(window.Zepto.fn.waypoint=t(window.Zepto))}();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
8 |
|
9 |
/*!
|
10 |
+
* jquery.counterup.js 2.0.0
|
11 |
*
|
12 |
* Copyright 2013, Benjamin Intal http://gambit.ph @bfintal
|
13 |
* Released under the GPL v2 License
|
14 |
*
|
15 |
+
* Amended by Ciro Mattia Gonano and others
|
16 |
+
*
|
17 |
+
* Date: Mar 24, 2016
|
18 |
*/
|
19 |
+
!function(t){"use strict";t.fn.counterUp=function(e){var a,n=t.extend({time:400,delay:10,formatter:!1,callback:function(){}},e);return this.each(function(){var e=t(this),u={time:t(this).data("counterup-time")||n.time,delay:t(this).data("counterup-delay")||n.delay};e.waypoint(function(t){!function(){var t=[],r=u.time/u.delay,o=e.text(),i=/[0-9]+,[0-9]+/.test(o),c=((o=o.replace(/,/g,"")).split(".")[1]||[]).length,s=/[0-9]+:[0-9]+:[0-9]+/.test(o);if(s){var l=o.split(":"),f=1;for(a=0;l.length>0;)a+=f*parseInt(l.pop(),10),f*=60}for(var d=r;d>=1;d--){var p=parseFloat(o/r*d).toFixed(c);if(s){p=parseInt(a/r*d);var m=parseInt(p/3600)%24,h=parseInt(p/60)%60,y=parseInt(p%60,10);p=(m<10?"0"+m:m)+":"+(h<10?"0"+h:h)+":"+(y<10?"0"+y:y)}if(i)for(;/(\d+)(\d{3})/.test(p.toString());)p=p.toString().replace(/(\d+)(\d{3})/,"$1,$2");n.formatter&&(p=n.formatter.call(this,p)),t.unshift(p)}e.data("counterup-nums",t),e.text("0");e.data("counterup-func",function(){e.html(e.data("counterup-nums").shift()),e.data("counterup-nums").length?setTimeout(e.data("counterup-func"),u.delay):(e.data("counterup-nums",null),e.data("counterup-func",null),n.callback.call(this))}),setTimeout(e.data("counterup-func"),u.delay)}(),this.destroy()},{offset:"100%"})})}}(jQuery);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
20 |
|
|
|
|
|
|
|
|
inc/assets/js/jquery.counterup.min.js
CHANGED
@@ -2,18 +2,21 @@
|
|
2 |
Waypoints - 4.0.0
|
3 |
Copyright © 2011-2015 Caleb Troughton
|
4 |
Licensed under the MIT license.
|
5 |
-
https://github.com/imakewebthings/waypoints/
|
6 |
*/
|
7 |
!function(){"use strict";function t(o){if(!o)throw new Error("No options passed to Waypoint constructor");if(!o.element)throw new Error("No element option passed to Waypoint constructor");if(!o.handler)throw new Error("No handler option passed to Waypoint constructor");this.key="waypoint-"+e,this.options=t.Adapter.extend({},t.defaults,o),this.element=this.options.element,this.adapter=new t.Adapter(this.element),this.callback=o.handler,this.axis=this.options.horizontal?"horizontal":"vertical",this.enabled=this.options.enabled,this.triggerPoint=null,this.group=t.Group.findOrCreate({name:this.options.group,axis:this.axis}),this.context=t.Context.findOrCreateByElement(this.options.context),t.offsetAliases[this.options.offset]&&(this.options.offset=t.offsetAliases[this.options.offset]),this.group.add(this),this.context.add(this),i[this.key]=this,e+=1}var e=0,i={};t.prototype.queueTrigger=function(t){this.group.queueTrigger(this,t)},t.prototype.trigger=function(t){this.enabled&&this.callback&&this.callback.apply(this,t)},t.prototype.destroy=function(){this.context.remove(this),this.group.remove(this),delete i[this.key]},t.prototype.disable=function(){return this.enabled=!1,this},t.prototype.enable=function(){return this.context.refresh(),this.enabled=!0,this},t.prototype.next=function(){return this.group.next(this)},t.prototype.previous=function(){return this.group.previous(this)},t.invokeAll=function(t){var e=[];for(var o in i)e.push(i[o]);for(var n=0,r=e.length;r>n;n++)e[n][t]()},t.destroyAll=function(){t.invokeAll("destroy")},t.disableAll=function(){t.invokeAll("disable")},t.enableAll=function(){t.invokeAll("enable")},t.refreshAll=function(){t.Context.refreshAll()},t.viewportHeight=function(){return window.innerHeight||document.documentElement.clientHeight},t.viewportWidth=function(){return document.documentElement.clientWidth},t.adapters=[],t.defaults={context:window,continuous:!0,enabled:!0,group:"default",horizontal:!1,offset:0},t.offsetAliases={"bottom-in-view":function(){return this.context.innerHeight()-this.adapter.outerHeight()},"right-in-view":function(){return this.context.innerWidth()-this.adapter.outerWidth()}},window.Waypoint=t}(),function(){"use strict";function t(t){window.setTimeout(t,1e3/60)}function e(t){this.element=t,this.Adapter=n.Adapter,this.adapter=new this.Adapter(t),this.key="waypoint-context-"+i,this.didScroll=!1,this.didResize=!1,this.oldScroll={x:this.adapter.scrollLeft(),y:this.adapter.scrollTop()},this.waypoints={vertical:{},horizontal:{}},t.waypointContextKey=this.key,o[t.waypointContextKey]=this,i+=1,this.createThrottledScrollHandler(),this.createThrottledResizeHandler()}var i=0,o={},n=window.Waypoint,r=window.onload;e.prototype.add=function(t){var e=t.options.horizontal?"horizontal":"vertical";this.waypoints[e][t.key]=t,this.refresh()},e.prototype.checkEmpty=function(){var t=this.Adapter.isEmptyObject(this.waypoints.horizontal),e=this.Adapter.isEmptyObject(this.waypoints.vertical);t&&e&&(this.adapter.off(".waypoints"),delete o[this.key])},e.prototype.createThrottledResizeHandler=function(){function t(){e.handleResize(),e.didResize=!1}var e=this;this.adapter.on("resize.waypoints",function(){e.didResize||(e.didResize=!0,n.requestAnimationFrame(t))})},e.prototype.createThrottledScrollHandler=function(){function t(){e.handleScroll(),e.didScroll=!1}var e=this;this.adapter.on("scroll.waypoints",function(){(!e.didScroll||n.isTouch)&&(e.didScroll=!0,n.requestAnimationFrame(t))})},e.prototype.handleResize=function(){n.Context.refreshAll()},e.prototype.handleScroll=function(){var t={},e={horizontal:{newScroll:this.adapter.scrollLeft(),oldScroll:this.oldScroll.x,forward:"right",backward:"left"},vertical:{newScroll:this.adapter.scrollTop(),oldScroll:this.oldScroll.y,forward:"down",backward:"up"}};for(var i in e){var o=e[i],n=o.newScroll>o.oldScroll,r=n?o.forward:o.backward;for(var s in this.waypoints[i]){var a=this.waypoints[i][s],l=o.oldScroll<a.triggerPoint,h=o.newScroll>=a.triggerPoint,p=l&&h,u=!l&&!h;(p||u)&&(a.queueTrigger(r),t[a.group.id]=a.group)}}for(var c in t)t[c].flushTriggers();this.oldScroll={x:e.horizontal.newScroll,y:e.vertical.newScroll}},e.prototype.innerHeight=function(){return this.element==this.element.window?n.viewportHeight():this.adapter.innerHeight()},e.prototype.remove=function(t){delete this.waypoints[t.axis][t.key],this.checkEmpty()},e.prototype.innerWidth=function(){return this.element==this.element.window?n.viewportWidth():this.adapter.innerWidth()},e.prototype.destroy=function(){var t=[];for(var e in this.waypoints)for(var i in this.waypoints[e])t.push(this.waypoints[e][i]);for(var o=0,n=t.length;n>o;o++)t[o].destroy()},e.prototype.refresh=function(){var t,e=this.element==this.element.window,i=e?void 0:this.adapter.offset(),o={};this.handleScroll(),t={horizontal:{contextOffset:e?0:i.left,contextScroll:e?0:this.oldScroll.x,contextDimension:this.innerWidth(),oldScroll:this.oldScroll.x,forward:"right",backward:"left",offsetProp:"left"},vertical:{contextOffset:e?0:i.top,contextScroll:e?0:this.oldScroll.y,contextDimension:this.innerHeight(),oldScroll:this.oldScroll.y,forward:"down",backward:"up",offsetProp:"top"}};for(var r in t){var s=t[r];for(var a in this.waypoints[r]){var l,h,p,u,c,d=this.waypoints[r][a],f=d.options.offset,w=d.triggerPoint,y=0,g=null==w;d.element!==d.element.window&&(y=d.adapter.offset()[s.offsetProp]),"function"==typeof f?f=f.apply(d):"string"==typeof f&&(f=parseFloat(f),d.options.offset.indexOf("%")>-1&&(f=Math.ceil(s.contextDimension*f/100))),l=s.contextScroll-s.contextOffset,d.triggerPoint=y+l-f,h=w<s.oldScroll,p=d.triggerPoint>=s.oldScroll,u=h&&p,c=!h&&!p,!g&&u?(d.queueTrigger(s.backward),o[d.group.id]=d.group):!g&&c?(d.queueTrigger(s.forward),o[d.group.id]=d.group):g&&s.oldScroll>=d.triggerPoint&&(d.queueTrigger(s.forward),o[d.group.id]=d.group)}}return n.requestAnimationFrame(function(){for(var t in o)o[t].flushTriggers()}),this},e.findOrCreateByElement=function(t){return e.findByElement(t)||new e(t)},e.refreshAll=function(){for(var t in o)o[t].refresh()},e.findByElement=function(t){return o[t.waypointContextKey]},window.onload=function(){r&&r(),e.refreshAll()},n.requestAnimationFrame=function(e){var i=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||t;i.call(window,e)},n.Context=e}(),function(){"use strict";function t(t,e){return t.triggerPoint-e.triggerPoint}function e(t,e){return e.triggerPoint-t.triggerPoint}function i(t){this.name=t.name,this.axis=t.axis,this.id=this.name+"-"+this.axis,this.waypoints=[],this.clearTriggerQueues(),o[this.axis][this.name]=this}var o={vertical:{},horizontal:{}},n=window.Waypoint;i.prototype.add=function(t){this.waypoints.push(t)},i.prototype.clearTriggerQueues=function(){this.triggerQueues={up:[],down:[],left:[],right:[]}},i.prototype.flushTriggers=function(){for(var i in this.triggerQueues){var o=this.triggerQueues[i],n="up"===i||"left"===i;o.sort(n?e:t);for(var r=0,s=o.length;s>r;r+=1){var a=o[r];(a.options.continuous||r===o.length-1)&&a.trigger([i])}}this.clearTriggerQueues()},i.prototype.next=function(e){this.waypoints.sort(t);var i=n.Adapter.inArray(e,this.waypoints),o=i===this.waypoints.length-1;return o?null:this.waypoints[i+1]},i.prototype.previous=function(e){this.waypoints.sort(t);var i=n.Adapter.inArray(e,this.waypoints);return i?this.waypoints[i-1]:null},i.prototype.queueTrigger=function(t,e){this.triggerQueues[e].push(t)},i.prototype.remove=function(t){var e=n.Adapter.inArray(t,this.waypoints);e>-1&&this.waypoints.splice(e,1)},i.prototype.first=function(){return this.waypoints[0]},i.prototype.last=function(){return this.waypoints[this.waypoints.length-1]},i.findOrCreate=function(t){return o[t.axis][t.name]||new i(t)},n.Group=i}(),function(){"use strict";function t(t){this.$element=e(t)}var e=window.jQuery,i=window.Waypoint;e.each(["innerHeight","innerWidth","off","offset","on","outerHeight","outerWidth","scrollLeft","scrollTop"],function(e,i){t.prototype[i]=function(){var t=Array.prototype.slice.call(arguments);return this.$element[i].apply(this.$element,t)}}),e.each(["extend","inArray","isEmptyObject"],function(i,o){t[o]=e[o]}),i.adapters.push({name:"jquery",Adapter:t}),i.Adapter=t}(),function(){"use strict";function t(t){return function(){var i=[],o=arguments[0];return t.isFunction(arguments[0])&&(o=t.extend({},arguments[1]),o.handler=arguments[0]),this.each(function(){var n=t.extend({},o,{element:this});"string"==typeof n.context&&(n.context=t(this).closest(n.context)[0]),i.push(new e(n))}),i}}var e=window.Waypoint;window.jQuery&&(window.jQuery.fn.waypoint=t(window.jQuery)),window.Zepto&&(window.Zepto.fn.waypoint=t(window.Zepto))}();
|
8 |
|
9 |
/*!
|
10 |
-
* jquery.counterup.js
|
11 |
-
*
|
12 |
-
* Copyright 2013, Benjamin Intal http://gambit.ph @bfintal
|
13 |
-
* Released under the GPL v2 License
|
14 |
-
*
|
15 |
-
*
|
16 |
-
|
|
|
|
|
|
|
17 |
|
18 |
|
19 |
// counter up
|
2 |
Waypoints - 4.0.0
|
3 |
Copyright © 2011-2015 Caleb Troughton
|
4 |
Licensed under the MIT license.
|
5 |
+
https://github.com/imakewebthings/waypoints/blog/master/licenses.txt
|
6 |
*/
|
7 |
!function(){"use strict";function t(o){if(!o)throw new Error("No options passed to Waypoint constructor");if(!o.element)throw new Error("No element option passed to Waypoint constructor");if(!o.handler)throw new Error("No handler option passed to Waypoint constructor");this.key="waypoint-"+e,this.options=t.Adapter.extend({},t.defaults,o),this.element=this.options.element,this.adapter=new t.Adapter(this.element),this.callback=o.handler,this.axis=this.options.horizontal?"horizontal":"vertical",this.enabled=this.options.enabled,this.triggerPoint=null,this.group=t.Group.findOrCreate({name:this.options.group,axis:this.axis}),this.context=t.Context.findOrCreateByElement(this.options.context),t.offsetAliases[this.options.offset]&&(this.options.offset=t.offsetAliases[this.options.offset]),this.group.add(this),this.context.add(this),i[this.key]=this,e+=1}var e=0,i={};t.prototype.queueTrigger=function(t){this.group.queueTrigger(this,t)},t.prototype.trigger=function(t){this.enabled&&this.callback&&this.callback.apply(this,t)},t.prototype.destroy=function(){this.context.remove(this),this.group.remove(this),delete i[this.key]},t.prototype.disable=function(){return this.enabled=!1,this},t.prototype.enable=function(){return this.context.refresh(),this.enabled=!0,this},t.prototype.next=function(){return this.group.next(this)},t.prototype.previous=function(){return this.group.previous(this)},t.invokeAll=function(t){var e=[];for(var o in i)e.push(i[o]);for(var n=0,r=e.length;r>n;n++)e[n][t]()},t.destroyAll=function(){t.invokeAll("destroy")},t.disableAll=function(){t.invokeAll("disable")},t.enableAll=function(){t.invokeAll("enable")},t.refreshAll=function(){t.Context.refreshAll()},t.viewportHeight=function(){return window.innerHeight||document.documentElement.clientHeight},t.viewportWidth=function(){return document.documentElement.clientWidth},t.adapters=[],t.defaults={context:window,continuous:!0,enabled:!0,group:"default",horizontal:!1,offset:0},t.offsetAliases={"bottom-in-view":function(){return this.context.innerHeight()-this.adapter.outerHeight()},"right-in-view":function(){return this.context.innerWidth()-this.adapter.outerWidth()}},window.Waypoint=t}(),function(){"use strict";function t(t){window.setTimeout(t,1e3/60)}function e(t){this.element=t,this.Adapter=n.Adapter,this.adapter=new this.Adapter(t),this.key="waypoint-context-"+i,this.didScroll=!1,this.didResize=!1,this.oldScroll={x:this.adapter.scrollLeft(),y:this.adapter.scrollTop()},this.waypoints={vertical:{},horizontal:{}},t.waypointContextKey=this.key,o[t.waypointContextKey]=this,i+=1,this.createThrottledScrollHandler(),this.createThrottledResizeHandler()}var i=0,o={},n=window.Waypoint,r=window.onload;e.prototype.add=function(t){var e=t.options.horizontal?"horizontal":"vertical";this.waypoints[e][t.key]=t,this.refresh()},e.prototype.checkEmpty=function(){var t=this.Adapter.isEmptyObject(this.waypoints.horizontal),e=this.Adapter.isEmptyObject(this.waypoints.vertical);t&&e&&(this.adapter.off(".waypoints"),delete o[this.key])},e.prototype.createThrottledResizeHandler=function(){function t(){e.handleResize(),e.didResize=!1}var e=this;this.adapter.on("resize.waypoints",function(){e.didResize||(e.didResize=!0,n.requestAnimationFrame(t))})},e.prototype.createThrottledScrollHandler=function(){function t(){e.handleScroll(),e.didScroll=!1}var e=this;this.adapter.on("scroll.waypoints",function(){(!e.didScroll||n.isTouch)&&(e.didScroll=!0,n.requestAnimationFrame(t))})},e.prototype.handleResize=function(){n.Context.refreshAll()},e.prototype.handleScroll=function(){var t={},e={horizontal:{newScroll:this.adapter.scrollLeft(),oldScroll:this.oldScroll.x,forward:"right",backward:"left"},vertical:{newScroll:this.adapter.scrollTop(),oldScroll:this.oldScroll.y,forward:"down",backward:"up"}};for(var i in e){var o=e[i],n=o.newScroll>o.oldScroll,r=n?o.forward:o.backward;for(var s in this.waypoints[i]){var a=this.waypoints[i][s],l=o.oldScroll<a.triggerPoint,h=o.newScroll>=a.triggerPoint,p=l&&h,u=!l&&!h;(p||u)&&(a.queueTrigger(r),t[a.group.id]=a.group)}}for(var c in t)t[c].flushTriggers();this.oldScroll={x:e.horizontal.newScroll,y:e.vertical.newScroll}},e.prototype.innerHeight=function(){return this.element==this.element.window?n.viewportHeight():this.adapter.innerHeight()},e.prototype.remove=function(t){delete this.waypoints[t.axis][t.key],this.checkEmpty()},e.prototype.innerWidth=function(){return this.element==this.element.window?n.viewportWidth():this.adapter.innerWidth()},e.prototype.destroy=function(){var t=[];for(var e in this.waypoints)for(var i in this.waypoints[e])t.push(this.waypoints[e][i]);for(var o=0,n=t.length;n>o;o++)t[o].destroy()},e.prototype.refresh=function(){var t,e=this.element==this.element.window,i=e?void 0:this.adapter.offset(),o={};this.handleScroll(),t={horizontal:{contextOffset:e?0:i.left,contextScroll:e?0:this.oldScroll.x,contextDimension:this.innerWidth(),oldScroll:this.oldScroll.x,forward:"right",backward:"left",offsetProp:"left"},vertical:{contextOffset:e?0:i.top,contextScroll:e?0:this.oldScroll.y,contextDimension:this.innerHeight(),oldScroll:this.oldScroll.y,forward:"down",backward:"up",offsetProp:"top"}};for(var r in t){var s=t[r];for(var a in this.waypoints[r]){var l,h,p,u,c,d=this.waypoints[r][a],f=d.options.offset,w=d.triggerPoint,y=0,g=null==w;d.element!==d.element.window&&(y=d.adapter.offset()[s.offsetProp]),"function"==typeof f?f=f.apply(d):"string"==typeof f&&(f=parseFloat(f),d.options.offset.indexOf("%")>-1&&(f=Math.ceil(s.contextDimension*f/100))),l=s.contextScroll-s.contextOffset,d.triggerPoint=y+l-f,h=w<s.oldScroll,p=d.triggerPoint>=s.oldScroll,u=h&&p,c=!h&&!p,!g&&u?(d.queueTrigger(s.backward),o[d.group.id]=d.group):!g&&c?(d.queueTrigger(s.forward),o[d.group.id]=d.group):g&&s.oldScroll>=d.triggerPoint&&(d.queueTrigger(s.forward),o[d.group.id]=d.group)}}return n.requestAnimationFrame(function(){for(var t in o)o[t].flushTriggers()}),this},e.findOrCreateByElement=function(t){return e.findByElement(t)||new e(t)},e.refreshAll=function(){for(var t in o)o[t].refresh()},e.findByElement=function(t){return o[t.waypointContextKey]},window.onload=function(){r&&r(),e.refreshAll()},n.requestAnimationFrame=function(e){var i=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||t;i.call(window,e)},n.Context=e}(),function(){"use strict";function t(t,e){return t.triggerPoint-e.triggerPoint}function e(t,e){return e.triggerPoint-t.triggerPoint}function i(t){this.name=t.name,this.axis=t.axis,this.id=this.name+"-"+this.axis,this.waypoints=[],this.clearTriggerQueues(),o[this.axis][this.name]=this}var o={vertical:{},horizontal:{}},n=window.Waypoint;i.prototype.add=function(t){this.waypoints.push(t)},i.prototype.clearTriggerQueues=function(){this.triggerQueues={up:[],down:[],left:[],right:[]}},i.prototype.flushTriggers=function(){for(var i in this.triggerQueues){var o=this.triggerQueues[i],n="up"===i||"left"===i;o.sort(n?e:t);for(var r=0,s=o.length;s>r;r+=1){var a=o[r];(a.options.continuous||r===o.length-1)&&a.trigger([i])}}this.clearTriggerQueues()},i.prototype.next=function(e){this.waypoints.sort(t);var i=n.Adapter.inArray(e,this.waypoints),o=i===this.waypoints.length-1;return o?null:this.waypoints[i+1]},i.prototype.previous=function(e){this.waypoints.sort(t);var i=n.Adapter.inArray(e,this.waypoints);return i?this.waypoints[i-1]:null},i.prototype.queueTrigger=function(t,e){this.triggerQueues[e].push(t)},i.prototype.remove=function(t){var e=n.Adapter.inArray(t,this.waypoints);e>-1&&this.waypoints.splice(e,1)},i.prototype.first=function(){return this.waypoints[0]},i.prototype.last=function(){return this.waypoints[this.waypoints.length-1]},i.findOrCreate=function(t){return o[t.axis][t.name]||new i(t)},n.Group=i}(),function(){"use strict";function t(t){this.$element=e(t)}var e=window.jQuery,i=window.Waypoint;e.each(["innerHeight","innerWidth","off","offset","on","outerHeight","outerWidth","scrollLeft","scrollTop"],function(e,i){t.prototype[i]=function(){var t=Array.prototype.slice.call(arguments);return this.$element[i].apply(this.$element,t)}}),e.each(["extend","inArray","isEmptyObject"],function(i,o){t[o]=e[o]}),i.adapters.push({name:"jquery",Adapter:t}),i.Adapter=t}(),function(){"use strict";function t(t){return function(){var i=[],o=arguments[0];return t.isFunction(arguments[0])&&(o=t.extend({},arguments[1]),o.handler=arguments[0]),this.each(function(){var n=t.extend({},o,{element:this});"string"==typeof n.context&&(n.context=t(this).closest(n.context)[0]),i.push(new e(n))}),i}}var e=window.Waypoint;window.jQuery&&(window.jQuery.fn.waypoint=t(window.jQuery)),window.Zepto&&(window.Zepto.fn.waypoint=t(window.Zepto))}();
|
8 |
|
9 |
/*!
|
10 |
+
* jquery.counterup.js 2.0.0
|
11 |
+
*
|
12 |
+
* Copyright 2013, Benjamin Intal http://gambit.ph @bfintal
|
13 |
+
* Released under the GPL v2 License
|
14 |
+
*
|
15 |
+
* Amended by Ciro Mattia Gonano and others
|
16 |
+
*
|
17 |
+
* Date: Mar 24, 2016
|
18 |
+
*/
|
19 |
+
!function(t){"use strict";t.fn.counterUp=function(e){var a,n=t.extend({time:400,delay:10,formatter:!1,callback:function(){}},e);return this.each(function(){var e=t(this),u={time:t(this).data("counterup-time")||n.time,delay:t(this).data("counterup-delay")||n.delay};e.waypoint(function(t){!function(){var t=[],r=u.time/u.delay,o=e.text(),i=/[0-9]+,[0-9]+/.test(o),c=((o=o.replace(/,/g,"")).split(".")[1]||[]).length,s=/[0-9]+:[0-9]+:[0-9]+/.test(o);if(s){var l=o.split(":"),f=1;for(a=0;l.length>0;)a+=f*parseInt(l.pop(),10),f*=60}for(var d=r;d>=1;d--){var p=parseFloat(o/r*d).toFixed(c);if(s){p=parseInt(a/r*d);var m=parseInt(p/3600)%24,h=parseInt(p/60)%60,y=parseInt(p%60,10);p=(m<10?"0"+m:m)+":"+(h<10?"0"+h:h)+":"+(y<10?"0"+y:y)}if(i)for(;/(\d+)(\d{3})/.test(p.toString());)p=p.toString().replace(/(\d+)(\d{3})/,"$1,$2");n.formatter&&(p=n.formatter.call(this,p)),t.unshift(p)}e.data("counterup-nums",t),e.text("0");e.data("counterup-func",function(){e.html(e.data("counterup-nums").shift()),e.data("counterup-nums").length?setTimeout(e.data("counterup-func"),u.delay):(e.data("counterup-nums",null),e.data("counterup-func",null),n.callback.call(this))}),setTimeout(e.data("counterup-func"),u.delay)}(),this.destroy()},{offset:"100%"})})}}(jQuery);
|
20 |
|
21 |
|
22 |
// counter up
|
inc/aviser/aviser.php
ADDED
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @package Avril
|
4 |
+
*/
|
5 |
+
|
6 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/avril/extras.php';
|
7 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/aviser/extras.php';
|
8 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/avril/dynamic-style.php';
|
9 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/aviser/sections/above-header.php';
|
10 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/aviser/features/avril-header.php';
|
11 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/avail/features/avril-cta.php';
|
12 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/avril/features/avril-features.php';
|
13 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/avril/features/avril-info.php';
|
14 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/avril/features/avril-service.php';
|
15 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/avril/features/avril-slider.php';
|
16 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/axtria/features/avril-funfact.php';
|
17 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/avril/features/avril-typography.php';
|
18 |
+
|
19 |
+
if ( ! function_exists( 'cleverfox_avril_frontpage_sections' ) ) :
|
20 |
+
function cleverfox_avril_frontpage_sections() {
|
21 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/avril/sections/section-slider.php';
|
22 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/avril/sections/section-info.php';
|
23 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/avril/sections/section-service.php';
|
24 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/aviser/sections/section-features.php';
|
25 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/axtria/sections/section-funfact.php';
|
26 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/aviser/sections/section-cta-2.php';
|
27 |
+
}
|
28 |
+
add_action( 'avril_sections', 'cleverfox_avril_frontpage_sections' );
|
29 |
+
endif;
|
30 |
+
|
31 |
+
function cleverfox_avril_enqueue_scripts() {
|
32 |
+
wp_enqueue_script( 'counterup', CLEVERFOX_PLUGIN_URL .'/inc/assets/js/jquery.counterup.min.js', array('jquery'), false, true);
|
33 |
+
wp_enqueue_style('animate',CLEVERFOX_PLUGIN_URL .'/inc/assets/css/animate.css');
|
34 |
+
wp_enqueue_style('owl-carousel-min',CLEVERFOX_PLUGIN_URL .'/inc/assets/css/owl.carousel.min.css');
|
35 |
+
wp_enqueue_script( 'owl-carousel', CLEVERFOX_PLUGIN_URL . 'inc/assets/js/owl.carousel.min.js', array('jquery'), false, true);
|
36 |
+
}
|
37 |
+
add_action( 'wp_enqueue_scripts', 'cleverfox_avril_enqueue_scripts' );
|
inc/aviser/default-pages/home-page.php
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
//post status and options
|
3 |
+
$post = array(
|
4 |
+
'comment_status' => 'closed',
|
5 |
+
'ping_status' => 'closed' ,
|
6 |
+
'post_author' => 1,
|
7 |
+
'post_date' => date('Y-m-d H:i:s'),
|
8 |
+
'post_name' => 'Home',
|
9 |
+
'post_status' => 'publish' ,
|
10 |
+
'post_title' => 'Home',
|
11 |
+
'post_type' => 'page',
|
12 |
+
);
|
13 |
+
//insert page and save the id
|
14 |
+
$newvalue = wp_insert_post( $post, false );
|
15 |
+
if ( $newvalue && ! is_wp_error( $newvalue ) ){
|
16 |
+
update_post_meta( $newvalue, '_wp_page_template', 'templates/template-homepage.php' );
|
17 |
+
|
18 |
+
// Use a static front page
|
19 |
+
$page = get_page_by_title('Home');
|
20 |
+
update_option( 'show_on_front', 'page' );
|
21 |
+
update_option( 'page_on_front', $page->ID );
|
22 |
+
|
23 |
+
}
|
24 |
+
?>
|
inc/aviser/default-pages/upload-media.php
ADDED
@@ -0,0 +1,32 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
$file = CLEVERFOX_PLUGIN_URL .'inc/aviser/images/logo.png';
|
3 |
+
$ImagePath = CLEVERFOX_PLUGIN_URL .'inc/aviser/images';
|
4 |
+
|
5 |
+
$images = array(
|
6 |
+
$ImagePath. '/logo.png',
|
7 |
+
);
|
8 |
+
$parent_post_id = null;
|
9 |
+
foreach($images as $name) {
|
10 |
+
$filename = basename($name);
|
11 |
+
$upload_file = wp_upload_bits($filename, null, file_get_contents($name));
|
12 |
+
if (!$upload_file['error']) {
|
13 |
+
$wp_filetype = wp_check_filetype($filename, null );
|
14 |
+
$attachment = array(
|
15 |
+
'post_mime_type' => $wp_filetype['type'],
|
16 |
+
'post_parent' => $parent_post_id,
|
17 |
+
'post_title' => preg_replace('/\.[^.]+$/', '', $filename),
|
18 |
+
'post_excerpt' => 'avril caption',
|
19 |
+
'post_status' => 'inherit'
|
20 |
+
);
|
21 |
+
$ImageId[] = $attachment_id = wp_insert_attachment( $attachment, $upload_file['file'], $parent_post_id );
|
22 |
+
|
23 |
+
if (!is_wp_error($attachment_id)) {
|
24 |
+
require_once(ABSPATH . "wp-admin" . '/includes/image.php');
|
25 |
+
$attachment_data = wp_generate_attachment_metadata( $attachment_id, $upload_file['file'] );
|
26 |
+
wp_update_attachment_metadata( $attachment_id, $attachment_data );
|
27 |
+
}
|
28 |
+
}
|
29 |
+
|
30 |
+
}
|
31 |
+
|
32 |
+
update_option( 'avril_media_id', $ImageId );
|
inc/aviser/default-widgets/default-widget.php
ADDED
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
$activate = array(
|
3 |
+
'avril-sidebar-primary' => array(
|
4 |
+
'search-1',
|
5 |
+
'recent-posts-1',
|
6 |
+
'archives-1',
|
7 |
+
),
|
8 |
+
'avril-footer-widget-area' => array(
|
9 |
+
'text-1',
|
10 |
+
'categories-1',
|
11 |
+
'archives-1',
|
12 |
+
'search-1',
|
13 |
+
)
|
14 |
+
);
|
15 |
+
/* the default titles will appear */
|
16 |
+
update_option('widget_text', array(
|
17 |
+
1 => array('title' => '',
|
18 |
+
'text'=>'<div class="footer-logo"><img src="'.CLEVERFOX_PLUGIN_URL.'inc/aviser/images/logo-2.png" alt=""></div>
|
19 |
+
<p>There are many variations of dummy passages of Lorem Ipsum a available, but the majority have suffered that is alteration in some that form injected humour or randomised.</p>
|
20 |
+
'),
|
21 |
+
2 => array('title' => 'Recent Posts'),
|
22 |
+
3 => array('title' => 'Categories'),
|
23 |
+
));
|
24 |
+
update_option('widget_categories', array(
|
25 |
+
1 => array('title' => 'Categories'),
|
26 |
+
2 => array('title' => 'Categories')));
|
27 |
+
|
28 |
+
update_option('widget_archives', array(
|
29 |
+
1 => array('title' => 'Archives'),
|
30 |
+
2 => array('title' => 'Archives')));
|
31 |
+
|
32 |
+
update_option('widget_search', array(
|
33 |
+
1 => array('title' => 'Search'),
|
34 |
+
2 => array('title' => 'Search')));
|
35 |
+
|
36 |
+
update_option('sidebars_widgets', $activate);
|
37 |
+
$MediaId = get_option('avril_media_id');
|
38 |
+
set_theme_mod( 'custom_logo', $MediaId[0] );
|
inc/aviser/extras.php
ADDED
@@ -0,0 +1,73 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @package Aviser
|
4 |
+
*/
|
5 |
+
if ( ! function_exists( 'avril_above_header_contact_info' ) ) :
|
6 |
+
function avril_above_header_contact_info() {
|
7 |
+
$hide_show_cntct_details = get_theme_mod( 'hide_show_cntct_details','1');
|
8 |
+
$hide_show_email_details = get_theme_mod( 'hide_show_email_details','1');
|
9 |
+
$hide_show_mbl_details = get_theme_mod( 'hide_show_mbl_details','1');
|
10 |
+
if($hide_show_cntct_details == '1' || $hide_show_email_details == '1' || $hide_show_mbl_details == '1') {
|
11 |
+
?>
|
12 |
+
<div class="contact-details">
|
13 |
+
<div class="widget-right text-av-right text-center">
|
14 |
+
<?php
|
15 |
+
$tlh_contct_icon = get_theme_mod( 'tlh_contct_icon','fa-clock-o');
|
16 |
+
$tlh_contact_title = get_theme_mod( 'tlh_contact_title','8:00AM - 6:00PM');
|
17 |
+
$tlh_contact_sbtitle = get_theme_mod( 'tlh_contact_sbtitle','Monday to Saturday');
|
18 |
+
?>
|
19 |
+
<?php if($hide_show_cntct_details == '1') { ?>
|
20 |
+
<aside class="widget widget-contact wgt-1">
|
21 |
+
<div class="contact-area">
|
22 |
+
<div class="contact-icon">
|
23 |
+
<i class="fa <?php echo esc_attr($tlh_contct_icon); ?>"></i>
|
24 |
+
</div>
|
25 |
+
<a href="javascript:void(0)" class="contact-info">
|
26 |
+
<span class="text"><?php echo esc_html($tlh_contact_title); ?></span>
|
27 |
+
<span class="title"><?php echo esc_html($tlh_contact_sbtitle); ?></span>
|
28 |
+
</a>
|
29 |
+
</div>
|
30 |
+
</aside>
|
31 |
+
<?php } ?>
|
32 |
+
<?php
|
33 |
+
$tlh_email_icon = get_theme_mod( 'tlh_email_icon','fa-phone');
|
34 |
+
$tlh_email_title = get_theme_mod( 'tlh_email_title','Email Us');
|
35 |
+
$tlh_email_sbtitle = get_theme_mod( 'tlh_email_sbtitle','email@email.com');
|
36 |
+
?>
|
37 |
+
<?php if($hide_show_email_details == '1') { ?>
|
38 |
+
<aside class="widget widget-contact wgt-2">
|
39 |
+
<div class="contact-area">
|
40 |
+
<div class="contact-icon">
|
41 |
+
<i class="fa <?php echo esc_attr($tlh_email_icon); ?>"></i>
|
42 |
+
</div>
|
43 |
+
<a href="mailto:<?php echo esc_html($tlh_email_sbtitle); ?>" class="contact-info">
|
44 |
+
<span class="text"><?php echo esc_html($tlh_email_title); ?></span>
|
45 |
+
<span class="title"><?php echo esc_html($tlh_email_sbtitle); ?></span>
|
46 |
+
</a>
|
47 |
+
</div>
|
48 |
+
</aside>
|
49 |
+
<?php } ?>
|
50 |
+
<?php
|
51 |
+
$tlh_mobile_icon = get_theme_mod( 'tlh_mobile_icon','fa-map-marker');
|
52 |
+
$tlh_mobile_title = get_theme_mod( 'tlh_mobile_title','Online 24x7');
|
53 |
+
$tlh_mobile_sbtitle = get_theme_mod( 'tlh_mobile_sbtitle','+1-0120-400-00-00');
|
54 |
+
?>
|
55 |
+
<?php if($hide_show_mbl_details == '1') { ?>
|
56 |
+
<aside class="widget widget-contact wgt-3">
|
57 |
+
<div class="contact-area">
|
58 |
+
<div class="contact-icon">
|
59 |
+
<i class="fa <?php echo esc_attr($tlh_mobile_icon); ?>"></i>
|
60 |
+
</div>
|
61 |
+
<a href="tel:<?php echo esc_html($tlh_mobile_sbtitle); ?>" class="contact-info">
|
62 |
+
<span class="text"><?php echo esc_html($tlh_mobile_title); ?></span>
|
63 |
+
<span class="title"><?php echo esc_html($tlh_mobile_sbtitle); ?></span>
|
64 |
+
</a>
|
65 |
+
</div>
|
66 |
+
</aside>
|
67 |
+
<?php } ?>
|
68 |
+
</div>
|
69 |
+
</div>
|
70 |
+
|
71 |
+
<?php
|
72 |
+
}} endif;
|
73 |
+
add_action('avril_above_header_contact_info', 'avril_above_header_contact_info');
|
inc/aviser/features/avril-header.php
ADDED
@@ -0,0 +1,721 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
function aviser_lite_header_settings( $wp_customize ) {
|
3 |
+
$selective_refresh = isset( $wp_customize->selective_refresh ) ? 'postMessage' : 'refresh';
|
4 |
+
/*=========================================
|
5 |
+
Header Settings Panel
|
6 |
+
=========================================*/
|
7 |
+
$wp_customize->add_panel(
|
8 |
+
'header_section',
|
9 |
+
array(
|
10 |
+
'priority' => 2,
|
11 |
+
'capability' => 'edit_theme_options',
|
12 |
+
'title' => __('Header', 'clever-fox'),
|
13 |
+
)
|
14 |
+
);
|
15 |
+
|
16 |
+
/*=========================================
|
17 |
+
Avril Site Identity
|
18 |
+
=========================================*/
|
19 |
+
|
20 |
+
// Logo Width //
|
21 |
+
if ( class_exists( 'Cleverfox_Customizer_Range_Slider_Control' ) ) {
|
22 |
+
$wp_customize->add_setting(
|
23 |
+
'logo_width',
|
24 |
+
array(
|
25 |
+
'default' => '140',
|
26 |
+
'capability' => 'edit_theme_options',
|
27 |
+
'sanitize_callback' => 'avril_sanitize_range_value',
|
28 |
+
'transport' => 'postMessage',
|
29 |
+
)
|
30 |
+
);
|
31 |
+
$wp_customize->add_control(
|
32 |
+
new Cleverfox_Customizer_Range_Slider_Control( $wp_customize, 'logo_width',
|
33 |
+
array(
|
34 |
+
'label' => __( 'Logo Width', 'clever-fox' ),
|
35 |
+
'section' => 'title_tagline',
|
36 |
+
'input_attrs' => array(
|
37 |
+
'min' => 0,
|
38 |
+
'max' => 500,
|
39 |
+
'step' => 1,
|
40 |
+
//'suffix' => 'px', //optional suffix
|
41 |
+
),
|
42 |
+
) )
|
43 |
+
);
|
44 |
+
}
|
45 |
+
|
46 |
+
/*=========================================
|
47 |
+
Above Header Section
|
48 |
+
=========================================*/
|
49 |
+
$wp_customize->add_section(
|
50 |
+
'above_header',
|
51 |
+
array(
|
52 |
+
'priority' => 2,
|
53 |
+
'title' => __('Above Header','clever-fox'),
|
54 |
+
'panel' => 'header_section',
|
55 |
+
)
|
56 |
+
);
|
57 |
+
|
58 |
+
// Social
|
59 |
+
$wp_customize->add_setting(
|
60 |
+
'hdr_top_social'
|
61 |
+
,array(
|
62 |
+
'capability' => 'edit_theme_options',
|
63 |
+
'sanitize_callback' => 'avril_sanitize_text',
|
64 |
+
'priority' => 1,
|
65 |
+
)
|
66 |
+
);
|
67 |
+
|
68 |
+
$wp_customize->add_control(
|
69 |
+
'hdr_top_social',
|
70 |
+
array(
|
71 |
+
'type' => 'hidden',
|
72 |
+
'label' => __('Social Icons','clever-fox'),
|
73 |
+
'section' => 'above_header',
|
74 |
+
|
75 |
+
)
|
76 |
+
);
|
77 |
+
|
78 |
+
$wp_customize->add_setting(
|
79 |
+
'hide_show_social_icon' ,
|
80 |
+
array(
|
81 |
+
'default' => '1',
|
82 |
+
'capability' => 'edit_theme_options',
|
83 |
+
'sanitize_callback' => 'avril_sanitize_checkbox',
|
84 |
+
'priority' => 1,
|
85 |
+
)
|
86 |
+
);
|
87 |
+
|
88 |
+
$wp_customize->add_control(
|
89 |
+
'hide_show_social_icon',
|
90 |
+
array(
|
91 |
+
'label' => esc_html__( 'Hide/Show', 'clever-fox' ),
|
92 |
+
'section' => 'above_header',
|
93 |
+
'type' => 'checkbox'
|
94 |
+
)
|
95 |
+
);
|
96 |
+
|
97 |
+
/**
|
98 |
+
* Customizer Repeater
|
99 |
+
*/
|
100 |
+
$wp_customize->add_setting( 'social_icons',
|
101 |
+
array(
|
102 |
+
'sanitize_callback' => 'avril_repeater_sanitize',
|
103 |
+
'priority' => 2,
|
104 |
+
'default' => avril_get_social_icon_default()
|
105 |
+
)
|
106 |
+
);
|
107 |
+
|
108 |
+
$wp_customize->add_control(
|
109 |
+
new AVRIL_Repeater( $wp_customize,
|
110 |
+
'social_icons',
|
111 |
+
array(
|
112 |
+
'label' => esc_html__('Social Icons','clever-fox'),
|
113 |
+
'section' => 'above_header',
|
114 |
+
'add_field_label' => esc_html__( 'Add New Social', 'clever-fox' ),
|
115 |
+
'item_name' => esc_html__( 'Social', 'clever-fox' ),
|
116 |
+
'customizer_repeater_icon_control' => true,
|
117 |
+
'customizer_repeater_link_control' => true,
|
118 |
+
)
|
119 |
+
)
|
120 |
+
);
|
121 |
+
|
122 |
+
//Pro feature
|
123 |
+
class Avril_social__section_upgrade extends WP_Customize_Control {
|
124 |
+
public function render_content() {
|
125 |
+
$theme = wp_get_theme(); // gets the current theme
|
126 |
+
if ( 'Aera' == $theme->name){
|
127 |
+
?>
|
128 |
+
<a class="customizer_social_upgrade_section up-to-pro" href="https://www.nayrathemes.com/aera-pro/" target="_blank" style="display: none;"><?php _e('Upgrade to Pro','clever-fox'); ?></a>
|
129 |
+
|
130 |
+
<?php }elseif ( 'Avail' == $theme->name){ ?>
|
131 |
+
|
132 |
+
<a class="customizer_social_upgrade_section up-to-pro" href="https://www.nayrathemes.com/avail-pro/" target="_blank" style="display: none;"><?php _e('Upgrade to Pro','clever-fox'); ?></a>
|
133 |
+
|
134 |
+
<?php }elseif ( 'Axtia' == $theme->name){ ?>
|
135 |
+
|
136 |
+
<a class="customizer_social_upgrade_section up-to-pro" href="https://www.nayrathemes.com/axtia-pro/" target="_blank" style="display: none;"><?php _e('Upgrade to Pro','clever-fox'); ?></a>
|
137 |
+
|
138 |
+
<?php }elseif ( 'Avtari' == $theme->name){ ?>
|
139 |
+
|
140 |
+
<a class="customizer_social_upgrade_section up-to-pro" href="https://www.nayrathemes.com/avtari-pro/" target="_blank" style="display: none;"><?php _e('Upgrade to Pro','clever-fox'); ?></a>
|
141 |
+
|
142 |
+
<?php
|
143 |
+
}else{
|
144 |
+
?>
|
145 |
+
<a class="customizer_social_upgrade_section up-to-pro" href="https://www.nayrathemes.com/avril-pro/" target="_blank" style="display: none;"><?php _e('Upgrade to Pro','clever-fox'); ?></a>
|
146 |
+
<?php
|
147 |
+
}
|
148 |
+
}
|
149 |
+
}
|
150 |
+
|
151 |
+
$wp_customize->add_setting( 'avril_social_upgrade_to_pro', array(
|
152 |
+
'capability' => 'edit_theme_options',
|
153 |
+
'sanitize_callback' => 'wp_filter_nohtml_kses',
|
154 |
+
));
|
155 |
+
$wp_customize->add_control(
|
156 |
+
new Avril_social__section_upgrade(
|
157 |
+
$wp_customize,
|
158 |
+
'avril_social_upgrade_to_pro',
|
159 |
+
array(
|
160 |
+
'section' => 'above_header',
|
161 |
+
'settings' => 'avril_social_upgrade_to_pro',
|
162 |
+
)
|
163 |
+
)
|
164 |
+
);
|
165 |
+
|
166 |
+
|
167 |
+
// Welcome
|
168 |
+
$wp_customize->add_setting(
|
169 |
+
'hdr_top_welcome'
|
170 |
+
,array(
|
171 |
+
'capability' => 'edit_theme_options',
|
172 |
+
'sanitize_callback' => 'avril_sanitize_text',
|
173 |
+
)
|
174 |
+
);
|
175 |
+
|
176 |
+
$wp_customize->add_control(
|
177 |
+
'hdr_top_welcome',
|
178 |
+
array(
|
179 |
+
'type' => 'hidden',
|
180 |
+
'label' => __('Welcome Content','clever-fox'),
|
181 |
+
'section' => 'above_header',
|
182 |
+
|
183 |
+
)
|
184 |
+
);
|
185 |
+
|
186 |
+
// Hide / Show
|
187 |
+
$wp_customize->add_setting(
|
188 |
+
'hs_hdr_welcome' ,
|
189 |
+
array(
|
190 |
+
'default' => '1',
|
191 |
+
'capability' => 'edit_theme_options',
|
192 |
+
'sanitize_callback' => 'avril_sanitize_checkbox',
|
193 |
+
)
|
194 |
+
);
|
195 |
+
|
196 |
+
$wp_customize->add_control(
|
197 |
+
'hs_hdr_welcome',
|
198 |
+
array(
|
199 |
+
'label' => esc_html__( 'Hide/Show', 'clever-fox' ),
|
200 |
+
'section' => 'above_header',
|
201 |
+
'type' => 'checkbox'
|
202 |
+
)
|
203 |
+
);
|
204 |
+
|
205 |
+
// icon //
|
206 |
+
$wp_customize->add_setting(
|
207 |
+
'hdr_welcome_icon',
|
208 |
+
array(
|
209 |
+
'default' => 'fa-building-o',
|
210 |
+
'sanitize_callback' => 'sanitize_text_field',
|
211 |
+
'capability' => 'edit_theme_options',
|
212 |
+
)
|
213 |
+
);
|
214 |
+
|
215 |
+
$wp_customize->add_control(new Avril_Icon_Picker_Control($wp_customize,
|
216 |
+
'hdr_welcome_icon',
|
217 |
+
array(
|
218 |
+
'label' => __('Icon','clever-fox'),
|
219 |
+
'section' => 'above_header',
|
220 |
+
'iconset' => 'fa',
|
221 |
+
|
222 |
+
))
|
223 |
+
);
|
224 |
+
|
225 |
+
|
226 |
+
// title //
|
227 |
+
$wp_customize->add_setting(
|
228 |
+
'hdr_welcome_ttl',
|
229 |
+
array(
|
230 |
+
'default' => __('Welcome to our Business Agency','clever-fox'),
|
231 |
+
'sanitize_callback' => 'avril_sanitize_text',
|
232 |
+
'transport' => $selective_refresh,
|
233 |
+
'capability' => 'edit_theme_options',
|
234 |
+
)
|
235 |
+
);
|
236 |
+
|
237 |
+
$wp_customize->add_control(
|
238 |
+
'hdr_welcome_ttl',
|
239 |
+
array(
|
240 |
+
'label' => __('Title','clever-fox'),
|
241 |
+
'section' => 'above_header',
|
242 |
+
'type' => 'text'
|
243 |
+
)
|
244 |
+
);
|
245 |
+
|
246 |
+
|
247 |
+
// Time
|
248 |
+
$wp_customize->add_setting(
|
249 |
+
'hdr_top_time'
|
250 |
+
,array(
|
251 |
+
'capability' => 'edit_theme_options',
|
252 |
+
'sanitize_callback' => 'avril_sanitize_text',
|
253 |
+
)
|
254 |
+
);
|
255 |
+
|
256 |
+
$wp_customize->add_control(
|
257 |
+
'hdr_top_time',
|
258 |
+
array(
|
259 |
+
'type' => 'hidden',
|
260 |
+
'label' => __('Time','clever-fox'),
|
261 |
+
'section' => 'above_header',
|
262 |
+
|
263 |
+
)
|
264 |
+
);
|
265 |
+
|
266 |
+
// Hide / Show
|
267 |
+
$wp_customize->add_setting(
|
268 |
+
'hs_hdr_time' ,
|
269 |
+
array(
|
270 |
+
'default' => '1',
|
271 |
+
'capability' => 'edit_theme_options',
|
272 |
+
'sanitize_callback' => 'avril_sanitize_checkbox',
|
273 |
+
)
|
274 |
+
);
|
275 |
+
|
276 |
+
$wp_customize->add_control(
|
277 |
+
'hs_hdr_time',
|
278 |
+
array(
|
279 |
+
'label' => esc_html__( 'Hide/Show', 'clever-fox' ),
|
280 |
+
'section' => 'above_header',
|
281 |
+
'type' => 'checkbox'
|
282 |
+
)
|
283 |
+
);
|
284 |
+
|
285 |
+
// icon //
|
286 |
+
$wp_customize->add_setting(
|
287 |
+
'hdr_time_icon',
|
288 |
+
array(
|
289 |
+
'default' => 'fa-clock-o',
|
290 |
+
'sanitize_callback' => 'sanitize_text_field',
|
291 |
+
'capability' => 'edit_theme_options',
|
292 |
+
)
|
293 |
+
);
|
294 |
+
|
295 |
+
$wp_customize->add_control(new Avril_Icon_Picker_Control($wp_customize,
|
296 |
+
'hdr_time_icon',
|
297 |
+
array(
|
298 |
+
'label' => __('Icon','clever-fox'),
|
299 |
+
'section' => 'above_header',
|
300 |
+
'iconset' => 'fa',
|
301 |
+
|
302 |
+
))
|
303 |
+
);
|
304 |
+
|
305 |
+
// title //
|
306 |
+
$wp_customize->add_setting(
|
307 |
+
'hdr_time_title',
|
308 |
+
array(
|
309 |
+
'default' => __('Opening Hours - 10 Am to 6 PM','clever-fox'),
|
310 |
+
'sanitize_callback' => 'avril_sanitize_text',
|
311 |
+
'transport' => $selective_refresh,
|
312 |
+
'capability' => 'edit_theme_options',
|
313 |
+
)
|
314 |
+
);
|
315 |
+
|
316 |
+
$wp_customize->add_control(
|
317 |
+
'hdr_time_title',
|
318 |
+
array(
|
319 |
+
'label' => __('Title','clever-fox'),
|
320 |
+
'section' => 'above_header',
|
321 |
+
'type' => 'text'
|
322 |
+
)
|
323 |
+
);
|
324 |
+
|
325 |
+
// Mobile
|
326 |
+
$wp_customize->add_setting(
|
327 |
+
'hdr_top_mbl'
|
328 |
+
,array(
|
329 |
+
'capability' => 'edit_theme_options',
|
330 |
+
'sanitize_callback' => 'avril_sanitize_text',
|
331 |
+
'priority' => 1,
|
332 |
+
)
|
333 |
+
);
|
334 |
+
|
335 |
+
$wp_customize->add_control(
|
336 |
+
'hdr_top_mbl',
|
337 |
+
array(
|
338 |
+
'type' => 'hidden',
|
339 |
+
'label' => __('Phone','clever-fox'),
|
340 |
+
'section' => 'above_header',
|
341 |
+
|
342 |
+
)
|
343 |
+
);
|
344 |
+
$wp_customize->add_setting(
|
345 |
+
'hide_show_mbl_details' ,
|
346 |
+
array(
|
347 |
+
'default' => '1',
|
348 |
+
'capability' => 'edit_theme_options',
|
349 |
+
'sanitize_callback' => 'avril_sanitize_checkbox',
|
350 |
+
'priority' => 2,
|
351 |
+
)
|
352 |
+
);
|
353 |
+
|
354 |
+
$wp_customize->add_control(
|
355 |
+
'hide_show_mbl_details',
|
356 |
+
array(
|
357 |
+
'label' => esc_html__( 'Hide/Show', 'clever-fox' ),
|
358 |
+
'section' => 'above_header',
|
359 |
+
'type' => 'checkbox'
|
360 |
+
)
|
361 |
+
);
|
362 |
+
// icon //
|
363 |
+
$wp_customize->add_setting(
|
364 |
+
'tlh_mobile_icon',
|
365 |
+
array(
|
366 |
+
'default' => 'fa-map-marker',
|
367 |
+
'sanitize_callback' => 'sanitize_text_field',
|
368 |
+
'capability' => 'edit_theme_options',
|
369 |
+
)
|
370 |
+
);
|
371 |
+
|
372 |
+
$wp_customize->add_control(new Avril_Icon_Picker_Control($wp_customize,
|
373 |
+
'tlh_mobile_icon',
|
374 |
+
array(
|
375 |
+
'label' => __('Icon','clever-fox'),
|
376 |
+
'section' => 'above_header',
|
377 |
+
'iconset' => 'fa',
|
378 |
+
|
379 |
+
))
|
380 |
+
);
|
381 |
+
|
382 |
+
// Mobile title //
|
383 |
+
$wp_customize->add_setting(
|
384 |
+
'tlh_mobile_title',
|
385 |
+
array(
|
386 |
+
'default' => __('Online 24x7','clever-fox'),
|
387 |
+
'sanitize_callback' => 'avril_sanitize_text',
|
388 |
+
'transport' => $selective_refresh,
|
389 |
+
'capability' => 'edit_theme_options',
|
390 |
+
'priority' => 3,
|
391 |
+
)
|
392 |
+
);
|
393 |
+
|
394 |
+
$wp_customize->add_control(
|
395 |
+
'tlh_mobile_title',
|
396 |
+
array(
|
397 |
+
'label' => __('Title','clever-fox'),
|
398 |
+
'section' => 'above_header',
|
399 |
+
'type' => 'text'
|
400 |
+
)
|
401 |
+
);
|
402 |
+
|
403 |
+
// Mobile subtitle //
|
404 |
+
$wp_customize->add_setting(
|
405 |
+
'tlh_mobile_sbtitle',
|
406 |
+
array(
|
407 |
+
'default' => __('+1-0120-400-00-00','clever-fox'),
|
408 |
+
'sanitize_callback' => 'avril_sanitize_text',
|
409 |
+
'capability' => 'edit_theme_options',
|
410 |
+
'transport' => $selective_refresh,
|
411 |
+
'priority' => 4,
|
412 |
+
)
|
413 |
+
);
|
414 |
+
|
415 |
+
$wp_customize->add_control(
|
416 |
+
'tlh_mobile_sbtitle',
|
417 |
+
array(
|
418 |
+
'label' => __('Subtitle','clever-fox'),
|
419 |
+
'section' => 'above_header',
|
420 |
+
'type' => 'text'
|
421 |
+
)
|
422 |
+
);
|
423 |
+
// Mobile
|
424 |
+
$wp_customize->add_setting(
|
425 |
+
'hdr_top_email'
|
426 |
+
,array(
|
427 |
+
'capability' => 'edit_theme_options',
|
428 |
+
'sanitize_callback' => 'avril_sanitize_text',
|
429 |
+
'priority' => 5,
|
430 |
+
)
|
431 |
+
);
|
432 |
+
|
433 |
+
$wp_customize->add_control(
|
434 |
+
'hdr_top_email',
|
435 |
+
array(
|
436 |
+
'type' => 'hidden',
|
437 |
+
'label' => __('Email','clever-fox'),
|
438 |
+
'section' => 'above_header',
|
439 |
+
)
|
440 |
+
);
|
441 |
+
$wp_customize->add_setting(
|
442 |
+
'hide_show_email_details' ,
|
443 |
+
array(
|
444 |
+
'default' => '1',
|
445 |
+
'capability' => 'edit_theme_options',
|
446 |
+
'sanitize_callback' => 'avril_sanitize_checkbox',
|
447 |
+
'priority' => 6,
|
448 |
+
)
|
449 |
+
);
|
450 |
+
|
451 |
+
$wp_customize->add_control(
|
452 |
+
'hide_show_email_details',
|
453 |
+
array(
|
454 |
+
'label' => esc_html__( 'Hide/Show', 'clever-fox' ),
|
455 |
+
'section' => 'above_header',
|
456 |
+
'type' => 'checkbox'
|
457 |
+
)
|
458 |
+
);
|
459 |
+
|
460 |
+
// icon //
|
461 |
+
$wp_customize->add_setting(
|
462 |
+
'tlh_email_icon',
|
463 |
+
array(
|
464 |
+
'default' => 'fa-phone',
|
465 |
+
'sanitize_callback' => 'sanitize_text_field',
|
466 |
+
'capability' => 'edit_theme_options',
|
467 |
+
)
|
468 |
+
);
|
469 |
+
|
470 |
+
$wp_customize->add_control(new Avril_Icon_Picker_Control($wp_customize,
|
471 |
+
'tlh_email_icon',
|
472 |
+
array(
|
473 |
+
'label' => __('Icon','clever-fox'),
|
474 |
+
'section' => 'above_header',
|
475 |
+
'iconset' => 'fa',
|
476 |
+
|
477 |
+
))
|
478 |
+
);
|
479 |
+
// Mobile title //
|
480 |
+
$wp_customize->add_setting(
|
481 |
+
'tlh_email_title',
|
482 |
+
array(
|
483 |
+
'default' => __('Email Us','clever-fox'),
|
484 |
+
'sanitize_callback' => 'avril_sanitize_text',
|
485 |
+
'capability' => 'edit_theme_options',
|
486 |
+
'transport' => $selective_refresh,
|
487 |
+
'priority' => 7,
|
488 |
+
)
|
489 |
+
);
|
490 |
+
|
491 |
+
$wp_customize->add_control(
|
492 |
+
'tlh_email_title',
|
493 |
+
array(
|
494 |
+
'label' => __('Title','clever-fox'),
|
495 |
+
'section' => 'above_header',
|
496 |
+
'type' => 'text'
|
497 |
+
)
|
498 |
+
);
|
499 |
+
|
500 |
+
// Mobile subtitle //
|
501 |
+
$wp_customize->add_setting(
|
502 |
+
'tlh_email_sbtitle',
|
503 |
+
array(
|
504 |
+
'default' => __('email@email.com','clever-fox'),
|
505 |
+
'sanitize_callback' => 'avril_sanitize_text',
|
506 |
+
'transport' => $selective_refresh,
|
507 |
+
'capability' => 'edit_theme_options',
|
508 |
+
'priority' => 8,
|
509 |
+
)
|
510 |
+
);
|
511 |
+
|
512 |
+
$wp_customize->add_control(
|
513 |
+
'tlh_email_sbtitle',
|
514 |
+
array(
|
515 |
+
'label' => __('Subtitle','clever-fox'),
|
516 |
+
'section' => 'above_header',
|
517 |
+
'type' => 'text'
|
518 |
+
)
|
519 |
+
);
|
520 |
+
|
521 |
+
// Contact
|
522 |
+
$wp_customize->add_setting(
|
523 |
+
'hdr_top_contact'
|
524 |
+
,array(
|
525 |
+
'capability' => 'edit_theme_options',
|
526 |
+
'sanitize_callback' => 'avril_sanitize_text',
|
527 |
+
'priority' => 9,
|
528 |
+
)
|
529 |
+
);
|
530 |
+
|
531 |
+
$wp_customize->add_control(
|
532 |
+
'hdr_top_contact',
|
533 |
+
array(
|
534 |
+
'type' => 'hidden',
|
535 |
+
'label' => __('Contact','clever-fox'),
|
536 |
+
'section' => 'above_header',
|
537 |
+
)
|
538 |
+
);
|
539 |
+
$wp_customize->add_setting(
|
540 |
+
'hide_show_cntct_details' ,
|
541 |
+
array(
|
542 |
+
'default' => '1',
|
543 |
+
'capability' => 'edit_theme_options',
|
544 |
+
'sanitize_callback' => 'avril_sanitize_checkbox',
|
545 |
+
'priority' => 10,
|
546 |
+
)
|
547 |
+
);
|
548 |
+
|
549 |
+
$wp_customize->add_control(
|
550 |
+
'hide_show_cntct_details',
|
551 |
+
array(
|
552 |
+
'label' => esc_html__( 'Hide/Show', 'clever-fox' ),
|
553 |
+
'section' => 'above_header',
|
554 |
+
'type' => 'checkbox'
|
555 |
+
)
|
556 |
+
);
|
557 |
+
|
558 |
+
// icon //
|
559 |
+
$wp_customize->add_setting(
|
560 |
+
'tlh_contct_icon',
|
561 |
+
array(
|
562 |
+
'default' => 'fa-clock-o',
|
563 |
+
'sanitize_callback' => 'sanitize_text_field',
|
564 |
+
'capability' => 'edit_theme_options',
|
565 |
+
)
|
566 |
+
);
|
567 |
+
|
568 |
+
$wp_customize->add_control(new Avril_Icon_Picker_Control($wp_customize,
|
569 |
+
'tlh_contct_icon',
|
570 |
+
array(
|
571 |
+
'label' => __('Icon','clever-fox'),
|
572 |
+
'section' => 'above_header',
|
573 |
+
'iconset' => 'fa',
|
574 |
+
|
575 |
+
))
|
576 |
+
);
|
577 |
+
// Mobile title //
|
578 |
+
$wp_customize->add_setting(
|
579 |
+
'tlh_contact_title',
|
580 |
+
array(
|
581 |
+
'default' => __('8:00AM - 6:00PM','clever-fox'),
|
582 |
+
'sanitize_callback' => 'avril_sanitize_text',
|
583 |
+
'transport' => $selective_refresh,
|
584 |
+
'capability' => 'edit_theme_options',
|
585 |
+
'priority' => 11,
|
586 |
+
)
|
587 |
+
);
|
588 |
+
|
589 |
+
$wp_customize->add_control(
|
590 |
+
'tlh_contact_title',
|
591 |
+
array(
|
592 |
+
'label' => __('Title','clever-fox'),
|
593 |
+
'section' => 'above_header',
|
594 |
+
'type' => 'text'
|
595 |
+
)
|
596 |
+
);
|
597 |
+
|
598 |
+
// Mobile subtitle //
|
599 |
+
$wp_customize->add_setting(
|
600 |
+
'tlh_contact_sbtitle',
|
601 |
+
array(
|
602 |
+
'default' => __('Monday to Saturday','clever-fox'),
|
603 |
+
'sanitize_callback' => 'avril_sanitize_text',
|
604 |
+
'transport' => $selective_refresh,
|
605 |
+
'capability' => 'edit_theme_options',
|
606 |
+
'priority' => 12,
|
607 |
+
)
|
608 |
+
);
|
609 |
+
|
610 |
+
$wp_customize->add_control(
|
611 |
+
'tlh_contact_sbtitle',
|
612 |
+
array(
|
613 |
+
'label' => __('Subtitle','clever-fox'),
|
614 |
+
'section' => 'above_header',
|
615 |
+
'type' => 'text'
|
616 |
+
)
|
617 |
+
);
|
618 |
+
}
|
619 |
+
add_action( 'customize_register', 'aviser_lite_header_settings' );
|
620 |
+
|
621 |
+
// Header selective refresh
|
622 |
+
function aviser_lite_header_partials( $wp_customize ){
|
623 |
+
|
624 |
+
// tlh_mobile_title
|
625 |
+
$wp_customize->selective_refresh->add_partial( 'tlh_mobile_title', array(
|
626 |
+
'selector' => '.contact-details .wgt-3 .text',
|
627 |
+
'settings' => 'tlh_mobile_title',
|
628 |
+
'render_callback' => 'avril_tlh_mobile_title_render_callback',
|
629 |
+
) );
|
630 |
+
|
631 |
+
// tlh_mobile_sbtitle
|
632 |
+
$wp_customize->selective_refresh->add_partial( 'tlh_mobile_sbtitle', array(
|
633 |
+
'selector' => '.contact-details .wgt-3 .title',
|
634 |
+
'settings' => 'tlh_mobile_sbtitle',
|
635 |
+
'render_callback' => 'avril_tlh_mobile_sbtitle_render_callback',
|
636 |
+
) );
|
637 |
+
|
638 |
+
// tlh_email_title
|
639 |
+
$wp_customize->selective_refresh->add_partial( 'tlh_email_title', array(
|
640 |
+
'selector' => '.contact-details .wgt-2 .text',
|
641 |
+
'settings' => 'tlh_email_title',
|
642 |
+
'render_callback' => 'avril_tlh_email_title_render_callback',
|
643 |
+
) );
|
644 |
+
|
645 |
+
// tlh_email_sbtitle
|
646 |
+
$wp_customize->selective_refresh->add_partial( 'tlh_email_sbtitle', array(
|
647 |
+
'selector' => '.contact-details .wgt-2 .title',
|
648 |
+
'settings' => 'tlh_email_sbtitle',
|
649 |
+
'render_callback' => 'avril_tlh_email_sbtitle_render_callback',
|
650 |
+
) );
|
651 |
+
|
652 |
+
// tlh_contact_title
|
653 |
+
$wp_customize->selective_refresh->add_partial( 'tlh_contact_title', array(
|
654 |
+
'selector' => '.contact-details .wgt-1 .text',
|
655 |
+
'settings' => 'tlh_contact_title',
|
656 |
+
'render_callback' => 'avril_tlh_contact_title_render_callback',
|
657 |
+
) );
|
658 |
+
|
659 |
+
// tlh_contact_sbtitle
|
660 |
+
$wp_customize->selective_refresh->add_partial( 'tlh_contact_sbtitle', array(
|
661 |
+
'selector' => '.contact-details .wgt-1 .title',
|
662 |
+
'settings' => 'tlh_contact_sbtitle',
|
663 |
+
'render_callback' => 'avril_tlh_contact_sbtitle_render_callback',
|
664 |
+
) );
|
665 |
+
|
666 |
+
// hdr_time_title
|
667 |
+
$wp_customize->selective_refresh->add_partial( 'hdr_time_title', array(
|
668 |
+
'selector' => '#above-header .wgt-5 .text',
|
669 |
+
'settings' => 'hdr_time_title',
|
670 |
+
'render_callback' => 'avril_hdr_time_title_render_callback',
|
671 |
+
) );
|
672 |
+
|
673 |
+
// hdr_welcome_ttl
|
674 |
+
$wp_customize->selective_refresh->add_partial( 'hdr_welcome_ttl', array(
|
675 |
+
'selector' => '#above-header .wgt-6 .text',
|
676 |
+
'settings' => 'hdr_welcome_ttl',
|
677 |
+
'render_callback' => 'avril_hdr_welcome_ttl_render_callback',
|
678 |
+
) );
|
679 |
+
}
|
680 |
+
|
681 |
+
add_action( 'customize_register', 'aviser_lite_header_partials' );
|
682 |
+
|
683 |
+
// tlh_mobile_title
|
684 |
+
function avril_tlh_mobile_title_render_callback() {
|
685 |
+
return get_theme_mod( 'tlh_mobile_title' );
|
686 |
+
}
|
687 |
+
|
688 |
+
// tlh_mobile_sbtitle
|
689 |
+
function avril_tlh_mobile_sbtitle_render_callback() {
|
690 |
+
return get_theme_mod( 'tlh_mobile_sbtitle' );
|
691 |
+
}
|
692 |
+
|
693 |
+
// tlh_email_title
|
694 |
+
function avril_tlh_email_title_render_callback() {
|
695 |
+
return get_theme_mod( 'tlh_email_title' );
|
696 |
+
}
|
697 |
+
|
698 |
+
// tlh_email_sbtitle
|
699 |
+
function avril_tlh_email_sbtitle_render_callback() {
|
700 |
+
return get_theme_mod( 'tlh_email_sbtitle' );
|
701 |
+
}
|
702 |
+
|
703 |
+
// tlh_contact_title
|
704 |
+
function avril_tlh_contact_title_render_callback() {
|
705 |
+
return get_theme_mod( 'tlh_contact_title' );
|
706 |
+
}
|
707 |
+
|
708 |
+
// tlh_contact_sbtitle
|
709 |
+
function avril_tlh_contact_sbtitle_render_callback() {
|
710 |
+
return get_theme_mod( 'tlh_contact_sbtitle' );
|
711 |
+
}
|
712 |
+
|
713 |
+
// hdr_time_title
|
714 |
+
function avril_hdr_time_title_render_callback() {
|
715 |
+
return get_theme_mod( 'hdr_time_title' );
|
716 |
+
}
|
717 |
+
|
718 |
+
// hdr_welcome_ttl
|
719 |
+
function avril_hdr_welcome_ttl_render_callback() {
|
720 |
+
return get_theme_mod( 'hdr_welcome_ttl' );
|
721 |
+
}
|
inc/aviser/images/logo-2.png
ADDED
Binary file
|
inc/aviser/images/logo.png
ADDED
Binary file
|
inc/aviser/sections/above-header.php
ADDED
@@ -0,0 +1,78 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
if ( ! function_exists( 'avril_above_header' ) ) :
|
3 |
+
function avril_above_header() {
|
4 |
+
?>
|
5 |
+
<?php
|
6 |
+
$hide_show_social_icon = get_theme_mod( 'hide_show_social_icon','1');
|
7 |
+
$social_icons = get_theme_mod( 'social_icons',avril_get_social_icon_default());
|
8 |
+
$hs_hdr_time = get_theme_mod( 'hs_hdr_time','1');
|
9 |
+
$hdr_time_icon = get_theme_mod( 'hdr_time_icon','fa-clock-o');
|
10 |
+
$hdr_time_title = get_theme_mod( 'hdr_time_title','Opening Hours - 10 Am to 6 PM');
|
11 |
+
$hs_hdr_welcome = get_theme_mod( 'hs_hdr_welcome','1');
|
12 |
+
$hdr_welcome_icon = get_theme_mod( 'hdr_welcome_icon','fa-building-o');
|
13 |
+
$hdr_welcome_ttl = get_theme_mod( 'hdr_welcome_ttl','Welcome to our Business Agency');
|
14 |
+
?>
|
15 |
+
<!--===// Start: Header Above
|
16 |
+
=================================-->
|
17 |
+
<div id="above-header" class="header-above-info d-av-block d-none wow fadeInDown">
|
18 |
+
<div class="header-widget">
|
19 |
+
<div class="av-container">
|
20 |
+
<div class="av-columns-area">
|
21 |
+
<div class="av-column-5">
|
22 |
+
<div class="widget-left text-av-left text-center">
|
23 |
+
<?php if($hide_show_social_icon == '1') { ?>
|
24 |
+
<aside class="widget widget_social_widget">
|
25 |
+
<ul>
|
26 |
+
<?php
|
27 |
+
$social_icons = json_decode($social_icons);
|
28 |
+
if( $social_icons!='' )
|
29 |
+
{
|
30 |
+
foreach($social_icons as $social_item){
|
31 |
+
$social_icon = ! empty( $social_item->icon_value ) ? apply_filters( 'avril_translate_single_string', $social_item->icon_value, 'Header section' ) : '';
|
32 |
+
$social_link = ! empty( $social_item->link ) ? apply_filters( 'avril_translate_single_string', $social_item->link, 'Header section' ) : '';
|
33 |
+
?>
|
34 |
+
<li><a href="<?php echo esc_url( $social_link ); ?>"><i class="fa <?php echo esc_attr( $social_icon ); ?>"></i></a></li>
|
35 |
+
<?php }} ?>
|
36 |
+
</ul>
|
37 |
+
</aside>
|
38 |
+
<?php } ?>
|
39 |
+
</div>
|
40 |
+
</div>
|
41 |
+
<div class="av-column-7">
|
42 |
+
<div class="widget-right text-av-right text-center">
|
43 |
+
<?php if($hs_hdr_welcome == '1') { ?>
|
44 |
+
<aside class="widget widget-contact wgt-6">
|
45 |
+
<div class="contact-area">
|
46 |
+
<div class="contact-icon">
|
47 |
+
<i class="fa <?php echo esc_attr($hdr_welcome_icon); ?>"></i>
|
48 |
+
</div>
|
49 |
+
<a href="javascript:void(0)" class="contact-info">
|
50 |
+
<span class="text"><?php echo esc_html($hdr_welcome_ttl); ?></span>
|
51 |
+
</a>
|
52 |
+
</div>
|
53 |
+
</aside>
|
54 |
+
<?php } ?>
|
55 |
+
<?php if($hs_hdr_time == '1') { ?>
|
56 |
+
<aside class="widget widget-contact wgt-5">
|
57 |
+
<div class="contact-area">
|
58 |
+
<div class="contact-icon">
|
59 |
+
<i class="fa <?php echo esc_attr($hdr_time_icon); ?>"></i>
|
60 |
+
</div>
|
61 |
+
<a href="javascript:void(0)" class="contact-info">
|
62 |
+
<span class="text"><?php echo esc_html($hdr_time_title); ?></span>
|
63 |
+
</a>
|
64 |
+
</div>
|
65 |
+
</aside>
|
66 |
+
<?php } ?>
|
67 |
+
</div>
|
68 |
+
</div>
|
69 |
+
</div>
|
70 |
+
</div>
|
71 |
+
</div>
|
72 |
+
</div>
|
73 |
+
<!--===// End: Header Top
|
74 |
+
=================================-->
|
75 |
+
<?php
|
76 |
+
} endif;
|
77 |
+
add_action('avril_above_header', 'avril_above_header');
|
78 |
+
?>
|
inc/aviser/sections/section-cta-2.php
ADDED
@@ -0,0 +1,51 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
if ( ! function_exists( 'avril_lite_cta' ) ) :
|
3 |
+
function avril_lite_cta() {
|
4 |
+
$hs_cta = get_theme_mod('hs_cta','1');
|
5 |
+
$cta_title = get_theme_mod('cta_title','We work in partnership with all the major <i>technology</i> solutions');
|
6 |
+
$cta_description = get_theme_mod('cta_description','There are many variations of passages of lorem Ipsum available, but the majority');
|
7 |
+
$cta_btn_lbl1 = get_theme_mod('cta_btn_lbl1','Purchase Now');
|
8 |
+
$cta_btn_link1 = get_theme_mod('cta_btn_link1');
|
9 |
+
$cta_btn_second_ttl = get_theme_mod('cta_btn_second_ttl','Get Quick Support');
|
10 |
+
$cta_btn_lbl2 = get_theme_mod('cta_btn_lbl2','+22 24588-55069');
|
11 |
+
$cta_btn_link2 = get_theme_mod('cta_btn_link2');
|
12 |
+
$cta_image = get_theme_mod('cta_image',CLEVERFOX_PLUGIN_URL . '/inc/avail/images/cta-image.png');
|
13 |
+
if($hs_cta == '1') {
|
14 |
+
?>
|
15 |
+
<section id="cta-section" class="cta-section cta-3 cta-bg-image home-cta">
|
16 |
+
<div class="av-container">
|
17 |
+
<div class="av-columns-area">
|
18 |
+
<div class="av-column-12">
|
19 |
+
<div class="cta-wrapper">
|
20 |
+
<div class="cta-content">
|
21 |
+
<?php if ( ! empty( $cta_image ) ) : ?>
|
22 |
+
<div class="cta-img"><img src="<?php echo esc_url($cta_image); ?>"></div>
|
23 |
+
<?php endif; ?>
|
24 |
+
<div class="cta-text">
|
25 |
+
<?php if ( ! empty( $cta_title ) ) : ?>
|
26 |
+
<h4><?php echo wp_kses_post($cta_title); ?></h4>
|
27 |
+
<?php endif; ?>
|
28 |
+
<?php if ( ! empty($cta_description) ) : ?>
|
29 |
+
<p><?php echo wp_kses_post($cta_description); ?></p>
|
30 |
+
<?php endif; ?>
|
31 |
+
</div>
|
32 |
+
</div>
|
33 |
+
<div class="cta-btn-wrap text-av-right text-center">
|
34 |
+
<?php if ( ! empty( $cta_btn_lbl2 ) ) : ?>
|
35 |
+
<a class="cta-more" href="<?php echo esc_url($cta_btn_link2); ?>"><div class="cta-icon"><i class="fa fa-phone"></i></div><div class="cta-label"><span class="cta-label-title"><?php if ( ! empty( $cta_btn_second_ttl ) ) : echo esc_html($cta_btn_second_ttl); endif; ?></span><span class="cta-label-dis"><?php echo esc_html($cta_btn_lbl2); ?></span></div></a>
|
36 |
+
<?php endif;?>
|
37 |
+
<?php if ( ! empty( $cta_btn_lbl1 ) ) : ?>
|
38 |
+
<a href="<?php echo esc_url($cta_btn_link1); ?>" class="av-btn av-btn-white" data-text="Contact With Us"><?php echo esc_html($cta_btn_lbl1); ?></a>
|
39 |
+
<?php endif;?>
|
40 |
+
</div>
|
41 |
+
</div>
|
42 |
+
</div>
|
43 |
+
</div>
|
44 |
+
</div>
|
45 |
+
</section>
|
46 |
+
<?php
|
47 |
+
}} endif;
|
48 |
+
if ( function_exists( 'avril_lite_cta' ) ) {
|
49 |
+
$section_priority = apply_filters( 'avril_section_priority', 13, 'avril_lite_cta' );
|
50 |
+
add_action( 'avril_sections', 'avril_lite_cta', absint( $section_priority ) );
|
51 |
+
}
|
inc/aviser/sections/section-features.php
ADDED
@@ -0,0 +1,66 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
if ( ! function_exists( 'avril_lite_features' ) ) :
|
3 |
+
function avril_lite_features() {
|
4 |
+
$feature_title = get_theme_mod('feature_title','Technology from tomorrow');
|
5 |
+
$feature_subtitle = get_theme_mod('feature_subtitle','Outstanding <span class="av-heading animate-7"><span class="av-text-wrapper"><b class="is-show">Features</b> <b>Features</b><b>Features</b></span></span>');
|
6 |
+
$feature_description = get_theme_mod('feature_description','Lorem Ipsum is simply dummy of printing and typesetting and industry. Lorem Ipsum been.');
|
7 |
+
$features_contents = get_theme_mod('features_contents',avril_get_features_default());
|
8 |
+
$hs_feature = get_theme_mod('hs_feature','1');
|
9 |
+
if($hs_feature == '1') {
|
10 |
+
?>
|
11 |
+
<section id="features-section" class="features-section av-py-default">
|
12 |
+
<div class="av-container">
|
13 |
+
<?php if(! empty( $feature_title ) || ! empty( $feature_subtitle ) || ! empty( $feature_description )) { ?>
|
14 |
+
<div class="av-columns-area">
|
15 |
+
<div class="av-column-12">
|
16 |
+
<div class="heading-default wow fadeInUp">
|
17 |
+
<?php if ( ! empty( $feature_title ) ) : ?>
|
18 |
+
<span class='ttl'><?php echo wp_kses_post($feature_title); ?></span>
|
19 |
+
<?php endif; ?>
|
20 |
+
<?php if ( ! empty( $feature_subtitle ) ) : ?>
|
21 |
+
<h3><?php echo wp_kses_post($feature_subtitle); ?></h3>
|
22 |
+
<?php endif; ?>
|
23 |
+
<?php if ( ! empty( $feature_description ) ) : ?>
|
24 |
+
<p><?php echo wp_kses_post($feature_description); ?></p>
|
25 |
+
<?php endif; ?>
|
26 |
+
</div>
|
27 |
+
</div>
|
28 |
+
</div>
|
29 |
+
<?php } ?>
|
30 |
+
<div class="av-columns-area features-area wow fadeInUp">
|
31 |
+
<?php
|
32 |
+
if ( ! empty( $features_contents ) ) {
|
33 |
+
$features_contents = json_decode( $features_contents );
|
34 |
+
foreach ( $features_contents as $feature_item ) {
|
35 |
+
$avril_features_title = ! empty( $feature_item->title ) ? apply_filters( 'avril_translate_single_string', $feature_item->title, 'feature section' ) : '';
|
36 |
+
$text = ! empty( $feature_item->text ) ? apply_filters( 'avril_translate_single_string', $feature_item->text, 'feature section' ) : '';
|
37 |
+
$icon = ! empty( $feature_item->icon_value) ? apply_filters( 'avril_translate_single_string', $feature_item->icon_value,'feature section' ) : '';
|
38 |
+
?>
|
39 |
+
<div class="av-column-4 av-md-column-6 mb-6">
|
40 |
+
<div class="features-item">
|
41 |
+
<div class="features-icon">
|
42 |
+
<?php if ( ! empty( $icon ) ) {?>
|
43 |
+
<i class="fa <?php echo esc_html( $icon ); ?> txt-pink"></i>
|
44 |
+
<?php } ?>
|
45 |
+
</div>
|
46 |
+
<div class="features-content">
|
47 |
+
<?php if ( ! empty( $avril_features_title ) ) : ?>
|
48 |
+
<h5 class="features-title"><a href="javascript:void(0)"><?php echo esc_html( $avril_features_title ); ?></a></h5>
|
49 |
+
<?php endif; ?>
|
50 |
+
<?php if ( ! empty( $text ) ) : ?>
|
51 |
+
<p><?php echo esc_html( $text ); ?></p>
|
52 |
+
<?php endif; ?>
|
53 |
+
</div>
|
54 |
+
</div>
|
55 |
+
</div>
|
56 |
+
<?php }}?>
|
57 |
+
</div>
|
58 |
+
</div>
|
59 |
+
</section>
|
60 |
+
|
61 |
+
<?php
|
62 |
+
}} endif;
|
63 |
+
if ( function_exists( 'avril_lite_features' ) ) {
|
64 |
+
$section_priority = apply_filters( 'avril_section_priority', 14, 'avril_lite_service' );
|
65 |
+
add_action( 'avril_sections', 'avril_lite_features', absint( $section_priority ) );
|
66 |
+
}
|
inc/avril/dynamic-style.php
CHANGED
@@ -57,6 +57,26 @@ if( ! function_exists( 'cleverfox_avril_dynamic_styles' ) ):
|
|
57 |
background: #000000;
|
58 |
}\n";
|
59 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
60 |
|
61 |
wp_add_inline_style( 'avril-style', $output_css );
|
62 |
}
|
57 |
background: #000000;
|
58 |
}\n";
|
59 |
}
|
60 |
+
|
61 |
+
/**
|
62 |
+
* Contact Info
|
63 |
+
*/
|
64 |
+
$theme = wp_get_theme(); // gets the current theme
|
65 |
+
if ( 'Aviser' == $theme->name){
|
66 |
+
$hide_show_cntct_details = get_theme_mod( 'hide_show_cntct_details','1');
|
67 |
+
$hide_show_email_details = get_theme_mod( 'hide_show_email_details','1');
|
68 |
+
$hide_show_mbl_details = get_theme_mod( 'hide_show_mbl_details','1');
|
69 |
+
if($hide_show_cntct_details == '1' || $hide_show_email_details == '1' || $hide_show_mbl_details == '1') {
|
70 |
+
$output_css .=".navbar-area:not(.sticky-menu) {
|
71 |
+
padding: 0rem 0 1rem 0;
|
72 |
+
}\n";
|
73 |
+
}else{
|
74 |
+
$output_css .="@media (min-width: 992px) {.logo a:before {
|
75 |
+
height: 105px !important;
|
76 |
+
top: -32px !important;
|
77 |
+
}}\n";
|
78 |
+
}
|
79 |
+
}
|
80 |
|
81 |
wp_add_inline_style( 'avril-style', $output_css );
|
82 |
}
|
inc/cleverfox-activator.php
CHANGED
@@ -100,6 +100,12 @@ class Cleverfox_Activator {
|
|
100 |
require CLEVERFOX_PLUGIN_DIR . 'inc/avtari/default-widgets/default-widget.php';
|
101 |
}
|
102 |
|
|
|
|
|
|
|
|
|
|
|
|
|
103 |
if ( 'Fiona Blog' == $theme->name || 'Fiona Food' == $theme->name || 'Fiona News' == $theme->name){
|
104 |
require CLEVERFOX_PLUGIN_DIR . 'inc/fiona-blog/default-pages/upload-media.php';
|
105 |
require CLEVERFOX_PLUGIN_DIR . 'inc/fiona-blog/default-pages/home-page.php';
|
100 |
require CLEVERFOX_PLUGIN_DIR . 'inc/avtari/default-widgets/default-widget.php';
|
101 |
}
|
102 |
|
103 |
+
if ( 'Aviser' == $theme->name){
|
104 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/aviser/default-pages/upload-media.php';
|
105 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/aviser/default-pages/home-page.php';
|
106 |
+
require CLEVERFOX_PLUGIN_DIR . 'inc/aviser/default-widgets/default-widget.php';
|
107 |
+
}
|
108 |
+
|
109 |
if ( 'Fiona Blog' == $theme->name || 'Fiona Food' == $theme->name || 'Fiona News' == $theme->name){
|
110 |
require CLEVERFOX_PLUGIN_DIR . 'inc/fiona-blog/default-pages/upload-media.php';
|
111 |
require CLEVERFOX_PLUGIN_DIR . 'inc/fiona-blog/default-pages/home-page.php';
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Tags: homepage, companion, demo, sections, customizer, widget, settings
|
|
4 |
Requires at least: 4.0
|
5 |
Tested up to: 5.9
|
6 |
Requires PHP: 5.6
|
7 |
-
Stable tag: 9.
|
8 |
License: GPLv3 or later
|
9 |
License URI: https://www.gnu.org/licenses/gpl-3.0.en.html
|
10 |
|
@@ -114,6 +114,9 @@ Clever Fox WordPress plugin is licensed under the GPL3 (https://www.gnu.org/lice
|
|
114 |
|
115 |
== Changelog ==
|
116 |
|
|
|
|
|
|
|
117 |
= 9.8 =
|
118 |
* Thai Spa Theme Header Phone & Email Link Issue Fixed
|
119 |
|
4 |
Requires at least: 4.0
|
5 |
Tested up to: 5.9
|
6 |
Requires PHP: 5.6
|
7 |
+
Stable tag: 9.9
|
8 |
License: GPLv3 or later
|
9 |
License URI: https://www.gnu.org/licenses/gpl-3.0.en.html
|
10 |
|
114 |
|
115 |
== Changelog ==
|
116 |
|
117 |
+
= 9.9 =
|
118 |
+
* Aviser Theme Functionality Added
|
119 |
+
|
120 |
= 9.8 =
|
121 |
* Thai Spa Theme Header Phone & Email Link Issue Fixed
|
122 |
|