Custom Share Buttons with Floating Sidebar - Version 3.7

Version Description

  • Tested with latest wordpress version 5.1.1
    • Removed Google+ button
Download this release

Release Info

Developer india-web-developer
Plugin Icon 128x128 Custom Share Buttons with Floating Sidebar
Version 3.7
Comparing to
See all releases

Code changes from version 3.6 to 3.7

csbwfs-class.php CHANGED
@@ -1,793 +1,751 @@
1
- <?php
2
- /*
3
- * Custom Share Buttons With Floating Sidebar (C)
4
- * @get_csbwf_sidebar_options()
5
- * @get_csbwf_sidebar_content()
6
- * */
7
- ?>
8
- <?php
9
- if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
10
- // get all options value for "Custom Share Buttons with Floating Sidebar"
11
- function get_csbwf_sidebar_options() {
12
- global $wpdb;
13
- $ctOptions = $wpdb->get_results("SELECT option_name, option_value FROM $wpdb->options WHERE option_name LIKE 'csbwfs_%'");
14
-
15
- foreach ($ctOptions as $option) {
16
- $ctOptions[$option->option_name] = $option->option_value;
17
- }
18
-
19
- return $ctOptions;
20
- }
21
- /** Get the current url*/
22
- if(!function_exists('csbwfs_current_path_protocol')):
23
- function csbwfs_current_path_protocol($s, $use_forwarded_host=false)
24
- {
25
- $pwahttp = (!empty($s['HTTPS']) && $s['HTTPS'] == 'on') ? true:false;
26
- $pwasprotocal = strtolower($s['SERVER_PROTOCOL']);
27
- $pwa_protocol = substr($pwasprotocal, 0, strpos($pwasprotocal, '/')) . (($pwahttp) ? 's' : '');
28
- $port = $s['SERVER_PORT'];
29
- $port = ((!$pwahttp && $port=='80') || ($pwahttp && $port=='443')) ? '' : ':'.$port;
30
- $host = ($use_forwarded_host && isset($s['HTTP_X_FORWARDED_HOST'])) ? $s['HTTP_X_FORWARDED_HOST'] : (isset($s['HTTP_HOST']) ? $s['HTTP_HOST'] : null);
31
- $host = isset($host) ? $host : $s['SERVER_NAME'] . $port;
32
- return $pwa_protocol . '://' . $host;
33
- }
34
- endif;
35
- if(!function_exists('csbwfs_get_current_page_url')):
36
- function csbwfs_get_current_page_url($s, $use_forwarded_host=false)
37
- {
38
- return csbwfs_current_path_protocol($s, $use_forwarded_host) . $s['REQUEST_URI'];
39
- }
40
- endif;
41
- /*
42
- * Site is browsing in mobile or not
43
- * @csbwfsIsMobile()
44
- * */
45
- if(!function_exists('csbwfsIsMobile')):
46
- function csbwfsIsMobile() {
47
- // Check the server headers to see if they're mobile friendly
48
- if(isset($_SERVER["HTTP_X_WAP_PROFILE"])) {
49
- return true;
50
- }
51
- // Let's NOT return "mobile" if it's an iPhone, because the iPhone can render normal pages quite well.
52
- if(isset($_SERVER["HTTP_USER_AGENT"])):
53
- if(strstr($_SERVER['HTTP_USER_AGENT'], 'iPad')) {
54
- return false;
55
- }
56
- endif;
57
-
58
- // If the http_accept header supports wap then it's a mobile too
59
- if(isset($_SERVER["HTTP_ACCEPT"])):
60
- if(preg_match("/wap\.|\.wap/i",$_SERVER["HTTP_ACCEPT"])) {
61
- return true;
62
- }
63
- endif;
64
- // Still no luck? Let's have a look at the user agent on the browser. If it contains
65
- // any of the following, it's probably a mobile device. Kappow!
66
- if(isset($_SERVER["HTTP_USER_AGENT"])){
67
- $user_agents = array("midp", "j2me", "avantg", "docomo", "novarra", "palmos", "palmsource", "240x320", "opwv", "chtml", "pda", "windows\ ce", "mmp\/", "blackberry", "mib\/", "symbian", "wireless", "nokia", "hand", "mobi", "phone", "cdm", "up\.b", "audio", "SIE\-", "SEC\-", "samsung", "HTC", "mot\-", "mitsu", "sagem", "sony", "alcatel", "lg", "erics", "vx", "NEC", "philips", "mmm", "xx", "panasonic", "sharp", "wap", "sch", "rover", "pocket", "benq", "java", "pt", "pg", "vox", "amoi", "bird", "compal", "kg", "voda", "sany", "kdd", "dbt", "sendo", "sgh", "gradi", "jb", "\d\d\di", "moto");
68
- foreach($user_agents as $user_string){
69
- if(preg_match("/".$user_string."/i",$_SERVER["HTTP_USER_AGENT"])) {
70
- return true;
71
- }
72
- }
73
- }
74
- // None of the above? Then it's probably not a mobile device.
75
- return false;
76
- }
77
- endif;
78
- // Get plugin options
79
- $pluginOptionsVal=get_csbwf_sidebar_options();
80
- //check plugin in enable or not
81
- if(isset($pluginOptionsVal['csbwfs_active']) && $pluginOptionsVal['csbwfs_active']==1){
82
-
83
- if((csbwfsIsMobile()) &&
84
- isset($pluginOptionsVal['csbwfs_deactive_for_mob']) && $pluginOptionsVal['csbwfs_deactive_for_mob']!='')
85
- {
86
- // silent is Gold;
87
- }else
88
- {
89
- add_action('wp_footer','get_csbwf_sidebar_content');
90
- add_action( 'wp_enqueue_scripts', 'csbwf_sidebar_scripts' );
91
- add_action('wp_footer','csbwf_sidebar_load_inline_js');
92
- add_action('wp_footer','csbwfs_cookie');
93
- }
94
-
95
- }
96
-
97
- function csbwfs_cookie()
98
- {
99
- echo $cookieVal='<script>csbwfsCheckCookie();function csbwfsSetCookie(cname,cvalue,exdays) {
100
- var d = new Date();
101
- d.setTime(d.getTime() + (exdays*24*60*60*1000));
102
- var expires = "expires=" + d.toGMTString();
103
- document.cookie = cname+"="+cvalue+"; "+expires;
104
- }
105
-
106
- function csbwfsGetCookie(cname) {
107
- var name = cname + "=";
108
- var ca = document.cookie.split(\';\');
109
- for(var i=0; i<ca.length; i++) {
110
- var c = ca[i];
111
- while (c.charAt(0)==\' \') c = c.substring(1);
112
- if (c.indexOf(name) != -1) {
113
- return c.substring(name.length, c.length);
114
- }
115
- }
116
- return "";
117
- }
118
-
119
- function csbwfsCheckCookie() {
120
- var hideshowhide = "'.get_option('csbwfs_rmSHBtn').'"
121
- var button_status=csbwfsGetCookie("csbwfs_show_hide_status");
122
- if (button_status != "") {
123
-
124
- } else {
125
- csbwfsSetCookie("csbwfs_show_hide_status", "active",1);
126
- }
127
- if(hideshowhide=="yes")
128
- {
129
- csbwfsSetCookie("csbwfs_show_hide_status", "active",0);
130
- }
131
- }
132
-
133
- </script>';
134
- }
135
- if(isset($pluginOptionsVal['csbwfs_buttons_active']) && $pluginOptionsVal['csbwfs_buttons_active']==1){
136
- add_filter( 'the_content', 'csbfs_the_content_filter', 20);
137
- add_action( 'wp_enqueue_scripts', 'csbwf_sidebar_scripts' );
138
- }
139
- //register style and scrip files
140
- function csbwf_sidebar_scripts() {
141
- wp_enqueue_script( 'jquery' ); // wordpress jQuery
142
- wp_register_style( 'csbwf_sidebar_style', plugins_url( 'css/csbwfs.css',__FILE__ ) );
143
- wp_enqueue_style( 'csbwf_sidebar_style' );
144
- }
145
- /*********************************************************
146
- "Add the jQuery code in head section using hooks"
147
- *********************************************************/
148
- function csbwf_sidebar_load_inline_js()
149
- {
150
- $pluginOptionsVal=get_csbwf_sidebar_options();
151
- $jscnt='<script>
152
- var windWidth=jQuery( window ).width();
153
- //alert(windWidth);
154
- var animateWidth;
155
- var defaultAnimateWidth;';
156
- $jscnt.='
157
- jQuery(document).ready(function()
158
- {
159
- animateWidth="55";
160
- defaultAnimateWidth= animateWidth-10;
161
- animateHeight="49";
162
- defaultAnimateHeight= animateHeight-2;';
163
- if($pluginOptionsVal['csbwfs_delayTimeBtn']!='0'):
164
- $jscnt.='jQuery("#csbwfs-delaydiv").hide();
165
- setTimeout(function(){
166
- jQuery("#csbwfs-delaydiv").fadeIn();}, '.$pluginOptionsVal['csbwfs_delayTimeBtn'].');';
167
- endif;
168
-
169
- if($pluginOptionsVal['csbwfs_position']=='right' || $pluginOptionsVal['csbwfs_position']=='left'){
170
-
171
- $jscnt.='jQuery("div.csbwfsbtns a").hover(function(){
172
- jQuery(this).animate({width:animateWidth});
173
- },function(){
174
- jQuery(this).stop( true, true ).animate({width:defaultAnimateWidth});
175
- });';
176
- }else
177
- {
178
- //silent
179
-
180
- }
181
-
182
- if(isset($pluginOptionsVal['csbwfs_auto_hide']) && $pluginOptionsVal['csbwfs_auto_hide']!=''):
183
- $jscnt.='csbwfsSetCookie("csbwfs_show_hide_status","in_active","1");';
184
- endif;
185
-
186
- $jscnt.='jQuery("div.csbwfs-show").hide();
187
- jQuery("div.csbwfs-show a").click(function(){
188
- jQuery("div#csbwfs-social-inner").show(500);
189
- jQuery("div.csbwfs-show").hide(500);
190
- jQuery("div.csbwfs-hide").show(500);
191
- csbwfsSetCookie("csbwfs_show_hide_status","active","1");
192
- });
193
-
194
- jQuery("div.csbwfs-hide a").click(function(){
195
- jQuery("div.csbwfs-show").show(500);
196
- jQuery("div.csbwfs-hide").hide(500);
197
- jQuery("div#csbwfs-social-inner").hide(500);
198
- csbwfsSetCookie("csbwfs_show_hide_status","in_active","1");
199
- });';
200
-
201
- $jscnt.='var button_status=csbwfsGetCookie("csbwfs_show_hide_status");
202
- if (button_status =="in_active") {
203
- jQuery("div.csbwfs-show").show();
204
- jQuery("div.csbwfs-hide").hide();
205
- jQuery("div#csbwfs-social-inner").hide();
206
- } else {
207
- jQuery("div#csbwfs-social-inner").show();
208
- jQuery("div.csbwfs-show").hide();
209
- jQuery("div.csbwfs-hide").show();
210
- }';
211
-
212
-
213
- $jscnt.='});
214
-
215
- </script>';
216
-
217
- echo $jscnt;
218
- }
219
-
220
- /********************************************************
221
- "Custom Share Buttons with Floating Sidebar" HTML
222
- *********************************************************/
223
- function get_csbwf_sidebar_content() {
224
- global $post;
225
- $pluginOptionsVal=get_csbwf_sidebar_options();
226
- $shareurl = htmlspecialchars(csbwfs_get_current_page_url($_SERVER), ENT_QUOTES, 'UTF-8');
227
- $ShareTitle = (is_front_page() && is_home()) ? get_bloginfo('name'): trim(wp_title('',false));
228
- $ShareTitle= htmlspecialchars(rawurlencode($ShareTitle));
229
- /* Get All buttons Image */
230
- //get facebook button image
231
- if($pluginOptionsVal['csbwfs_fb_image']!=''){ $fImg=$pluginOptionsVal['csbwfs_fb_image'];}
232
- else{$fImg='';}
233
- //get twitter button image
234
- if($pluginOptionsVal['csbwfs_tw_image']!=''){ $tImg=$pluginOptionsVal['csbwfs_tw_image'];}
235
- else{$tImg='';}
236
- //get Linkedin button image
237
- if($pluginOptionsVal['csbwfs_li_image']!=''){ $lImg=$pluginOptionsVal['csbwfs_li_image'];}
238
- else{$lImg='';}
239
- //get mail button image
240
- if($pluginOptionsVal['csbwfs_mail_image']!=''){ $mImg=$pluginOptionsVal['csbwfs_mail_image'];}
241
- else{$mImg='';}
242
- //get google plus button image
243
- if($pluginOptionsVal['csbwfs_gp_image']!=''){ $gImg=$pluginOptionsVal['csbwfs_gp_image'];}
244
- else{$gImg='';}
245
- //get pinterest button image
246
- if($pluginOptionsVal['csbwfs_pin_image']!=''){ $pImg=$pluginOptionsVal['csbwfs_pin_image'];}
247
- else{$pImg='';}
248
- //get youtube button image
249
- if(isset($pluginOptionsVal['csbwfs_yt_image']) && $pluginOptionsVal['csbwfs_yt_image']!=''){ $ytImg=$pluginOptionsVal['csbwfs_yt_image'];}
250
- else{$ytImg='';}
251
- //get reddit plus button image
252
- if(isset($pluginOptionsVal['csbwfs_re_image']) && $pluginOptionsVal['csbwfs_re_image']!=''){ $reImg=$pluginOptionsVal['csbwfs_re_image'];}
253
- else{$reImg='';}
254
- //get stumbleupon button image
255
- if(isset($pluginOptionsVal['csbwfs_st_image']) && $pluginOptionsVal['csbwfs_st_image']!=''){ $stImg=$pluginOptionsVal['csbwfs_st_image'];}
256
- else{$stImg='';}
257
- /* Get All buttons Image Alt/Title */
258
- //get facebook button image alt/title
259
- if($pluginOptionsVal['csbwfs_fb_title']!=''){ $fImgAlt=$pluginOptionsVal['csbwfs_fb_title'];}
260
- else{$fImgAlt='Share On Facebook';}
261
- //get twitter button image alt/title
262
- if($pluginOptionsVal['csbwfs_tw_title']!=''){ $tImgAlt=$pluginOptionsVal['csbwfs_tw_title'];}
263
- else{$tImgAlt='Share On Twitter';}
264
- //get Linkedin button image alt/title
265
- if($pluginOptionsVal['csbwfs_li_title']!=''){ $lImgAlt=$pluginOptionsVal['csbwfs_li_title'];}
266
- else{$lImgAlt='Share On Linkedin';}
267
- //get mail button image alt/title
268
- if($pluginOptionsVal['csbwfs_mail_title']!=''){ $mImgAlt=$pluginOptionsVal['csbwfs_mail_title'];}
269
- else{$mImgAlt='Contact us';}
270
- //get google plus button image alt/title
271
- if($pluginOptionsVal['csbwfs_gp_title']!=''){ $gImgAlt=$pluginOptionsVal['csbwfs_gp_title'];}
272
- else{$gImgAlt='Share On Google Plus';}
273
- //get pinterest button image alt/title
274
- if($pluginOptionsVal['csbwfs_pin_title']!=''){ $pImgAlt=$pluginOptionsVal['csbwfs_pin_title'];}
275
- else{$pImgAlt='Share On Pinterest';}
276
- //get youtube button image alt/title
277
- if(isset($pluginOptionsVal['csbwfs_yt_title']) && $pluginOptionsVal['csbwfs_yt_title']!=''){ $ytImgAlt=$pluginOptionsVal['csbwfs_yt_title'];}
278
- else{$ytImgAlt='Share On Youtube';}
279
- //get reddit plus button image alt/title
280
- if(isset($pluginOptionsVal['csbwfs_re_title']) && $pluginOptionsVal['csbwfs_re_title']!=''){ $reImgAlt=$pluginOptionsVal['csbwfs_re_title'];}
281
- else{$reImgAlt='Share On Reddit';}
282
- //get stumbleupon button image alt/title
283
- if(isset($pluginOptionsVal['csbwfs_st_title']) && $pluginOptionsVal['csbwfs_st_title']!=''){ $stImgAlt=$pluginOptionsVal['csbwfs_st_title'];}
284
- else{$stImgAlt='Share On Stumbleupon';}
285
- //get email message
286
- if(is_page() || is_single() || is_category() || is_archive()){
287
- if($pluginOptionsVal['csbwfs_mailMessage']!=''){ $mailMsg=$pluginOptionsVal['csbwfs_mailMessage'];} else{
288
- $mailMsg='?subject='.$ShareTitle.'&body='.$shareurl;}
289
- }else
290
- {
291
- $mailMsg='?subject='.get_bloginfo('name').'&body='.home_url('/');
292
- }
293
- // Top Margin
294
- if($pluginOptionsVal['csbwfs_top_margin']!=''){
295
- $margin=$pluginOptionsVal['csbwfs_top_margin'];
296
- }else
297
- {
298
- $margin='25%';
299
- }
300
-
301
- //Sidebar Position
302
- if($pluginOptionsVal['csbwfs_position']=='right'){
303
- $style=' style="top:'.$margin.';right:-5px;"'; $idName=' id="csbwfs-right"'; $showImg='hide-r.png'; $hideImg='show.png';
304
- }else if($pluginOptionsVal['csbwfs_position']=='bottom'){
305
- $style=' style="bottom:0;"'; $idName=' id="csbwfs-bottom"'; $showImg='hide-b.png'; $hideImg='show.png';
306
- }
307
- else
308
- {
309
- $idName=' id="csbwfs-left"'; $style=' style="top:'.$margin.';left:0;"'; $showImg='hide-l.png';$hideImg='hide.png';
310
- }
311
- /* Get All buttons background color */
312
- //get facebook button image background color
313
- if($pluginOptionsVal['csbwfs_fb_bg']!=''){ $fImgbg=' style="background:'.$pluginOptionsVal['csbwfs_fb_bg'].';"';}
314
- else{$fImgbg='';}
315
- //get twitter button image background color
316
- if($pluginOptionsVal['csbwfs_tw_bg']!=''){ $tImgbg=' style="background:'.$pluginOptionsVal['csbwfs_tw_bg'].';"';}
317
- else{$tImgbg='';}
318
- //get Linkedin button image background color
319
- if($pluginOptionsVal['csbwfs_li_bg']!=''){ $lImgbg=' style="background:'.$pluginOptionsVal['csbwfs_li_bg'].';"';}
320
- else{$lImgbg='';}
321
- //get mail button image background color
322
- if($pluginOptionsVal['csbwfs_mail_bg']!=''){ $mImgbg=' style="background:'.$pluginOptionsVal['csbwfs_mail_bg'].';"';}
323
- else{$mImgbg='';}
324
- //get google plus button image background color
325
- if($pluginOptionsVal['csbwfs_gp_bg']!=''){ $gImgbg=' style="background:'.$pluginOptionsVal['csbwfs_gp_bg'].';"';}
326
- else{$gImgbg='';}
327
- //get pinterest button image background color
328
- if($pluginOptionsVal['csbwfs_pin_bg']!=''){ $pImgbg=' style="background:'.$pluginOptionsVal['csbwfs_pin_bg'].';"';}
329
- else{$pImgbg='';}
330
-
331
- //get youtube button image background color
332
- if(isset($pluginOptionsVal['csbwfs_yt_bg']) && $pluginOptionsVal['csbwfs_yt_bg']!=''){ $ytImgbg=' style="background:'.$pluginOptionsVal['csbwfs_yt_bg'].';"';}else{$ytImgbg='';}
333
- //get reddit button image background color
334
- if(isset($pluginOptionsVal['csbwfs_re_bg']) && $pluginOptionsVal['csbwfs_re_bg']!=''){ $reImgbg=' style="background:'.$pluginOptionsVal['csbwfs_re_bg'].';"';}else{$reImgbg='';}
335
- //get stumbleupon button image background color
336
- if(isset($pluginOptionsVal['csbwfs_st_bg']) && $pluginOptionsVal['csbwfs_st_bg']!=''){ $stImgbg=' style="background:'.$pluginOptionsVal['csbwfs_st_bg'].';"';} else{$stImgbg='';}
337
-
338
- /** Message */
339
- if($pluginOptionsVal['csbwfs_show_btn']!=''){ $showbtn=$pluginOptionsVal['csbwfs_show_btn'];}
340
- else{$showbtn='Show Buttons';}
341
- //get show/hide button message
342
- if($pluginOptionsVal['csbwfs_hide_btn']!=''){ $hidebtn=$pluginOptionsVal['csbwfs_hide_btn'];}
343
- else{$hidebtn='Hide Buttons';}
344
- //get mail button message
345
- if($pluginOptionsVal['csbwfs_share_msg']!=''){ $sharemsg=$pluginOptionsVal['csbwfs_share_msg'];}
346
- else{$sharemsg='Share This With Your Friends';}
347
-
348
- /** Check display Show/Hide button or not*/
349
- if(isset($pluginOptionsVal['csbwfs_rmSHBtn']) && $pluginOptionsVal['csbwfs_rmSHBtn']!=''):
350
- $isActiveHideShowBtn='yes';
351
- else:
352
- $isActiveHideShowBtn='no';
353
- endif;
354
- $floatingSidebarContent='<div id="csbwfs-delaydiv"><div class="csbwfs-social-widget" '.$idName.' title="'.$sharemsg.'" '.$style.'>';
355
-
356
- if($isActiveHideShowBtn!='yes') :
357
- $floatingSidebarContent .= '<div class="csbwfs-show"><a href="javascript:" title="'.$showbtn.'" id="csbwfs-show"><img src="'.plugins_url('custom-share-buttons-with-floating-sidebar/images/'.$showImg).'" alt="'.$showbtn.'"></a></div>';
358
- endif;
359
-
360
- $floatingSidebarContent .= '<div id="csbwfs-social-inner">';
361
-
362
- /** FB */
363
- if($pluginOptionsVal['csbwfs_fpublishBtn']!=''):
364
- $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-fb" class="csbwfs-fb"><a href="javascript:" onclick="javascript:window.open(\'//www.facebook.com/sharer/sharer.php?u='.$shareurl.'\', \'\', \'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=300,width=600\');return false;" target="_blank" title="'.$fImgAlt.'" '.$fImgbg.'>';
365
-
366
- if($fImg!=''){
367
- $floatingSidebarContent .='<img src="'.$fImg.'" alt="'.$fImgAlt.'" width="35" height="35" >';
368
- }else{
369
- $floatingSidebarContent .='<i class="csbwfs_facebook"></i>';
370
- }
371
- $floatingSidebarContent .='</a></div></div>';
372
- endif;
373
-
374
- /** TW */
375
- if($pluginOptionsVal['csbwfs_tpublishBtn']!=''):
376
- $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-tw" class="csbwfs-tw"><a href="javascript:" onclick="window.open(\'//twitter.com/share?url='.$shareurl.'&text='.$ShareTitle.'\',\'_blank\',\'width=800,height=300\')" title="'.$tImgAlt.'" '.$tImgbg.'>';
377
- if($tImg!='')
378
- {
379
- $floatingSidebarContent .='<img src="'.$tImg.'" alt="'.$tImgAlt.'" width="35" height="35" >';
380
- }else{
381
- $floatingSidebarContent .='<i class="csbwfs_twitter"></i>';
382
- }
383
- $floatingSidebarContent .='</a></div></div>';
384
-
385
- endif;
386
-
387
- /** GP */
388
- if($pluginOptionsVal['csbwfs_gpublishBtn']!=''):
389
- $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-gp" class="csbwfs-gp"><a href="javascript:" onclick="javascript:window.open(\'//plus.google.com/share?url='.$shareurl.'\',\'\',\'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=800\');return false;" title="'.$gImgAlt.'" '.$gImgbg.'>';
390
- if($gImg!='')
391
- {
392
- $floatingSidebarContent .='<img src="'.$gImg.'" alt="'.$gImgAlt.'" width="35" height="35" >';
393
- }else{
394
- $floatingSidebarContent .='<i class="csbwfs_plus"></i>';
395
- }
396
- $floatingSidebarContent .='</a></div></div>';
397
- endif;
398
-
399
- /** LI */
400
- if($pluginOptionsVal['csbwfs_lpublishBtn']!=''):
401
- $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-li" class="csbwfs-li"><a href="javascript:" onclick="javascript:window.open(\'//www.linkedin.com/cws/share?mini=true&url='. $shareurl.'\',\'\',\'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=800\');return false;" title="'.$lImgAlt.'" '.$lImgbg.'>';
402
- if($lImg!='')
403
- {
404
- $floatingSidebarContent .='<img src="'.$lImg.'" alt="'.$lImgAlt.'" width="35" height="35" >';
405
- }else{
406
- $floatingSidebarContent .='<i class="csbwfs_linkedin"></i>';
407
- }
408
- $floatingSidebarContent .='</a></div></div>';
409
- endif;
410
-
411
- /** PIN */
412
- if($pluginOptionsVal['csbwfs_ppublishBtn']!=''):
413
- $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-pin" class="csbwfs-pin"><a onclick="javascript:void((function(){var e=document.createElement(\'script\');e.setAttribute(\'type\',\'text/javascript\');e.setAttribute(\'charset\',\'UTF-8\');e.setAttribute(\'src\',\'//assets.pinterest.com/js/pinmarklet.js?r=\'+Math.random()*99999999);document.body.appendChild(e)})());" href="javascript:void(0);" '.$pImgbg.' title="'.$pImgAlt.'">';
414
- if($pImg!='')
415
- {
416
- $floatingSidebarContent .='<img src="'.$pImg.'" alt="'.$pImgAlt.'" width="35" height="35" >';
417
- }else{
418
- $floatingSidebarContent .='<i class="csbwfs_pinterest"></i>';
419
- }
420
- $floatingSidebarContent .='</a></div></div>';
421
- endif;
422
-
423
- /** Reddit */
424
- if(isset($pluginOptionsVal['csbwfs_republishBtn']) && $pluginOptionsVal['csbwfs_republishBtn']!=''):
425
- $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-re" class="csbwfs-re"><a onclick="window.open(\'//reddit.com/submit?url='.$shareurl.'&amp;title='.$ShareTitle.'\',\'Reddit\',\'toolbar=0,status=0,width=1000,height=800\');" href="javascript:void(0);" '.$reImgbg.' title="'.$reImgAlt.'">';
426
- if($reImg!='')
427
- {
428
- $floatingSidebarContent .='<img src="'.$reImg.'" alt="'.$reImgAlt.'" width="35" height="35" >';
429
- }else{
430
- $floatingSidebarContent .='<i class="csbwfs_reddit"></i>';
431
- }
432
- $floatingSidebarContent .='</a></div></div>';
433
- endif;
434
-
435
- /** Stumbleupon */
436
- if(isset($pluginOptionsVal['csbwfs_stpublishBtn']) && $pluginOptionsVal['csbwfs_stpublishBtn']!=''):
437
- $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-st" class="csbwfs-st"><a onclick="window.open(\'//www.stumbleupon.com/submit?url='.$shareurl.'&amp;title='.$ShareTitle.'\',\'Stumbleupon\',\'toolbar=0,status=0,width=1000,height=800\');" href="javascript:void(0);" '.$stImgbg.' title="'.$stImgAlt.'">';
438
- if($stImg!='')
439
- {
440
- $floatingSidebarContent .='<img src="'.$stImg.'" alt="'.$stImgAlt.'" width="35" height="35" >';
441
- }else{
442
- $floatingSidebarContent .='<i class="csbwfs_stumbleupon"></i>';
443
- }
444
- $floatingSidebarContent .='</a></div></div>';
445
- endif;
446
- /** YT */
447
- if(isset($pluginOptionsVal['csbwfs_ytpublishBtn']) && $pluginOptionsVal['csbwfs_ytpublishBtn']!=''):
448
- $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-yt" class="csbwfs-yt"><a onclick="window.open(\''.$pluginOptionsVal['csbwfs_ytPath'].'\');" href="javascript:void(0);" '.$ytImgbg.' title="'.$ytImgAlt.'">';
449
- if($ytImg!='')
450
- {
451
- $floatingSidebarContent .='<img src="'.$ytImg.'" alt="'.$ytImgAlt.'" width="35" height="35" >';
452
- }else{
453
- $floatingSidebarContent .='<i class="csbwfs_youtube"></i>';
454
- }
455
- $floatingSidebarContent .='</a></div></div>';
456
- endif;
457
- /** Mail*/
458
- if($pluginOptionsVal['csbwfs_mpublishBtn']!=''):
459
- $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-ml" class="csbwfs-ml"><a href="mailto:'.$mailMsg.'" title="'.$mImgAlt.'" '.$mImgbg.' >';
460
- if($mImg!='')
461
- {
462
- $floatingSidebarContent .='<img src="'.$mImg.'" alt="'.$mImgAlt.'" width="35" height="35" >';
463
- }else{
464
- $floatingSidebarContent .='<i class="csbwfs_mail"></i>';
465
- }
466
- $floatingSidebarContent .='</a></div></div>';
467
- endif;
468
-
469
- $floatingSidebarContent .='</div>'; //End social-inner
470
-
471
- if($isActiveHideShowBtn!='yes') :
472
- $floatingSidebarContent .='<div class="csbwfs-hide"><a href="javascript:" title="'.$hidebtn.'" id="csbwfs-hide"><img src="'.plugins_url('custom-share-buttons-with-floating-sidebar/images/'.$hideImg).'" alt="'.$hidebtn.'"></a></div>';
473
- endif;
474
-
475
- $floatingSidebarContent .='</div></div>'; //End social-inner
476
- /** Check conditions */
477
- // Returns the content.
478
- if(isset($pluginOptionsVal['csbwfs_hide_home'])){$hideOnHome=$pluginOptionsVal['csbwfs_hide_home']; }else{ $hideOnHome='';}
479
-
480
- if((is_home() && is_front_page()) && $hideOnHome=='yes'):
481
- $floatingSidebarContent='';
482
- endif;
483
- if(is_front_page() && $hideOnHome=='yes' ):
484
- $floatingSidebarContent='';
485
- endif;
486
- /** hide on 404 pages */
487
- if(is_404()):$floatingSidebarContent='';endif;
488
-
489
- print $floatingSidebarContent;
490
- }
491
-
492
- /**
493
- * Add social share bottons to the end of every post/page.
494
- *
495
- * @uses is_home()
496
- * @uses is_page()
497
- * @uses is_single()
498
- */
499
- function csbfs_the_content_filter( $content ) {
500
-
501
- global $post;
502
- $pluginOptionsVal=get_csbwf_sidebar_options();
503
- if(is_category())
504
- {
505
- $category_id = get_query_var('cat');
506
- $cats = get_the_category();
507
- $ShareTitle=$cats[0]->name;
508
- }elseif($post && is_singular($post->post_type))
509
- {
510
- $ShareTitle=$post->post_title;
511
- }
512
- elseif(is_archive()){
513
- global $wp;
514
- if ( is_day() ) :
515
- $ShareTitle='Daily Archives: '. get_the_date();
516
- elseif ( is_month() ) :
517
- $ShareTitle='Monthly Archives: '. get_the_date('F Y');
518
- elseif ( is_year() ) :
519
- $ShareTitle='Yearly Archives: '. get_the_date('Y');
520
- elseif ( is_author() ) :
521
- $ShareTitle='Author Archives: '. get_the_author();
522
- else :
523
- $ShareTitle ='Blog Archives';
524
- endif;
525
- }
526
- else
527
- {
528
- $ShareTitle=get_bloginfo('name');
529
- }
530
- /* Set title and url for home page */
531
- if(is_home() && is_front_page()){
532
- $ShareTitle=get_bloginfo('name');
533
- }
534
-
535
- $shareurl = htmlspecialchars(csbwfs_get_current_page_url($_SERVER), ENT_QUOTES, 'UTF-8');
536
-
537
- $ShareTitle= htmlspecialchars(rawurlencode($ShareTitle));
538
-
539
- /* Get All buttons Image */
540
-
541
- //get facebook button image
542
- if($pluginOptionsVal['csbwfs_page_fb_image']!=''){ $fImg=$pluginOptionsVal['csbwfs_page_fb_image'];}
543
- else{$fImg='';}
544
- //get twitter button image
545
- if($pluginOptionsVal['csbwfs_page_tw_image']!=''){ $tImg=$pluginOptionsVal['csbwfs_page_tw_image'];}
546
- else{$tImg='';}
547
- //get Linkedin button image
548
- if($pluginOptionsVal['csbwfs_page_li_image']!=''){ $lImg=$pluginOptionsVal['csbwfs_page_li_image'];}
549
- else{$lImg='';}
550
- //get mail button image
551
- if($pluginOptionsVal['csbwfs_page_mail_image']!=''){ $mImg=$pluginOptionsVal['csbwfs_page_mail_image'];}
552
- else{$mImg='';}
553
- //get google plus button image
554
- if($pluginOptionsVal['csbwfs_page_gp_image']!=''){ $gImg=$pluginOptionsVal['csbwfs_page_gp_image'];}
555
- else{$gImg='';}
556
- //get pinterest button image
557
- if($pluginOptionsVal['csbwfs_page_pin_image']!=''){ $pImg=$pluginOptionsVal['csbwfs_page_pin_image'];}
558
- else{$pImg='';}
559
-
560
- //get youtube button image
561
- if(isset($pluginOptionsVal['csbwfs_page_yt_image']) && $pluginOptionsVal['csbwfs_page_yt_image']!=''){ $ytImg=$pluginOptionsVal['csbwfs_page_yt_image'];}
562
- else{$ytImg='';}
563
- //get reddit plus button image
564
- if(isset($pluginOptionsVal['csbwfs_page_re_image']) && $pluginOptionsVal['csbwfs_page_re_image']!=''){ $reImg=$pluginOptionsVal['csbwfs_page_re_image'];}
565
- else{$reImg='';}
566
- //get stumbleupon button image
567
- if(isset($pluginOptionsVal['csbwfs_page_st_image']) && $pluginOptionsVal['csbwfs_page_st_image']!=''){ $stImg=$pluginOptionsVal['csbwfs_page_st_image'];}
568
- else{$stImg='';}
569
-
570
- /* Get All buttons Image Alt/Title */
571
- //get facebook button image alt/title
572
- if($pluginOptionsVal['csbwfs_page_fb_title']!=''){ $fImgAlt=$pluginOptionsVal['csbwfs_page_fb_title'];}
573
- else{$fImgAlt='Share On Facebook';}
574
- //get twitter button image alt/title
575
- if($pluginOptionsVal['csbwfs_page_tw_title']!=''){ $tImgAlt=$pluginOptionsVal['csbwfs_page_tw_title'];}
576
- else{$tImgAlt='Share On Twitter';}
577
- //get Linkedin button image alt/title
578
- if($pluginOptionsVal['csbwfs_page_li_title']!=''){ $lImgAlt=$pluginOptionsVal['csbwfs_page_li_title'];}
579
- else{$lImgAlt='Share On Linkedin';}
580
- //get mail button image alt/title
581
- if($pluginOptionsVal['csbwfs_page_mail_title']!=''){ $mImgAlt=$pluginOptionsVal['csbwfs_page_mail_title'];}
582
- else{$mImgAlt='Contact us';}
583
- //get google plus button image alt/title
584
- if($pluginOptionsVal['csbwfs_page_gp_title']!=''){ $gImgAlt=$pluginOptionsVal['csbwfs_page_gp_title'];}
585
- else{$gImgAlt='Share On Google Plus';}
586
- //get pinterest button image alt/title
587
- if($pluginOptionsVal['csbwfs_page_pin_title']!=''){ $pImgAlt=$pluginOptionsVal['csbwfs_page_pin_title'];}
588
- else{$pImgAlt='Share On Pinterest';}
589
- //get youtube button image alt/title
590
- if(isset($pluginOptionsVal['csbwfs_page_yt_title']) && $pluginOptionsVal['csbwfs_page_yt_title']!=''){ $ytImgAlt=$pluginOptionsVal['csbwfs_page_yt_title'];}
591
- else{$ytImgAlt='Share On Youtube';}
592
- //get reddit plus button image alt/title
593
- if(isset($pluginOptionsVal['csbwfs_page_re_title']) && $pluginOptionsVal['csbwfs_page_re_title']!=''){ $reImgAlt=$pluginOptionsVal['csbwfs_page_re_title'];}
594
- else{$reImgAlt='Share On Reddit';}
595
- //get stumbleupon button image alt/title
596
- if(isset($pluginOptionsVal['csbwfs_page_st_title']) && $pluginOptionsVal['csbwfs_page_st_title']!=''){ $stImgAlt=$pluginOptionsVal['csbwfs_page_st_title'];}
597
- else{$stImgAlt='Share On Stumbleupon';}
598
-
599
- /* Get All buttons background color */
600
- //get facebook button image background color
601
- if($pluginOptionsVal['csbwfs_page_fb_bg']!=''){ $fImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_fb_bg'].';"';}
602
- else{$fImgbg='';}
603
- //get twitter button image background color
604
- if($pluginOptionsVal['csbwfs_page_tw_bg']!=''){ $tImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_tw_bg'].';"';}
605
- else{$tImgbg='';}
606
- //get Linkedin button image background color
607
- if($pluginOptionsVal['csbwfs_page_li_bg']!=''){ $lImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_li_bg'].';"';}
608
- else{$lImgbg='';}
609
- //get mail button image background color
610
- if($pluginOptionsVal['csbwfs_page_mail_bg']!=''){ $mImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_mail_bg'].';"';}
611
- else{$mImgbg='';}
612
- //get google plus button image background color
613
- if($pluginOptionsVal['csbwfs_page_gp_bg']!=''){ $gImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_gp_bg'].';"';}
614
- else{$gImgbg='';}
615
- //get pinterest button image background color
616
- if($pluginOptionsVal['csbwfs_page_pin_bg']!=''){ $pImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_pin_bg'].';"';}
617
- else{$pImgbg='';}
618
-
619
- //get youtube button image background color
620
- if(isset($pluginOptionsVal['csbwfs_page_yt_bg']) && $pluginOptionsVal['csbwfs_page_yt_bg']!=''){ $ytImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_yt_bg'].';"';}else{$ytImgbg='';}
621
- //get reddit button image background color
622
- if(isset($pluginOptionsVal['csbwfs_page_re_bg']) && $pluginOptionsVal['csbwfs_page_re_bg']!=''){ $reImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_re_bg'].';"';}else{$reImgbg='';}
623
- //get stumbleupon button image background color
624
- if(isset($pluginOptionsVal['csbwfs_page_st_bg']) && $pluginOptionsVal['csbwfs_page_st_bg']!=''){ $stImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_st_bg'].';"';} else{$stImgbg='';}
625
- //get email message
626
- if(is_page() || is_single() || is_category() || is_archive()){
627
-
628
- if($pluginOptionsVal['csbwfs_mailMessage']!=''){ $mailMsg=$pluginOptionsVal['csbwfs_mailMessage'];} else{
629
- $mailMsg='?subject='.get_the_title().'&body='.$shareurl;}
630
- }else
631
- {
632
- $mailMsg='?subject='.get_bloginfo('name').'&body='.home_url('/');
633
- }
634
- if(isset($pluginOptionsVal['csbwfs_btn_position']) && $pluginOptionsVal['csbwfs_btn_position']!=''):
635
- $btnPosition=$pluginOptionsVal['csbwfs_btn_position'];
636
- else:
637
- $btnPosition='left';
638
- endif;
639
-
640
- if(isset($pluginOptionsVal['csbwfs_btn_text']) && $pluginOptionsVal['csbwfs_btn_text']!=''):
641
- $btnText=$pluginOptionsVal['csbwfs_btn_text'];
642
- else:
643
- $btnText='';
644
- endif;
645
-
646
- $shareButtonContent='<div id="socialButtonOnPage" class="'.$btnPosition.'SocialButtonOnPage">';
647
- if($btnText!=''):
648
- $shareButtonContent.='<div class="sharethis-arrow" title="'.$btnText.'"><span>'.$btnText.'</span></div>';
649
- endif;
650
- /* Facebook*/
651
- if($pluginOptionsVal['csbwfs_fpublishBtn']!=''):
652
- $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="fb-p" class="csbwfs-fb"><a href="javascript:" onclick="window.open(\'//www.facebook.com/sharer/sharer.php?u='.$shareurl.'\',\'Facebook\',\'width=800,height=300\');return false;"
653
- target="_blank" title="'.$fImgAlt.'" '.$fImgbg.'>';
654
- if($fImg!=''){
655
- $shareButtonContent .='<img src="'.$fImg.'" alt="'.$fImgAlt.'" width="35" height="35" >';
656
- }else{
657
- $shareButtonContent .='<i class="csbwfs_facebook"></i>';
658
- }
659
- $shareButtonContent .='</a></div></div>';
660
- endif;
661
-
662
- /* Twitter */
663
- if($pluginOptionsVal['csbwfs_tpublishBtn']!=''):
664
- $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="tw-p" class="csbwfs-tw"><a href="javascript:" onclick="window.open(\'//twitter.com/share?url='.$shareurl.'&text='.$ShareTitle.'&nbsp;&nbsp;\', \'_blank\', \'width=800,height=300\')" title="'.$tImgAlt.'" '.$tImgbg.'>';
665
- if($tImg!='')
666
- {
667
- $shareButtonContent .='<img src="'.$tImg.'" alt="'.$tImgAlt.'" width="35" height="35" >';
668
- }else{
669
- $shareButtonContent .='<i class="csbwfs_twitter"></i>';
670
- }
671
- $shareButtonContent .='</a></div></div>';
672
- endif;
673
-
674
- /* Google Plus */
675
- if($pluginOptionsVal['csbwfs_gpublishBtn']!=''):
676
- $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="gp-p" class="csbwfs-gp"><a href="javascript:" onclick="javascript:window.open(\'//plus.google.com/share?url='.$shareurl.'\',\'\',\'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=800\');return false;" title="'.$gImgAlt.'" '.$gImgbg.'>';
677
- if($gImg!='')
678
- {
679
- $shareButtonContent .='<img src="'.$gImg.'" alt="'.$gImgAlt.'" width="35" height="35" >';
680
- }else{
681
- $shareButtonContent .='<i class="csbwfs_plus"></i>';
682
- }
683
- $shareButtonContent .='</a></div></div>';
684
- endif;
685
-
686
- /* Linkedin */
687
- if($pluginOptionsVal['csbwfs_lpublishBtn']!=''):
688
- $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="li-p" class="csbwfs-li"><a href="javascript:" onclick="javascript:window.open(\'//www.linkedin.com/shareArticle?mini=true&url='.$shareurl.'\',\'\', \'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=600\');return false;" title="'.$lImgAlt.'" '.$lImgbg.'>';
689
- if($lImg!='')
690
- {
691
- $shareButtonContent .='<img src="'.$lImg.'" alt="'.$lImgAlt.'" width="35" height="35" >';
692
- }else{
693
- $shareButtonContent .='<i class="csbwfs_linkedin"></i>';
694
- }
695
- $shareButtonContent .='</a></div></div>';
696
- endif;
697
-
698
- /* Pinterest */
699
- if($pluginOptionsVal['csbwfs_ppublishBtn']!=''):
700
- $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="pin-p" class="csbwfs-pin"><a onclick="javascript:void((function(){var e=document.createElement(\'script\');e.setAttribute(\'type\',\'text/javascript\');e.setAttribute(\'charset\',\'UTF-8\');e.setAttribute(\'src\',\'//assets.pinterest.com/js/pinmarklet.js?r=\'+Math.random()*99999999);document.body.appendChild(e)})());" href="javascript:void(0);" title="'.$pImgAlt.'" '.$pImgbg.'>';
701
- if($pImg!='')
702
- {
703
- $shareButtonContent .='<img src="'.$pImg.'" alt="'.$pImgAlt.'" width="35" height="35" >';
704
- }else{
705
- $shareButtonContent .='<i class="csbwfs_pinterest"></i>';
706
- }
707
- $shareButtonContent .='</a></div></div>';
708
- endif;
709
- /* Reddit */
710
- if(isset($pluginOptionsVal['csbwfs_republishBtn']) && $pluginOptionsVal['csbwfs_republishBtn']!=''):
711
- $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="re-p" class="csbwfs-re"><a onclick="window.open(\'//reddit.com/submit?url='.$shareurl.'&amp;title='.$ShareTitle.'\',\'Reddit\',\'toolbar=0,status=0,width=1000,height=800\');" href="javascript:void(0);" title="'.$reImgAlt.'" '.$reImgbg.'>';
712
- if($reImg!='')
713
- {
714
- $shareButtonContent .='<img src="'.$reImg.'" alt="'.$reImgAlt.'" width="35" height="35" >';
715
- }else{
716
- $shareButtonContent .='<i class="csbwfs_reddit"></i>';
717
- }
718
- $shareButtonContent .='</a></div></div>';
719
- endif;
720
- /* Stumbleupon */
721
- if(isset($pluginOptionsVal['csbwfs_stpublishBtn']) && $pluginOptionsVal['csbwfs_stpublishBtn']!=''):
722
- $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="st-p" class="csbwfs-st"><a onclick="window.open(\'//www.stumbleupon.com/submit?url='.$shareurl.'&amp;title='.$ShareTitle.'\',\'Stumbleupon\',\'toolbar=0,status=0,width=1000,height=800\');" href="javascript:void(0);" title="'.$stImgAlt.'" '.$stImgbg.'>';
723
- if($stImg!='')
724
- {
725
- $shareButtonContent .='<img src="'.$stImg.'" alt="'.$stImgAlt.'" width="35" height="35" >';
726
- }else{
727
- $shareButtonContent .='<i class="csbwfs_stumbleupon"></i>';
728
- }
729
- $shareButtonContent .='</a></div></div>';
730
- endif;
731
- /* Youtube */
732
- if(isset($pluginOptionsVal['csbwfs_ytpublishBtn']) && $pluginOptionsVal['csbwfs_ytpublishBtn']!=''):
733
- $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="yt-p" class="csbwfs-yt"><a onclick="window.open(\''.$pluginOptionsVal['csbwfs_ytPath'].'\');" href="javascript:void(0);" title="'.$ytImgAlt.'" '.$ytImgbg.'>';
734
- if($ytImg!='')
735
- {
736
- $shareButtonContent .='<img src="'.$ytImg.'" alt="'.$ytImgAlt.'" width="35" height="35" >';
737
- }else{
738
- $shareButtonContent .='<i class="csbwfs_youtube"></i>';
739
- }
740
- $shareButtonContent .='</a></div></div>';
741
- endif;
742
- /* Email */
743
- if($pluginOptionsVal['csbwfs_mpublishBtn']!=''):
744
- $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="ml-p" class="csbwfs-ml"><a href="mailto:'.$mailMsg.'" title="'.$mImgAlt.'" '.$mImgbg.'>';
745
- if($mImg!='')
746
- {
747
- $shareButtonContent .='<img src="'.$mImg.'" alt="'.$mImgAlt.'" width="35" height="35" >';
748
- }else{
749
- $shareButtonContent .='<i class="csbwfs_mail"></i>';
750
- }
751
- $shareButtonContent .='</a></div></div>';
752
- endif;
753
- $shareButtonContent.='</div>';
754
-
755
- // Returns the content.
756
- global $post;
757
- $shareButtonContentReturn='';
758
- /* DEFAULT HOME */
759
- if((is_home() && is_front_page()) && $pluginOptionsVal['csbwfs_page_hide_home']=='yes'):
760
- $shareButtonContentReturn=$shareButtonContent;
761
- endif;
762
- /* STATIC front page */
763
- if(is_front_page() && $pluginOptionsVal['csbwfs_page_hide_home']=='yes'):
764
- $shareButtonContentReturn=$shareButtonContent;
765
- endif;
766
- //post
767
- if(is_single() && $pluginOptionsVal['csbwfs_page_hide_post']=='yes'):
768
- $shareButtonContentReturn=$shareButtonContent;
769
- endif;
770
- //page
771
- if(is_page() && $pluginOptionsVal['csbwfs_page_hide_page']=='yes'):
772
- if(!is_front_page()):
773
- $shareButtonContentReturn=$shareButtonContent;
774
- endif;
775
- endif;
776
- //archive
777
- if(is_archive() && $pluginOptionsVal['csbwfs_page_hide_archive']=='yes'):
778
- $shareButtonContentReturn=$shareButtonContent;
779
- endif;
780
- // 404
781
- if(is_404()):
782
- $shareButtonContentReturn='';
783
- endif;
784
- /** Buttons position on content */
785
- if(isset($pluginOptionsVal['csbwfs_btn_display']) && $pluginOptionsVal['csbwfs_btn_display']=='above'){
786
- $finalContent= $shareButtonContentReturn.$content;
787
- }else
788
- {
789
- $finalContent = $content.$shareButtonContentReturn;
790
- }
791
- return $finalContent;
792
- }
793
- ?>
1
+ <?php
2
+ /*
3
+ * Custom Share Buttons With Floating Sidebar (C)
4
+ * @get_csbwf_sidebar_options()
5
+ * @get_csbwf_sidebar_content()
6
+ * */
7
+ ?>
8
+ <?php
9
+ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
10
+ // get all options value for "Custom Share Buttons with Floating Sidebar"
11
+ function get_csbwf_sidebar_options() {
12
+ global $wpdb;
13
+ $ctOptions = $wpdb->get_results("SELECT option_name, option_value FROM $wpdb->options WHERE option_name LIKE 'csbwfs_%'");
14
+
15
+ foreach ($ctOptions as $option) {
16
+ $ctOptions[$option->option_name] = $option->option_value;
17
+ }
18
+
19
+ return $ctOptions;
20
+ }
21
+ /** Get the current url*/
22
+ if(!function_exists('csbwfs_current_path_protocol')):
23
+ function csbwfs_current_path_protocol($s, $use_forwarded_host=false)
24
+ {
25
+ $pwahttp = (!empty($s['HTTPS']) && $s['HTTPS'] == 'on') ? true:false;
26
+ $pwasprotocal = strtolower($s['SERVER_PROTOCOL']);
27
+ $pwa_protocol = substr($pwasprotocal, 0, strpos($pwasprotocal, '/')) . (($pwahttp) ? 's' : '');
28
+ $port = $s['SERVER_PORT'];
29
+ $port = ((!$pwahttp && $port=='80') || ($pwahttp && $port=='443')) ? '' : ':'.$port;
30
+ $host = ($use_forwarded_host && isset($s['HTTP_X_FORWARDED_HOST'])) ? $s['HTTP_X_FORWARDED_HOST'] : (isset($s['HTTP_HOST']) ? $s['HTTP_HOST'] : null);
31
+ $host = isset($host) ? $host : $s['SERVER_NAME'] . $port;
32
+ return $pwa_protocol . '://' . $host;
33
+ }
34
+ endif;
35
+ if(!function_exists('csbwfs_get_current_page_url')):
36
+ function csbwfs_get_current_page_url($s, $use_forwarded_host=false)
37
+ {
38
+ return csbwfs_current_path_protocol($s, $use_forwarded_host) . $s['REQUEST_URI'];
39
+ }
40
+ endif;
41
+ /*
42
+ * Site is browsing in mobile or not
43
+ * @csbwfsIsMobile()
44
+ * */
45
+ if(!function_exists('csbwfsIsMobile')):
46
+ function csbwfsIsMobile() {
47
+ // Check the server headers to see if they're mobile friendly
48
+ if(isset($_SERVER["HTTP_X_WAP_PROFILE"])) {
49
+ return true;
50
+ }
51
+ // Let's NOT return "mobile" if it's an iPhone, because the iPhone can render normal pages quite well.
52
+ if(isset($_SERVER["HTTP_USER_AGENT"])):
53
+ if(strstr($_SERVER['HTTP_USER_AGENT'], 'iPad')) {
54
+ return false;
55
+ }
56
+ endif;
57
+
58
+ // If the http_accept header supports wap then it's a mobile too
59
+ if(isset($_SERVER["HTTP_ACCEPT"])):
60
+ if(preg_match("/wap\.|\.wap/i",$_SERVER["HTTP_ACCEPT"])) {
61
+ return true;
62
+ }
63
+ endif;
64
+ // Still no luck? Let's have a look at the user agent on the browser. If it contains
65
+ // any of the following, it's probably a mobile device. Kappow!
66
+ if(isset($_SERVER["HTTP_USER_AGENT"])){
67
+ $user_agents = array("midp", "j2me", "avantg", "docomo", "novarra", "palmos", "palmsource", "240x320", "opwv", "chtml", "pda", "windows\ ce", "mmp\/", "blackberry", "mib\/", "symbian", "wireless", "nokia", "hand", "mobi", "phone", "cdm", "up\.b", "audio", "SIE\-", "SEC\-", "samsung", "HTC", "mot\-", "mitsu", "sagem", "sony", "alcatel", "lg", "erics", "vx", "NEC", "philips", "mmm", "xx", "panasonic", "sharp", "wap", "sch", "rover", "pocket", "benq", "java", "pt", "pg", "vox", "amoi", "bird", "compal", "kg", "voda", "sany", "kdd", "dbt", "sendo", "sgh", "gradi", "jb", "\d\d\di", "moto");
68
+ foreach($user_agents as $user_string){
69
+ if(preg_match("/".$user_string."/i",$_SERVER["HTTP_USER_AGENT"])) {
70
+ return true;
71
+ }
72
+ }
73
+ }
74
+ // None of the above? Then it's probably not a mobile device.
75
+ return false;
76
+ }
77
+ endif;
78
+ // Get plugin options
79
+ $pluginOptionsVal=get_csbwf_sidebar_options();
80
+ //check plugin in enable or not
81
+ if(isset($pluginOptionsVal['csbwfs_active']) && $pluginOptionsVal['csbwfs_active']==1){
82
+
83
+ if((csbwfsIsMobile()) &&
84
+ isset($pluginOptionsVal['csbwfs_deactive_for_mob']) && $pluginOptionsVal['csbwfs_deactive_for_mob']!='')
85
+ {
86
+ // silent is Gold;
87
+ }else
88
+ {
89
+ add_action('wp_footer','get_csbwf_sidebar_content');
90
+ add_action( 'wp_enqueue_scripts', 'csbwf_sidebar_scripts' );
91
+ add_action('wp_footer','csbwf_sidebar_load_inline_js');
92
+ add_action('wp_footer','csbwfs_cookie');
93
+ }
94
+
95
+ }
96
+
97
+ function csbwfs_cookie()
98
+ {
99
+ echo $cookieVal='<script>csbwfsCheckCookie();function csbwfsSetCookie(cname,cvalue,exdays) {
100
+ var d = new Date();
101
+ d.setTime(d.getTime() + (exdays*24*60*60*1000));
102
+ var expires = "expires=" + d.toGMTString();
103
+ document.cookie = cname+"="+cvalue+"; "+expires;
104
+ }
105
+
106
+ function csbwfsGetCookie(cname) {
107
+ var name = cname + "=";
108
+ var ca = document.cookie.split(\';\');
109
+ for(var i=0; i<ca.length; i++) {
110
+ var c = ca[i];
111
+ while (c.charAt(0)==\' \') c = c.substring(1);
112
+ if (c.indexOf(name) != -1) {
113
+ return c.substring(name.length, c.length);
114
+ }
115
+ }
116
+ return "";
117
+ }
118
+
119
+ function csbwfsCheckCookie() {
120
+ var hideshowhide = "'.get_option('csbwfs_rmSHBtn').'"
121
+ var button_status=csbwfsGetCookie("csbwfs_show_hide_status");
122
+ if (button_status != "") {
123
+
124
+ } else {
125
+ csbwfsSetCookie("csbwfs_show_hide_status", "active",1);
126
+ }
127
+ if(hideshowhide=="yes")
128
+ {
129
+ csbwfsSetCookie("csbwfs_show_hide_status", "active",0);
130
+ }
131
+ }
132
+
133
+ </script>';
134
+ }
135
+ if(isset($pluginOptionsVal['csbwfs_buttons_active']) && $pluginOptionsVal['csbwfs_buttons_active']==1){
136
+ add_filter( 'the_content', 'csbfs_the_content_filter', 20);
137
+ add_action( 'wp_enqueue_scripts', 'csbwf_sidebar_scripts' );
138
+ }
139
+ //register style and scrip files
140
+ function csbwf_sidebar_scripts() {
141
+ wp_enqueue_script( 'jquery' ); // wordpress jQuery
142
+ wp_register_style( 'csbwf_sidebar_style', plugins_url( 'css/csbwfs.css',__FILE__ ) );
143
+ wp_enqueue_style( 'csbwf_sidebar_style' );
144
+ }
145
+ /*********************************************************
146
+ "Add the jQuery code in head section using hooks"
147
+ *********************************************************/
148
+ function csbwf_sidebar_load_inline_js()
149
+ {
150
+ $pluginOptionsVal=get_csbwf_sidebar_options();
151
+ $jscnt='<script>
152
+ var windWidth=jQuery( window ).width();
153
+ //alert(windWidth);
154
+ var animateWidth;
155
+ var defaultAnimateWidth;';
156
+ $jscnt.='
157
+ jQuery(document).ready(function()
158
+ {
159
+ animateWidth="55";
160
+ defaultAnimateWidth= animateWidth-10;
161
+ animateHeight="49";
162
+ defaultAnimateHeight= animateHeight-2;';
163
+ if($pluginOptionsVal['csbwfs_delayTimeBtn']!='0'):
164
+ $jscnt.='jQuery("#csbwfs-delaydiv").hide();
165
+ setTimeout(function(){
166
+ jQuery("#csbwfs-delaydiv").fadeIn();}, '.$pluginOptionsVal['csbwfs_delayTimeBtn'].');';
167
+ endif;
168
+
169
+ if($pluginOptionsVal['csbwfs_position']=='right' || $pluginOptionsVal['csbwfs_position']=='left'){
170
+
171
+ $jscnt.='jQuery("div.csbwfsbtns a").hover(function(){
172
+ jQuery(this).animate({width:animateWidth});
173
+ },function(){
174
+ jQuery(this).stop( true, true ).animate({width:defaultAnimateWidth});
175
+ });';
176
+ }else
177
+ {
178
+ //silent
179
+
180
+ }
181
+
182
+ if(isset($pluginOptionsVal['csbwfs_auto_hide']) && $pluginOptionsVal['csbwfs_auto_hide']!=''):
183
+ $jscnt.='csbwfsSetCookie("csbwfs_show_hide_status","in_active","1");';
184
+ endif;
185
+
186
+ $jscnt.='jQuery("div.csbwfs-show").hide();
187
+ jQuery("div.csbwfs-show a").click(function(){
188
+ jQuery("div#csbwfs-social-inner").show(500);
189
+ jQuery("div.csbwfs-show").hide(500);
190
+ jQuery("div.csbwfs-hide").show(500);
191
+ csbwfsSetCookie("csbwfs_show_hide_status","active","1");
192
+ });
193
+
194
+ jQuery("div.csbwfs-hide a").click(function(){
195
+ jQuery("div.csbwfs-show").show(500);
196
+ jQuery("div.csbwfs-hide").hide(500);
197
+ jQuery("div#csbwfs-social-inner").hide(500);
198
+ csbwfsSetCookie("csbwfs_show_hide_status","in_active","1");
199
+ });';
200
+
201
+ $jscnt.='var button_status=csbwfsGetCookie("csbwfs_show_hide_status");
202
+ if (button_status =="in_active") {
203
+ jQuery("div.csbwfs-show").show();
204
+ jQuery("div.csbwfs-hide").hide();
205
+ jQuery("div#csbwfs-social-inner").hide();
206
+ } else {
207
+ jQuery("div#csbwfs-social-inner").show();
208
+ jQuery("div.csbwfs-show").hide();
209
+ jQuery("div.csbwfs-hide").show();
210
+ }';
211
+
212
+
213
+ $jscnt.='});
214
+
215
+ </script>';
216
+
217
+ echo $jscnt;
218
+ }
219
+
220
+ /********************************************************
221
+ "Custom Share Buttons with Floating Sidebar" HTML
222
+ *********************************************************/
223
+ function get_csbwf_sidebar_content() {
224
+ global $post;
225
+ $pluginOptionsVal=get_csbwf_sidebar_options();
226
+ $shareurl = htmlspecialchars(csbwfs_get_current_page_url($_SERVER), ENT_QUOTES, 'UTF-8');
227
+ $ShareTitle = (is_front_page() && is_home()) ? get_bloginfo('name'): trim(wp_title('',false));
228
+ $ShareTitle= htmlspecialchars(rawurlencode($ShareTitle));
229
+ $ShareTitle = str_replace("%26%23039%3B","",$ShareTitle);// remove single quate
230
+ /* Get All buttons Image */
231
+ //get facebook button image
232
+ if($pluginOptionsVal['csbwfs_fb_image']!=''){ $fImg=$pluginOptionsVal['csbwfs_fb_image'];}
233
+ else{$fImg='';}
234
+ //get twitter button image
235
+ if($pluginOptionsVal['csbwfs_tw_image']!=''){ $tImg=$pluginOptionsVal['csbwfs_tw_image'];}
236
+ else{$tImg='';}
237
+ //get Linkedin button image
238
+ if($pluginOptionsVal['csbwfs_li_image']!=''){ $lImg=$pluginOptionsVal['csbwfs_li_image'];}
239
+ else{$lImg='';}
240
+ //get mail button image
241
+ if($pluginOptionsVal['csbwfs_mail_image']!=''){ $mImg=$pluginOptionsVal['csbwfs_mail_image'];}
242
+ else{$mImg='';}
243
+ //get pinterest button image
244
+ if($pluginOptionsVal['csbwfs_pin_image']!=''){ $pImg=$pluginOptionsVal['csbwfs_pin_image'];}
245
+ else{$pImg='';}
246
+ //get youtube button image
247
+ if(isset($pluginOptionsVal['csbwfs_yt_image']) && $pluginOptionsVal['csbwfs_yt_image']!=''){ $ytImg=$pluginOptionsVal['csbwfs_yt_image'];}
248
+ else{$ytImg='';}
249
+ //get reddit plus button image
250
+ if(isset($pluginOptionsVal['csbwfs_re_image']) && $pluginOptionsVal['csbwfs_re_image']!=''){ $reImg=$pluginOptionsVal['csbwfs_re_image'];}
251
+ else{$reImg='';}
252
+ //get stumbleupon button image
253
+ if(isset($pluginOptionsVal['csbwfs_st_image']) && $pluginOptionsVal['csbwfs_st_image']!=''){ $stImg=$pluginOptionsVal['csbwfs_st_image'];}
254
+ else{$stImg='';}
255
+ /* Get All buttons Image Alt/Title */
256
+ //get facebook button image alt/title
257
+ if($pluginOptionsVal['csbwfs_fb_title']!=''){ $fImgAlt=$pluginOptionsVal['csbwfs_fb_title'];}
258
+ else{$fImgAlt='Share On Facebook';}
259
+ //get twitter button image alt/title
260
+ if($pluginOptionsVal['csbwfs_tw_title']!=''){ $tImgAlt=$pluginOptionsVal['csbwfs_tw_title'];}
261
+ else{$tImgAlt='Share On Twitter';}
262
+ //get Linkedin button image alt/title
263
+ if($pluginOptionsVal['csbwfs_li_title']!=''){ $lImgAlt=$pluginOptionsVal['csbwfs_li_title'];}
264
+ else{$lImgAlt='Share On Linkedin';}
265
+ //get mail button image alt/title
266
+ if($pluginOptionsVal['csbwfs_mail_title']!=''){ $mImgAlt=$pluginOptionsVal['csbwfs_mail_title'];}
267
+ else{$mImgAlt='Contact us';}
268
+ //get pinterest button image alt/title
269
+ if($pluginOptionsVal['csbwfs_pin_title']!=''){ $pImgAlt=$pluginOptionsVal['csbwfs_pin_title'];}
270
+ else{$pImgAlt='Share On Pinterest';}
271
+ //get youtube button image alt/title
272
+ if(isset($pluginOptionsVal['csbwfs_yt_title']) && $pluginOptionsVal['csbwfs_yt_title']!=''){ $ytImgAlt=$pluginOptionsVal['csbwfs_yt_title'];}
273
+ else{$ytImgAlt='Share On Youtube';}
274
+ //get reddit plus button image alt/title
275
+ if(isset($pluginOptionsVal['csbwfs_re_title']) && $pluginOptionsVal['csbwfs_re_title']!=''){ $reImgAlt=$pluginOptionsVal['csbwfs_re_title'];}
276
+ else{$reImgAlt='Share On Reddit';}
277
+ //get stumbleupon button image alt/title
278
+ if(isset($pluginOptionsVal['csbwfs_st_title']) && $pluginOptionsVal['csbwfs_st_title']!=''){ $stImgAlt=$pluginOptionsVal['csbwfs_st_title'];}
279
+ else{$stImgAlt='Share On Stumbleupon';}
280
+ //get email message
281
+ if(is_page() || is_single() || is_category() || is_archive()){
282
+ if($pluginOptionsVal['csbwfs_mailMessage']!=''){ $mailMsg=$pluginOptionsVal['csbwfs_mailMessage'];} else{
283
+ $mailMsg='?subject='.$ShareTitle.'&body='.$shareurl;}
284
+ }else
285
+ {
286
+ $mailMsg='?subject='.get_bloginfo('name').'&body='.home_url('/');
287
+ }
288
+ // Top Margin
289
+ if($pluginOptionsVal['csbwfs_top_margin']!=''){
290
+ $margin=$pluginOptionsVal['csbwfs_top_margin'];
291
+ }else
292
+ {
293
+ $margin='25%';
294
+ }
295
+
296
+ //Sidebar Position
297
+ if($pluginOptionsVal['csbwfs_position']=='right'){
298
+ $style=' style="top:'.$margin.';right:-5px;"'; $idName=' id="csbwfs-right"'; $showImg='hide-r.png'; $hideImg='show.png';
299
+ }else if($pluginOptionsVal['csbwfs_position']=='bottom'){
300
+ $style=' style="bottom:0;"'; $idName=' id="csbwfs-bottom"'; $showImg='hide-b.png'; $hideImg='show.png';
301
+ }
302
+ else
303
+ {
304
+ $idName=' id="csbwfs-left"'; $style=' style="top:'.$margin.';left:0;"'; $showImg='hide-l.png';$hideImg='hide.png';
305
+ }
306
+ /* Get All buttons background color */
307
+ //get facebook button image background color
308
+ if($pluginOptionsVal['csbwfs_fb_bg']!=''){ $fImgbg=' style="background:'.$pluginOptionsVal['csbwfs_fb_bg'].';"';}
309
+ else{$fImgbg='';}
310
+ //get twitter button image background color
311
+ if($pluginOptionsVal['csbwfs_tw_bg']!=''){ $tImgbg=' style="background:'.$pluginOptionsVal['csbwfs_tw_bg'].';"';}
312
+ else{$tImgbg='';}
313
+ //get Linkedin button image background color
314
+ if($pluginOptionsVal['csbwfs_li_bg']!=''){ $lImgbg=' style="background:'.$pluginOptionsVal['csbwfs_li_bg'].';"';}
315
+ else{$lImgbg='';}
316
+ //get mail button image background color
317
+ if($pluginOptionsVal['csbwfs_mail_bg']!=''){ $mImgbg=' style="background:'.$pluginOptionsVal['csbwfs_mail_bg'].';"';}
318
+ else{$mImgbg='';}
319
+ //get pinterest button image background color
320
+ if($pluginOptionsVal['csbwfs_pin_bg']!=''){ $pImgbg=' style="background:'.$pluginOptionsVal['csbwfs_pin_bg'].';"';}
321
+ else{$pImgbg='';}
322
+
323
+ //get youtube button image background color
324
+ if(isset($pluginOptionsVal['csbwfs_yt_bg']) && $pluginOptionsVal['csbwfs_yt_bg']!=''){ $ytImgbg=' style="background:'.$pluginOptionsVal['csbwfs_yt_bg'].';"';}else{$ytImgbg='';}
325
+ //get reddit button image background color
326
+ if(isset($pluginOptionsVal['csbwfs_re_bg']) && $pluginOptionsVal['csbwfs_re_bg']!=''){ $reImgbg=' style="background:'.$pluginOptionsVal['csbwfs_re_bg'].';"';}else{$reImgbg='';}
327
+ //get stumbleupon button image background color
328
+ if(isset($pluginOptionsVal['csbwfs_st_bg']) && $pluginOptionsVal['csbwfs_st_bg']!=''){ $stImgbg=' style="background:'.$pluginOptionsVal['csbwfs_st_bg'].';"';} else{$stImgbg='';}
329
+
330
+ /** Message */
331
+ if($pluginOptionsVal['csbwfs_show_btn']!=''){ $showbtn=$pluginOptionsVal['csbwfs_show_btn'];}
332
+ else{$showbtn='Show Buttons';}
333
+ //get show/hide button message
334
+ if($pluginOptionsVal['csbwfs_hide_btn']!=''){ $hidebtn=$pluginOptionsVal['csbwfs_hide_btn'];}
335
+ else{$hidebtn='Hide Buttons';}
336
+ //get mail button message
337
+ if($pluginOptionsVal['csbwfs_share_msg']!=''){ $sharemsg=$pluginOptionsVal['csbwfs_share_msg'];}
338
+ else{$sharemsg='Share This With Your Friends';}
339
+
340
+ /** Check display Show/Hide button or not*/
341
+ if(isset($pluginOptionsVal['csbwfs_rmSHBtn']) && $pluginOptionsVal['csbwfs_rmSHBtn']!=''):
342
+ $isActiveHideShowBtn='yes';
343
+ else:
344
+ $isActiveHideShowBtn='no';
345
+ endif;
346
+ $floatingSidebarContent='<div id="csbwfs-delaydiv"><div class="csbwfs-social-widget" '.$idName.' title="'.$sharemsg.'" '.$style.'>';
347
+
348
+ if($isActiveHideShowBtn!='yes') :
349
+ $floatingSidebarContent .= '<div class="csbwfs-show"><a href="javascript:" title="'.$showbtn.'" id="csbwfs-show"><img src="'.plugins_url('custom-share-buttons-with-floating-sidebar/images/'.$showImg).'" alt="'.$showbtn.'"></a></div>';
350
+ endif;
351
+
352
+ $floatingSidebarContent .= '<div id="csbwfs-social-inner">';
353
+
354
+ /** FB */
355
+ if($pluginOptionsVal['csbwfs_fpublishBtn']!=''):
356
+ $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-fb" class="csbwfs-fb"><a href="javascript:" onclick="javascript:window.open(\'//www.facebook.com/sharer/sharer.php?u='.$shareurl.'\', \'\', \'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=300,width=600\');return false;" target="_blank" title="'.$fImgAlt.'" '.$fImgbg.'>';
357
+
358
+ if($fImg!=''){
359
+ $floatingSidebarContent .='<img src="'.$fImg.'" alt="'.$fImgAlt.'" width="35" height="35" >';
360
+ }else{
361
+ $floatingSidebarContent .='<i class="csbwfs_facebook"></i>';
362
+ }
363
+ $floatingSidebarContent .='</a></div></div>';
364
+ endif;
365
+
366
+ /** TW */
367
+ if($pluginOptionsVal['csbwfs_tpublishBtn']!=''):
368
+ $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-tw" class="csbwfs-tw"><a href="javascript:" onclick="window.open(\'//twitter.com/share?url='.$shareurl.'&text='.$ShareTitle.'\',\'_blank\',\'width=800,height=300\')" title="'.$tImgAlt.'" '.$tImgbg.'>';
369
+ if($tImg!='')
370
+ {
371
+ $floatingSidebarContent .='<img src="'.$tImg.'" alt="'.$tImgAlt.'" width="35" height="35" >';
372
+ }else{
373
+ $floatingSidebarContent .='<i class="csbwfs_twitter"></i>';
374
+ }
375
+ $floatingSidebarContent .='</a></div></div>';
376
+
377
+ endif;
378
+
379
+ /** LI */
380
+ if($pluginOptionsVal['csbwfs_lpublishBtn']!=''):
381
+ $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-li" class="csbwfs-li"><a href="javascript:" onclick="javascript:window.open(\'//www.linkedin.com/cws/share?mini=true&url='. $shareurl.'\',\'\',\'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=800\');return false;" title="'.$lImgAlt.'" '.$lImgbg.'>';
382
+ if($lImg!='')
383
+ {
384
+ $floatingSidebarContent .='<img src="'.$lImg.'" alt="'.$lImgAlt.'" width="35" height="35" >';
385
+ }else{
386
+ $floatingSidebarContent .='<i class="csbwfs_linkedin"></i>';
387
+ }
388
+ $floatingSidebarContent .='</a></div></div>';
389
+ endif;
390
+
391
+ /** PIN */
392
+ if($pluginOptionsVal['csbwfs_ppublishBtn']!=''):
393
+ $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-pin" class="csbwfs-pin"><a onclick="javascript:void((function(){var e=document.createElement(\'script\');e.setAttribute(\'type\',\'text/javascript\');e.setAttribute(\'charset\',\'UTF-8\');e.setAttribute(\'src\',\'//assets.pinterest.com/js/pinmarklet.js?r=\'+Math.random()*99999999);document.body.appendChild(e)})());" href="javascript:void(0);" '.$pImgbg.' title="'.$pImgAlt.'">';
394
+ if($pImg!='')
395
+ {
396
+ $floatingSidebarContent .='<img src="'.$pImg.'" alt="'.$pImgAlt.'" width="35" height="35" >';
397
+ }else{
398
+ $floatingSidebarContent .='<i class="csbwfs_pinterest"></i>';
399
+ }
400
+ $floatingSidebarContent .='</a></div></div>';
401
+ endif;
402
+
403
+ /** Reddit */
404
+ if(isset($pluginOptionsVal['csbwfs_republishBtn']) && $pluginOptionsVal['csbwfs_republishBtn']!=''):
405
+ $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-re" class="csbwfs-re"><a onclick="window.open(\'//reddit.com/submit?url='.$shareurl.'&amp;title='.$ShareTitle.'\',\'Reddit\',\'toolbar=0,status=0,width=1000,height=800\');" href="javascript:void(0);" '.$reImgbg.' title="'.$reImgAlt.'">';
406
+ if($reImg!='')
407
+ {
408
+ $floatingSidebarContent .='<img src="'.$reImg.'" alt="'.$reImgAlt.'" width="35" height="35" >';
409
+ }else{
410
+ $floatingSidebarContent .='<i class="csbwfs_reddit"></i>';
411
+ }
412
+ $floatingSidebarContent .='</a></div></div>';
413
+ endif;
414
+
415
+ /** Stumbleupon */
416
+ if(isset($pluginOptionsVal['csbwfs_stpublishBtn']) && $pluginOptionsVal['csbwfs_stpublishBtn']!=''):
417
+ $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-st" class="csbwfs-st"><a onclick="window.open(\'//www.stumbleupon.com/submit?url='.$shareurl.'&amp;title='.$ShareTitle.'\',\'Stumbleupon\',\'toolbar=0,status=0,width=1000,height=800\');" href="javascript:void(0);" '.$stImgbg.' title="'.$stImgAlt.'">';
418
+ if($stImg!='')
419
+ {
420
+ $floatingSidebarContent .='<img src="'.$stImg.'" alt="'.$stImgAlt.'" width="35" height="35" >';
421
+ }else{
422
+ $floatingSidebarContent .='<i class="csbwfs_stumbleupon"></i>';
423
+ }
424
+ $floatingSidebarContent .='</a></div></div>';
425
+ endif;
426
+ /** YT */
427
+ if(isset($pluginOptionsVal['csbwfs_ytpublishBtn']) && $pluginOptionsVal['csbwfs_ytpublishBtn']!=''):
428
+ $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-yt" class="csbwfs-yt"><a onclick="window.open(\''.$pluginOptionsVal['csbwfs_ytPath'].'\');" href="javascript:void(0);" '.$ytImgbg.' title="'.$ytImgAlt.'">';
429
+ if($ytImg!='')
430
+ {
431
+ $floatingSidebarContent .='<img src="'.$ytImg.'" alt="'.$ytImgAlt.'" width="35" height="35" >';
432
+ }else{
433
+ $floatingSidebarContent .='<i class="csbwfs_youtube"></i>';
434
+ }
435
+ $floatingSidebarContent .='</a></div></div>';
436
+ endif;
437
+ /** Mail*/
438
+ if($pluginOptionsVal['csbwfs_mpublishBtn']!=''):
439
+ $floatingSidebarContent .='<div class="csbwfs-sbutton csbwfsbtns"><div id="csbwfs-ml" class="csbwfs-ml"><a href="mailto:'.$mailMsg.'" title="'.$mImgAlt.'" '.$mImgbg.' >';
440
+ if($mImg!='')
441
+ {
442
+ $floatingSidebarContent .='<img src="'.$mImg.'" alt="'.$mImgAlt.'" width="35" height="35" >';
443
+ }else{
444
+ $floatingSidebarContent .='<i class="csbwfs_mail"></i>';
445
+ }
446
+ $floatingSidebarContent .='</a></div></div>';
447
+ endif;
448
+
449
+ $floatingSidebarContent .='</div>'; //End social-inner
450
+
451
+ if($isActiveHideShowBtn!='yes') :
452
+ $floatingSidebarContent .='<div class="csbwfs-hide"><a href="javascript:" title="'.$hidebtn.'" id="csbwfs-hide"><img src="'.plugins_url('custom-share-buttons-with-floating-sidebar/images/'.$hideImg).'" alt="'.$hidebtn.'"></a></div>';
453
+ endif;
454
+
455
+ $floatingSidebarContent .='</div></div>'; //End social-inner
456
+ /** Check conditions */
457
+ // Returns the content.
458
+ if(isset($pluginOptionsVal['csbwfs_hide_home'])){$hideOnHome=$pluginOptionsVal['csbwfs_hide_home']; }else{ $hideOnHome='';}
459
+
460
+ if((is_home() && is_front_page()) && $hideOnHome=='yes'):
461
+ $floatingSidebarContent='';
462
+ endif;
463
+ if(is_front_page() && $hideOnHome=='yes' ):
464
+ $floatingSidebarContent='';
465
+ endif;
466
+ /** hide on 404 pages */
467
+ if(is_404()):$floatingSidebarContent='';endif;
468
+
469
+ print $floatingSidebarContent;
470
+ }
471
+
472
+ /**
473
+ * Add social share bottons to the end of every post/page.
474
+ *
475
+ * @uses is_home()
476
+ * @uses is_page()
477
+ * @uses is_single()
478
+ */
479
+ function csbfs_the_content_filter( $content ) {
480
+
481
+ global $post;
482
+ $pluginOptionsVal=get_csbwf_sidebar_options();
483
+ if(is_category())
484
+ {
485
+ $category_id = get_query_var('cat');
486
+ $cats = get_the_category();
487
+ $ShareTitle=$cats[0]->name;
488
+ }elseif($post && is_singular($post->post_type))
489
+ {
490
+ $ShareTitle=$post->post_title;
491
+ }
492
+ elseif(is_archive()){
493
+ global $wp;
494
+ if ( is_day() ) :
495
+ $ShareTitle='Daily Archives: '. get_the_date();
496
+ elseif ( is_month() ) :
497
+ $ShareTitle='Monthly Archives: '. get_the_date('F Y');
498
+ elseif ( is_year() ) :
499
+ $ShareTitle='Yearly Archives: '. get_the_date('Y');
500
+ elseif ( is_author() ) :
501
+ $ShareTitle='Author Archives: '. get_the_author();
502
+ else :
503
+ $ShareTitle ='Blog Archives';
504
+ endif;
505
+ }
506
+ else
507
+ {
508
+ $ShareTitle=get_bloginfo('name');
509
+ }
510
+ /* Set title and url for home page */
511
+ if(is_home() && is_front_page()){
512
+ $ShareTitle=get_bloginfo('name');
513
+ }
514
+
515
+ $shareurl = htmlspecialchars(csbwfs_get_current_page_url($_SERVER), ENT_QUOTES, 'UTF-8');
516
+
517
+ $ShareTitle= htmlspecialchars(rawurlencode($ShareTitle));
518
+
519
+ /* Get All buttons Image */
520
+
521
+ //get facebook button image
522
+ if($pluginOptionsVal['csbwfs_page_fb_image']!=''){ $fImg=$pluginOptionsVal['csbwfs_page_fb_image'];}
523
+ else{$fImg='';}
524
+ //get twitter button image
525
+ if($pluginOptionsVal['csbwfs_page_tw_image']!=''){ $tImg=$pluginOptionsVal['csbwfs_page_tw_image'];}
526
+ else{$tImg='';}
527
+ //get Linkedin button image
528
+ if($pluginOptionsVal['csbwfs_page_li_image']!=''){ $lImg=$pluginOptionsVal['csbwfs_page_li_image'];}
529
+ else{$lImg='';}
530
+ //get mail button image
531
+ if($pluginOptionsVal['csbwfs_page_mail_image']!=''){ $mImg=$pluginOptionsVal['csbwfs_page_mail_image'];}
532
+ else{$mImg='';}
533
+ //get pinterest button image
534
+ if($pluginOptionsVal['csbwfs_page_pin_image']!=''){ $pImg=$pluginOptionsVal['csbwfs_page_pin_image'];}
535
+ else{$pImg='';}
536
+
537
+ //get youtube button image
538
+ if(isset($pluginOptionsVal['csbwfs_page_yt_image']) && $pluginOptionsVal['csbwfs_page_yt_image']!=''){ $ytImg=$pluginOptionsVal['csbwfs_page_yt_image'];}
539
+ else{$ytImg='';}
540
+ //get reddit plus button image
541
+ if(isset($pluginOptionsVal['csbwfs_page_re_image']) && $pluginOptionsVal['csbwfs_page_re_image']!=''){ $reImg=$pluginOptionsVal['csbwfs_page_re_image'];}
542
+ else{$reImg='';}
543
+ //get stumbleupon button image
544
+ if(isset($pluginOptionsVal['csbwfs_page_st_image']) && $pluginOptionsVal['csbwfs_page_st_image']!=''){ $stImg=$pluginOptionsVal['csbwfs_page_st_image'];}
545
+ else{$stImg='';}
546
+
547
+ /* Get All buttons Image Alt/Title */
548
+ //get facebook button image alt/title
549
+ if($pluginOptionsVal['csbwfs_page_fb_title']!=''){ $fImgAlt=$pluginOptionsVal['csbwfs_page_fb_title'];}
550
+ else{$fImgAlt='Share On Facebook';}
551
+ //get twitter button image alt/title
552
+ if($pluginOptionsVal['csbwfs_page_tw_title']!=''){ $tImgAlt=$pluginOptionsVal['csbwfs_page_tw_title'];}
553
+ else{$tImgAlt='Share On Twitter';}
554
+ //get Linkedin button image alt/title
555
+ if($pluginOptionsVal['csbwfs_page_li_title']!=''){ $lImgAlt=$pluginOptionsVal['csbwfs_page_li_title'];}
556
+ else{$lImgAlt='Share On Linkedin';}
557
+ //get mail button image alt/title
558
+ if($pluginOptionsVal['csbwfs_page_mail_title']!=''){ $mImgAlt=$pluginOptionsVal['csbwfs_page_mail_title'];}
559
+ else{$mImgAlt='Contact us';}
560
+ //get pinterest button image alt/title
561
+ if($pluginOptionsVal['csbwfs_page_pin_title']!=''){ $pImgAlt=$pluginOptionsVal['csbwfs_page_pin_title'];}
562
+ else{$pImgAlt='Share On Pinterest';}
563
+ //get youtube button image alt/title
564
+ if(isset($pluginOptionsVal['csbwfs_page_yt_title']) && $pluginOptionsVal['csbwfs_page_yt_title']!=''){ $ytImgAlt=$pluginOptionsVal['csbwfs_page_yt_title'];}
565
+ else{$ytImgAlt='Share On Youtube';}
566
+ //get reddit plus button image alt/title
567
+ if(isset($pluginOptionsVal['csbwfs_page_re_title']) && $pluginOptionsVal['csbwfs_page_re_title']!=''){ $reImgAlt=$pluginOptionsVal['csbwfs_page_re_title'];}
568
+ else{$reImgAlt='Share On Reddit';}
569
+ //get stumbleupon button image alt/title
570
+ if(isset($pluginOptionsVal['csbwfs_page_st_title']) && $pluginOptionsVal['csbwfs_page_st_title']!=''){ $stImgAlt=$pluginOptionsVal['csbwfs_page_st_title'];}
571
+ else{$stImgAlt='Share On Stumbleupon';}
572
+
573
+ /* Get All buttons background color */
574
+ //get facebook button image background color
575
+ if($pluginOptionsVal['csbwfs_page_fb_bg']!=''){ $fImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_fb_bg'].';"';}
576
+ else{$fImgbg='';}
577
+ //get twitter button image background color
578
+ if($pluginOptionsVal['csbwfs_page_tw_bg']!=''){ $tImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_tw_bg'].';"';}
579
+ else{$tImgbg='';}
580
+ //get Linkedin button image background color
581
+ if($pluginOptionsVal['csbwfs_page_li_bg']!=''){ $lImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_li_bg'].';"';}
582
+ else{$lImgbg='';}
583
+ //get mail button image background color
584
+ if($pluginOptionsVal['csbwfs_page_mail_bg']!=''){ $mImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_mail_bg'].';"';}
585
+ else{$mImgbg='';}
586
+ //get pinterest button image background color
587
+ if($pluginOptionsVal['csbwfs_page_pin_bg']!=''){ $pImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_pin_bg'].';"';}
588
+ else{$pImgbg='';}
589
+
590
+ //get youtube button image background color
591
+ if(isset($pluginOptionsVal['csbwfs_page_yt_bg']) && $pluginOptionsVal['csbwfs_page_yt_bg']!=''){ $ytImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_yt_bg'].';"';}else{$ytImgbg='';}
592
+ //get reddit button image background color
593
+ if(isset($pluginOptionsVal['csbwfs_page_re_bg']) && $pluginOptionsVal['csbwfs_page_re_bg']!=''){ $reImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_re_bg'].';"';}else{$reImgbg='';}
594
+ //get stumbleupon button image background color
595
+ if(isset($pluginOptionsVal['csbwfs_page_st_bg']) && $pluginOptionsVal['csbwfs_page_st_bg']!=''){ $stImgbg=' style="background:'.$pluginOptionsVal['csbwfs_page_st_bg'].';"';} else{$stImgbg='';}
596
+ //get email message
597
+ if(is_page() || is_single() || is_category() || is_archive()){
598
+
599
+ if($pluginOptionsVal['csbwfs_mailMessage']!=''){ $mailMsg=$pluginOptionsVal['csbwfs_mailMessage'];} else{
600
+ $mailMsg='?subject='.get_the_title().'&body='.$shareurl;}
601
+ }else
602
+ {
603
+ $mailMsg='?subject='.get_bloginfo('name').'&body='.home_url('/');
604
+ }
605
+ if(isset($pluginOptionsVal['csbwfs_btn_position']) && $pluginOptionsVal['csbwfs_btn_position']!=''):
606
+ $btnPosition=$pluginOptionsVal['csbwfs_btn_position'];
607
+ else:
608
+ $btnPosition='left';
609
+ endif;
610
+
611
+ if(isset($pluginOptionsVal['csbwfs_btn_text']) && $pluginOptionsVal['csbwfs_btn_text']!=''):
612
+ $btnText=$pluginOptionsVal['csbwfs_btn_text'];
613
+ else:
614
+ $btnText='';
615
+ endif;
616
+
617
+ $shareButtonContent='<div id="socialButtonOnPage" class="'.$btnPosition.'SocialButtonOnPage">';
618
+ if($btnText!=''):
619
+ $shareButtonContent.='<div class="sharethis-arrow" title="'.$btnText.'"><span>'.$btnText.'</span></div>';
620
+ endif;
621
+ /* Facebook*/
622
+ if($pluginOptionsVal['csbwfs_fpublishBtn']!=''):
623
+ $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="fb-p" class="csbwfs-fb"><a href="javascript:" onclick="window.open(\'//www.facebook.com/sharer/sharer.php?u='.$shareurl.'\',\'Facebook\',\'width=800,height=300\');return false;"
624
+ target="_blank" title="'.$fImgAlt.'" '.$fImgbg.'>';
625
+ if($fImg!=''){
626
+ $shareButtonContent .='<img src="'.$fImg.'" alt="'.$fImgAlt.'" width="35" height="35" >';
627
+ }else{
628
+ $shareButtonContent .='<i class="csbwfs_facebook"></i>';
629
+ }
630
+ $shareButtonContent .='</a></div></div>';
631
+ endif;
632
+
633
+ /* Twitter */
634
+ if($pluginOptionsVal['csbwfs_tpublishBtn']!=''):
635
+ $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="tw-p" class="csbwfs-tw"><a href="javascript:" onclick="window.open(\'//twitter.com/share?url='.$shareurl.'&text='.$ShareTitle.'&nbsp;&nbsp;\', \'_blank\', \'width=800,height=300\')" title="'.$tImgAlt.'" '.$tImgbg.'>';
636
+ if($tImg!='')
637
+ {
638
+ $shareButtonContent .='<img src="'.$tImg.'" alt="'.$tImgAlt.'" width="35" height="35" >';
639
+ }else{
640
+ $shareButtonContent .='<i class="csbwfs_twitter"></i>';
641
+ }
642
+ $shareButtonContent .='</a></div></div>';
643
+ endif;
644
+ /* Linkedin */
645
+ if($pluginOptionsVal['csbwfs_lpublishBtn']!=''):
646
+ $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="li-p" class="csbwfs-li"><a href="javascript:" onclick="javascript:window.open(\'//www.linkedin.com/shareArticle?mini=true&url='.$shareurl.'\',\'\', \'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=600\');return false;" title="'.$lImgAlt.'" '.$lImgbg.'>';
647
+ if($lImg!='')
648
+ {
649
+ $shareButtonContent .='<img src="'.$lImg.'" alt="'.$lImgAlt.'" width="35" height="35" >';
650
+ }else{
651
+ $shareButtonContent .='<i class="csbwfs_linkedin"></i>';
652
+ }
653
+ $shareButtonContent .='</a></div></div>';
654
+ endif;
655
+
656
+ /* Pinterest */
657
+ if($pluginOptionsVal['csbwfs_ppublishBtn']!=''):
658
+ $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="pin-p" class="csbwfs-pin"><a onclick="javascript:void((function(){var e=document.createElement(\'script\');e.setAttribute(\'type\',\'text/javascript\');e.setAttribute(\'charset\',\'UTF-8\');e.setAttribute(\'src\',\'//assets.pinterest.com/js/pinmarklet.js?r=\'+Math.random()*99999999);document.body.appendChild(e)})());" href="javascript:void(0);" title="'.$pImgAlt.'" '.$pImgbg.'>';
659
+ if($pImg!='')
660
+ {
661
+ $shareButtonContent .='<img src="'.$pImg.'" alt="'.$pImgAlt.'" width="35" height="35" >';
662
+ }else{
663
+ $shareButtonContent .='<i class="csbwfs_pinterest"></i>';
664
+ }
665
+ $shareButtonContent .='</a></div></div>';
666
+ endif;
667
+ /* Reddit */
668
+ if(isset($pluginOptionsVal['csbwfs_republishBtn']) && $pluginOptionsVal['csbwfs_republishBtn']!=''):
669
+ $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="re-p" class="csbwfs-re"><a onclick="window.open(\'//reddit.com/submit?url='.$shareurl.'&amp;title='.$ShareTitle.'\',\'Reddit\',\'toolbar=0,status=0,width=1000,height=800\');" href="javascript:void(0);" title="'.$reImgAlt.'" '.$reImgbg.'>';
670
+ if($reImg!='')
671
+ {
672
+ $shareButtonContent .='<img src="'.$reImg.'" alt="'.$reImgAlt.'" width="35" height="35" >';
673
+ }else{
674
+ $shareButtonContent .='<i class="csbwfs_reddit"></i>';
675
+ }
676
+ $shareButtonContent .='</a></div></div>';
677
+ endif;
678
+ /* Stumbleupon */
679
+ if(isset($pluginOptionsVal['csbwfs_stpublishBtn']) && $pluginOptionsVal['csbwfs_stpublishBtn']!=''):
680
+ $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="st-p" class="csbwfs-st"><a onclick="window.open(\'//www.stumbleupon.com/submit?url='.$shareurl.'&amp;title='.$ShareTitle.'\',\'Stumbleupon\',\'toolbar=0,status=0,width=1000,height=800\');" href="javascript:void(0);" title="'.$stImgAlt.'" '.$stImgbg.'>';
681
+ if($stImg!='')
682
+ {
683
+ $shareButtonContent .='<img src="'.$stImg.'" alt="'.$stImgAlt.'" width="35" height="35" >';
684
+ }else{
685
+ $shareButtonContent .='<i class="csbwfs_stumbleupon"></i>';
686
+ }
687
+ $shareButtonContent .='</a></div></div>';
688
+ endif;
689
+ /* Youtube */
690
+ if(isset($pluginOptionsVal['csbwfs_ytpublishBtn']) && $pluginOptionsVal['csbwfs_ytpublishBtn']!=''):
691
+ $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="yt-p" class="csbwfs-yt"><a onclick="window.open(\''.$pluginOptionsVal['csbwfs_ytPath'].'\');" href="javascript:void(0);" title="'.$ytImgAlt.'" '.$ytImgbg.'>';
692
+ if($ytImg!='')
693
+ {
694
+ $shareButtonContent .='<img src="'.$ytImg.'" alt="'.$ytImgAlt.'" width="35" height="35" >';
695
+ }else{
696
+ $shareButtonContent .='<i class="csbwfs_youtube"></i>';
697
+ }
698
+ $shareButtonContent .='</a></div></div>';
699
+ endif;
700
+ /* Email */
701
+ if($pluginOptionsVal['csbwfs_mpublishBtn']!=''):
702
+ $shareButtonContent.='<div class="csbwfs-sbutton-post"><div id="ml-p" class="csbwfs-ml"><a href="mailto:'.$mailMsg.'" title="'.$mImgAlt.'" '.$mImgbg.'>';
703
+ if($mImg!='')
704
+ {
705
+ $shareButtonContent .='<img src="'.$mImg.'" alt="'.$mImgAlt.'" width="35" height="35" >';
706
+ }else{
707
+ $shareButtonContent .='<i class="csbwfs_mail"></i>';
708
+ }
709
+ $shareButtonContent .='</a></div></div>';
710
+ endif;
711
+ $shareButtonContent.='</div>';
712
+
713
+ // Returns the content.
714
+ global $post;
715
+ $shareButtonContentReturn='';
716
+ /* DEFAULT HOME */
717
+ if((is_home() && is_front_page()) && $pluginOptionsVal['csbwfs_page_hide_home']=='yes'):
718
+ $shareButtonContentReturn=$shareButtonContent;
719
+ endif;
720
+ /* STATIC front page */
721
+ if(is_front_page() && $pluginOptionsVal['csbwfs_page_hide_home']=='yes'):
722
+ $shareButtonContentReturn=$shareButtonContent;
723
+ endif;
724
+ //post
725
+ if(is_single() && $pluginOptionsVal['csbwfs_page_hide_post']=='yes'):
726
+ $shareButtonContentReturn=$shareButtonContent;
727
+ endif;
728
+ //page
729
+ if(is_page() && $pluginOptionsVal['csbwfs_page_hide_page']=='yes'):
730
+ if(!is_front_page()):
731
+ $shareButtonContentReturn=$shareButtonContent;
732
+ endif;
733
+ endif;
734
+ //archive
735
+ if(is_archive() && $pluginOptionsVal['csbwfs_page_hide_archive']=='yes'):
736
+ $shareButtonContentReturn=$shareButtonContent;
737
+ endif;
738
+ // 404
739
+ if(is_404()):
740
+ $shareButtonContentReturn='';
741
+ endif;
742
+ /** Buttons position on content */
743
+ if(isset($pluginOptionsVal['csbwfs_btn_display']) && $pluginOptionsVal['csbwfs_btn_display']=='above'){
744
+ $finalContent= $shareButtonContentReturn.$content;
745
+ }else
746
+ {
747
+ $finalContent = $content.$shareButtonContentReturn;
748
+ }
749
+ return $finalContent;
750
+ }
751
+ ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
custom-share-buttons-with-floating-sidebar.php CHANGED
@@ -1,321 +1,309 @@
1
- <?php
2
- /*
3
- Plugin Name: Custom Share Buttons with Floating Sidebar
4
- Plugin URI: http://www.mrwebsolution.in/
5
- Description: It's a very simple plugin to add social share buttons with floating sidebar. Even you can edit share buttons images if you wish
6
- Author: MR Web Solution
7
- Author URI: http://raghunathgurjar.wordpress.com
8
- Version: 3.5
9
- */
10
-
11
- /* Copyright 2018 custom-share-buttons-with-floating-sidebar (email : raghunath.0087@gmail.com)
12
-
13
- This program is free software; you can redistribute it and/or modify
14
- it under the terms of the GNU General Public License, version 2, as
15
- published by the Free Software Foundation.
16
-
17
- This program is distributed in the hope that it will be useful,
18
- but WITHOUT ANY WARRANTY; without even the implied warranty of
19
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20
- GNU General Public License for more details.
21
-
22
- You should have received a copy of the GNU General Public License
23
- along with this program; if not, write to the Free Software
24
- Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
25
- */
26
-
27
- //Admin "Custom Share Buttons with Floating Sidebar" Menu Item
28
- if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
29
- if(!class_exists('Csbwfs_Class'))
30
- {
31
- class Csbwfs_Class
32
- {
33
- /**
34
- * Construct the plugin object
35
- */
36
- public function __construct()
37
- {
38
- // register actions
39
- add_action('admin_init', array(&$this, 'csbwfs_admin_init'));
40
- add_action('admin_menu', array(&$this, 'csbwf_sidebar_menu'));
41
- add_action( 'admin_bar_menu', array(&$this,'toolbar_link_to_csbwfs'), 999 );
42
- } // END public function __construct
43
- /**
44
- * hook to add link under adminmenu bar
45
- */
46
- public function toolbar_link_to_csbwfs( $wp_admin_bar ) {
47
- $args = array(
48
- 'id' => 'csbwfs_menu_bar',
49
- 'title' => 'Social Share',
50
- 'href' => admin_url('options-general.php?page=csbwfs-settings'),
51
- 'meta' => array( 'class' => 'csbwfs-toolbar-page' )
52
- );
53
- $wp_admin_bar->add_node( $args );
54
- //second lavel
55
- $wp_admin_bar->add_node( array(
56
- 'id' => 'csbwfs-second-sub-item',
57
- 'parent' => 'csbwfs_menu_bar',
58
- 'title' => 'Settings',
59
- 'href' => admin_url('options-general.php?page=csbwfs-settings'),
60
- 'meta' => array(
61
- 'title' => __('Settings'),
62
- 'target' => '_self',
63
- 'class' => 'csbwfs_menu_item_class'
64
- ),
65
- ));
66
- }
67
- /**
68
- * hook into WP's admin_init action hook
69
- */
70
- public function csbwfs_admin_init()
71
- {
72
- // Set up the settings for this plugin
73
- $this->csbwf_sidebar_init();
74
- // Possibly do additional admin_init tasks
75
- } // END public static function activate
76
- /**
77
- * Initialize some custom settings
78
- */
79
- public function csbwf_sidebar_init()
80
- {
81
- // register the settings for this plugin
82
- register_setting('csbwf_sidebar_options','csbwfs_active');
83
- register_setting('csbwf_sidebar_options','csbwfs_position');
84
- register_setting('csbwf_sidebar_options','csbwfs_btn_position');
85
- register_setting('csbwf_sidebar_options','csbwfs_btn_text');
86
- register_setting('csbwf_sidebar_options','csbwfs_fb_image');
87
- register_setting('csbwf_sidebar_options','csbwfs_tw_image');
88
- register_setting('csbwf_sidebar_options','csbwfs_li_image');
89
- register_setting('csbwf_sidebar_options','csbwfs_re_image');
90
- register_setting('csbwf_sidebar_options','csbwfs_st_image');
91
- register_setting('csbwf_sidebar_options','csbwfs_mail_image');
92
- register_setting('csbwf_sidebar_options','csbwfs_gp_image');
93
- register_setting('csbwf_sidebar_options','csbwfs_pin_image');
94
- register_setting('csbwf_sidebar_options','csbwfs_yt_image');
95
- register_setting('csbwf_sidebar_options','csbwfs_fb_bg');
96
- register_setting('csbwf_sidebar_options','csbwfs_tw_bg');
97
- register_setting('csbwf_sidebar_options','csbwfs_li_bg');
98
- register_setting('csbwf_sidebar_options','csbwfs_mail_bg');
99
- register_setting('csbwf_sidebar_options','csbwfs_gp_bg');
100
- register_setting('csbwf_sidebar_options','csbwfs_pin_bg');
101
- register_setting('csbwf_sidebar_options','csbwfs_re_bg');
102
- register_setting('csbwf_sidebar_options','csbwfs_st_bg');
103
- register_setting('csbwf_sidebar_options','csbwfs_yt_bg');
104
- register_setting('csbwf_sidebar_options','csbwfs_page_fb_bg');
105
- register_setting('csbwf_sidebar_options','csbwfs_page_tw_bg');
106
- register_setting('csbwf_sidebar_options','csbwfs_page_li_bg');
107
- register_setting('csbwf_sidebar_options','csbwfs_page_mail_bg');
108
- register_setting('csbwf_sidebar_options','csbwfs_page_gp_bg');
109
- register_setting('csbwf_sidebar_options','csbwfs_page_pin_bg');
110
- register_setting('csbwf_sidebar_options','csbwfs_page_re_bg');
111
- register_setting('csbwf_sidebar_options','csbwfs_page_st_bg');
112
- register_setting('csbwf_sidebar_options','csbwfs_page_yt_bg');
113
- register_setting('csbwf_sidebar_options','csbwfs_fpublishBtn');
114
- register_setting('csbwf_sidebar_options','csbwfs_tpublishBtn');
115
- register_setting('csbwf_sidebar_options','csbwfs_gpublishBtn');
116
- register_setting('csbwf_sidebar_options','csbwfs_ppublishBtn');
117
- register_setting('csbwf_sidebar_options','csbwfs_ytpublishBtn');
118
- register_setting('csbwf_sidebar_options','csbwfs_republishBtn');
119
- register_setting('csbwf_sidebar_options','csbwfs_stpublishBtn');
120
- register_setting('csbwf_sidebar_options','csbwfs_ytPath');
121
- register_setting('csbwf_sidebar_options','csbwfs_lpublishBtn');
122
- register_setting('csbwf_sidebar_options','csbwfs_mpublishBtn');
123
- register_setting('csbwf_sidebar_options','csbwfs_mailMessage');
124
- register_setting('csbwf_sidebar_options','csbwfs_top_margin');
125
- register_setting('csbwf_sidebar_options','csbwfs_delayTimeBtn');
126
- register_setting('csbwf_sidebar_options','csbwfs_btn_display');
127
- /** Image Alt */
128
- register_setting('csbwf_sidebar_options','csbwfs_fb_title');
129
- register_setting('csbwf_sidebar_options','csbwfs_tw_title');
130
- register_setting('csbwf_sidebar_options','csbwfs_li_title');
131
- register_setting('csbwf_sidebar_options','csbwfs_pin_title');
132
- register_setting('csbwf_sidebar_options','csbwfs_gp_title');
133
- register_setting('csbwf_sidebar_options','csbwfs_mail_title');
134
- register_setting('csbwf_sidebar_options','csbwfs_yt_title');
135
- register_setting('csbwf_sidebar_options','csbwfs_re_title');
136
- register_setting('csbwf_sidebar_options','csbwfs_st_title');
137
- register_setting('csbwf_sidebar_options','csbwfs_page_fb_title');
138
- register_setting('csbwf_sidebar_options','csbwfs_page_tw_title');
139
- register_setting('csbwf_sidebar_options','csbwfs_page_li_title');
140
- register_setting('csbwf_sidebar_options','csbwfs_page_pin_title');
141
- register_setting('csbwf_sidebar_options','csbwfs_page_gp_title');
142
- register_setting('csbwf_sidebar_options','csbwfs_page_mail_title');
143
- register_setting('csbwf_sidebar_options','csbwfs_page_yt_title');
144
- register_setting('csbwf_sidebar_options','csbwfs_page_re_title');
145
- register_setting('csbwf_sidebar_options','csbwfs_page_st_title');
146
- register_setting('csbwf_sidebar_options','csbwfs_auto_hide');
147
- //Options for post/pages
148
- register_setting('csbwf_sidebar_options','csbwfs_buttons_active');
149
- register_setting('csbwf_sidebar_options','csbwfs_page_hide_home');
150
- register_setting('csbwf_sidebar_options','csbwfs_page_hide_post');
151
- register_setting('csbwf_sidebar_options','csbwfs_page_hide_page');
152
- register_setting('csbwf_sidebar_options','csbwfs_page_hide_archive');
153
- register_setting('csbwf_sidebar_options','csbwfs_hide_home');
154
- register_setting('csbwf_sidebar_options','csbwfs_page_fb_image');
155
- register_setting('csbwf_sidebar_options','csbwfs_page_tw_image');
156
- register_setting('csbwf_sidebar_options','csbwfs_page_li_image');
157
- register_setting('csbwf_sidebar_options','csbwfs_page_mail_image');
158
- register_setting('csbwf_sidebar_options','csbwfs_page_gp_image');
159
- register_setting('csbwf_sidebar_options','csbwfs_page_pin_image');
160
- register_setting('csbwf_sidebar_options','csbwfs_page_re_image');
161
- register_setting('csbwf_sidebar_options','csbwfs_page_st_image');
162
- register_setting('csbwf_sidebar_options','csbwfs_page_yt_image');
163
- /** message content */
164
- register_setting('csbwf_sidebar_options','csbwfs_show_btn');
165
- register_setting('csbwf_sidebar_options','csbwfs_hide_btn');
166
- register_setting('csbwf_sidebar_options','csbwfs_share_msg');
167
- register_setting('csbwf_sidebar_options','csbwfs_rmSHBtn');
168
- //register_setting('csbwf_sidebar_options','csbwfs_featuredshrimg');
169
- //register_setting('csbwf_sidebar_options','csbwfs_defaultfeaturedshrimg');
170
- register_setting('csbwf_sidebar_options','csbwfs_deactive_for_mob');
171
- } // END public function init_custom_settings()
172
- /**
173
- * add a menu
174
- */
175
- public function csbwf_sidebar_menu()
176
- {
177
- add_options_page('Social Share Buttons(CSBWFS)','Social Share Buttons(CSBWFS)','manage_options','csbwfs-settings',array(&$this,'csbwf_sidebar_admin_option_page'));
178
-
179
- } // END public function add_menu()
180
-
181
- public function csbwf_sidebar_admin_option_page()
182
- {
183
- if(!current_user_can('manage_options'))
184
- {
185
- wp_die(__('You do not have sufficient permissions to access this page.'));
186
- }
187
-
188
- // Render the settings template
189
- include(sprintf("%s/lib/settings.php", dirname(__FILE__)));
190
- /**
191
- * REGISTER SCRIPT
192
- * */
193
- wp_enqueue_script('media-upload');
194
- wp_enqueue_script('thickbox');
195
- wp_register_script('csbwfs-image-upload', plugins_url('/js/csbwfs.js',__FILE__ ), array('jquery','media-upload','thickbox','wp-color-picker'));
196
- wp_enqueue_script('csbwfs-image-upload');
197
- /**
198
- * REGISTER STYLE
199
- * */
200
- wp_register_style( 'csbwf_admin_style', plugins_url( 'css/admin-csbwfs.css',__FILE__ ) );
201
- wp_enqueue_style( 'csbwf_admin_style' );
202
- wp_enqueue_style( 'wp-color-picker' );
203
- wp_enqueue_style('thickbox');
204
-
205
- }// END public static function csbwf_sidebar_admin_option_page
206
- /**
207
- * hook into WP's plugin_action_links_ action hook
208
- */
209
- public static function csbwfs_add_settings_link( $links ) {
210
- $settings_link = '<a href="options-general.php?page=csbwfs-settings">' . __( 'Settings', 'csbwfs' ) . '</a>';
211
- $settings_link .= ' | <a href="https://rgaddons.wordpress.com/custom-share-buttons-with-floating-sidebar-pro/" target="_blank">' . __( 'GO PRO', 'csbwfs' ) . '</a>';
212
- array_unshift( $links, $settings_link );
213
- return $links;
214
- }
215
- /**
216
- * uninstall the plugin
217
- */
218
- public function csbwfs_uninstall()
219
- {
220
- delete_option('csbwfs_active');
221
- delete_option('csbbuttons_active');
222
- delete_option('csbwfs_position');
223
- delete_option('csbwfs_btn_position');
224
- delete_option('csbwfs_btn_text');
225
- delete_option('csbwfs_fb_image');
226
- delete_option('csbwfs_tw_image');
227
- delete_option('csbwfs_li_image');
228
- delete_option('csbwfs_re_image');
229
- delete_option('csbwfs_st_image');
230
- delete_option('csbwfs_mail_image');
231
- delete_option('csbwfs_gp_image');
232
- delete_option('csbwfs_pin_image');
233
- delete_option('csbwfs_yt_image');
234
- delete_option('csbwfs_re_image');
235
- delete_option('csbwfs_st_image');
236
- delete_option('csbwfs_ytPath');
237
- delete_option('csbwfs_fb_bg');
238
- delete_option('csbwfs_tw_bg');
239
- delete_option('csbwfs_li_bg');
240
- delete_option('csbwfs_mail_bg');
241
- delete_option('csbwfs_gp_bg');
242
- delete_option('csbwfs_pin_bg');
243
- delete_option('csbwfs_yt_bg');
244
- delete_option('csbwfs_fpublishBtn');
245
- delete_option('csbwfs_tpublishBtn');
246
- delete_option('csbwfs_gpublishBtn');
247
- delete_option('csbwfs_ppublishBtn');
248
- delete_option('csbwfs_lpublishBtn');
249
- delete_option('csbwfs_mpublishBtn');
250
- delete_option('csbwfs_republishBtn');
251
- delete_option('csbwfs_stpublishBtn');
252
- delete_option('csbwfs_ytpublishBtn');
253
- delete_option('csbwfs_mailMessage');
254
- delete_option('csbwfs_top_margin');
255
- delete_option('csbwfs_page_hide_home');
256
- delete_option('csbwfs_page_hide_post');
257
- delete_option('csbwfs_page_hide_page');
258
- delete_option('csbwfs_fb_title');
259
- delete_option('csbwfs_tw_title');
260
- delete_option('csbwfs_li_title');
261
- delete_option('csbwfs_pin_title');
262
- delete_option('csbwfs_gp_title');
263
- delete_option('csbwfs_mail_title');
264
- delete_option('csbwfs_yt_title');
265
- delete_option('csbwfs_re_title');
266
- delete_option('csbwfs_st_title');
267
- delete_option('csbwfs_page_fb_image');
268
- delete_option('csbwfs_page_tw_image');
269
- delete_option('csbwfs_page_li_image');
270
- delete_option('csbwfs_page_re_image');
271
- delete_option('csbwfs_page_st_image');
272
- delete_option('csbwfs_page_mail_image');
273
- delete_option('csbwfs_page_gp_image');
274
- delete_option('csbwfs_page_pin_image');
275
- delete_option('csbwfs_page_yt_image');
276
- delete_option('csbwfs_rmSHBtn');
277
- //delete_option('csbwfs_featuredshrimg');
278
- //delete_option('csbwfs_defaultfeaturedshrimg');
279
- delete_option('csbwfs_deactive_for_mob');
280
- // Do nothing
281
- } // END public static function uninstall
282
- /**
283
- * Activate the plugin
284
- */
285
- public static function csbwfs_activate()
286
- {
287
- // Do nothing
288
- } // END public static function activate
289
-
290
- /**
291
- * Deactivate the plugin
292
- */
293
- public static function csbwfs_deactivate()
294
- {
295
- // Do nothing
296
- } // END public static function deactivate
297
-
298
- } // END class Csbwfs_Class
299
- } // END if(!class_exists('Csbwfs_Class'))
300
-
301
- if(class_exists('Csbwfs_Class'))
302
- {
303
- // Installation and uninstallation hooks
304
- register_activation_hook(__FILE__, array('Csbwfs_Class', 'csbwfs_activate'));
305
- register_deactivation_hook(__FILE__, array('Csbwfs_Class', 'csbwfs_deactivate'));
306
- register_uninstall_hook(__FILE__, array('Csbwfs_Class', 'csbwfs_uninstall'));
307
- // instantiate the plugin class
308
- $csbwfs_plugin_template = new Csbwfs_Class();
309
- // Add a link to the settings page onto the plugin page
310
- if(isset($csbwfs_plugin_template))
311
- {
312
- $plugin = plugin_basename(__FILE__);
313
- add_filter("plugin_action_links_$plugin", array('Csbwfs_Class','csbwfs_add_settings_link'));
314
- require dirname(__FILE__).'/csbwfs-class.php';
315
- //shortcode
316
- require dirname(__FILE__).'/lib/shortcode.php';
317
- }
318
-
319
-
320
- }
321
- ?>
1
+ <?php
2
+ /*
3
+ Plugin Name: Custom Share Buttons with Floating Sidebar
4
+ Plugin URI: http://www.mrwebsolution.in/
5
+ Description: Share buttons with extra features to sharing your website posts/pages on Facebook, Twitter, Instagram, Whatsapp, Pinterest etc.
6
+ Author: MR Web Solution
7
+ Author URI: http://raghunathgurjar.wordpress.com
8
+ Version: 3.7
9
+ */
10
+
11
+ /* Copyright 2018 custom-share-buttons-with-floating-sidebar (email : raghunath.0087@gmail.com)
12
+
13
+ This program is free software; you can redistribute it and/or modify
14
+ it under the terms of the GNU General Public License, version 2, as
15
+ published by the Free Software Foundation.
16
+
17
+ This program is distributed in the hope that it will be useful,
18
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
19
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20
+ GNU General Public License for more details.
21
+
22
+ You should have received a copy of the GNU General Public License
23
+ along with this program; if not, write to the Free Software
24
+ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
25
+ */
26
+
27
+ //Admin "Custom Share Buttons with Floating Sidebar" Menu Item
28
+ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
29
+ if(!class_exists('Csbwfs_Class'))
30
+ {
31
+ class Csbwfs_Class
32
+ {
33
+ /**
34
+ * Construct the plugin object
35
+ */
36
+ public function __construct()
37
+ {
38
+ // register actions
39
+ add_action('admin_init', array(&$this, 'csbwfs_admin_init'));
40
+ add_action('admin_menu', array(&$this, 'csbwf_sidebar_menu'));
41
+ add_action( 'admin_bar_menu', array(&$this,'toolbar_link_to_csbwfs'), 999 );
42
+ } // END public function __construct
43
+ /**
44
+ * hook to add link under adminmenu bar
45
+ */
46
+ public function toolbar_link_to_csbwfs( $wp_admin_bar ) {
47
+ $args = array(
48
+ 'id' => 'csbwfs_menu_bar',
49
+ 'title' => 'Social Share',
50
+ 'href' => admin_url('options-general.php?page=csbwfs-settings'),
51
+ 'meta' => array( 'class' => 'csbwfs-toolbar-page' )
52
+ );
53
+ $wp_admin_bar->add_node( $args );
54
+ //second lavel
55
+ $wp_admin_bar->add_node( array(
56
+ 'id' => 'csbwfs-second-sub-item',
57
+ 'parent' => 'csbwfs_menu_bar',
58
+ 'title' => 'Settings',
59
+ 'href' => admin_url('options-general.php?page=csbwfs-settings'),
60
+ 'meta' => array(
61
+ 'title' => __('Settings'),
62
+ 'target' => '_self',
63
+ 'class' => 'csbwfs_menu_item_class'
64
+ ),
65
+ ));
66
+ }
67
+ /**
68
+ * hook into WP's admin_init action hook
69
+ */
70
+ public function csbwfs_admin_init()
71
+ {
72
+ // Set up the settings for this plugin
73
+ $this->csbwf_sidebar_init();
74
+ // Possibly do additional admin_init tasks
75
+ } // END public static function activate
76
+ /**
77
+ * Initialize some custom settings
78
+ */
79
+ public function csbwf_sidebar_init()
80
+ {
81
+ // register the settings for this plugin
82
+ register_setting('csbwf_sidebar_options','csbwfs_active');
83
+ register_setting('csbwf_sidebar_options','csbwfs_position');
84
+ register_setting('csbwf_sidebar_options','csbwfs_btn_position');
85
+ register_setting('csbwf_sidebar_options','csbwfs_btn_text');
86
+ register_setting('csbwf_sidebar_options','csbwfs_fb_image');
87
+ register_setting('csbwf_sidebar_options','csbwfs_tw_image');
88
+ register_setting('csbwf_sidebar_options','csbwfs_li_image');
89
+ register_setting('csbwf_sidebar_options','csbwfs_re_image');
90
+ register_setting('csbwf_sidebar_options','csbwfs_st_image');
91
+ register_setting('csbwf_sidebar_options','csbwfs_mail_image');
92
+ register_setting('csbwf_sidebar_options','csbwfs_pin_image');
93
+ register_setting('csbwf_sidebar_options','csbwfs_yt_image');
94
+ register_setting('csbwf_sidebar_options','csbwfs_fb_bg');
95
+ register_setting('csbwf_sidebar_options','csbwfs_tw_bg');
96
+ register_setting('csbwf_sidebar_options','csbwfs_li_bg');
97
+ register_setting('csbwf_sidebar_options','csbwfs_mail_bg');
98
+ register_setting('csbwf_sidebar_options','csbwfs_pin_bg');
99
+ register_setting('csbwf_sidebar_options','csbwfs_re_bg');
100
+ register_setting('csbwf_sidebar_options','csbwfs_st_bg');
101
+ register_setting('csbwf_sidebar_options','csbwfs_yt_bg');
102
+ register_setting('csbwf_sidebar_options','csbwfs_page_fb_bg');
103
+ register_setting('csbwf_sidebar_options','csbwfs_page_tw_bg');
104
+ register_setting('csbwf_sidebar_options','csbwfs_page_li_bg');
105
+ register_setting('csbwf_sidebar_options','csbwfs_page_mail_bg');
106
+ register_setting('csbwf_sidebar_options','csbwfs_page_pin_bg');
107
+ register_setting('csbwf_sidebar_options','csbwfs_page_re_bg');
108
+ register_setting('csbwf_sidebar_options','csbwfs_page_st_bg');
109
+ register_setting('csbwf_sidebar_options','csbwfs_page_yt_bg');
110
+ register_setting('csbwf_sidebar_options','csbwfs_fpublishBtn');
111
+ register_setting('csbwf_sidebar_options','csbwfs_tpublishBtn');
112
+ register_setting('csbwf_sidebar_options','csbwfs_ppublishBtn');
113
+ register_setting('csbwf_sidebar_options','csbwfs_ytpublishBtn');
114
+ register_setting('csbwf_sidebar_options','csbwfs_republishBtn');
115
+ register_setting('csbwf_sidebar_options','csbwfs_stpublishBtn');
116
+ register_setting('csbwf_sidebar_options','csbwfs_ytPath');
117
+ register_setting('csbwf_sidebar_options','csbwfs_lpublishBtn');
118
+ register_setting('csbwf_sidebar_options','csbwfs_mpublishBtn');
119
+ register_setting('csbwf_sidebar_options','csbwfs_mailMessage');
120
+ register_setting('csbwf_sidebar_options','csbwfs_top_margin');
121
+ register_setting('csbwf_sidebar_options','csbwfs_delayTimeBtn');
122
+ register_setting('csbwf_sidebar_options','csbwfs_btn_display');
123
+ /** Image Alt */
124
+ register_setting('csbwf_sidebar_options','csbwfs_fb_title');
125
+ register_setting('csbwf_sidebar_options','csbwfs_tw_title');
126
+ register_setting('csbwf_sidebar_options','csbwfs_li_title');
127
+ register_setting('csbwf_sidebar_options','csbwfs_pin_title');
128
+ register_setting('csbwf_sidebar_options','csbwfs_mail_title');
129
+ register_setting('csbwf_sidebar_options','csbwfs_yt_title');
130
+ register_setting('csbwf_sidebar_options','csbwfs_re_title');
131
+ register_setting('csbwf_sidebar_options','csbwfs_st_title');
132
+ register_setting('csbwf_sidebar_options','csbwfs_page_fb_title');
133
+ register_setting('csbwf_sidebar_options','csbwfs_page_tw_title');
134
+ register_setting('csbwf_sidebar_options','csbwfs_page_li_title');
135
+ register_setting('csbwf_sidebar_options','csbwfs_page_pin_title');
136
+ register_setting('csbwf_sidebar_options','csbwfs_page_mail_title');
137
+ register_setting('csbwf_sidebar_options','csbwfs_page_yt_title');
138
+ register_setting('csbwf_sidebar_options','csbwfs_page_re_title');
139
+ register_setting('csbwf_sidebar_options','csbwfs_page_st_title');
140
+ register_setting('csbwf_sidebar_options','csbwfs_auto_hide');
141
+ //Options for post/pages
142
+ register_setting('csbwf_sidebar_options','csbwfs_buttons_active');
143
+ register_setting('csbwf_sidebar_options','csbwfs_page_hide_home');
144
+ register_setting('csbwf_sidebar_options','csbwfs_page_hide_post');
145
+ register_setting('csbwf_sidebar_options','csbwfs_page_hide_page');
146
+ register_setting('csbwf_sidebar_options','csbwfs_page_hide_archive');
147
+ register_setting('csbwf_sidebar_options','csbwfs_hide_home');
148
+ register_setting('csbwf_sidebar_options','csbwfs_page_fb_image');
149
+ register_setting('csbwf_sidebar_options','csbwfs_page_tw_image');
150
+ register_setting('csbwf_sidebar_options','csbwfs_page_li_image');
151
+ register_setting('csbwf_sidebar_options','csbwfs_page_mail_image');
152
+ register_setting('csbwf_sidebar_options','csbwfs_page_pin_image');
153
+ register_setting('csbwf_sidebar_options','csbwfs_page_re_image');
154
+ register_setting('csbwf_sidebar_options','csbwfs_page_st_image');
155
+ register_setting('csbwf_sidebar_options','csbwfs_page_yt_image');
156
+ /** message content */
157
+ register_setting('csbwf_sidebar_options','csbwfs_show_btn');
158
+ register_setting('csbwf_sidebar_options','csbwfs_hide_btn');
159
+ register_setting('csbwf_sidebar_options','csbwfs_share_msg');
160
+ register_setting('csbwf_sidebar_options','csbwfs_rmSHBtn');
161
+ //register_setting('csbwf_sidebar_options','csbwfs_featuredshrimg');
162
+ //register_setting('csbwf_sidebar_options','csbwfs_defaultfeaturedshrimg');
163
+ register_setting('csbwf_sidebar_options','csbwfs_deactive_for_mob');
164
+ } // END public function init_custom_settings()
165
+ /**
166
+ * add a menu
167
+ */
168
+ public function csbwf_sidebar_menu()
169
+ {
170
+ add_options_page('Social Share Buttons(CSBWFS)','Social Share Buttons(CSBWFS)','manage_options','csbwfs-settings',array(&$this,'csbwf_sidebar_admin_option_page'));
171
+
172
+ } // END public function add_menu()
173
+
174
+ public function csbwf_sidebar_admin_option_page()
175
+ {
176
+ if(!current_user_can('manage_options'))
177
+ {
178
+ wp_die(__('You do not have sufficient permissions to access this page.'));
179
+ }
180
+
181
+ // Render the settings template
182
+ include(sprintf("%s/lib/settings.php", dirname(__FILE__)));
183
+ /**
184
+ * REGISTER SCRIPT
185
+ * */
186
+ wp_enqueue_script('media-upload');
187
+ wp_enqueue_script('thickbox');
188
+ wp_register_script('csbwfs-image-upload', plugins_url('/js/csbwfs.js',__FILE__ ), array('jquery','media-upload','thickbox','wp-color-picker'));
189
+ wp_enqueue_script('csbwfs-image-upload');
190
+ /**
191
+ * REGISTER STYLE
192
+ * */
193
+ wp_register_style( 'csbwf_admin_style', plugins_url( 'css/admin-csbwfs.css',__FILE__ ) );
194
+ wp_enqueue_style( 'csbwf_admin_style' );
195
+ wp_enqueue_style( 'wp-color-picker' );
196
+ wp_enqueue_style('thickbox');
197
+
198
+ }// END public static function csbwf_sidebar_admin_option_page
199
+ /**
200
+ * hook into WP's plugin_action_links_ action hook
201
+ */
202
+ public static function csbwfs_add_settings_link( $links ) {
203
+ $settings_link = '<a href="options-general.php?page=csbwfs-settings">' . __( 'Settings', 'csbwfs' ) . '</a>';
204
+ $settings_link .= ' | <a href="https://rgaddons.wordpress.com/custom-share-buttons-with-floating-sidebar-pro/" target="_blank">' . __( 'GO PRO', 'csbwfs' ) . '</a>';
205
+ array_unshift( $links, $settings_link );
206
+ return $links;
207
+ }
208
+ /**
209
+ * uninstall the plugin
210
+ */
211
+ public function csbwfs_uninstall()
212
+ {
213
+ delete_option('csbwfs_active');
214
+ delete_option('csbbuttons_active');
215
+ delete_option('csbwfs_position');
216
+ delete_option('csbwfs_btn_position');
217
+ delete_option('csbwfs_btn_text');
218
+ delete_option('csbwfs_fb_image');
219
+ delete_option('csbwfs_tw_image');
220
+ delete_option('csbwfs_li_image');
221
+ delete_option('csbwfs_re_image');
222
+ delete_option('csbwfs_st_image');
223
+ delete_option('csbwfs_mail_image');
224
+ delete_option('csbwfs_pin_image');
225
+ delete_option('csbwfs_yt_image');
226
+ delete_option('csbwfs_re_image');
227
+ delete_option('csbwfs_st_image');
228
+ delete_option('csbwfs_ytPath');
229
+ delete_option('csbwfs_fb_bg');
230
+ delete_option('csbwfs_tw_bg');
231
+ delete_option('csbwfs_li_bg');
232
+ delete_option('csbwfs_mail_bg');
233
+ delete_option('csbwfs_pin_bg');
234
+ delete_option('csbwfs_yt_bg');
235
+ delete_option('csbwfs_fpublishBtn');
236
+ delete_option('csbwfs_tpublishBtn');
237
+ delete_option('csbwfs_ppublishBtn');
238
+ delete_option('csbwfs_lpublishBtn');
239
+ delete_option('csbwfs_mpublishBtn');
240
+ delete_option('csbwfs_republishBtn');
241
+ delete_option('csbwfs_stpublishBtn');
242
+ delete_option('csbwfs_ytpublishBtn');
243
+ delete_option('csbwfs_mailMessage');
244
+ delete_option('csbwfs_top_margin');
245
+ delete_option('csbwfs_page_hide_home');
246
+ delete_option('csbwfs_page_hide_post');
247
+ delete_option('csbwfs_page_hide_page');
248
+ delete_option('csbwfs_fb_title');
249
+ delete_option('csbwfs_tw_title');
250
+ delete_option('csbwfs_li_title');
251
+ delete_option('csbwfs_pin_title');
252
+ delete_option('csbwfs_mail_title');
253
+ delete_option('csbwfs_yt_title');
254
+ delete_option('csbwfs_re_title');
255
+ delete_option('csbwfs_st_title');
256
+ delete_option('csbwfs_page_fb_image');
257
+ delete_option('csbwfs_page_tw_image');
258
+ delete_option('csbwfs_page_li_image');
259
+ delete_option('csbwfs_page_re_image');
260
+ delete_option('csbwfs_page_st_image');
261
+ delete_option('csbwfs_page_mail_image');
262
+ delete_option('csbwfs_page_pin_image');
263
+ delete_option('csbwfs_page_yt_image');
264
+ delete_option('csbwfs_rmSHBtn');
265
+ //delete_option('csbwfs_featuredshrimg');
266
+ //delete_option('csbwfs_defaultfeaturedshrimg');
267
+ delete_option('csbwfs_deactive_for_mob');
268
+ // Do nothing
269
+ } // END public static function uninstall
270
+ /**
271
+ * Activate the plugin
272
+ */
273
+ public static function csbwfs_activate()
274
+ {
275
+ // Do nothing
276
+ } // END public static function activate
277
+
278
+ /**
279
+ * Deactivate the plugin
280
+ */
281
+ public static function csbwfs_deactivate()
282
+ {
283
+ // Do nothing
284
+ } // END public static function deactivate
285
+
286
+ } // END class Csbwfs_Class
287
+ } // END if(!class_exists('Csbwfs_Class'))
288
+
289
+ if(class_exists('Csbwfs_Class'))
290
+ {
291
+ // Installation and uninstallation hooks
292
+ register_activation_hook(__FILE__, array('Csbwfs_Class', 'csbwfs_activate'));
293
+ register_deactivation_hook(__FILE__, array('Csbwfs_Class', 'csbwfs_deactivate'));
294
+ register_uninstall_hook(__FILE__, array('Csbwfs_Class', 'csbwfs_uninstall'));
295
+ // instantiate the plugin class
296
+ $csbwfs_plugin_template = new Csbwfs_Class();
297
+ // Add a link to the settings page onto the plugin page
298
+ if(isset($csbwfs_plugin_template))
299
+ {
300
+ $plugin = plugin_basename(__FILE__);
301
+ add_filter("plugin_action_links_$plugin", array('Csbwfs_Class','csbwfs_add_settings_link'));
302
+ require dirname(__FILE__).'/csbwfs-class.php';
303
+ //shortcode
304
+ require dirname(__FILE__).'/lib/shortcode.php';
305
+ }
306
+
307
+
308
+ }
309
+ ?>
 
 
 
 
 
 
 
 
 
 
 
 
lib/settings.php CHANGED
@@ -1,312 +1,301 @@
1
- <div style="width: 80%; padding: 10px; margin: 10px;">
2
- <h1>Custom Share Buttons With Floating Sidebar Settings</h1>
3
- <!-- Start Options Form -->
4
-
5
- <form action="options.php" method="post" id="csbwf-sidebar-admin-form">
6
-
7
- <div id="csbwf-tab-menu"><a id="csbwfs-general" class="csbwf-tab-links active" >General</a> <a id="csbwfs-sidebar" class="csbwf-tab-links">Floating Sidebar</a> <a id="csbwfs-share-buttons" class="csbwf-tab-links">Social Share Buttons</a> <a id="csbwfs-pro" class="csbwf-tab-links">GO PRO</a> <a id="csbwfs-support" class="csbwf-tab-links">Support</a></div>
8
- <p align="right"><span class="submit-btn"><?php echo get_submit_button('Save Settings','button-primary extrabtn','submit','','');?></span></p>
9
- <div class="csbwfs-setting">
10
- <!-- General Setting -->
11
- <div class="first csbwfs-tab" id="div-csbwfs-general">
12
- <h2>General Settings</h2>
13
- <table cellpadding="10">
14
- <tr>
15
- <td valign="top" nowrap>
16
- <p><input type="checkbox" id="csbwfs_active" name="csbwfs_active" value='1' <?php checked(get_option('csbwfs_active'),1);?>/> <b><?php _e('Enable Sidebar');?> </b></p>
17
- <p><h3><strong><?php _e('Social Share Button Publish Options:','csbwfs');?></strong></h3></p>
18
- <p><input type="checkbox" id="publish1" value="yes" name="csbwfs_fpublishBtn" <?php checked(get_option('csbwfs_fpublishBtn'),'yes');?>/><b>Facebook Button</b></p>
19
- <p><input type="checkbox" id="publish2" name="csbwfs_tpublishBtn" value="yes" <?php checked(get_option('csbwfs_tpublishBtn'),'yes');?>/> <b>Twitter Button</b></p>
20
- <p><input type="checkbox" id="publish3" name="csbwfs_gpublishBtn" value="yes" <?php checked(get_option('csbwfs_gpublishBtn'),'yes');?>/> <b>Google Button</b></p>
21
- <p><input type="checkbox" id="publish4" name="csbwfs_lpublishBtn" value="yes" <?php checked(get_option('csbwfs_lpublishBtn'),'yes');?>/> <b>Linkedin Button</b></p>
22
- <p><input type="checkbox" id="publish6" name="csbwfs_ppublishBtn" value="yes" <?php checked(get_option('csbwfs_ppublishBtn'),'yes');?>/> <b>Pinterest Button</b></p>
23
- <p><input type="checkbox" id="publish7" name="csbwfs_republishBtn" value="yes" <?php checked(get_option('csbwfs_republishBtn'),'yes');?>/> <b>Reddit Button</b></p>
24
- <p><input type="checkbox" id="publish8" name="csbwfs_stpublishBtn" value="yes" <?php checked(get_option('csbwfs_stpublishBtn'),'yes');?>/> <b>Stumbleupon Button</b></p>
25
- <p><input type="checkbox" id="publish5" name="csbwfs_mpublishBtn" value="yes" <?php checked(get_option('csbwfs_mpublishBtn'),'yes');?>/> <b>Mailbox Button</b></p>
26
- <?php if(get_option('csbwfs_mpublishBtn')=='yes');{?>
27
- <p id="mailmsg"><input type="text" name="csbwfs_mailMessage" id="csbwfs_mailMessage" value="<?php echo get_option('csbwfs_mailMessage');?>" placeholder="your@email.com?subject=Your Subject" size="40" class="regular-text ltr"><br><i>Leave empty to add current page title as subject line and url as body text </i></p>
28
- <?php } ?>
29
- <p><input type="checkbox" id="ytBtns" name="csbwfs_ytpublishBtn" value="yes" <?php checked(get_option('csbwfs_ytpublishBtn'),'yes');?>/> <b>Youtube Button</b></p>
30
- <p id="ytpath"><input type="text" name="csbwfs_ytPath" id="csbwfs_ytPath" value="<?php echo get_option('csbwfs_ytPath');?>" placeholder="http://www.youtube.com" size="40" class="regular-text ltr"><br>add youtube channel url</p>
31
- <p><label><h3 ><strong><?php _e('Define your custom message:','csbwfs');?></strong></h3></label></p>
32
- <p><label><?php _e('Show:');?></label><input type="text" id="csbwfs_show_btn" name="csbwfs_show_btn" value="<?php echo get_option('csbwfs_show_btn'); ?>" placeholder="Show Buttons" size="40"/></p>
33
- <p><label><?php _e('Hide:');?></label><input type="text" id="csbwfs_hide_btn" name="csbwfs_hide_btn" value="<?php echo get_option('csbwfs_hide_btn'); ?>" placeholder="Hide Buttons" size="40"/></p>
34
- <p><label><?php _e('Message:');?></label><input type="textbox" id="csbwfs_share_msg" name="csbwfs_share_msg" value="<?php echo get_option('csbwfs_share_msg'); ?>" placeholder="Share This With Your Friends" size="40"/></p>
35
- </td>
36
- <td valign="top" style="border-left:1px solid #ccc;padding-left:20px;">
37
- <p style="font-size:16px;">Watch given below video to view addon features and settings</p>
38
- <iframe width="100%" height="500" src="https://www.youtube.com/embed/QUnxtCe95Ww?rel=0&autoplay=1&start=90" frameborder="0" allow="autoplay; encrypted-media" allowfullscreen></iframe>
39
- <h2><a href="https://rgaddons.wordpress.com/custom-share-buttons-with-floating-sidebar-pro/" target="_blank" class="contact-author"><strong>Click Here</strong></a> to download addon.</h2>
40
- </tr>
41
- </table>
42
- </div>
43
- <!-- Floating Sidebar -->
44
- <div class="csbwfs-tab" id="div-csbwfs-sidebar">
45
- <h2>Floating Sidebar Settings</h2>
46
- <table>
47
- <tr>
48
- <th nowrap><?php echo 'Siderbar Position:';?></th>
49
- <td>
50
- <select id="csbwfs_position" name="csbwfs_position" >
51
- <option value="left" <?php selected(get_option('csbwfs_position'),'left');?>>Left</option>
52
- <option value="right" <?php selected(get_option('csbwfs_position'),'right');?>>Right</option>
53
- <option value="bottom" <?php selected(get_option('csbwfs_position'),'bottom');?>>Bottom</option>
54
- </select>
55
- </td>
56
- </tr>
57
- <tr>
58
- <th>&nbsp;</th>
59
- <td><input type="checkbox" id="csbwfs_rmSHBtn" name="csbwfs_rmSHBtn" value="yes" <?php checked(get_option('csbwfs_rmSHBtn'),'yes');?>/> <strong><?php _e('Remove Show/Hide Button:','csbwfs');?></strong></td>
60
- </tr>
61
- <tr><th nowrap valign="top"><?php echo 'Delay Time: '; ?></th><td><input type="text" name="csbwfs_delayTimeBtn" id="csbwfs_delayTimeBtn" value="<?php echo get_option('csbwfs_delayTimeBtn')?get_option('csbwfs_delayTimeBtn'):0;?>" size="40" class="regular-text ltr"><br><i>Publish share buttons after given time(millisecond)</i></td></tr>
62
- <tr>
63
- <th>&nbsp;</th>
64
- <td><input type="checkbox" id="csbwfs_deactive_for_mob" name="csbwfs_deactive_for_mob" value="yes" <?php checked(get_option('csbwfs_deactive_for_mob'),'yes');?>/><?php _e('Disable Sidebar For Mobile','csbwfs');?></td>
65
- </tr>
66
- <tr><th></th>
67
- <td><input type="checkbox" id="csbwfs_auto_hide" name="csbwfs_auto_hide" value="yes" <?php checked(get_option('csbwfs_auto_hide'),'yes');?>/><?php _e('Auto Hide Sidebar On Page Load','csbwfs');?></td>
68
- </tr>
69
- <tr><th>&nbsp;</th><td><input type="checkbox" id="csbwfs_hide_home" value="yes" name="csbwfs_hide_home" <?php checked(get_option('csbwfs_hide_home'),'yes');?>/>Hide Sidebar On Home Page</td></tr>
70
- <tr><td colspan="2"><strong><h4>Social Share Button Images 32X32 (Optional) :</h4></strong></td></tr>
71
- <tr><td colspan="2" align="right"><input type="button" id="csbwfs_resetpage" value="Reset"></td></tr>
72
- <tr>
73
- <th><?php echo 'Facebook:';?></th>
74
- <td class="csbwfsButtonsImg" id="csbwfsButtonsFbImg">
75
- <input type="text" id="csbwfs_fb_image" name="csbwfs_fb_image" value="<?php echo get_option('csbwfs_fb_image'); ?>" placeholder="Insert facebook button image path" size="30" class="inputButtonid"/> <input id="csbwfs_fb_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_fb_bg" data-default-color="#305891" class="color-field" name="csbwfs_fb_bg" value="<?php echo get_option('csbwfs_fb_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_fb_title" name="csbwfs_fb_title" value="<?php echo get_option('csbwfs_fb_title'); ?>" placeholder="Share on facebook" size="20" class="csbwfs_title"/>
76
- </td>
77
- </tr>
78
- <tr><th><?php echo 'Twitter:';?></th>
79
- <td class="csbwfsButtonsImg" id="csbwfsButtonsTwImg">
80
- <input type="text" id="csbwfs_tw_image" name="csbwfs_tw_image" value="<?php echo get_option('csbwfs_tw_image'); ?>" placeholder="Insert twitter button image path" size="30" class="inputButtonid"/><input id="csbwfs_tw_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_tw_bg" name="csbwfs_tw_bg" value="<?php echo get_option('csbwfs_tw_bg'); ?>" data-default-color="#2ca8d2" class="color-field" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_tw_title" name="csbwfs_tw_title" value="<?php echo get_option('csbwfs_tw_title'); ?>" placeholder="Share on twitter" size="20" class="csbwfs_title"/>
81
- </td>
82
- </tr>
83
- <tr>
84
- <th><?php echo 'Linkedin:';?></th>
85
- <td class="csbwfsButtonsImg" id="csbwfsButtonsLiImg">
86
- <input type="text" id="csbwfs_li_image" name="csbwfs_li_image" value="<?php echo get_option('csbwfs_li_image'); ?>" placeholder="Insert Linkedin button image path" class="inputButtonid" size="30" class="buttonimg"/><input id="csbwfs_li_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_li_bg" name="csbwfs_li_bg" value="<?php echo get_option('csbwfs_li_bg'); ?>" data-default-color="#dd4c39" class="color-field" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_li_title" name="csbwfs_li_title" value="<?php echo get_option('csbwfs_li_title'); ?>" placeholder="Share on Linkedin" size="20" class="csbwfs_title"/>
87
- </td>
88
- </tr>
89
- <tr><th><?php echo 'Pintrest:';?></th>
90
- <td class="csbwfsButtonsImg" id="csbwfsButtonsPiImg">
91
- <input type="text" id="csbwfs_pin_image" name="csbwfs_pin_image" value="<?php echo get_option('csbwfs_pin_image'); ?>" class="inputButtonid" placeholder="Insert pinterest button image path" size="30" class="buttonimg"/><input id="csbwfs_pin_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_pin_bg" name="csbwfs_pin_bg" value="<?php echo get_option('csbwfs_pin_bg'); ?>" data-default-color="#ca2027" class="color-field" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_pin_title" name="csbwfs_pin_title" value="<?php echo get_option('csbwfs_pin_title'); ?>" placeholder="Share on pintrest" size="20" class="csbwfs_title"/>
92
- </td>
93
- </tr>
94
- <tr><th><?php echo 'Google Plus:';?></th>
95
- <td class="csbwfsButtonsImg" id="csbwfsButtonsGoImg">
96
- <input type="text" id="csbwfs_gp_image" name="csbwfs_gp_image" value="<?php echo get_option('csbwfs_gp_image'); ?>" placeholder="Insert google button image path" size="30" class="inputButtonid"/><input id="csbwfs_gp_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_gp_image" name="csbwfs_gp_bg" value="<?php echo get_option('csbwfs_gp_bg'); ?>" data-default-color="#dd4c39" class="color-field" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_gp_title" name="csbwfs_gp_title" value="<?php echo get_option('csbwfs_gp_title'); ?>" placeholder="Share on google" size="20" class="csbwfs_title"/>
97
- </td>
98
- </tr>
99
- <tr><th><?php echo 'Reddit:';?></th>
100
- <td class="csbwfsButtonsImg" id="csbwfsButtonsReImg">
101
- <input type="text" id="csbwfs_re_image" name="csbwfs_re_image" value="<?php echo get_option('csbwfs_re_image'); ?>" placeholder="Insert reddit button image path" size="30" class="inputButtonid"/><input id="csbwfs_re_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_re_bg" name="csbwfs_re_bg" value="<?php echo get_option('csbwfs_re_bg'); ?>" data-default-color="#ff1a00" class="color-field" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_re_title" name="csbwfs_re_title" value="<?php echo get_option('csbwfs_re_title'); ?>" placeholder="Share on reddit" size="20" class="csbwfs_title"/>
102
- </td>
103
- </tr>
104
- <tr><th><?php echo 'Stumbleupon:';?></th>
105
- <td class="csbwfsButtonsImg" id="csbwfsButtonsStImg">
106
- <input type="text" id="csbwfs_st_image" name="csbwfs_st_image" value="<?php echo get_option('csbwfs_st_image'); ?>" placeholder="Insert stumbleupon button image path" size="30" class="inputButtonid"/><input id="csbwfs_st_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_st_bg" name="csbwfs_st_bg" value="<?php echo get_option('csbwfs_st_bg'); ?>" data-default-color="#eb4924" class="color-field" size="20"/>
107
- &nbsp;&nbsp;<input type="text" id="csbwfs_st_title" name="csbwfs_st_title" value="<?php echo get_option('csbwfs_st_title'); ?>" placeholder="Share on stumbleupon" size="20" class="csbwfs_title"/>
108
- </td>
109
- </tr>
110
- <tr><th><?php echo 'Mail:';?></th>
111
- <td class="csbwfsButtonsImg" id="csbwfsButtonsMaImg">
112
- <input type="text" id="csbwfs_mail_image" name="csbwfs_mail_image" value="<?php echo get_option('csbwfs_mail_image'); ?>" placeholder="Insert mail button image path" size="30" class="inputButtonid"/><input id="csbwfs_mail_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_mail_bg" name="csbwfs_mail_bg" value="<?php echo get_option('csbwfs_mail_bg'); ?>" data-default-color="#738a8d" class="color-field" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_mail_title" name="csbwfs_mail_title" value="<?php echo get_option('csbwfs_mail_title'); ?>" placeholder="Send contact request" size="20" class="csbwfs_title"/>
113
- </td>
114
- </tr>
115
- <tr><th><?php echo 'Youtube:';?></th>
116
- <td class="csbwfsButtonsImg" id="csbwfsButtonsYtImg">
117
- <input type="text" id="csbwfs_yt_image" name="csbwfs_yt_image" value="<?php echo get_option('csbwfs_yt_image'); ?>" placeholder="Insert youtube button image path" size="30" class="inputButtonid"/><input id="csbwfs_yt_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_yt_bg" name="csbwfs_yt_bg" value="<?php echo get_option('csbwfs_yt_bg'); ?>" data-default-color="#ffffff" class="color-field" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_yt_title" name="csbwfs_yt_title" value="<?php echo get_option('csbwfs_yt_title'); ?>" placeholder="Youtube" size="20" class="csbwfs_title"/>
118
- </td>
119
- </tr>
120
- <tr><td colspan="2"><h3><strong>Style(Optional):</strong></h3></td></tr>
121
-
122
- <tr>
123
- <th><?php echo 'Top Margin:';?></th>
124
- <td>
125
-
126
- <input type="textbox" id="csbwfs_top_margin" name="csbwfs_top_margin" value="<?php echo get_option('csbwfs_top_margin'); ?>" placeholder="10% OR 10px" size="10"/>
127
- </td>
128
- </tr>
129
- </table>
130
- </div>
131
- <!-- Share Buttons -->
132
- <div class="csbwfs-tab" id="div-csbwfs-share-buttons">
133
- <h2>Social Share Buttons Settings</h2>
134
- <table>
135
- <td><?php _e('Enable:','csbwfs');?></td>
136
- <td colspan="2">
137
- <input type="checkbox" id="csbwfs_buttons_active" name="csbwfs_buttons_active" value='1' <?php checked(get_option('csbwfs_buttons_active'),1);?>/>
138
- </td>
139
- </tr>
140
- <tr>
141
- <th nowrap><?php echo 'Share Button Position:';?></th>
142
- <td>
143
- <select id="csbwfs_btn_position" name="csbwfs_btn_position" >
144
- <option value="left" <?php selected(get_option('csbwfs_btn_position'),'left');?>>Left</option>
145
- <option value="right" <?php selected(get_option('csbwfs_btn_position'),'right');?>>Right</option>
146
- </select>
147
- </td>
148
- </tr>
149
- <tr>
150
- <th nowrap><?php echo 'Display Buttons On ';?></th>
151
- <td>
152
- <select id="csbwfs_btn_display" name="csbwfs_btn_display" >
153
- <option value="below" <?php selected(get_option('csbwfs_btn_display'),'below');?>>Bottom Of The Content</option>
154
- <option value="above" <?php selected(get_option('csbwfs_btn_display'),'above');?>>Top Of The Content</option>
155
- </select>
156
- </td>
157
- </tr>
158
- <tr>
159
- <th nowrap><?php echo 'Share Button Text:';?></th>
160
- <td>
161
- <input type="textbox" id="csbwfs_btn_text" name="csbwfs_btn_text" value="<?php echo get_option('csbwfs_btn_text'); ?>" placeholder="Share This!" size="20"/>
162
- <i>(Leave blank if you want hide button)</i></td>
163
- </tr>
164
- <tr><td colspan="2"><strong>Show Share Buttons On :</strong> Home <input type="checkbox" id="csbwfs_page_hide_home" value="yes" name="csbwfs_page_hide_home" <?php checked(get_option('csbwfs_page_hide_home'),'yes');?>/> Page <input type="checkbox" id="csbwfs_page_hide_page" value="yes" name="csbwfs_page_hide_page" <?php checked(get_option('csbwfs_page_hide_page'),'yes');?>/> Post <input type="checkbox" id="csbwfs_page_hide_post" value="yes" name="csbwfs_page_hide_post" <?php checked(get_option('csbwfs_page_hide_post'),'yes');?>/> Category/Archive <input type="checkbox" id="csbwfs_page_hide_archive" value="yes" name="csbwfs_page_hide_archive" <?php checked(get_option('csbwfs_page_hide_archive'),'yes');?>/> <br>
165
- </td></tr>
166
-
167
- <tr><td colspan="2"><strong><h4>Social Share Button Images 32X32 (Optional) :</h4></strong></td></tr>
168
- <tr><td colspan="2" align="right"><input type="button" id="csbwfsresetpage" value="RESET"></td></tr>
169
- <tr><th><?php echo 'Facebook:';?></th>
170
- <td class="csbwfsButtonsImg" id="csbwfsButtonsFbImg2"><input type="text" id="csbwfs_page_fb_image" name="csbwfs_page_fb_image" value="<?php echo get_option('csbwfs_page_fb_image'); ?>" placeholder="Insert facebook button image path" size="40" class="inputButtonid"/>
171
- <input id="csbwfs_fb_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_fb_bg" data-default-color="#305891" class="color-field" name="csbwfs_page_fb_bg" value="<?php echo get_option('csbwfs_page_fb_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_fb_title" name="csbwfs_page_fb_title" value="<?php echo get_option('csbwfs_page_fb_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
172
- </td>
173
- </tr>
174
- <tr>
175
- <th><?php echo 'Twitter:';?></th>
176
- <td class="csbwfsButtonsImg" id="csbwfsButtonsTwImg2">
177
- <input type="text" id="csbwfs_page_tw_image" name="csbwfs_page_tw_image" value="<?php echo get_option('csbwfs_page_tw_image'); ?>" placeholder="Insert twitter button image path" size="40" class="inputButtonid"/>
178
- <input id="csbwfs_tw_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_tw_bg" data-default-color="#2ca8d2" class="color-field" name="csbwfs_page_tw_bg" value="<?php echo get_option('csbwfs_page_tw_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_tw_title" name="csbwfs_page_tw_title" value="<?php echo get_option('csbwfs_page_tw_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
179
- </td>
180
- </tr>
181
- <tr><th><?php echo 'Linkedin:';?></th>
182
- <td class="csbwfsButtonsImg" id="csbwfsButtonsLiImg2"><input type="text" id="csbwfs_page_li_image" name="csbwfs_page_li_image" value="<?php echo get_option('csbwfs_page_li_image'); ?>" placeholder="Insert Linkedin button image path" size="40" class="inputButtonid"/>
183
- <input id="csbwfs_li_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_li_bg" data-default-color="#dd4c39" class="color-field" name="csbwfs_page_li_bg" value="<?php echo get_option('csbwfs_page_li_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_li_title" name="csbwfs_page_li_title" value="<?php echo get_option('csbwfs_page_li_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
184
- </td>
185
- </tr>
186
- <tr>
187
- <th><?php echo 'Pintrest:';?></th>
188
- <td class="csbwfsButtonsImg" id="csbwfsButtonsPiImg2"><input type="text" id="csbwfs_page_pin_image" name="csbwfs_page_pin_image" value="<?php echo get_option('csbwfs_page_pin_image'); ?>" placeholder="Insert pinterest button image path" size="40" class="inputButtonid"/>
189
- <input id="csbwfs_pi_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_pin_bg" data-default-color="#ca2027" class="color-field" name="csbwfs_page_pin_bg" value="<?php echo get_option('csbwfs_page_pin_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_pin_title" name="csbwfs_page_pin_title" value="<?php echo get_option('csbwfs_page_pin_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
190
- </td>
191
- </tr>
192
- <tr>
193
- <th><?php echo 'Google Plus:';?></th>
194
- <td class="csbwfsButtonsImg" id="csbwfsButtonsGpImg2">
195
- <input type="text" id="csbwfs_page_gp_image" name="csbwfs_page_gp_image" value="<?php echo get_option('csbwfs_page_gp_image'); ?>" placeholder="Insert google button image path" size="40" class="inputButtonid"/>
196
- <input id="csbwfs_gp_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_gp_bg" data-default-color="#dd4c39" class="color-field" name="csbwfs_page_gp_bg" value="<?php echo get_option('csbwfs_page_gp_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_gp_title" name="csbwfs_page_gp_title" value="<?php echo get_option('csbwfs_page_gp_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
197
- </td>
198
- </tr>
199
- <tr>
200
- <th><?php echo 'Reddit:';?></th>
201
- <td class="csbwfsButtonsImg" id="csbwfsButtonsReImg2">
202
- <input type="text" id="csbwfs_page_re_image" name="csbwfs_page_re_image" value="<?php echo get_option('csbwfs_page_re_image'); ?>" placeholder="Insert reddit button image path" size="40" class="inputButtonid"/>
203
- <input id="csbwfs_re_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_re_bg" data-default-color="#ff1a00" class="color-field" name="csbwfs_page_re_bg" value="<?php echo get_option('csbwfs_page_re_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_re_title" name="csbwfs_page_re_title" value="<?php echo get_option('csbwfs_page_re_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
204
- </td>
205
- </tr>
206
- <tr>
207
- <th><?php echo 'Stumbleupon:';?></th>
208
- <td class="csbwfsButtonsImg" id="csbwfsButtonsStImg2">
209
- <input type="text" id="csbwfs_page_st_image" name="csbwfs_page_st_image" value="<?php echo get_option('csbwfs_page_st_image'); ?>" placeholder="Insert stumbleupon button image path" size="40" class="inputButtonid"/>
210
- <input id="csbwfs_st_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_st_bg" data-default-color="#eb4924" class="color-field" name="csbwfs_page_st_bg" value="<?php echo get_option('csbwfs_page_st_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_st_title" name="csbwfs_page_st_title" value="<?php echo get_option('csbwfs_page_st_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
211
- </td>
212
- </tr>
213
- <tr>
214
- <th><?php echo 'Mail:';?></th>
215
- <td class="csbwfsButtonsImg" id="csbwfsButtonsMlImg2">
216
- <input type="text" id="csbwfs_page_mail_image" name="csbwfs_page_mail_image" value="<?php echo get_option('csbwfs_page_mail_image'); ?>" placeholder="Insert mail button image path" size="40" class="inputButtonid"/>
217
- <input id="csbwfs_ml_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_mail_bg" data-default-color="#738a8d" class="color-field" name="csbwfs_page_mail_bg" value="<?php echo get_option('csbwfs_page_mail_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_mail_title" name="csbwfs_page_mail_title" value="<?php echo get_option('csbwfs_page_mail_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
218
- </td>
219
- </tr>
220
- <tr>
221
- <th><?php echo 'Youtube:';?></th>
222
- <td class="csbwfsButtonsImg" id="csbwfsButtonsYtImg2">
223
- <input type="text" id="csbwfs_page_yt_image" name="csbwfs_page_yt_image" value="<?php echo get_option('csbwfs_page_yt_image'); ?>" placeholder="Insert youtube button image path" size="40" class="inputButtonid"/>
224
- <input id="csbwfs_yt_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_yt_bg" data-default-color="#ffffff" class="color-field" name="csbwfs_page_yt_bg" value="<?php echo get_option('csbwfs_page_yt_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_yt_title" name="csbwfs_page_yt_title" value="<?php echo get_option('csbwfs_page_yt_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
225
- </td>
226
- </tr>
227
- </table>
228
-
229
- </div>
230
- <!-- Support -->
231
- <div class="last author csbwfs-tab" id="div-csbwfs-support">
232
-
233
- <h2>Plugin Support</h2>
234
-
235
- <p><a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=ZEMSYQUZRUK6A" target="_blank" style="font-size: 17px; font-weight: bold;"><img src="https://www.paypal.com/en_US/i/btn/btn_donate_LG.gif" title="Donate for this plugin"></a></p>
236
-
237
- <p><strong>Plugin Author:</strong><br><img src="<?php echo plugins_url( '../images/mrweb.jpg' , __FILE__ );?>" width="75" height="75"><br><a href="http://raghunathgurjar.wordpress.com" target="_blank">MR Web Soluttion</a></p>
238
- <p><a href="mailto:raghunath.0087@gmail.com" target="_blank" class="contact-author">Contact Author</a></p>
239
- <p><strong>Our Other Plugins:</strong><br>
240
- <ol>
241
- <li><a href="https://wordpress.org/plugins/custom-share-buttons-with-floating-sidebar" target="_blank">Custom Share Buttons With Floating Sidebar</a></li>
242
- <li><a href="https://wordpress.org/plugins/protect-wp-admin/" target="_blank">Protect WP-Admin</a></li>
243
- <li><a href="https://wordpress.org/plugins/wp-sales-notifier/" target="_blank">WP Sales Notifier</a></li>
244
- <li><a href="https://wordpress.org/plugins/wp-categories-widget/" target="_blank">WP Categories Widget</a></li>
245
- <li><a href="https://wordpress.org/plugins/wp-protect-content/" target="_blank">WP Protect Content</a></li>
246
- <li><a href="https://wordpress.org/plugins/wp-version-remover/" target="_blank">WP Version Remover</a></li>
247
- <li><a href="https://wordpress.org/plugins/wp-posts-widget/" target="_blank">WP Post Widget</a></li>
248
- <li><a href="https://wordpress.org/plugins/wp-importer" target="_blank">WP Importer</a></li>
249
- <li><a href="https://wordpress.org/plugins/wp-csv-importer/" target="_blank">WP CSV Importer</a></li>
250
- <li><a href="https://wordpress.org/plugins/wp-testimonial/" target="_blank">WP Testimonial</a></li>
251
- <li><a href="https://wordpress.org/plugins/wc-sales-count-manager/" target="_blank">WooCommerce Sales Count Manager</a></li>
252
- <li><a href="https://wordpress.org/plugins/wp-social-buttons/" target="_blank">WP Social Buttons</a></li>
253
- <li><a href="https://wordpress.org/plugins/wp-youtube-gallery/" target="_blank">WP Youtube Gallery</a></li>
254
- <li><a href="https://wordpress.org/plugins/tweets-slider/" target="_blank">Tweets Slider</a></li>
255
- <li><a href="https://wordpress.org/plugins/rg-responsive-gallery/" target="_blank">RG Responsive Slider</a></li>
256
- <li><a href="https://wordpress.org/plugins/cf7-advance-security" target="_blank">Contact Form 7 Advance Security WP-Admin</a></li>
257
- <li><a href="https://wordpress.org/plugins/wp-easy-recipe/" target="_blank">WP Easy Recipe</a></li>
258
- </ol>
259
- </div>
260
- <!-- GO PRO -->
261
- <div class="last author csbwfs-tab" id="div-csbwfs-pro">
262
- <h2 style="color:green;text-align:center;"><strong>Pay one time use lifetime!!!!!</strong></h2>
263
- <table>
264
- <tr>
265
- <td valign="top" width="30%">
266
- <h2>GO PRO</h2>
267
- <p><a href="https://rgaddons.wordpress.com/custom-share-buttons-with-floating-sidebar-pro/" target="_blank" class="contact-author">Click here</a> to download addon.</p>
268
- <p>We have released an add-on for Custom Share Buttons With Floating Sidebar which not only demonstrates the flexibility of CSBWFS, but also adds some important features:</p>
269
- <iframe width="560" height="450" src="https://www.youtube.com/embed/tqnAPG5VfFY" frameborder="0" allowfullscreen></iframe>
270
- </td>
271
- <td><h2>Key Features</h2><hr>
272
- <ol>
273
- <li>Responsive Floating Sidebar</li>
274
- <li>Shortcode</li>
275
- <li>An option to Hide Floating Sidebar On Home/Blog/Search/Category/Author pages</li>
276
- <li>An option to Hide Floating Sidebar On any post type (i.e page,post,event,product…etc)</li>
277
- <li>An option to Hide Floating Sidebar On any taxonomy type (support all custom taxonomy type)</li>
278
- <li>An Option to Show/Hide sidebar on specific page/post and on any custom post type pages as well.</li>
279
- <li>An option to Show Social Share Buttons On Home/Blog/Search/Category/Author pages</li>
280
- <li>An option to Show Social Share Buttons on any taxonomy type (support all custom taxonomy type)</li>
281
- <li>An Option to Show/Hide social share buttons on specific page/post and on any custom post type pages as well.</li>
282
- <li>Responsive Light box Contact Form (for Mail Icon)</li>
283
- <li>An option to add to any custom shortcode into light box</li>
284
- <li>Advance feature for choose to pinterest share image</li>
285
- <li>An option to enable to OG tags meta boxes for define to share window content(share title, share description &amp; share image path)</li>
286
- <li>An option to set sidebar position (left/right/bottom) for mobile</li>
287
- <li>An option to add social site official page URL for all social buttons</li>
288
- <li>Extra Buttons (Xing,Instagram,Whatsapp,Digg,Yummly,Vk, Buffer, Line, Skype, RSS, Print, G-Mail, Blogger, Tumbler, Delicious, Weibo, Telegram, Google Translate, Phone &amp; SMS )</li>
289
- <li>An option to define to twitter username as hash tag in share window.</li>
290
- <li>An option to display share count(Facebook, StumbleUpon, Pinterest, Xing and Reddit)</li>
291
- <li>An options to change to buttons image, title, background color and url (You can use any button as your own custom button)</li>
292
- <li>An options to define sorting order for all buttons</li>
293
- <li>10 extra custom floating sidebar buttons with extra options (i.e you can define your own custom size for these buttons)</li>
294
- <li>An option to show sum of total share count for all buttons</li>
295
- <li>An option to remove mouse hover animation effect for all social buttons</li>
296
- <li>An options to choose different style of sidebar</li>
297
- <li>An option to define page specific sidebar position (Left/Right/Bottom) for all page</li>
298
- <li>An option to choose custom styles of social share buttons</li>
299
- <li>An option to define sidebar position for every page separately</li>
300
- <li>An option to show/hide sidebar from any specific page</li>
301
- <li>Faster support</li>
302
- </ol>
303
- </td>
304
- </tr>
305
- </table>
306
- </div>
307
- </div>
308
- <span class="submit-btn"><?php echo get_submit_button('Save Settings','button-primary','submit','','');?></span>
309
- <?php settings_fields('csbwf_sidebar_options'); ?>
310
- </form>
311
- <!-- End Options Form -->
312
- </div>
1
+ <div style="width: 80%; padding: 10px; margin: 10px;">
2
+ <h1>Custom Share Buttons With Floating Sidebar Settings</h1>
3
+ <!-- Start Options Form -->
4
+
5
+ <form action="options.php" method="post" id="csbwf-sidebar-admin-form">
6
+
7
+ <div id="csbwf-tab-menu"><a id="csbwfs-general" class="csbwf-tab-links active" >General</a> <a id="csbwfs-sidebar" class="csbwf-tab-links">Floating Sidebar</a> <a id="csbwfs-share-buttons" class="csbwf-tab-links">Social Share Buttons</a> <a id="csbwfs-pro" class="csbwf-tab-links">GO PRO</a> <a id="csbwfs-support" class="csbwf-tab-links">Support</a></div>
8
+ <p align="right"><span class="submit-btn"><?php echo get_submit_button('Save Settings','button-primary extrabtn','submit','','');?></span></p>
9
+ <div class="csbwfs-setting">
10
+ <!-- General Setting -->
11
+ <div class="first csbwfs-tab" id="div-csbwfs-general">
12
+ <h2>General Settings</h2>
13
+ <table cellpadding="10">
14
+ <tr>
15
+ <td valign="top" nowrap>
16
+ <p><input type="checkbox" id="csbwfs_active" name="csbwfs_active" value='1' <?php checked(get_option('csbwfs_active'),1);?>/> <b><?php _e('Enable Sidebar');?> </b></p>
17
+ <p><h3><strong><?php _e('Social Share Button Publish Options:','csbwfs');?></strong></h3></p>
18
+ <p><input type="checkbox" id="publish1" value="yes" name="csbwfs_fpublishBtn" <?php checked(get_option('csbwfs_fpublishBtn'),'yes');?>/><b>Facebook</b></p>
19
+ <p><input type="checkbox" id="publish2" name="csbwfs_tpublishBtn" value="yes" <?php checked(get_option('csbwfs_tpublishBtn'),'yes');?>/> <b>Twitter</b></p>
20
+ <p><input type="checkbox" id="publish4" name="csbwfs_lpublishBtn" value="yes" <?php checked(get_option('csbwfs_lpublishBtn'),'yes');?>/> <b>Linkedin</b></p>
21
+ <p><input type="checkbox" id="publish6" name="csbwfs_ppublishBtn" value="yes" <?php checked(get_option('csbwfs_ppublishBtn'),'yes');?>/> <b>Pinterest</b></p>
22
+ <p><input type="checkbox" id="publish7" name="csbwfs_republishBtn" value="yes" <?php checked(get_option('csbwfs_republishBtn'),'yes');?>/> <b>Reddit</b></p>
23
+ <p><input type="checkbox" id="publish8" name="csbwfs_stpublishBtn" value="yes" <?php checked(get_option('csbwfs_stpublishBtn'),'yes');?>/> <b>Stumbleupon</b></p>
24
+ <p><input type="checkbox" id="publish5" name="csbwfs_mpublishBtn" value="yes" <?php checked(get_option('csbwfs_mpublishBtn'),'yes');?>/> <b>Mail</b></p>
25
+ <?php if(get_option('csbwfs_mpublishBtn')=='yes');{?>
26
+ <p id="mailmsg"><input type="text" name="csbwfs_mailMessage" id="csbwfs_mailMessage" value="<?php echo get_option('csbwfs_mailMessage');?>" placeholder="your@email.com?subject=Your Subject" size="40" class="regular-text ltr"><br><i>Leave empty to add current page title as subject line and url as body text </i></p>
27
+ <?php } ?>
28
+ <p><input type="checkbox" id="ytBtns" name="csbwfs_ytpublishBtn" value="yes" <?php checked(get_option('csbwfs_ytpublishBtn'),'yes');?>/> <b>Youtube</b></p>
29
+ <p id="ytpath"><input type="text" name="csbwfs_ytPath" id="csbwfs_ytPath" value="<?php echo get_option('csbwfs_ytPath');?>" placeholder="http://www.youtube.com" size="40" class="regular-text ltr"><br>add youtube channel url</p>
30
+ <p><label><h3 ><strong><?php _e('Define your custom message:','csbwfs');?></strong></h3></label></p>
31
+ <p><label><?php _e('Show:');?></label><input type="text" id="csbwfs_show_btn" name="csbwfs_show_btn" value="<?php echo get_option('csbwfs_show_btn'); ?>" placeholder="Show Buttons" size="40"/></p>
32
+ <p><label><?php _e('Hide:');?></label><input type="text" id="csbwfs_hide_btn" name="csbwfs_hide_btn" value="<?php echo get_option('csbwfs_hide_btn'); ?>" placeholder="Hide Buttons" size="40"/></p>
33
+ <p><label><?php _e('Message:');?></label><input type="textbox" id="csbwfs_share_msg" name="csbwfs_share_msg" value="<?php echo get_option('csbwfs_share_msg'); ?>" placeholder="Share This With Your Friends" size="40"/></p>
34
+ </td>
35
+ <td valign="top" style="border-left:1px solid #ccc;padding-left:20px;">
36
+ <p style="font-size:16px;">Watch given below video to view addon features and settings</p>
37
+ <iframe width="100%" height="500" src="https://www.youtube.com/embed/QUnxtCe95Ww?rel=0&autoplay=1&start=90" frameborder="0" allow="autoplay; encrypted-media" allowfullscreen></iframe>
38
+ <h2><a href="https://rgaddons.wordpress.com/custom-share-buttons-with-floating-sidebar-pro/" target="_blank" class="contact-author"><strong>Click Here</strong></a> to download addon.</h2>
39
+ </tr>
40
+ </table>
41
+ </div>
42
+ <!-- Floating Sidebar -->
43
+ <div class="csbwfs-tab" id="div-csbwfs-sidebar">
44
+ <h2>Floating Sidebar Settings</h2>
45
+ <table>
46
+ <tr>
47
+ <th nowrap><?php echo 'Siderbar Position:';?></th>
48
+ <td>
49
+ <select id="csbwfs_position" name="csbwfs_position" >
50
+ <option value="left" <?php selected(get_option('csbwfs_position'),'left');?>>Left</option>
51
+ <option value="right" <?php selected(get_option('csbwfs_position'),'right');?>>Right</option>
52
+ <option value="bottom" <?php selected(get_option('csbwfs_position'),'bottom');?>>Bottom</option>
53
+ </select>
54
+ </td>
55
+ </tr>
56
+ <tr>
57
+ <th>&nbsp;</th>
58
+ <td><input type="checkbox" id="csbwfs_rmSHBtn" name="csbwfs_rmSHBtn" value="yes" <?php checked(get_option('csbwfs_rmSHBtn'),'yes');?>/> <strong><?php _e('Remove Show/Hide Button:','csbwfs');?></strong></td>
59
+ </tr>
60
+ <tr><th nowrap valign="top"><?php echo 'Delay Time: '; ?></th><td><input type="text" name="csbwfs_delayTimeBtn" id="csbwfs_delayTimeBtn" value="<?php echo get_option('csbwfs_delayTimeBtn')?get_option('csbwfs_delayTimeBtn'):0;?>" size="40" class="regular-text ltr"><br><i>Publish share buttons after given time(millisecond)</i></td></tr>
61
+ <tr>
62
+ <th>&nbsp;</th>
63
+ <td><input type="checkbox" id="csbwfs_deactive_for_mob" name="csbwfs_deactive_for_mob" value="yes" <?php checked(get_option('csbwfs_deactive_for_mob'),'yes');?>/><?php _e('Disable Sidebar For Mobile','csbwfs');?></td>
64
+ </tr>
65
+ <tr><th></th>
66
+ <td><input type="checkbox" id="csbwfs_auto_hide" name="csbwfs_auto_hide" value="yes" <?php checked(get_option('csbwfs_auto_hide'),'yes');?>/><?php _e('Auto Hide Sidebar On Page Load','csbwfs');?></td>
67
+ </tr>
68
+ <tr><th>&nbsp;</th><td><input type="checkbox" id="csbwfs_hide_home" value="yes" name="csbwfs_hide_home" <?php checked(get_option('csbwfs_hide_home'),'yes');?>/>Hide Sidebar On Home Page</td></tr>
69
+ <tr><td colspan="2"><strong><h4>Social Share Button Images 32X32 (Optional) :</h4></strong></td></tr>
70
+ <tr><td colspan="2" align="right"><input type="button" id="csbwfs_resetpage" value="Reset"></td></tr>
71
+ <tr>
72
+ <th><?php echo 'Facebook:';?></th>
73
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsFbImg">
74
+ <input type="text" id="csbwfs_fb_image" name="csbwfs_fb_image" value="<?php echo get_option('csbwfs_fb_image'); ?>" placeholder="Insert facebook button image path" size="30" class="inputButtonid"/> <input id="csbwfs_fb_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_fb_bg" data-default-color="#305891" class="color-field" name="csbwfs_fb_bg" value="<?php echo get_option('csbwfs_fb_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_fb_title" name="csbwfs_fb_title" value="<?php echo get_option('csbwfs_fb_title'); ?>" placeholder="Share on facebook" size="20" class="csbwfs_title"/>
75
+ </td>
76
+ </tr>
77
+ <tr><th><?php echo 'Twitter:';?></th>
78
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsTwImg">
79
+ <input type="text" id="csbwfs_tw_image" name="csbwfs_tw_image" value="<?php echo get_option('csbwfs_tw_image'); ?>" placeholder="Insert twitter button image path" size="30" class="inputButtonid"/><input id="csbwfs_tw_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_tw_bg" name="csbwfs_tw_bg" value="<?php echo get_option('csbwfs_tw_bg'); ?>" data-default-color="#2ca8d2" class="color-field" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_tw_title" name="csbwfs_tw_title" value="<?php echo get_option('csbwfs_tw_title'); ?>" placeholder="Share on twitter" size="20" class="csbwfs_title"/>
80
+ </td>
81
+ </tr>
82
+ <tr>
83
+ <th><?php echo 'Linkedin:';?></th>
84
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsLiImg">
85
+ <input type="text" id="csbwfs_li_image" name="csbwfs_li_image" value="<?php echo get_option('csbwfs_li_image'); ?>" placeholder="Insert Linkedin button image path" class="inputButtonid" size="30" class="buttonimg"/><input id="csbwfs_li_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_li_bg" name="csbwfs_li_bg" value="<?php echo get_option('csbwfs_li_bg'); ?>" data-default-color="#dd4c39" class="color-field" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_li_title" name="csbwfs_li_title" value="<?php echo get_option('csbwfs_li_title'); ?>" placeholder="Share on Linkedin" size="20" class="csbwfs_title"/>
86
+ </td>
87
+ </tr>
88
+ <tr><th><?php echo 'Pintrest:';?></th>
89
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsPiImg">
90
+ <input type="text" id="csbwfs_pin_image" name="csbwfs_pin_image" value="<?php echo get_option('csbwfs_pin_image'); ?>" class="inputButtonid" placeholder="Insert pinterest button image path" size="30" class="buttonimg"/><input id="csbwfs_pin_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_pin_bg" name="csbwfs_pin_bg" value="<?php echo get_option('csbwfs_pin_bg'); ?>" data-default-color="#ca2027" class="color-field" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_pin_title" name="csbwfs_pin_title" value="<?php echo get_option('csbwfs_pin_title'); ?>" placeholder="Share on pintrest" size="20" class="csbwfs_title"/>
91
+ </td>
92
+ </tr>
93
+
94
+ <tr><th><?php echo 'Reddit:';?></th>
95
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsReImg">
96
+ <input type="text" id="csbwfs_re_image" name="csbwfs_re_image" value="<?php echo get_option('csbwfs_re_image'); ?>" placeholder="Insert reddit button image path" size="30" class="inputButtonid"/><input id="csbwfs_re_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_re_bg" name="csbwfs_re_bg" value="<?php echo get_option('csbwfs_re_bg'); ?>" data-default-color="#ff1a00" class="color-field" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_re_title" name="csbwfs_re_title" value="<?php echo get_option('csbwfs_re_title'); ?>" placeholder="Share on reddit" size="20" class="csbwfs_title"/>
97
+ </td>
98
+ </tr>
99
+ <tr><th><?php echo 'Stumbleupon:';?></th>
100
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsStImg">
101
+ <input type="text" id="csbwfs_st_image" name="csbwfs_st_image" value="<?php echo get_option('csbwfs_st_image'); ?>" placeholder="Insert stumbleupon button image path" size="30" class="inputButtonid"/><input id="csbwfs_st_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_st_bg" name="csbwfs_st_bg" value="<?php echo get_option('csbwfs_st_bg'); ?>" data-default-color="#eb4924" class="color-field" size="20"/>
102
+ &nbsp;&nbsp;<input type="text" id="csbwfs_st_title" name="csbwfs_st_title" value="<?php echo get_option('csbwfs_st_title'); ?>" placeholder="Share on stumbleupon" size="20" class="csbwfs_title"/>
103
+ </td>
104
+ </tr>
105
+ <tr><th><?php echo 'Mail:';?></th>
106
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsMaImg">
107
+ <input type="text" id="csbwfs_mail_image" name="csbwfs_mail_image" value="<?php echo get_option('csbwfs_mail_image'); ?>" placeholder="Insert mail button image path" size="30" class="inputButtonid"/><input id="csbwfs_mail_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_mail_bg" name="csbwfs_mail_bg" value="<?php echo get_option('csbwfs_mail_bg'); ?>" data-default-color="#738a8d" class="color-field" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_mail_title" name="csbwfs_mail_title" value="<?php echo get_option('csbwfs_mail_title'); ?>" placeholder="Send contact request" size="20" class="csbwfs_title"/>
108
+ </td>
109
+ </tr>
110
+ <tr><th><?php echo 'Youtube:';?></th>
111
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsYtImg">
112
+ <input type="text" id="csbwfs_yt_image" name="csbwfs_yt_image" value="<?php echo get_option('csbwfs_yt_image'); ?>" placeholder="Insert youtube button image path" size="30" class="inputButtonid"/><input id="csbwfs_yt_image_button" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_yt_bg" name="csbwfs_yt_bg" value="<?php echo get_option('csbwfs_yt_bg'); ?>" data-default-color="#ffffff" class="color-field" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_yt_title" name="csbwfs_yt_title" value="<?php echo get_option('csbwfs_yt_title'); ?>" placeholder="Youtube" size="20" class="csbwfs_title"/>
113
+ </td>
114
+ </tr>
115
+ <tr><td colspan="2"><h3><strong>Style(Optional):</strong></h3></td></tr>
116
+
117
+ <tr>
118
+ <th><?php echo 'Top Margin:';?></th>
119
+ <td>
120
+
121
+ <input type="textbox" id="csbwfs_top_margin" name="csbwfs_top_margin" value="<?php echo get_option('csbwfs_top_margin'); ?>" placeholder="10% OR 10px" size="10"/>
122
+ </td>
123
+ </tr>
124
+ </table>
125
+ </div>
126
+ <!-- Share Buttons -->
127
+ <div class="csbwfs-tab" id="div-csbwfs-share-buttons">
128
+ <h2>Social Share Buttons Settings</h2>
129
+ <table>
130
+ <td><?php _e('Enable:','csbwfs');?></td>
131
+ <td colspan="2">
132
+ <input type="checkbox" id="csbwfs_buttons_active" name="csbwfs_buttons_active" value='1' <?php checked(get_option('csbwfs_buttons_active'),1);?>/>
133
+ </td>
134
+ </tr>
135
+ <tr>
136
+ <th nowrap><?php echo 'Share Button Position:';?></th>
137
+ <td>
138
+ <select id="csbwfs_btn_position" name="csbwfs_btn_position" >
139
+ <option value="left" <?php selected(get_option('csbwfs_btn_position'),'left');?>>Left</option>
140
+ <option value="right" <?php selected(get_option('csbwfs_btn_position'),'right');?>>Right</option>
141
+ </select>
142
+ </td>
143
+ </tr>
144
+ <tr>
145
+ <th nowrap><?php echo 'Display Buttons On ';?></th>
146
+ <td>
147
+ <select id="csbwfs_btn_display" name="csbwfs_btn_display" >
148
+ <option value="below" <?php selected(get_option('csbwfs_btn_display'),'below');?>>Bottom Of The Content</option>
149
+ <option value="above" <?php selected(get_option('csbwfs_btn_display'),'above');?>>Top Of The Content</option>
150
+ </select>
151
+ </td>
152
+ </tr>
153
+ <tr>
154
+ <th nowrap><?php echo 'Share Button Text:';?></th>
155
+ <td>
156
+ <input type="textbox" id="csbwfs_btn_text" name="csbwfs_btn_text" value="<?php echo get_option('csbwfs_btn_text'); ?>" placeholder="Share This!" size="20"/>
157
+ <i>(Leave blank if you want hide button)</i></td>
158
+ </tr>
159
+ <tr><td colspan="2"><strong>Show Share Buttons On :</strong> Home <input type="checkbox" id="csbwfs_page_hide_home" value="yes" name="csbwfs_page_hide_home" <?php checked(get_option('csbwfs_page_hide_home'),'yes');?>/> Page <input type="checkbox" id="csbwfs_page_hide_page" value="yes" name="csbwfs_page_hide_page" <?php checked(get_option('csbwfs_page_hide_page'),'yes');?>/> Post <input type="checkbox" id="csbwfs_page_hide_post" value="yes" name="csbwfs_page_hide_post" <?php checked(get_option('csbwfs_page_hide_post'),'yes');?>/> Category/Archive <input type="checkbox" id="csbwfs_page_hide_archive" value="yes" name="csbwfs_page_hide_archive" <?php checked(get_option('csbwfs_page_hide_archive'),'yes');?>/> <br>
160
+ </td></tr>
161
+
162
+ <tr><td colspan="2"><strong><h4>Social Share Button Images 32X32 (Optional) :</h4></strong></td></tr>
163
+ <tr><td colspan="2" align="right"><input type="button" id="csbwfsresetpage" value="RESET"></td></tr>
164
+ <tr><th><?php echo 'Facebook:';?></th>
165
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsFbImg2"><input type="text" id="csbwfs_page_fb_image" name="csbwfs_page_fb_image" value="<?php echo get_option('csbwfs_page_fb_image'); ?>" placeholder="Insert facebook button image path" size="40" class="inputButtonid"/>
166
+ <input id="csbwfs_fb_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_fb_bg" data-default-color="#305891" class="color-field" name="csbwfs_page_fb_bg" value="<?php echo get_option('csbwfs_page_fb_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_fb_title" name="csbwfs_page_fb_title" value="<?php echo get_option('csbwfs_page_fb_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
167
+ </td>
168
+ </tr>
169
+ <tr>
170
+ <th><?php echo 'Twitter:';?></th>
171
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsTwImg2">
172
+ <input type="text" id="csbwfs_page_tw_image" name="csbwfs_page_tw_image" value="<?php echo get_option('csbwfs_page_tw_image'); ?>" placeholder="Insert twitter button image path" size="40" class="inputButtonid"/>
173
+ <input id="csbwfs_tw_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_tw_bg" data-default-color="#2ca8d2" class="color-field" name="csbwfs_page_tw_bg" value="<?php echo get_option('csbwfs_page_tw_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_tw_title" name="csbwfs_page_tw_title" value="<?php echo get_option('csbwfs_page_tw_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
174
+ </td>
175
+ </tr>
176
+ <tr><th><?php echo 'Linkedin:';?></th>
177
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsLiImg2"><input type="text" id="csbwfs_page_li_image" name="csbwfs_page_li_image" value="<?php echo get_option('csbwfs_page_li_image'); ?>" placeholder="Insert Linkedin button image path" size="40" class="inputButtonid"/>
178
+ <input id="csbwfs_li_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_li_bg" data-default-color="#dd4c39" class="color-field" name="csbwfs_page_li_bg" value="<?php echo get_option('csbwfs_page_li_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_li_title" name="csbwfs_page_li_title" value="<?php echo get_option('csbwfs_page_li_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
179
+ </td>
180
+ </tr>
181
+ <tr>
182
+ <th><?php echo 'Pintrest:';?></th>
183
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsPiImg2"><input type="text" id="csbwfs_page_pin_image" name="csbwfs_page_pin_image" value="<?php echo get_option('csbwfs_page_pin_image'); ?>" placeholder="Insert pinterest button image path" size="40" class="inputButtonid"/>
184
+ <input id="csbwfs_pi_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_pin_bg" data-default-color="#ca2027" class="color-field" name="csbwfs_page_pin_bg" value="<?php echo get_option('csbwfs_page_pin_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_pin_title" name="csbwfs_page_pin_title" value="<?php echo get_option('csbwfs_page_pin_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
185
+ </td>
186
+ </tr>
187
+
188
+ <tr>
189
+ <th><?php echo 'Reddit:';?></th>
190
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsReImg2">
191
+ <input type="text" id="csbwfs_page_re_image" name="csbwfs_page_re_image" value="<?php echo get_option('csbwfs_page_re_image'); ?>" placeholder="Insert reddit button image path" size="40" class="inputButtonid"/>
192
+ <input id="csbwfs_re_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_re_bg" data-default-color="#ff1a00" class="color-field" name="csbwfs_page_re_bg" value="<?php echo get_option('csbwfs_page_re_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_re_title" name="csbwfs_page_re_title" value="<?php echo get_option('csbwfs_page_re_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
193
+ </td>
194
+ </tr>
195
+ <tr>
196
+ <th><?php echo 'Stumbleupon:';?></th>
197
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsStImg2">
198
+ <input type="text" id="csbwfs_page_st_image" name="csbwfs_page_st_image" value="<?php echo get_option('csbwfs_page_st_image'); ?>" placeholder="Insert stumbleupon button image path" size="40" class="inputButtonid"/>
199
+ <input id="csbwfs_st_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_st_bg" data-default-color="#eb4924" class="color-field" name="csbwfs_page_st_bg" value="<?php echo get_option('csbwfs_page_st_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_st_title" name="csbwfs_page_st_title" value="<?php echo get_option('csbwfs_page_st_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
200
+ </td>
201
+ </tr>
202
+ <tr>
203
+ <th><?php echo 'Mail:';?></th>
204
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsMlImg2">
205
+ <input type="text" id="csbwfs_page_mail_image" name="csbwfs_page_mail_image" value="<?php echo get_option('csbwfs_page_mail_image'); ?>" placeholder="Insert mail button image path" size="40" class="inputButtonid"/>
206
+ <input id="csbwfs_ml_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_mail_bg" data-default-color="#738a8d" class="color-field" name="csbwfs_page_mail_bg" value="<?php echo get_option('csbwfs_page_mail_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_mail_title" name="csbwfs_page_mail_title" value="<?php echo get_option('csbwfs_page_mail_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
207
+ </td>
208
+ </tr>
209
+ <tr>
210
+ <th><?php echo 'Youtube:';?></th>
211
+ <td class="csbwfsButtonsImg" id="csbwfsButtonsYtImg2">
212
+ <input type="text" id="csbwfs_page_yt_image" name="csbwfs_page_yt_image" value="<?php echo get_option('csbwfs_page_yt_image'); ?>" placeholder="Insert youtube button image path" size="40" class="inputButtonid"/>
213
+ <input id="csbwfs_yt_image_button2" type="button" value="Upload Image" class="cswbfsUploadBtn"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_yt_bg" data-default-color="#ffffff" class="color-field" name="csbwfs_page_yt_bg" value="<?php echo get_option('csbwfs_page_yt_bg'); ?>" size="20"/>&nbsp;&nbsp;<input type="text" id="csbwfs_page_yt_title" name="csbwfs_page_yt_title" value="<?php echo get_option('csbwfs_page_yt_title'); ?>" placeholder="Alt Text" size="20" class="csbwfs_title"/>
214
+ </td>
215
+ </tr>
216
+ </table>
217
+
218
+ </div>
219
+ <!-- Support -->
220
+ <div class="last author csbwfs-tab" id="div-csbwfs-support">
221
+
222
+ <h2>Plugin Support</h2>
223
+
224
+ <p><a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=ZEMSYQUZRUK6A" target="_blank" style="font-size: 17px; font-weight: bold;"><img src="https://www.paypal.com/en_US/i/btn/btn_donate_LG.gif" title="Donate for this plugin"></a></p>
225
+
226
+ <p><strong>Plugin Author:</strong><br><img src="<?php echo plugins_url( '../images/mrweb.jpg' , __FILE__ );?>" width="75" height="75"><br><a href="http://raghunathgurjar.wordpress.com" target="_blank">MR Web Soluttion</a></p>
227
+ <p><a href="mailto:raghunath.0087@gmail.com" target="_blank" class="contact-author">Contact Author</a></p>
228
+ <p><strong>Our Other Plugins:</strong><br>
229
+ <ol>
230
+ <li><a href="https://wordpress.org/plugins/custom-share-buttons-with-floating-sidebar" target="_blank">Custom Share Buttons With Floating Sidebar</a></li>
231
+ <li><a href="https://wordpress.org/plugins/protect-wp-admin/" target="_blank">Protect WP-Admin</a></li>
232
+ <li><a href="https://wordpress.org/plugins/wp-sales-notifier/" target="_blank">WP Sales Notifier</a></li>
233
+ <li><a href="https://wordpress.org/plugins/wp-categories-widget/" target="_blank">WP Categories Widget</a></li>
234
+ <li><a href="https://wordpress.org/plugins/wp-protect-content/" target="_blank">WP Protect Content</a></li>
235
+ <li><a href="https://wordpress.org/plugins/wp-version-remover/" target="_blank">WP Version Remover</a></li>
236
+ <li><a href="https://wordpress.org/plugins/wp-posts-widget/" target="_blank">WP Post Widget</a></li>
237
+ <li><a href="https://wordpress.org/plugins/wp-importer" target="_blank">WP Importer</a></li>
238
+ <li><a href="https://wordpress.org/plugins/wp-csv-importer/" target="_blank">WP CSV Importer</a></li>
239
+ <li><a href="https://wordpress.org/plugins/wp-testimonial/" target="_blank">WP Testimonial</a></li>
240
+ <li><a href="https://wordpress.org/plugins/wc-sales-count-manager/" target="_blank">WooCommerce Sales Count Manager</a></li>
241
+ <li><a href="https://wordpress.org/plugins/wp-social-buttons/" target="_blank">WP Social Buttons</a></li>
242
+ <li><a href="https://wordpress.org/plugins/wp-youtube-gallery/" target="_blank">WP Youtube Gallery</a></li>
243
+ <li><a href="https://wordpress.org/plugins/tweets-slider/" target="_blank">Tweets Slider</a></li>
244
+ <li><a href="https://wordpress.org/plugins/rg-responsive-gallery/" target="_blank">RG Responsive Slider</a></li>
245
+ <li><a href="https://wordpress.org/plugins/cf7-advance-security" target="_blank">Contact Form 7 Advance Security WP-Admin</a></li>
246
+ <li><a href="https://wordpress.org/plugins/wp-easy-recipe/" target="_blank">WP Easy Recipe</a></li>
247
+ </ol>
248
+ </div>
249
+ <!-- GO PRO -->
250
+ <div class="last author csbwfs-tab" id="div-csbwfs-pro">
251
+ <h2 style="color:green;text-align:center;"><strong>Pay one time use lifetime!!!!!</strong></h2>
252
+ <table>
253
+ <tr>
254
+ <td valign="top" width="30%">
255
+ <h2>GO PRO</h2>
256
+ <p><a href="https://rgaddons.wordpress.com/custom-share-buttons-with-floating-sidebar-pro/" target="_blank" class="contact-author">Click here</a> to download addon.</p>
257
+ <p>We have released an add-on for Custom Share Buttons With Floating Sidebar which not only demonstrates the flexibility of CSBWFS, but also adds some important features:</p>
258
+ <iframe width="560" height="450" src="https://www.youtube.com/embed/tqnAPG5VfFY" frameborder="0" allowfullscreen></iframe>
259
+ </td>
260
+ <td><h2>Key Features</h2><hr>
261
+ <ol>
262
+ <li>Responsive Floating Sidebar</li>
263
+ <li>Shortcode</li>
264
+ <li>An option to Hide Floating Sidebar On Home/Blog/Search/Category/Author pages</li>
265
+ <li>An option to Hide Floating Sidebar On any post type (i.e page,post,event,product…etc)</li>
266
+ <li>An option to Hide Floating Sidebar On any taxonomy type (support all custom taxonomy type)</li>
267
+ <li>An Option to Show/Hide sidebar on specific page/post and on any custom post type pages as well.</li>
268
+ <li>An option to Show Social Share Buttons On Home/Blog/Search/Category/Author pages</li>
269
+ <li>An option to Show Social Share Buttons on any taxonomy type (support all custom taxonomy type)</li>
270
+ <li>An Option to Show/Hide social share buttons on specific page/post and on any custom post type pages as well.</li>
271
+ <li>Responsive Light box Contact Form (for Mail Icon)</li>
272
+ <li>An option to add to any custom shortcode into light box</li>
273
+ <li>Advance feature for choose to pinterest share image</li>
274
+ <li>An option to enable to OG tags meta boxes for define to share window content(share title, share description &amp; share image path)</li>
275
+ <li>An option to set sidebar position (left/right/bottom) for mobile</li>
276
+ <li>An option to add social site official page URL for all social buttons</li>
277
+ <li>Extra Buttons (Xing,Instagram,Whatsapp,Digg,Yummly,Vk, Buffer, Line, Skype, RSS, Print, G-Mail, Blogger, Tumbler, Delicious, Weibo, Telegram, Google Translate, Phone &amp; SMS )</li>
278
+ <li>An option to define to twitter username as hash tag in share window.</li>
279
+ <li>An option to display share count(Facebook, StumbleUpon, Pinterest, Xing and Reddit)</li>
280
+ <li>An options to change to buttons image, title, background color and url (You can use any button as your own custom button)</li>
281
+ <li>An options to define sorting order for all buttons</li>
282
+ <li>10 extra custom floating sidebar buttons with extra options (i.e you can define your own custom size for these buttons)</li>
283
+ <li>An option to show sum of total share count for all buttons</li>
284
+ <li>An option to remove mouse hover animation effect for all social buttons</li>
285
+ <li>An options to choose different style of sidebar</li>
286
+ <li>An option to define page specific sidebar position (Left/Right/Bottom) for all page</li>
287
+ <li>An option to choose custom styles of social share buttons</li>
288
+ <li>An option to define sidebar position for every page separately</li>
289
+ <li>An option to show/hide sidebar from any specific page</li>
290
+ <li>Faster support</li>
291
+ </ol>
292
+ </td>
293
+ </tr>
294
+ </table>
295
+ </div>
296
+ </div>
297
+ <span class="submit-btn"><?php echo get_submit_button('Save Settings','button-primary','submit','','');?></span>
298
+ <?php settings_fields('csbwf_sidebar_options'); ?>
299
+ </form>
300
+ <!-- End Options Form -->
301
+ </div>
 
 
 
 
 
 
 
 
 
 
 
lib/shortcode.php CHANGED
@@ -1,87 +1,82 @@
1
- <?php
2
- /*
3
- * Template files to define CSBWFS Shortcodes
4
- * @add_shortcode()
5
- * @do_shortcode()
6
- * shortcode [csbwfs_buttons]
7
- **/
8
- if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
9
-
10
- if(!class_exists('CsbwfsShortcodeClass')):
11
- class CsbwfsShortcodeClass {
12
- /**
13
- * Construct the plugin object
14
- */
15
- public function __construct()
16
- {
17
- // register actions
18
- add_shortcode( 'csbwfs_buttons', array(&$this, 'csbwfs_shortcode_func' ) );
19
- add_filter( 'widget_text', 'do_shortcode' );
20
- } // END public function __construct
21
-
22
-
23
- public function csbwfs_shortcode_style_func() {
24
- echo '<style type="text/css">.csbwfs-shortcode a{box-shadow:inherit}.csbwfs-shortcode a i{display:inline-block;position:relative;width:35px;height:36px;background-image:url('.plugin_dir_url( __FILE__ ).'../images/minify-social.png)}.csbwfs-shortcode{display:inline-block;position:relative;width:auto;}i.csbwfs_facebook{background-position:68% 4%}i.csbwfs_twitter{background-position:14% 4%}i.csbwfs_plus{background-position:80% 4%}i.csbwfs_linkedin{background-position:92% 4%}i.csbwfs_pinterest{background-position:14% 19%}i.csbwfs_youtube{background-position:32% 4%}i.csbwfs_reddit{background-position:26% 19%}i.csbwfs_stumbleupon{background-position:2% 4%}i.csbwfs_mail{background-position:8% 19%}</style>';
25
- }
26
-
27
- public static function csbwfs_shortcode_func($atts) {
28
- //[csbwfs_buttons buttons='fb,tw,gp,li,pi,yt,re,st,ml']
29
- $shortcode_html = '';
30
- $btnsordaryy = isset($atts['buttons']) ? explode(',',$atts['buttons']) : array();
31
- $class = isset($atts['class']) ? $atts['class'] : '';
32
- if(is_array($btnsordaryy) && count($btnsordaryy) > 0 ){
33
- add_action( 'wp_footer', array(&$this,'csbwfs_shortcode_style_func' ));
34
- $shortcode_html .= '<div id="csbwfs-shortcode" class="'.$class.'">';
35
- foreach($btnsordaryy as $btnsVal)
36
- {
37
- /** FB */
38
- if($btnsVal=='fb'):
39
- $shortcode_html .='<div id="csbwfs-fb" class="csbwfs-shortcode"><a href="javascript:" onclick="javascript:window.open(\'//www.facebook.com/sharer/sharer.php?u=\'+encodeURIComponent(location.href)+\'&title=\'+encodeURIComponent(document.title)+\'&jump=close\', \'\', \'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=300,width=600\');return false;" target="_blank" ><i class="csbwfs_facebook"></i></a></div>';
40
- endif;
41
- /** TW */
42
- if($btnsVal=='tw'):
43
- $shortcode_html .='<div id="csbwfs-tw" class="csbwfs-shortcode"><a href="javascript:" onclick="window.open(\'//twitter.com/share?url=\'+encodeURIComponent(location.href)+\'&text=\'+encodeURIComponent(document.title)+\'&jump=close\',\'_blank\',\'width=800,height=300\')" ><i class="csbwfs_twitter"></i></a></div>';
44
-
45
- endif;
46
-
47
- /** GP */
48
- if($btnsVal=='gp'):
49
- $shortcode_html .='<div id="csbwfs-gp" class="csbwfs-shortcode"><a href="javascript:" onclick="javascript:window.open(\'//plus.google.com/share?url=\'+encodeURIComponent(location.href)+\'&title=\'+encodeURIComponent(document.title)+\'&jump=close\',\'\',\'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=800\');return false;"><i class="csbwfs_plus"></i></a></div>';
50
- endif;
51
-
52
- /** LI */
53
- if($btnsVal=='li'):
54
- $shortcode_html .='<div id="csbwfs-li" class="csbwfs-shortcode"><a href="javascript:" onclick="javascript:window.open(\'//www.linkedin.com/shareArticle?mini=true&url=\'+encodeURIComponent(location.href)+\'&title=\'+encodeURIComponent(document.title)+\'&jump=close\',\'\',\'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=800\');return false;" ><i class="csbwfs_linkedin"></i></a></div>';
55
- endif;
56
-
57
- /** PIN */
58
- if($btnsVal=='pi'):
59
- $shortcode_html .='<div id="csbwfs-pin" class="csbwfs-shortcode"><a onclick="javascript:void((function(){var e=document.createElement(\'script\');e.setAttribute(\'type\',\'text/javascript\');e.setAttribute(\'charset\',\'UTF-8\');e.setAttribute(\'src\',\'//assets.pinterest.com/js/pinmarklet.js?r=\'+Math.random()*99999999);document.body.appendChild(e)})());" href="javascript:void(0);"><i class="csbwfs_pinterest"></i></a></div>';
60
- endif;
61
-
62
- /** Reddit */
63
- if($btnsVal=='re'):
64
- $shortcode_html .='<div id="csbwfs-re" class="csbwfs-shortcode"><a onclick="window.open(\'//reddit.com/submit?url=\'+encodeURIComponent(location.href)+\'&title=\'+encodeURIComponent(document.title)+\'&jump=close\',\'Reddit\',\'toolbar=0,status=0,width=1000,height=800\');" href="javascript:void(0);"><i class="csbwfs_reddit"></i></a></div>';
65
- endif;
66
-
67
- /** Stumbleupon */
68
- if($btnsVal=='st'):
69
- $shortcode_html .='<div id="csbwfs-st" class="csbwfs-shortcode"><a onclick="window.open(\'//www.stumbleupon.com/submit?url=\'+encodeURIComponent(location.href)+\'&title=\'+encodeURIComponent(document.title)+\'&jump=close\',\'Stumbleupon\',\'toolbar=0,status=0,width=1000,height=800\');" href="javascript:void(0);"><i class="csbwfs_stumbleupon"></i></a></div>';
70
- endif;
71
- /** YT */
72
- if($btnsVal=='yt'):
73
- $shortcode_html .='<div id="csbwfs-yt" class="csbwfs-shortcode"><a onclick="window.open(\''.get_option('csbwfs_ytPath').'\');" href="javascript:void(0);"><i class="csbwfs_youtube"></i></a></div>';
74
- endif;
75
- /** Mail*/
76
- if($btnsVal=='ml'):
77
- $shortcode_html .='<div id="csbwfs-ml" class="csbwfs-shortcode"><a onclick="javascript:window.location=(\'mailto:'.get_bloginfo('admin_email').'\'+\'?subject=\'+encodeURIComponent(document.title)+\'&body=\'+encodeURIComponent(location.href));" href="javascript:void(0);" ><i class="csbwfs_mail"></i></a></div>';
78
- endif;
79
- }
80
- $shortcode_html .='</div>'; //End #csbwfs-shortcode
81
- }
82
- return $shortcode_html;
83
- }
84
- }
85
- //init class
86
- new CsbwfsShortcodeClass(); //init
87
- endif;
1
+ <?php
2
+ /*
3
+ * Template files to define CSBWFS Shortcodes
4
+ * @add_shortcode()
5
+ * @do_shortcode()
6
+ * shortcode [csbwfs_buttons]
7
+ **/
8
+ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
9
+
10
+ if(!class_exists('CsbwfsShortcodeClass')):
11
+ class CsbwfsShortcodeClass {
12
+ /**
13
+ * Construct the plugin object
14
+ */
15
+ public function __construct()
16
+ {
17
+ // register actions
18
+ add_shortcode( 'csbwfs_buttons', array(&$this, 'csbwfs_shortcode_func' ) );
19
+ add_filter( 'widget_text', 'do_shortcode' );
20
+ } // END public function __construct
21
+
22
+
23
+ public function csbwfs_shortcode_style_func() {
24
+ echo '<style type="text/css">.csbwfs-shortcode a{box-shadow:inherit}.csbwfs-shortcode a i{display:inline-block;position:relative;width:35px;height:36px;background-image:url('.plugin_dir_url( __FILE__ ).'../images/minify-social.png)}.csbwfs-shortcode{display:inline-block;position:relative;width:auto;}i.csbwfs_facebook{background-position:68% 4%}i.csbwfs_twitter{background-position:14% 4%}i.csbwfs_plus{background-position:80% 4%}i.csbwfs_linkedin{background-position:92% 4%}i.csbwfs_pinterest{background-position:14% 19%}i.csbwfs_youtube{background-position:32% 4%}i.csbwfs_reddit{background-position:26% 19%}i.csbwfs_stumbleupon{background-position:2% 4%}i.csbwfs_mail{background-position:8% 19%}</style>';
25
+ }
26
+
27
+ public static function csbwfs_shortcode_func($atts) {
28
+ //[csbwfs_buttons buttons='fb,tw,gp,li,pi,yt,re,st,ml']
29
+ $shortcode_html = '';
30
+ $btnsordaryy = isset($atts['buttons']) ? explode(',',$atts['buttons']) : array();
31
+ $class = isset($atts['class']) ? $atts['class'] : '';
32
+ if(is_array($btnsordaryy) && count($btnsordaryy) > 0 ){
33
+ add_action( 'wp_footer', array(&$this,'csbwfs_shortcode_style_func' ));
34
+ $shortcode_html .= '<div id="csbwfs-shortcode" class="'.$class.'">';
35
+ foreach($btnsordaryy as $btnsVal)
36
+ {
37
+ /** FB */
38
+ if($btnsVal=='fb'):
39
+ $shortcode_html .='<div id="csbwfs-fb" class="csbwfs-shortcode"><a href="javascript:" onclick="javascript:window.open(\'//www.facebook.com/sharer/sharer.php?u=\'+encodeURIComponent(location.href)+\'&title=\'+encodeURIComponent(document.title)+\'&jump=close\', \'\', \'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=300,width=600\');return false;" target="_blank" ><i class="csbwfs_facebook"></i></a></div>';
40
+ endif;
41
+ /** TW */
42
+ if($btnsVal=='tw'):
43
+ $shortcode_html .='<div id="csbwfs-tw" class="csbwfs-shortcode"><a href="javascript:" onclick="window.open(\'//twitter.com/share?url=\'+encodeURIComponent(location.href)+\'&text=\'+encodeURIComponent(document.title)+\'&jump=close\',\'_blank\',\'width=800,height=300\')" ><i class="csbwfs_twitter"></i></a></div>';
44
+
45
+ endif;
46
+
47
+ /** LI */
48
+ if($btnsVal=='li'):
49
+ $shortcode_html .='<div id="csbwfs-li" class="csbwfs-shortcode"><a href="javascript:" onclick="javascript:window.open(\'//www.linkedin.com/shareArticle?mini=true&url=\'+encodeURIComponent(location.href)+\'&title=\'+encodeURIComponent(document.title)+\'&jump=close\',\'\',\'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=600,width=800\');return false;" ><i class="csbwfs_linkedin"></i></a></div>';
50
+ endif;
51
+
52
+ /** PIN */
53
+ if($btnsVal=='pi'):
54
+ $shortcode_html .='<div id="csbwfs-pin" class="csbwfs-shortcode"><a onclick="javascript:void((function(){var e=document.createElement(\'script\');e.setAttribute(\'type\',\'text/javascript\');e.setAttribute(\'charset\',\'UTF-8\');e.setAttribute(\'src\',\'//assets.pinterest.com/js/pinmarklet.js?r=\'+Math.random()*99999999);document.body.appendChild(e)})());" href="javascript:void(0);"><i class="csbwfs_pinterest"></i></a></div>';
55
+ endif;
56
+
57
+ /** Reddit */
58
+ if($btnsVal=='re'):
59
+ $shortcode_html .='<div id="csbwfs-re" class="csbwfs-shortcode"><a onclick="window.open(\'//reddit.com/submit?url=\'+encodeURIComponent(location.href)+\'&title=\'+encodeURIComponent(document.title)+\'&jump=close\',\'Reddit\',\'toolbar=0,status=0,width=1000,height=800\');" href="javascript:void(0);"><i class="csbwfs_reddit"></i></a></div>';
60
+ endif;
61
+
62
+ /** Stumbleupon */
63
+ if($btnsVal=='st'):
64
+ $shortcode_html .='<div id="csbwfs-st" class="csbwfs-shortcode"><a onclick="window.open(\'//www.stumbleupon.com/submit?url=\'+encodeURIComponent(location.href)+\'&title=\'+encodeURIComponent(document.title)+\'&jump=close\',\'Stumbleupon\',\'toolbar=0,status=0,width=1000,height=800\');" href="javascript:void(0);"><i class="csbwfs_stumbleupon"></i></a></div>';
65
+ endif;
66
+ /** YT */
67
+ if($btnsVal=='yt'):
68
+ $shortcode_html .='<div id="csbwfs-yt" class="csbwfs-shortcode"><a onclick="window.open(\''.get_option('csbwfs_ytPath').'\');" href="javascript:void(0);"><i class="csbwfs_youtube"></i></a></div>';
69
+ endif;
70
+ /** Mail*/
71
+ if($btnsVal=='ml'):
72
+ $shortcode_html .='<div id="csbwfs-ml" class="csbwfs-shortcode"><a onclick="javascript:window.location=(\'mailto:'.get_bloginfo('admin_email').'\'+\'?subject=\'+encodeURIComponent(document.title)+\'&body=\'+encodeURIComponent(location.href));" href="javascript:void(0);" ><i class="csbwfs_mail"></i></a></div>';
73
+ endif;
74
+ }
75
+ $shortcode_html .='</div>'; //End #csbwfs-shortcode
76
+ }
77
+ return $shortcode_html;
78
+ }
79
+ }
80
+ //init class
81
+ new CsbwfsShortcodeClass(); //init
82
+ endif;
 
 
 
 
 
readme.txt CHANGED
@@ -1,307 +1,307 @@
1
- === Custom Share Buttons with Floating Sidebar ===
2
- Contributors:india-web-developer
3
- Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=ZEMSYQUZRUK6A
4
- Tags: social share buttons,custom share buttons,facebook, twitter, google+,linkedin,Stumbleupon,Reddit,pinterest,Xing, social share floating sidebar
5
- Requires at least: 4.0
6
- Tested up to: 4.9.8
7
- Stable tag: 3.6
8
-
9
- A best =Social Share= plugin that help to increases traffic & engagement on your website.
10
-
11
- == Description ==
12
-
13
- = “custom-share-buttons-with-floating-sidebar” = It is a plugin to share your site among your friends through social sites and help to increases traffic on your website. This plugin supports 9 social networking websites.
14
-
15
- Using =custom-share-buttons-with-floating-sidebar= plugin, visitors can share your website on popular social networks such as Facebook, Twitter, Linkedin, Pinterest, Google+, Stumbleupon, Reddit, Youtube.
16
-
17
- https://youtu.be/tqnAPG5VfFY
18
-
19
- With this plugin, you can give users a tool to share your content, product details and other information with their own networks.
20
-
21
- More than 22 billion shares are viewed each and every day on the internet, with sharing becoming an increasingly important part of every website owner’s marketing strategies.
22
-
23
- Let your users share via their accounts on popular social networks. Install this free plugin to enable Social Sharing on your WordPress site and start driving high quality referrals to your website.
24
-
25
- It is a lightweight plugin. There is no external JS file added in this plugin so it will affect your site speed.
26
-
27
- You can add a social share floating sidebar with all social share buttons and Even you can change the share buttons images and their style from admin if you wish!.
28
-
29
-
30
- =Shortcode=
31
-
32
- [csbwfs_buttons buttons='fb,tw,gp,li,pi,yt,re,st,ml']
33
-
34
- fb-facebook,tw-twitter,gp-google-plus,li-linkedin,pi-pinterest,yt-youtube,re-reddit,st-stumbleupon,ml-mail
35
-
36
-
37
- **[I want upgrade to Pro Version](https://rgaddons.wordpress.com/custom-share-buttons-with-floating-sidebar-pro/)**
38
-
39
-
40
- = Features =
41
- * Shortcode
42
- * An options to add Custom Image of any social button.
43
- * An options to add background color of social button.
44
- * Floating Sidebar
45
- * Share Buttons to every post/page
46
- * Show/Hide options for any buttons
47
- * An options to edit message ("Show Buttons","Hide Buttons"...etc)
48
- * An options to set the position of Floating Sidebar (Left/Right/Bottom)
49
- * An options to set the position of Social Buttons (Left/Right)
50
- * An options to manage the style of the plugin
51
- * An option to disable sidebar for mobile
52
- * Advance feature of pinterest share buttons to share images.
53
- * An option to auto close sidebar buttons on page load
54
- * An option to hide "Share This!!" button on page/post
55
- * An option to define share buttons postion (above content/below content)
56
-
57
- = Go Pro =
58
-
59
- We have also released an addon of Custom Share Buttons With Floating Sidebar which not only demonstrates the flexibility of CSBWFS, but also adds some important features:
60
-
61
- PRO FEATURES :
62
-
63
- https://youtu.be/QUnxtCe95Ww
64
-
65
- * Responsive Floating Sidebar
66
- * Shortcode
67
- * An option to Hide Floating Sidebar On Home/Blog/Search/Category/Author pages
68
- * An option to Hide Floating Sidebar On any post type (i.e page,post,event,product…etc)
69
- * An option to Hide Floating Sidebar On any taxonomy type (support all custom taxonomy type)
70
- * An Option to Show/Hide sidebar on specific page/post and on any custom post type pages as well.
71
- * An option to Show Social Share Buttons On Home/Blog/Search/Category/Author pages
72
- * An option to Show Social Share Buttons on any taxonomy type (support all custom taxonomy type)
73
- * An Option to Show/Hide social share buttons on specific page/post and on any custom post type pages as well.
74
- * Responsive Light box Contact Form (for Mail Icon)
75
- * An option to add to any custom shortcode into light box
76
- * Advance feature for choose to pinterest share image
77
- * An option to enable to OG tags meta boxes for define to share window content(share title, share description &amp; share image path)
78
- * An option to set sidebar position (left/right/bottom) for mobile
79
- * An option to add social site official page URL for all social buttons
80
- * Extra Buttons (Xing,Instagram,Whatsapp,Digg,Yummly,Vk, Buffer, Line, Skype, RSS, Print, G-Mail, Blogger, Tumbler, Delicious, Weibo, Telegram, Google Translate, Phone &amp; SMS )
81
- * An option to define to twitter username as hash tag in share window.
82
- * An option to display share count(Facebook, StumbleUpon, Pinterest, Xing and Reddit)
83
- * An options to change to buttons image, title, background color and url (You can use any button as your own custom button)
84
- * An options to define sorting order for all buttons
85
- * 10 extra custom floating sidebar buttons with extra options (i.e you can define your own custom size for these buttons)
86
- * An option to show sum of total share count for all buttons
87
- * An option to remove mouse hover animation effect for all social buttons
88
- * An options to choose different style of sidebar
89
- * An option to define page specific sidebar position (Left/Right/Bottom) for all page
90
- * An option to choose custom styles of social share buttons
91
- * An option to define sidebar position for every page separately
92
- * An option to show/hide sidebar from any specific page
93
- * Faster support
94
-
95
- **[Upgrade to Pro Version](https://rgaddons.wordpress.com/custom-share-buttons-with-floating-sidebar-pro/)**
96
-
97
-
98
- For any query contact to **[plugin author](mailto:raghunath.0087@gmail.com)**
99
-
100
-
101
- == Installation ==
102
-
103
- Step 1.Dowanload the plugin and upload "custom-share-buttons-with-floating-sidebar" plugins file to plugin (`/wp-content/plugins/`) directory
104
-
105
- Step 2. Activate the plugin through the Plugins menu in WordPress
106
-
107
- Step 3. Go to Settings/"Social Share Buttons(CSBWFS)" and configure the plugin settings.
108
-
109
- == Frequently Asked Questions ==
110
- 1.) How add floating share buttons on my website?
111
-
112
- * After active the plugin you have must need to enable this plugin through the plugin settings.
113
-
114
- 2.) Can i change the custom share buttons images from admin?
115
-
116
- * Yes,admin can changes all social share custom buttons images if you wish, for that you have only need to define the buttons images path from plugins settings page.
117
-
118
- 3.) Can i disable the floating sidebar for mobile?
119
-
120
- * Yes,You can disable the floating sidebar by configure the plugin settings
121
-
122
- 4.) Can i define the top margin for share buttons block?
123
-
124
- * Yes, admin can define the top margin from plugin settings page
125
-
126
- 5.) Can we add the social share buttons on bottom of every post/pages?
127
-
128
- * Yes,you have only need to enable the "Social Share Button" from admin by plugin settings
129
-
130
- 6.) Can we add at a time only the "Floating Sidebar" OR "Social Share Buttons"?
131
-
132
- * Yes,You have need to enable at a time only one from both "Floating Sidebar" and "Social Share Buttons"
133
-
134
- 7.) Is this mobile friendly OR is this responsive plugin?
135
-
136
- * No,this is not a responsibe but you can use our csbwfs addon, Our CSBWFS ADDON is responsive with some new extra features.Please visit on this [site](https://rgaddons.wordpress.com/custom-share-buttons-with-floating-sidebar-pro/) for check full details about addon.
137
-
138
- 8.) Is there any option for show share count number for share buttons?
139
-
140
- * No, there are not an option for show share count number but you can use our csbwfs addon, In CSBWFS ADDON we have given an option.Please visit on this [site](https://rgaddons.wordpress.com/custom-share-buttons-with-floating-sidebar-pro/) for check full details about addon.
141
-
142
- 9.) Is there any option for show/hide share buttons OR floating sidebar on some specific pages?
143
-
144
- * No. this options are available in pro addon.
145
-
146
- 9.) Is there any shortcode of social share buttons?
147
-
148
- * Yes, [csbwfs_buttons]
149
-
150
- == Screenshots ==
151
-
152
- 1. screenshot-1.png
153
-
154
- 2. screenshot-2.png
155
-
156
- 3. screenshot-3.png
157
-
158
- 4. screenshot-4.png
159
-
160
- 5. screenshot-5.png
161
-
162
- 6. screenshot-6.png
163
-
164
- 7. screenshot-7.png
165
-
166
- 8. screenshot-8.png
167
-
168
- 9. screenshot-9.png
169
-
170
- == Changelog ==
171
-
172
- = 3.6 =
173
- * Tested with latest wordpress version 4.9.8
174
- * Optimized code and fixed some minor issues
175
-
176
- = 3.5 =
177
- * Tested with latest wordpress version 4.9.7
178
- * Fixed blog page share url issues
179
- * Optimized code
180
- * Released addon new version 3.5 with new features
181
-
182
- = 3.4 =
183
- * Tested with latest wordpress version 4.9.1
184
- * Optimized CSS of share buttons
185
- * Added an extra feature to Pinterest button for share to multi images
186
-
187
- = 3.3 =
188
- * Tested with latest wordpress version 4.8.2
189
- * Released addon new version 3.2 with new features
190
- * Fixed a minor bug
191
- * Optimized code
192
- = 3.2 =
193
- * Tested with latest wordpress version 4.8
194
- * Fixed a minor bug
195
- = 3.1 =
196
- * Tested with latest wordpress version 4.7.3
197
- * Added an option for define to button background color of social share buttons
198
- * Fixed show/hide buttons related bug
199
- * Released new addon verson 3.0
200
-
201
- = 3.0 =
202
- * Tested with latest wordpress version 4.7
203
- * Optimized plugin code
204
- = 2.9 =
205
- * Tested with latest wordpress version 4.6
206
- * optmized CSS
207
- * Released pro addon new verion 2.8
208
- = 2.8 =
209
- * Tested with latest wordpress version 4.5.3
210
- * Minify sidebar share buttons images.
211
- * optmized CSS
212
- * Released addon new verion 2.7
213
- = 2.7 =
214
- * Tested with latest wordpress version 4.5.2
215
- * Fixed linkdin button spelling error.
216
- * Fixed + sign issue for mail button
217
-
218
- = 2.6 =
219
- * Tested with latest wordpress version 4.5
220
- * Fixed buttons hover animation effect issue.
221
- * Optimized image, html and css
222
- * Updated home page conditions for show/hide social buttons
223
-
224
- = 2.5 =
225
- * Fixed upload image issue.
226
- * Added reset button for reset to images/title for sidebar and social buttons.
227
- * Optimized js code for floating sidebar
228
- * Optimized design and css of social share buttons
229
-
230
- = 2.4 =
231
- * Fixed share url issue for custom post type.
232
- * Fixed show/hide share buttons issues
233
- * Tested with wordpress latest version
234
-
235
- = 2.3 =
236
- * update code to display content into footer section
237
- * Added an option for define position of share buttons (below/above or content)
238
- * Fixed some minor js/css issue
239
-
240
- = 2.2 =
241
- * Fixed double time open share url issue
242
- * Added an option for auto close sidebar buttons on page load
243
- * Added an option for hide "Share This!!" button on page/post
244
-
245
- = 2.1 =
246
- * Fixed share buttons css issues
247
- * Fixed some minor js conflict issues
248
-
249
- = 2.0 =
250
- * Fixed pinterest share image issue
251
- * Fixed youtube buttons url issue
252
- * modify layout of plugin settings page
253
- * Added options for define the buttons image alt text
254
- * Released Pro Version 1.6
255
-
256
- = 1.9 =
257
- * Released Pro Version 1.3
258
- * Fixed all suggested issues by users
259
- * Fixed css conflict issues
260
- * Added Stumbleupon and Reddit buttons to social share buttons
261
- * Minify CSS
262
-
263
- = 1.8 =
264
- * Released Pro Version 1.1
265
- * Added new bottom position option for floating sidebar
266
- * Modify CSS
267
-
268
- = 1.7 =
269
- * Released Pro Version
270
- * Added an option disable floating sidebar on home page
271
- * Fixed share url issue on home page
272
-
273
- = 1.6 =
274
- * Added new option for disable floating sidebar for mobile site
275
- * Added two new Stumbleupon and Reddit buttons
276
- * Added options for define Pinterest Share images
277
- * Fixed show/hide button issue
278
-
279
- = 1.5 =
280
- * Make plugin settings page more stylish
281
- * Added a new option for remove show/hide buttions
282
- * Added an option for change position of social share buttons
283
- * Make "Share This!" button text editable
284
- * Add Youtube button
285
- * Change image opacity on hover
286
-
287
- = 1.4 =
288
- * Added an options for define the background color of custom social share buttons
289
- * Added a new options for show/hide the buttions, so now if you will be click on hide buttons and then go to next page OR reload same page,then buttons will be not publish in front end,so buttons status will be remain until you will not change the their status by click on show/hide buttons
290
- * Added an options for manage the general text (like "Show buttons", "Hide buttons"..etc)
291
- * Fixed some JS issues
292
-
293
- = 1.3 =
294
- * Added an options for add the social share buttons on bottom of the content on every post/pages
295
-
296
- = 1.2 =
297
- * Fixed button image gap issue for right position
298
- * Added new option for set the delay time to publish the share butttons
299
-
300
- = 1.1 =
301
- * Fixed the right float sidebar issue
302
- * Added new option for define the margin from TOP
303
- * Added the show/hide buttons
304
- * On Mail buttons :by default set current page title as a mail subject-line and page link in mail-body
305
-
306
- = 1.0 =
307
- * First stable release
1
+ === Custom Share Buttons with Floating Sidebar ===
2
+ Contributors:india-web-developer
3
+ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=ZEMSYQUZRUK6A
4
+ Tags: social share buttons,custom share buttons,facebook, twitter,linkedin,Stumbleupon,Reddit,pinterest,Xing, social share floating sidebar
5
+ Requires at least: 4.0
6
+ Tested up to: 5.1.1
7
+ Stable tag: 3.7
8
+
9
+ Share buttons with extra features to sharing your website posts/pages on Facebook, Twitter, Instagram, Whatsapp, Pinterest etc.
10
+
11
+ == Description ==
12
+
13
+ = “Most Popular Social Share Plugin” = to share your website among your friends through social sites( Facebook, Twitter, Instagram, Whatsapp, Pinterest etc.) and help you to quickly grow your business.
14
+
15
+ https://youtu.be/tqnAPG5VfFY
16
+
17
+ More than 22 billion shares are viewed each and every day on the internet, with sharing becoming an increasingly important part of every website owner’s marketing strategies.
18
+
19
+ With this plugin, you can give users a tool to share your website (posts/pages/products) via their accounts on popular social networks.
20
+
21
+ Install and start driving high quality referrals to your website.
22
+
23
+ You can display social share buttons on your website via floating sidebar. Easily Customizable & Extensible social share buttons and they will not affect your site speed as well.
24
+
25
+
26
+
27
+ =Shortcode=
28
+
29
+ [csbwfs_buttons buttons='fb,tw,li,pi,yt,re,st,ml']
30
+
31
+ fb-facebook,tw-twitter,li-linkedin,pi-pinterest,yt-youtube,re-reddit,st-stumbleupon,ml-mail
32
+
33
+
34
+ **[I want upgrade to Pro Version](https://rgaddons.wordpress.com/custom-share-buttons-with-floating-sidebar-pro/)**
35
+
36
+
37
+ = Features =
38
+ * Light weight (No extra JS/CSS)
39
+ * Shortcode
40
+ * An options to add Custom Image for any social button.
41
+ * An options to add background color for social button.
42
+ * Floating Sidebar
43
+ * Standard Share Buttons to every post/page
44
+ * Show/Hide options for any button
45
+ * An options to edit message ("Show Buttons","Hide Buttons"...etc)
46
+ * An options to set position of floating sidebar (Left/Right/Bottom)
47
+ * An options to set position of social buttons (Left/Right)
48
+ * An options to manage style of buttons
49
+ * An option to disable sidebar on mobile
50
+ * An advance feature for pinterest share buttons.
51
+ * An option to auto close sidebar buttons on page load
52
+ * An option to hide "Share This!!" button on page/post
53
+ * An option to show share buttons position (above content/below content)
54
+
55
+ = Go Pro =
56
+
57
+ We have also released an addon of Custom Share Buttons With Floating Sidebar which not only demonstrates the flexibility of free version, but also added some more important features.
58
+
59
+ PRO FEATURES :
60
+
61
+ https://youtu.be/QUnxtCe95Ww
62
+
63
+ * Responsive Floating Sidebar
64
+ * Shortcode
65
+ * An option to Hide Floating Sidebar On Home/Blog/Search/Category/Author pages
66
+ * An option to Hide Floating Sidebar On any post type (i.e page,post,event,product…etc)
67
+ * An option to Hide Floating Sidebar On any taxonomy type (support all custom taxonomy type)
68
+ * An Option to Show/Hide sidebar on specific page/post and on any custom post type pages as well.
69
+ * An option to Show Social Share Buttons On Home/Blog/Search/Category/Author pages
70
+ * An option to Show Social Share Buttons on any taxonomy type (support all custom taxonomy type)
71
+ * An Option to Show/Hide social share buttons on specific page/post and on any custom post type pages as well.
72
+ * Responsive Light box Contact Form (for Mail Icon)
73
+ * An option to define shortcode into light box popup
74
+ * An option to enable OG tags meta boxes to define share window content(share title, share description &amp; share image path)
75
+ * An option to set sidebar position (left/right/bottom) for mobile
76
+ * An option to add social website official page URL for all social buttons
77
+ * Extra Buttons (Xing,Instagram,Whatsapp,Digg,Yummly,Vk, Buffer, Line, Skype, RSS, Print, G-Mail, Blogger, Tumbler, Delicious, Weibo, Telegram, Google Translate, Phone &amp; SMS )
78
+ * An option to define twitter username as hash tag into share window.
79
+ * An option to display share count(Facebook, StumbleUpon, Pinterest, Xing and Reddit)
80
+ * An options to change social buttons image, title, background color and url (You can use any button as your own custom button)
81
+ * An options to define sorting order for all buttons
82
+ * 10 extra custom floating sidebar buttons with extra options (i.e you can define your own custom size for these buttons)
83
+ * An option to show sum of total share count for all buttons
84
+ * An options to choose different style of sidebar
85
+ * An option to define page specific sidebar position (Left/Right/Bottom) for all page
86
+ * An option to choose custom styles of social share buttons
87
+ * An option to define sidebar position for every page separately
88
+ * An option to show/hide sidebar from any specific page
89
+ * Faster support
90
+
91
+ **[Upgrade to Pro Version](https://rgaddons.wordpress.com/custom-share-buttons-with-floating-sidebar-pro/)**
92
+
93
+
94
+ For any query contact to **[plugin author](mailto:raghunath.0087@gmail.com)**
95
+
96
+
97
+ == Installation ==
98
+
99
+ Step 1.Dowanload the plugin and upload "custom-share-buttons-with-floating-sidebar" plugins file to plugin (`/wp-content/plugins/`) directory
100
+
101
+ Step 2. Activate the plugin through the Plugins menu in WordPress
102
+
103
+ Step 3. Go to Settings/"Social Share Buttons(CSBWFS)" and configure the plugin settings.
104
+
105
+ == Frequently Asked Questions ==
106
+ 1.) How add floating share buttons on my website?
107
+
108
+ * After active the plugin you have must need to enable this plugin through the plugin settings.
109
+
110
+ 2.) Can i change the custom share buttons images from admin?
111
+
112
+ * Yes,admin can changes all social share custom buttons images if you wish, for that you have only need to define the buttons images path from plugins settings page.
113
+
114
+ 3.) Can i disable the floating sidebar for mobile?
115
+
116
+ * Yes,You can disable the floating sidebar by configure the plugin settings
117
+
118
+ 4.) Can i define the top margin for share buttons block?
119
+
120
+ * Yes, admin can define the top margin from plugin settings page
121
+
122
+ 5.) Can we add the social share buttons on bottom of every post/pages?
123
+
124
+ * Yes,you have only need to enable the "Social Share Button" from admin by plugin settings
125
+
126
+ 6.) Can we add at a time only the "Floating Sidebar" OR "Social Share Buttons"?
127
+
128
+ * Yes,You have need to enable at a time only one from both "Floating Sidebar" and "Social Share Buttons"
129
+
130
+ 7.) Is this mobile friendly OR is this responsive plugin?
131
+
132
+ * No,this is not a responsibe but you can use our csbwfs addon, Our CSBWFS ADDON is responsive with some new extra features.Please visit on this [site](https://rgaddons.wordpress.com/custom-share-buttons-with-floating-sidebar-pro/) for check full details about addon.
133
+
134
+ 8.) Is there any option for show share count number for share buttons?
135
+
136
+ * No, there are not an option for show share count number but you can use our csbwfs addon, In CSBWFS ADDON we have given an option.Please visit on this [site](https://rgaddons.wordpress.com/custom-share-buttons-with-floating-sidebar-pro/) for check full details about addon.
137
+
138
+ 9.) Is there any option for show/hide share buttons OR floating sidebar on some specific pages?
139
+
140
+ * No. this options are available in pro addon.
141
+
142
+ 9.) Is there any shortcode of social share buttons?
143
+
144
+ * Yes, [csbwfs_buttons]
145
+
146
+ == Screenshots ==
147
+
148
+ 1. screenshot-1.png
149
+
150
+ 2. screenshot-2.png
151
+
152
+ 3. screenshot-3.png
153
+
154
+ 4. screenshot-4.png
155
+
156
+ 5. screenshot-5.png
157
+
158
+ 6. screenshot-6.png
159
+
160
+ 7. screenshot-7.png
161
+
162
+ 8. screenshot-8.png
163
+
164
+ 9. screenshot-9.png
165
+
166
+ == Changelog ==
167
+
168
+ = 3.7 =
169
+ * Tested with latest wordpress version 5.1.1
170
+ * Removed Google+ button
171
+
172
+ = 3.6 =
173
+ * Tested with latest wordpress version 5.0.2
174
+ * Optimized code and fixed some minor issues
175
+
176
+ = 3.5 =
177
+ * Tested with latest wordpress version 4.9.7
178
+ * Fixed blog page share url issues
179
+ * Optimized code
180
+ * Released addon new version 3.5 with new features
181
+
182
+ = 3.4 =
183
+ * Tested with latest wordpress version 4.9.1
184
+ * Optimized CSS of share buttons
185
+ * Added an extra feature to Pinterest button for share to multi images
186
+
187
+ = 3.3 =
188
+ * Tested with latest wordpress version 4.8.2
189
+ * Released addon new version 3.2 with new features
190
+ * Fixed a minor bug
191
+ * Optimized code
192
+ = 3.2 =
193
+ * Tested with latest wordpress version 4.8
194
+ * Fixed a minor bug
195
+ = 3.1 =
196
+ * Tested with latest wordpress version 4.7.3
197
+ * Added an option for define to button background color of social share buttons
198
+ * Fixed show/hide buttons related bug
199
+ * Released new addon verson 3.0
200
+
201
+ = 3.0 =
202
+ * Tested with latest wordpress version 4.7
203
+ * Optimized plugin code
204
+ = 2.9 =
205
+ * Tested with latest wordpress version 4.6
206
+ * optmized CSS
207
+ * Released pro addon new verion 2.8
208
+ = 2.8 =
209
+ * Tested with latest wordpress version 4.5.3
210
+ * Minify sidebar share buttons images.
211
+ * optmized CSS
212
+ * Released addon new verion 2.7
213
+ = 2.7 =
214
+ * Tested with latest wordpress version 4.5.2
215
+ * Fixed linkdin button spelling error.
216
+ * Fixed + sign issue for mail button
217
+
218
+ = 2.6 =
219
+ * Tested with latest wordpress version 4.5
220
+ * Fixed buttons hover animation effect issue.
221
+ * Optimized image, html and css
222
+ * Updated home page conditions for show/hide social buttons
223
+
224
+ = 2.5 =
225
+ * Fixed upload image issue.
226
+ * Added reset button for reset to images/title for sidebar and social buttons.
227
+ * Optimized js code for floating sidebar
228
+ * Optimized design and css of social share buttons
229
+
230
+ = 2.4 =
231
+ * Fixed share url issue for custom post type.
232
+ * Fixed show/hide share buttons issues
233
+ * Tested with wordpress latest version
234
+
235
+ = 2.3 =
236
+ * update code to display content into footer section
237
+ * Added an option for define position of share buttons (below/above or content)
238
+ * Fixed some minor js/css issue
239
+
240
+ = 2.2 =
241
+ * Fixed double time open share url issue
242
+ * Added an option for auto close sidebar buttons on page load
243
+ * Added an option for hide "Share This!!" button on page/post
244
+
245
+ = 2.1 =
246
+ * Fixed share buttons css issues
247
+ * Fixed some minor js conflict issues
248
+
249
+ = 2.0 =
250
+ * Fixed pinterest share image issue
251
+ * Fixed youtube buttons url issue
252
+ * modify layout of plugin settings page
253
+ * Added options for define the buttons image alt text
254
+ * Released Pro Version 1.6
255
+
256
+ = 1.9 =
257
+ * Released Pro Version 1.3
258
+ * Fixed all suggested issues by users
259
+ * Fixed css conflict issues
260
+ * Added Stumbleupon and Reddit buttons to social share buttons
261
+ * Minify CSS
262
+
263
+ = 1.8 =
264
+ * Released Pro Version 1.1
265
+ * Added new bottom position option for floating sidebar
266
+ * Modify CSS
267
+
268
+ = 1.7 =
269
+ * Released Pro Version
270
+ * Added an option disable floating sidebar on home page
271
+ * Fixed share url issue on home page
272
+
273
+ = 1.6 =
274
+ * Added new option for disable floating sidebar for mobile site
275
+ * Added two new Stumbleupon and Reddit buttons
276
+ * Added options for define Pinterest Share images
277
+ * Fixed show/hide button issue
278
+
279
+ = 1.5 =
280
+ * Make plugin settings page more stylish
281
+ * Added a new option for remove show/hide buttions
282
+ * Added an option for change position of social share buttons
283
+ * Make "Share This!" button text editable
284
+ * Add Youtube button
285
+ * Change image opacity on hover
286
+
287
+ = 1.4 =
288
+ * Added an options for define the background color of custom social share buttons
289
+ * Added a new options for show/hide the buttions, so now if you will be click on hide buttons and then go to next page OR reload same page,then buttons will be not publish in front end,so buttons status will be remain until you will not change the their status by click on show/hide buttons
290
+ * Added an options for manage the general text (like "Show buttons", "Hide buttons"..etc)
291
+ * Fixed some JS issues
292
+
293
+ = 1.3 =
294
+ * Added an options for add the social share buttons on bottom of the content on every post/pages
295
+
296
+ = 1.2 =
297
+ * Fixed button image gap issue for right position
298
+ * Added new option for set the delay time to publish the share butttons
299
+
300
+ = 1.1 =
301
+ * Fixed the right float sidebar issue
302
+ * Added new option for define the margin from TOP
303
+ * Added the show/hide buttons
304
+ * On Mail buttons :by default set current page title as a mail subject-line and page link in mail-body
305
+
306
+ = 1.0 =
307
+ * First stable release