<?php









// no direct access



defined('_JEXEC') or die('Restricted access');
ini_set('display_errors',0);
$path=$_SERVER['HTTP_HOST'].$_SERVER[REQUEST_URI];
$button_style                 = $params->get('button_style');
$pubKey                       = $params->get('pubKey');
$widget_type                  = $params->get('widget_type');

$moduleclass_sfx = $params->get('moduleclass_sfx');





if(($widget_type)!=0)

			{

				/* New version of shareThis widget i.e. 5.x */

				$newWidget = "<script type='text/javascript'>var switchTo5x=true;</script>";

			} 

			else

			{

				/* Old version of shareThis widget 4.x */

				$newWidget ="";

			}

			echo $newWidget;

?>

<script type="text/javascript" src="http://w.sharethis.com/button/buttons.js"></script>

<script type="text/javascript">stLight.options({publisher:'<?php echo $pubKey; ?>'});</script>



<div class="joomla_sharethis<?php echo $moduleclass_sfx?>">



<!-- SHARETHIS BUTTON BEGIN -->



<?php

						  $notext="0";



	/* Button Style : Large Icons */

			if(($button_style)=='lg-icons')

			{

              $style="_large";

			}

			

			/* Button Style : Horizontal Count */

			if(($button_style)=='lg-horizontal')

			{

			              $style="_hcount";



			}

			

			/* Button Style : Vertical Count */

			if(($button_style)=='lg-vertical')

			{

			$style="_vcount";



			}

			

			/* Button Style : Classic */

			if(($button_style)=='sm-classic')

			{

				return "<span class='st_sharethis' displayText='ShareThis'></span>";

			}

			

			/* Button Style : Regular Buttons */

			if(($button_style)=='sm-regular')

			{

			 $style="";



			}

			

			/* Button Style : Regular Button No-Text */

			if(($button_style)=='sm-notext')

			{

			              $style="";

						  $notext="1";



			}

			

			/* Button Style : Buttons */

			if(($button_style)=='button')

			{

			              $style="_buttons";

			}



$facebook=$params->get('facebook');

if ($facebook=="yes")

{

$facebook="<span class='st_facebook".$style."' displayText='Facebook'></span>";

if($notext==1) {$facebook="<span class='st_facebook".$style."' ></span>";}



}

else

{

$facebook="";

}



$twitter=$params->get('twitter');

if ($twitter=="yes")

{

$twitter="<span class='st_twitter".$style."' displayText='Tweet'></span>";

if($notext==1) {$twitter="<span class='st_twitter".$style."'></span>";}

}

else

{

$twitter="";

}



$sharethis=$params->get('sharethis');

if ($sharethis=="yes")

{

$sharethis="<span class='st_sharethis".$style."' displayText='ShareThis'></span>";

if($notext==1) {$sharethis="<span class='st_sharethis".$style."'></span>";}



}

else

{

$sharethis="";

}





$email=$params->get('email');

if ($email=="yes")

{

$email="<span class='st_email".$style."' displayText='Email'></span>";

if($notext==1) {$email="<span class='st_email".$style."'></span>";}



}

else

{

$email="";

}





$plusone=$params->get('plusone');

if ($plusone=="yes")

{

$plusone="<span class='st_plusone".$style."' displayText='+1'></span>";

if($notext==1) {$plusone="<span class='st_plusone".$style."'></span>";}



}

else

{

$plusone="";

}



$fblike=$params->get('fblike');

if ($fblike=="yes")

{

$fblike="<span class='st_fblike".$style."' displayText='fblike'></span>";

if($notext==1) {$fblike="<span class='st_fblike".$style."'></span>";}



}

else

{

$fblike="";

}







$linkedin=$params->get('linkedin');

if ($linkedin=="yes")

{

$linkedin="<span class='st_linkedin".$style."' displayText='LinkedIn'></span>";

if($notext==1) {$linkedin="<span class='st_linkedin".$style."'></span>";}



}

else

{

$linkedin="";

}





$yahoo=$params->get('yahoo');

if ($yahoo=="yes")

{

$yahoo="<span class='st_yahoo".$style."' displayText='Yahoo'></span>";

if($notext==1) {$yahoo="<span class='st_yahoo".$style."'></span>";}



}

else

{

$yahoo="";

}



$gbuzz=$params->get('gbuzz');

if ($gbuzz=="yes")

{

$gbuzz="<span class='st_gbuzz".$style."' displayText='Gbuzz'></span>";

if($notext==1) {$gbuzz="<span class='st_gbuzz".$style."'></span>";}



}

else

{

$gbuzz="";

}



echo $linkedin.$facebook.$twitter.$yahoo.$gbuzz.$email.$sharethis.$plusone.$fblike;
?>
<!-- SHARETHIS BUTTON END -->


</div>