# share-button/0.9/classes/network/simple.php

Social Share Buttons, version 0.9. 157 lines.

- Page: https://pluginprobe.com/plugins/share-button/0.9/code/classes/network/simple.php
- Raw: https://pluginprobe.com/plugins/share-button/0.9/raw/classes/network/simple.php
- Modified: 2017-11-22T15:53:42+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/share-button/0.9/code/classes/network/simple.php#L10-L20`.

```php
<?php 
namespace MBSocial; 
defined('ABSPATH') or die('No direct access permitted');

/*
class blogLovingNetwork extends mbNetwork
{
	protected $network = 'blogloving';
	protected $icon = 'fa-bold';
	 
	
	public function __construct() 
	{
	
		$this->popup = false; 
	}
} */

class diggNetwork extends mbNetwork 
{
	protected $network = 'digg'; 
	protected $icon = 'fa-digg'; 
	protected $priority = 'readmore'; 	
	
	public function __construct() 
	{
		$this->label = __('Share', 'mbsocial'); 
		$this->share_url = 'http://digg.com/submit?url={url}&title={title}'; 
		$this->popup_dimensions = array(600,600); 
		
	}
}

class emailNetwork extends mbNetwork
{
	protected $network = 'email'; 
	protected $icon = 'fa-envelope'; 
	
	public function __construct() 
	{

		$this->label = __('Email', 'mbsocial');
		$this->share_url = 'mailto:?subject={title}&body={url}';
		$this->popup = false; 
		$this->countable = false;		
	}
}

class facebookNetwork extends mbNetwork
{
	protected $network = 'facebook'; 
	protected $icon = 'fa-facebook'; 
	
	public function __construct() 
	{
		$this->label = __('Share', 'mbsocial'); 
		$this->share_url = 'https://www.facebook.com/sharer.php?u={url}'; 
		$this->countable = true;
		$this->count_api = 'https://graph.facebook.com/{url}'; 
		$this->return_var = 'share|share_count'; 
		
	}
}



class linkedinNetwork extends mbNetwork 
{
	protected $network = 'linkedin'; 
	protected $icon = 'fa-linkedin'; 
	
	public function __construct() 
	{
		$this->label = __('Share','mbsocial');
		$this->share_url = 'https://www.linkedin.com/shareArticle?mini=true&url={url}'; 
		$this->count_api = 'https://www.linkedin.com/countserv/count/share?url={url}&format=json'; 
		$this->countable = true;
		$this->return_var = 'count'; 
		$this->popup_dimensions = array(700,500); 
	}

}
 

class printNetwork extends mbNetwork 
{
	protected $network = 'print'; 
	protected $icon = 'fa-print'; 

	public function __construct() 
	{
		$this->label = __('Print', 'mbsocial');
		$this->share_url = 'javascript:window.print()'; 
		$this->countable = false;
		$this->popup = false; 
	}
}


class stumbleuponNetwork extends mbNetwork 
{
	protected $network = 'stumbleupon'; 
	protected $priority = 'readmore'; 
	protected $icon = 'fa-stumbleupon'; 

	public function __construct() 
	{
		$this->label = __('Share','mbsocial');
		$this->share_url = 'https://www.stumbleupon.com/submit?url={url}&title={title}'; 
		$this->count_api = 'https://www.stumbleupon.com/services/1.01/badge.getinfo?url={url}'; 
		$this->countable = true;
		$this->return_var = 'result|views'; 
		
	
	}	
}

class redditNetwork extends mbNetwork 
{
	protected $network = 'reddit'; 
	protected $priority = 'readmore'; 
	protected $icon = 'fa-reddit'; 
	
	
	public function __construct() 
	{
		$this->label = __('Share', 'mbsocial');
		$this->share_url = 'https://reddit.com/submit?url={url}&title={title}'; 
		$this->count_api = 'https://buttons.reddit.com/button_info.json?url={url}'; 
		$this->countable = true;
		$this->return_var = 'data|children|0|data|score'; 
		$this->popup_dimensions = array(800,500); 
		
	
	}

}


class whatappNetwork extends mbNetwork 
{
	protected $network = 'whatsapp'; 
	protected $priority = 'readmore'; 
	protected $icon = 'fa-whatsapp'; 
	
	protected $displayDesktop = false;
	
	public function __construct() 
	{
		$this->label = __('Send', 'mbsocial');
		$this->share_url = 'whatsapp://send?text={url} {title}'; 
		$this->countable = false;
		
	}

}

```
