array('icon' => 'e-social-mail', 'title'=> LAN_SOCIAL_002, 'url' => "mailto:EMAIL_RECIPIENT?subject=[t]&body=".rawurlencode($emailMessage)."[u]"), 'facebook-like' => array('icon' => 'e-social-thumbs-up', 'title'=> $tp->lanVars(LAN_SOCIAL_001, "Facebook"), 'url' => "http://www.facebook.com/plugins/like.php?href=[u]"), 'facebook-share' => array('icon' => 'e-social-facebook', 'title'=> $tp->lanVars(LAN_SOCIAL_000, "Facebook"), 'url' => "http://www.facebook.com/sharer.php?u=[u]&t=[t]"), 'twitter' => array('icon' => 'e-social-twitter', 'title'=> $tp->lanVars(LAN_SOCIAL_000, "Twitter"), 'url' => "http://twitter.com/share?url=[u]&text=[t]"), 'google-plus1' => array('icon' => 'e-social-gplus', 'title'=> LAN_SOCIAL_003, 'url' => "https://apis.google.com/_/+1/fastbutton?usegapi=1&size=large&hl=en&url=[u]"), // 'google-plus' => array('icon' => 'fa-google-plus', 'title'=>"On Google Plus", 'url' => "https://plusone.google.com/_/+1/confirm?hl=en&url=[u]"), 'linkedin' => array('icon' => 'e-social-linkedin', 'title'=> $tp->lanVars(LAN_SOCIAL_000, "LinkedIn"), 'url' => "http://www.linkedin.com/shareArticle?mini=true&url=[u]"), 'pinterest' => array('icon' => 'e-social-pinterest', 'title'=> $tp->lanVars(LAN_SOCIAL_000, "Pinterest"), 'url' => "http://www.pinterest.com/pin/create/button/?url=[u]&description=[t]&media=[m]"), 'stumbleupon' => array('icon' => 'e-social-stumbleupon', 'title'=> $tp->lanVars(LAN_SOCIAL_000, "StumbleUpon"), 'url' => "http://www.stumbleupon.com/submit?url=[u]&title=[t]"), 'reddit' => array('icon' => 'e-social-reddit', 'title'=> $tp->lanVars(LAN_SOCIAL_000, "Reddit"), 'url' => "http://reddit.com/submit?url=[u]&title=[t]"), 'digg' => array('icon' => 'e-social-digg', 'title'=> $tp->lanVars(LAN_SOCIAL_000, "Digg"), 'url' => "http://www.digg.com/submit?url=[u]"), 'tumblr' => array('icon' => 'e-social-tumblr', 'title'=> $tp->lanVars(LAN_SOCIAL_000, "Tumblr"), 'url' => "http://www.tumblr.com/share?v=3&u=[u]&t=[t]&s="), 'pocket' => array('icon' => 'e-social-pocket', 'title'=> $tp->lanVars(LAN_SOCIAL_004, "Pocket"), 'url' => "https://getpocket.com/save?url=[u]&title=[t]"), 'wordpress' => array('icon' => 'e-social-wordpress', 'title'=> $tp->lanVars(LAN_SOCIAL_000, "Wordpress"), 'url' => "http://wordpress.com/press-this.php?u=[u]&t=[t]&s=[t]"), 'pinboard' => array('icon' => 'e-social-pinboard', 'title'=> $tp->lanVars(LAN_SOCIAL_004, "Pinboard"), 'url' => "https://pinboard.in/popup_login/?url=[u]&title=[t]&description=[t]"), // 'whatsapp' =>array('icon' => 'e-social-whatsapp', 'mobile'=>true, 'title'=> $tp->lanVars(LAN_SOCIAL_000, "WhatsApp"), 'url'=> "whatsapp://send?text=[u]", 'data-action' =>"share/whatsapp/share"), // 'sms' => array('icon' => 'e-social-sms', 'mobile'=>true, 'title'=>'sms', 'url'=> "sms://&body=[u]"), // 'viber' => array('icon' => 'e-social-viber', 'mobile'=>true, 'title'=>'viber', 'url'=>"viber://forward?text=[u]") ); return $providers; } /** * {XURL_ICONS: size=2x} * {XURL_ICONS: type=facebook,twitter,vimeo} */ function sc_xurl_icons($parm='') { $tp = e107::getParser(); $template = e107::getTemplate('social','social','xurl_icons'); $social = array( 'rss' => array('href'=> (e107::isInstalled('rss_menu') ? e107::url('rss_menu', 'index', array('rss_url'=>'news')) : ''), 'title'=>'RSS/Atom Feed'), 'facebook' => array('href'=> deftrue('XURL_FACEBOOK'), 'title'=>'Facebook'), 'twitter' => array('href'=> deftrue('XURL_TWITTER'), 'title'=>'Twitter'), 'google-plus' => array('href'=> deftrue('XURL_GOOGLE'), 'title'=>'Google Plus'), 'linkedin' => array('href'=> deftrue('XURL_LINKEDIN'), 'title'=>'LinkedIn'), 'github' => array('href'=> deftrue('XURL_GITHUB'), 'title'=>'Github'), 'pinterest' => array('href'=> deftrue('XURL_PINTEREST'), 'title'=>'Pinterest'), 'flickr' => array('href'=> deftrue('XURL_FLICKR'), 'title'=>'Flickr'), 'instagram' => array('href'=> deftrue('XURL_INSTAGRAM'), 'title'=>'Instagram'), 'youtube' => array('href'=> deftrue('XURL_YOUTUBE'), 'title'=>'YouTube'), 'vimeo' => array('href'=> deftrue('XURL_VIMEO'), 'title'=>'Vimeo') ); $class = (vartrue($parm['size'])) ? 'fa-'.$parm['size'] : ''; // @deprecated - use template. /* $tooltipPos = vartrue($parm['tip-pos'], 'top'); if(isset($parm['tip'])) { $tooltip = ($parm['tip'] == 'false' || empty($parm['tooltip'])) ? '' : 'e-tip'; } else { $tooltip = 'e-tip'; } */ if(!empty($parm['type'])) { $newList = array(); $tmp = explode(",",$parm['type']); foreach($tmp as $v) { $newList[$v] = $social[$v]; } $social = $newList; } $text = ''; foreach($social as $id => $data) { if(!empty($data['href'])) { $data['id'] = $id; $data['class'] = $class; $this->setVars($data); // $text .= ''; $text .= $tp->parseTemplate($template['item'],true, $this); $text .= "\n"; } } if(!empty($text)) { return $tp->parseTemplate($template['start'],true). $text.$tp->parseTemplate($template['end'],true); } return null; } // ----------- Internal Use only by sc_xurl_icons() ------------------ function sc_xurl_icons_href($parm=null) { return $this->var['href']; } function sc_xurl_icons_id($parm=null) { return $this->var['id']; } function sc_xurl_icons_title($parm=null) { return $this->var['title']; } function sc_xurl_icons_class($parm=null) { return $this->var['class']; } // ------------------------------------------------ function sc_social_login($parm=null) { $pref = e107::pref('core', 'social_login_active'); if(empty($pref)) { return; } $sc = e107::getScBatch('signup'); $text = ''; if(!empty($parm['label'])) { $text .= "
".LAN_PLUGIN_SOCIAL_SIGNIN."
"; } $text .= $sc->sc_signup_xup_login($parm); $text .= "