C:\xampp\htdocs\landing\wp-content\plugins\mega-addons-for-visual-composer\render\statcounter.php


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
<?php
if ( ! defined'ABSPATH' ) ) {
    die( 
'-1' );
}

class 
WPBakeryShortCode_mvc_counter extends WPBakeryShortCode {

    protected function 
content$atts$content null ) {

        
extractshortcode_atts( array(
            
'counter_style'     =>         'style',
            
'css'                 =>         '',
            
'sec_style'         =>         'image',
            
'image_id'             =>         '',
            
'alt'                 =>         '',
            
'image_width'         =>         '80',
            
'image_height'         =>         '',
            
'count_icon'         =>         '',
            
'icon_size'         =>         '',
            
'icon_clr'             =>         '',
            
'count_title'         =>         '',
            
'icon_bg'            =>         '',
            
'icon_radius'        =>         '0px',
            
'icon_style'        =>         '',
            
'title_size'         =>         '30',
            
'title_font'         =>         '500',
            
'title_clr'         =>         '',
            
'lineheight'        =>         '1.1',
            
'stat_numb'         =>         '4329',
            
'stat_size'         =>         '20',
            
'stat_font'         =>         '',
            
'stat_clr'             =>         '',
            
'count_speed'         =>         '4000',
            
'count_interv'         =>         '10',
            
'start_from'         =>         '0',
        ), 
$atts ) );
        
$css_class apply_filtersVC_SHORTCODE_CUSTOM_CSS_FILTER_TAGvc_shortcode_custom_css_class$css' ' ), $this->settings['base'], $atts );
        
wp_enqueue_style'counter-css'plugins_url'../css/statcounter.css' __FILE__ ));
        
wp_enqueue_script'count-to'plugins_url'../js/count-up.js' __FILE__ ), array('jquery') );
        if (
$image_id != '') {
            
$image_url wp_get_attachment_url$image_id );        
        }
        
$content wpb_js_remove_wpautop($contenttrue);
        
ob_start(); ?>
        
            <!-- Counter style one -->
        <?php if ($counter_style == 'style') { ?>
            <div id="mega_count_bar" class="<?php echo $css_class?> messive-wrapper-counter" data-delay="<?php echo $count_interv?>" data-time="<?php echo $count_speed?>">
                <div class="mega_count_img">
                    <?php if ($sec_style == 'image') { ?>           
                        <img src="<?php echo $image_url?>" alt="<?php echo $alt?>" width="<?php echo $image_width?>px" height="<?php echo $image_height?>px">
                    <?php ?>
                    <?php if ($sec_style == 'icon') { ?>
                        <i class="<?php echo $count_icon?>" style="width: <?php echo $image_width?>px; height: <?php echo $image_height?>px; line-height: <?php echo $image_height-4?>px; background: <?php echo $icon_bg?>; border-radius: <?php echo $icon_radius?>; border: <?php echo $icon_style?>; font-size: <?php echo $icon_size?>px; color: <?php echo $icon_clr?>;"></i>
                    <?php ?>
                </div>
                <div class="mega_count_content" style="text-align: center;">
                    <span class="main-counter" style="font-size: <?php echo $stat_size?>px; font-weight: <?php echo $stat_font?>; color: <?php echo $stat_clr?>; line-height: <?php echo $lineheight?>;"><?php echo $stat_numb?></span>
                    <span class="counter-after" style="font-size: <?php echo $stat_size?>px; font-weight: <?php echo $stat_font?>; color: <?php echo $stat_clr?>;"></span>
                    
                    <h3 style="font-size: <?php echo $title_size?>px; font-weight: <?php echo $title_font?>; color: <?php echo $title_clr?>;">
                        <?php echo $count_title?>
                    </h3>
                </div>
            </div>
        <?php ?>

        <!-- Counter style two -->
        <?php if ($counter_style == 'style2') { ?>
            <div id="mega_count_bar" class="<?php echo $css_class?> messive-wrapper-counter" data-delay="<?php echo $count_interv?>" data-time="<?php echo $count_speed?>">
                <div class="mega_count_img">
                    <?php if ($sec_style == 'image') { ?>           
                        <img src="<?php echo $image_url?>" alt="<?php echo $alt?>" width="<?php echo $image_width?>px" height="<?php echo $image_height?>px" alt="">
                    <?php ?>
                    <?php if ($sec_style == 'icon') { ?>
                        <i class="<?php echo $count_icon?>" style="width: <?php echo $image_width?>px; height: <?php echo $image_height?>px; line-height: <?php echo $image_height-4?>px; background: <?php echo $icon_bg?>; border-radius: <?php echo $icon_radius?>; border: <?php echo $icon_style?>; font-size: <?php echo $icon_size?>px; color: <?php echo $icon_clr?>;"></i>
                    <?php ?>
                </div>
                <div class="mega_count_content" style="text-align: center;">
                    <h3 style="font-size: <?php echo $title_size?>px; font-weight: <?php echo $title_font?>; color: <?php echo $title_clr?>; margin-bottom: 0px;">
                        <?php echo $count_title?>
                    </h3>
                    <hr style="margin:<?php echo $lineheight?>px auto;">
                    <span class="main-counter" style="font-size: <?php echo $stat_size?>px; font-weight: <?php echo $stat_font?>; color: <?php echo $stat_clr?>;"><?php echo $stat_numb?></span>
                    <span class="counter-after" style="font-size: <?php echo $stat_size?>px; font-weight: <?php echo $stat_font?>; color: <?php echo $stat_clr?>;"></span>
                </div>
            </div>
        <?php ?>

        <!-- Counter style three -->
        <?php if ($counter_style == 'style3') { ?>
            <div id="mega_count_bar_2" class="<?php echo $css_class?> messive-wrapper-counter" data-delay="<?php echo $count_interv?>" data-time="<?php echo $count_speed?>">
                <div class="mega_count_img">           
                    <?php if ($sec_style == 'image') { ?>           
                        <img src="<?php echo $image_url?>" alt="<?php echo $alt?>" width="<?php echo $image_width?>px" height="<?php echo $image_height?>px" alt="">
                    <?php ?>
                    <?php if ($sec_style == 'icon') { ?>
                        <i class="<?php echo $count_icon?>" style="width: <?php echo $image_width?>px; height: <?php echo $image_height?>px; line-height: <?php echo $image_height-2?>px; background: <?php echo $icon_bg?>; border-radius: <?php echo $icon_radius?>; border: <?php echo $icon_style?>; font-size: <?php echo $icon_size?>px; color: <?php echo $icon_clr?>;"></i>
                    <?php ?>
                </div>
                <div class="mega_count_content" style="text-align: center;">
                    <h3 style="line-height: <?php echo $lineheight?>; font-size: <?php echo $title_size?>px; font-weight: <?php echo $title_font?>; color: <?php echo $title_clr?>;">
                        <?php echo $count_title?>
                    </h3>
                    <span class="main-counter" style="font-size: <?php echo $stat_size?>px; font-weight: <?php echo $stat_font?>; color: <?php echo $stat_clr?>;"><?php echo $stat_numb?></span>
                    <span class="counter-after" style="font-size: <?php echo $stat_size?>px; font-weight: <?php echo $stat_font?>; color: <?php echo $stat_clr?>;"></span>        
                </div>
            </div>
        <?php ?>

        <!-- Counter style four -->
        <?php if ($counter_style == 'style4') { ?>
            <div id="mega_count_bar_3" class="<?php echo $css_class?> messive-wrapper-counter" data-delay="<?php echo $count_interv?>" data-time="<?php echo $count_speed?>">
                <div class="mega_count_content">
                    <h3 style="font-size: <?php echo $title_size?>px; font-weight: <?php echo $title_font?>; color: <?php echo $title_clr?>;">
                        <?php echo $count_title?>
                    </h3>
                    <span class="main-counter" style="font-size: <?php echo $stat_size?>px; text-align: right; font-weight: <?php echo $stat_font?>; color: <?php echo $stat_clr?>; line-height: <?php echo $lineheight?>;"><?php echo $stat_numb?></span>
                    <span class="counter-after" style="font-size: <?php echo $stat_size?>px; font-weight: <?php echo $stat_font?>; color: <?php echo $stat_clr?>;"></span>
                </div>
                <div class="mega_count_img">           
                    <?php if ($sec_style == 'image') { ?>           
                        <img src="<?php echo $image_url?>" alt="<?php echo $alt?>" width="<?php echo $image_width?>px" height="<?php echo $image_height?>px" alt="">
                    <?php ?>
                    <?php if ($sec_style == 'icon') { ?>
                        <i class="<?php echo $count_icon?>" style="width: <?php echo $image_width?>px; height: <?php echo $image_height?>px; line-height: <?php echo $image_height-2?>px; background: <?php echo $icon_bg?>; border-radius: <?php echo $icon_radius?>; border: <?php echo $icon_style?>; font-size: <?php echo $icon_size?>px; color: <?php echo $icon_clr?>;"></i>
                    <?php ?>
                </div>
            </div>
        <?php ?>

        <!-- Counter style five -->
        <?php if ($counter_style == 'style5') { ?>
            <div id="mega_count_bar_4" class="<?php echo $css_class?> messive-wrapper-counter" data-delay="<?php echo $count_interv?>" data-time="<?php echo $count_speed?>">
                <div class="mega_count_content">
                    <h3 style="font-size: <?php echo $title_size?>px; font-weight: <?php echo $title_font?>; color: <?php echo $title_clr?>;">
                        <?php echo $count_title?>
                    </h3>
                </div>
                <div class="mega_count_img" style="line-height: <?php echo $lineheight?>;">           
                    <?php if ($sec_style == 'image') { ?>           
                        <img src="<?php echo $image_url?>" alt="<?php echo $alt?>" width="<?php echo $image_width?>px" height="<?php echo $image_height?>px" alt="">
                    <?php ?>
                    <?php if ($sec_style == 'icon') { ?>
                        <i class="<?php echo $count_icon?>" style="font-size: <?php echo $icon_size?>px; color: <?php echo $icon_clr?>;"></i>
                    <?php ?>
                </div>
                <div class="mega_count_content" style="text-align: center;">
                    <span class="main-counter" style="font-size: <?php echo $stat_size?>px; font-weight: <?php echo $stat_font?>; color: <?php echo $stat_clr?>;"><?php echo $stat_numb?></span>
                    <span class="counter-after" style="font-size: <?php echo $stat_size?>px; font-weight: <?php echo $stat_font?>; color: <?php echo $stat_clr?>;"></span>
                </div>
            </div>
        <?php ?>
        

        <?php
        
return ob_get_clean();
    }
}


vc_map( array(
    
"name"             => __'Stats counter''counter' ),
    
"base"             => "mvc_counter",
    
"category"         => __('Mega Addons'),
    
"description"     => __('Your milestones, achievements etc''counter'),
    
"icon" => plugin_dir_url__FILE__ ).'../icons/counter.png',
    
'params' => array(
        array(
            
"type"             =>     "dropdown",
            
"heading"         =>     __'Counter styles''counter' ),
            
"param_name"     =>     "counter_style",
            
"description"     =>     __'Select counter styles <a href="http://addons.topdigitaltrends.net/stats-counter/">See demo</a>''counter' ),
            
"group"         =>     'General',
            
"value"         => array(
                
"Top logo bottom content"        => "style"
                
"Top logo bottom content 2"     => "style2",
                
"Left logo right content"     => "style3",
                
"Left content right logo"     => "style4",
                
"Logo in center"     => "style5",
            )
        ),

        array(
            
"type"             =>     "dropdown",
            
"heading"         =>     __'Image/Icon''counter' ),
            
"param_name"     =>     "sec_style",
            
"description"     =>     __'Select Image or font Icon''counter' ),
            
"group"         =>     'General',
            
"value" => array(
                
"Image" => "image"
                
"Icon" => "icon"
            )
        ),
        array(
            
"type"             =>     "attach_image",
            
"heading"         =>     __'Image''counter' ),
            
"param_name"     =>     "image_id",
            
"description"     =>     __'select image for logo''counter' ),
            
"group"         =>     'General',
            
"dependency" => array('element' => "sec_style"'value' => 'image'),
        ),

        array(
            
"type"             =>     "textfield",
            
"heading"         =>     __'Alternate Text''info-banner-vc' ),
            
"param_name"     =>     "alt",
            
"description"     =>     __'It will be used as alt attribute of img tag''info-banner-vc' ),
            
"dependency" => array('element' => "sec_style"'value' => 'image'),
            
"group"         =>     'General',
        ),

        array(
            
"type"             =>     "iconpicker",
            
"heading"         =>     __'Font Icon''counter' ),
            
"param_name"     =>     "count_icon",
            
"description"     =>     __'Select font icon''counter' ),
            
"dependency" => array('element' => "sec_style"'value' => 'icon'),
            
"group"         =>     'General',
        ),
        array(
            
"type"             =>     "vc_number",
            
"heading"         =>     __'Icon font size''counter' ),
            
"param_name"     =>     "icon_size",
            
"description"     =>     __'set font size in pixel e.g 25''counter' ),
            
"dependency" => array('element' => "sec_style"'value' => 'icon'),
            
"value"            =>    "25",
            
"suffix"         =>     'px',
            
"group"         =>     'General',
        ),
        array(
            
"type"             =>     "vc_number",
            
"heading"         =>     __'Width''counter' ),
            
"param_name"     =>     "image_width",
            
"description"     =>     __'Set custom width in pixel or leave blank e.g 100''counter' ),
            
"value"            =>    "80",
            
"suffix"         =>     'px',
            
"group"         =>     'General',
        ),
        array(
            
"type"             =>     "vc_number",
            
"heading"         =>     __'Height''counter' ),
            
"param_name"     =>     "image_height",
            
"description"     =>     __'Set custom height in pixel or leave blank e.g 100''counter' ),
            
"value"            =>    "",
            
"suffix"         =>     'px',
            
"group"         =>     'General',
        ),
        array(
            
"type"             =>     "colorpicker",
            
"heading"         =>     __'Icon Color''counter' ),
            
"param_name"     =>     "icon_clr",
            
"description"     =>     __'Select icon color''counter' ),
            
"dependency" => array('element' => "sec_style"'value' => 'icon'),
            
"group"         =>     'General',
        ),
        array(
            
"type"             =>     "colorpicker",
            
"heading"         =>     __'Icon Background''counter' ),
            
"param_name"     =>     "icon_bg",
            
"description"     =>     __'background color for Icon''counter' ),
            
"dependency" => array('element' => "sec_style"'value' => 'icon'),
            
"group"         =>     'General',
        ),
        array(
            
"type"             =>     "dropdown",
            
"heading"         =>     __'Border Radius''counter' ),
            
"param_name"     =>     "icon_radius",
            
"description"     =>     __'border radius for icon''counter' ),
            
"dependency" => array('element' => "sec_style"'value' => 'icon'),
            
"group"         =>     'General',
            
"value"         => array(
                
"0px"        => "0px"
                
"5px"         => "5px",
                
"10px"         => "10px",
                
"20px"         => "20px",
                
"30px"         => "30px",
                
"50px"         => "50px",
                
"50%"         => "50%",
            )
        ),
        array(
            
"type"             =>     "textfield",
            
"heading"         =>     __'Border Style''counter' ),
            
"param_name"     =>     "icon_style",
            
"description"     =>     __'[width style color]''counter' ),
            
"dependency" => array('element' => "sec_style"'value' => 'icon'),
            
"value"            =>    "0px solid #fff",
            
"group"         =>     'General',
        ),

        array(
            
"type"             => "vc_links",
            
"param_name"     => "caption_url",
            
"class"            =>    "ult_param_heading",
            
"description"     => __'<span style="Background: #ddd;padding: 10px; display: block; color: #0073aa;font-weight:600;"><a href="https://1.envato.market/02aNL" target="_blank" style="text-decoration: none;">Get the Pro version for more stunning elements and customization options.</a></span>''ihover' ),
            
"group"         => 'General',
        ),


        
// Content Section 
        
        
        
array(
            
"type"             =>     "vc_number",
            
"heading"         =>     __'Line Height''counter' ),
            
"param_name"     =>     "lineheight",
            
"description"     =>     __'set line height''counter' ),
            
"value"            =>    "1",
            
"group"         =>     'Title',
        ),
        array(
            
"type"             =>     "textfield",
            
"heading"         =>     __'Title''counter' ),
            
"param_name"     =>     "count_title",
            
"description"     =>     __'write counter title for info''counter' ),
            
"group"         =>     'Title',
        ),
        array(
            
"type"             =>     "vc_number",
            
"heading"         =>     __'Font size''counter' ),
            
"param_name"     =>     "title_size",
            
"description"     =>     __'set title font size in pixel e.g 30''counter' ),
            
"suffix"         =>     'px',
            
"group"         =>     'Title',
        ),
        array(
            
"type"             =>     "vc_number",
            
"heading"         =>     __'Font Weight''counter' ),
            
"param_name"     =>     "title_font",
            
"description"     =>     __'set font thickness with difference of 100 in numbers e.g 500''counter' ),
            
"max"            =>    "",
            
"group"         =>     'Title',
        ),
        array(
            
"type"             =>     "colorpicker",
            
"heading"         =>     __'Title Color''counter' ),
            
"param_name"     =>     "title_clr",
            
"description"     =>     __'Select title color''counter' ),
            
"group"         =>     'Title',
        ),


        
// Counter Section 
        
        
array(
            
"type"             =>     "textfield",
            
"heading"         =>     __'Number''counter' ),
            
"param_name"     =>     "stat_numb",
            
"description"     =>     __'Here you can use integers: 12345, floats: 0.1234, formatted numbers: 1,234,567.00''counter' ),
            
"value"            =>    "4329",
            
"max"            =>    "",
            
"group"         =>     'Setting',
        ),
        array(
            
"type"             =>     "textfield",
            
"heading"         =>     __'After Text <a href="https://1.envato.market/02aNL" target="_blank">Pro feature</a>''counter' ),
            
"param_name"     =>     "stat_numbs",
            
"group"         =>     'Setting',
        ),
        array(
            
"type"             =>     "vc_number",
            
"heading"         =>     __'Font size''counter' ),
            
"param_name"     =>     "stat_size",
            
"description"     =>     __'set counter font size in pixel e.g 20''counter' ),
            
"suffix"         =>     'px',
            
"group"         =>     'Setting',
        ),
        array(
            
"type"             =>     "vc_number",
            
"heading"         =>     __'Font Weight''counter' ),
            
"param_name"     =>     "stat_font",
            
"description"     =>     __'set counter font thickness with difference of 100 in numbers e.g 500''counter' ),
            
"max"            =>    "",
            
"group"         =>     'Setting',
        ),
        array(
            
"type"             =>     "colorpicker",
            
"heading"         =>     __'Color''counter' ),
            
"param_name"     =>     "stat_clr",
            
"description"     =>     __'Select counter title color''counter' ),
            
"group"         =>     'Setting',
        ),
        
        array(
            
"type"             =>     "vc_number",
            
"heading"         =>     __'Time''counter' ),
            
"param_name"     =>     "count_speed",
            
"value"            =>    "4000",
            
"description"     =>     __'The total duration of the count up animation in milli second 1s=1000''counter' ),
            
"max"            =>    "",
            
"group"         =>     'Setting',
        ),
        array(
            
"type"             =>     "vc_number",
            
"heading"         =>     __'Delay''counter' ),
            
"param_name"     =>     "count_interv",
            
"description"     =>     __'The delay in milliseconds per number count up''counter' ),
            
"max"            =>    "",
            
"group"         =>     'Setting',
        ),

        
/* Design Options
        ============================*/ 

        
array(
            
"type"             =>     "css_editor",
            
"heading"         =>     __'Custom Styling''counter' ),
            
"param_name"     =>     "css",
            
"group"         =>     'Design Options',
        ),
    ),
) );

x

Windows NT KPTV 6.2 build 9200 (Windows Server 2012 Datacenter Edition) i586