From 5e439194209c810b446286cc1a6436856b7110c3 Mon Sep 17 00:00:00 2001 From: Cameron Date: Sat, 21 May 2016 10:05:28 -0700 Subject: [PATCH] Corrected Social LANs. --- e107_plugins/social/e_shortcode.php | 22 ++++++++++--------- .../languages/English/English_admin.php | 3 +-- .../languages/English/English_front.php | 5 ++--- .../languages/English/English_global.php | 1 - 4 files changed, 15 insertions(+), 16 deletions(-) diff --git a/e107_plugins/social/e_shortcode.php b/e107_plugins/social/e_shortcode.php index e97e3d8ff..db786eea8 100644 --- a/e107_plugins/social/e_shortcode.php +++ b/e107_plugins/social/e_shortcode.php @@ -20,21 +20,23 @@ class social_shortcodes extends e_shortcode $emailMessage = LAN_SOCIAL_LINK_CHK; + $tp = e107::getParser(); + $providers = array( - 'email' => 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'=>" ".LAN_SOCIAL_001." Facebook", 'url' => "http://www.facebook.com/plugins/like.php?href=[u]"), - 'facebook-share' => array('icon' => 'e-social-facebook', 'title'=>" ".LAN_SOCIAL_000." Facebook", 'url' => "http://www.facebook.com/sharer.php?u=[u]&t=[t]"), - 'twitter' => array('icon' => 'e-social-twitter', 'title'=>"".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]"), + 'email' => 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'=>"".LAN_SOCIAL_000." LinkedIn", 'url' => "http://www.linkedin.com/shareArticle?mini=true&url=[u]"), - 'pinterest' => array('icon' => 'e-social-pinterest', 'title'=>"".LAN_SOCIAL_000." Pinterest", 'url' => "http://www.pinterest.com/pin/create/button/?url=[u]&description=[t]&media=[m]"), + '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]"), // 'thumblr' => array('icon' => 'fa-tumblr', 'title'=>"On Tumblr", 'url' => "http://www.tumblr.com/share/link?url=[u]&name=[t]&description=[d]"), - 'stumbleupon' => array('icon' => 'e-social-stumbleupon', 'title'=>"".LAN_SOCIAL_000." StumbleUpon",'url' => "http://www.stumbleupon.com/submit?url=[u]&title=[t]"), - 'reddit' => array('icon' => 'e-social-reddit', 'title'=>"".LAN_SOCIAL_000." Reddit", 'url' => "http://reddit.com/submit?url=[u]&title=[t]"), - 'digg' => array('icon' => 'e-social-digg', 'title'=>"".LAN_SOCIAL_000." Digg", 'url' => "http://www.digg.com/submit?url=[u]"), + '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]"), //http://reddit.com/submit?url=http%3A%2F%2Fwebsite.com&title=Website%20Title // no fa icon available //http://www.digg.com/submit?url=http%3A%2F%2Fwebsite.com // no fa icon available diff --git a/e107_plugins/social/languages/English/English_admin.php b/e107_plugins/social/languages/English/English_admin.php index 64fd8fe51..bc7776ab2 100644 --- a/e107_plugins/social/languages/English/English_admin.php +++ b/e107_plugins/social/languages/English/English_admin.php @@ -15,7 +15,7 @@ define("LAN_SOCIAL_ADMIN_04", "Provider"); define("LAN_SOCIAL_ADMIN_05", "Key/ID"); define("LAN_SOCIAL_ADMIN_06", "Secret"); define("LAN_SOCIAL_ADMIN_07", "Allows users to signup/login with their social media accounts. When enabled, this option will still allow users to signup/login even if the core user registration system above is disabled."); -define("LAN_SOCIAL_ADMIN_08", "Note: In most cases you will need to obtain an id and secret key from one of the providers.
Click the blue links to the right to configure.

You may test your configuration with the following URL:"); +define("LAN_SOCIAL_ADMIN_08", "Note: In most cases you will need to obtain an id and secret key from one of the providers.\nClick the blue links to the right to configure.\n\nYou may test your configuration with the following URL:"); define("LAN_SOCIAL_ADMIN_09", "Your callback URL is: "); define("LAN_SOCIAL_ADMIN_10", "Get a key from the provider"); define("LAN_SOCIAL_ADMIN_11", "Your"); @@ -46,4 +46,3 @@ define("LAN_SOCIAL_ADMIN_35", "Light"); define("LAN_SOCIAL_ADMIN_36", "Dark"); -?> \ No newline at end of file diff --git a/e107_plugins/social/languages/English/English_front.php b/e107_plugins/social/languages/English/English_front.php index cd26e8165..bfe5ee15c 100644 --- a/e107_plugins/social/languages/English/English_front.php +++ b/e107_plugins/social/languages/English/English_front.php @@ -7,8 +7,8 @@ +----------------------------------------------------------------------------+ */ //LAN_SOCIAL_000 to LAN_SOCIAL_099 // Common parts of the frontend -define("LAN_SOCIAL_000", "Share On"); -define("LAN_SOCIAL_001", "Like on"); +define("LAN_SOCIAL_000", "Share On [x]"); +define("LAN_SOCIAL_001", "Like on [x]"); define("LAN_SOCIAL_002", "Email to someone"); define("LAN_SOCIAL_003", "+1 on Google"); @@ -22,4 +22,3 @@ define("LAN_SOCIAL_201", "Tweets by"); define("LAN_SOCIAL_202", "Post to Twitter"); define("LAN_SOCIAL_203", "Type your tweet here."); -?> \ No newline at end of file diff --git a/e107_plugins/social/languages/English/English_global.php b/e107_plugins/social/languages/English/English_global.php index 53da5bccb..9e975f2ce 100644 --- a/e107_plugins/social/languages/English/English_global.php +++ b/e107_plugins/social/languages/English/English_global.php @@ -14,4 +14,3 @@ define("LAN_PLUGIN_SOCIAL_XUP_SIGNUP", "Sign-in with your [x] account"); define("LAN_PLUGIN_SOCIAL_XUP_REG", "Register with your [x] account"); -?> \ No newline at end of file