Version Notes
Twelth release of social login
Download this release
Release Info
Developer | LoginRadius Team |
Extension | LoginRadius |
Version | 3.6.0 |
Comparing to | |
See all releases |
Code changes from version 3.5.0 to 3.6.0
- app/code/community/Loginradius/Sociallogin/Block/Auth.php +5 -5
- app/code/community/Loginradius/Sociallogin/Block/horizontalsharing.php +4 -0
- app/code/community/Loginradius/Sociallogin/Model/Source/Iconsize.php +2 -2
- app/code/community/Loginradius/Sociallogin/Model/Source/SharingVerticalAlignment.php +4 -4
- app/code/community/Loginradius/Sociallogin/Model/Source/Uihover.php +5 -4
- app/code/community/Loginradius/Sociallogin/Model/Source/Uihover2.php +3 -3
- app/code/community/Loginradius/Sociallogin/Model/System/Config/Info.php +19 -19
- app/code/community/Loginradius/Sociallogin/controllers/IndexController.php +34 -20
- app/code/community/Loginradius/Sociallogin/controllers/Popup.php +21 -18
- app/code/community/Loginradius/Sociallogin/etc/config.xml +10 -1
- app/code/community/Loginradius/Sociallogin/etc/system.xml +22 -43
- app/code/community/Loginradius/Sociallogin/etc/widget.xml +9 -0
- app/code/community/Loginradius/Sociallogin/sql/sociallogin_setup/{mysql4-install-3.5.0.php → mysql4-install-3.6.0.php} +0 -0
- app/design/adminhtml/default/default/layout/loginradius_sociallogin.xml +1 -1
- app/design/frontend/default/default/layout/sociallogin.xml +1 -1
- app/design/frontend/default/default/template/sociallogin/abovelogin.phtml +4 -4
- app/design/frontend/default/default/template/sociallogin/aboveregister.phtml +4 -4
- app/design/frontend/default/default/template/sociallogin/belowlogin.phtml +4 -4
- app/design/frontend/default/default/template/sociallogin/belowregister.phtml +4 -4
- app/design/frontend/default/default/template/sociallogin/linking.phtml +9 -9
- app/design/frontend/default/default/template/sociallogin/sociallogin.phtml +5 -5
- app/design/frontend/default/default/template/sociallogin/sociallogincustom.phtml +3 -3
- app/design/frontend/default/default/template/sociallogin/socialshare_head.phtml +2 -2
- app/design/frontend/default/default/template/sociallogin/socialshareproduct.phtml +2 -2
- app/design/frontend/default/default/template/sociallogin/socialsharesuccess.phtml +1 -1
- package.xml +7 -7
- skin/frontend/base/default/Loginradius/Sociallogin/css/admin-ui.css +3 -0
- skin/frontend/base/default/Loginradius/Sociallogin/images/Sharing/Vertical/verticalhorizontal.png +0 -0
- skin/frontend/base/default/Loginradius/Sociallogin/images/Sharing/Vertical/verticalvertical.png +0 -0
- skin/frontend/base/default/Loginradius/Sociallogin/js/admin-ui.js +31 -0
app/code/community/Loginradius/Sociallogin/Block/Auth.php
CHANGED
@@ -9,15 +9,15 @@ class Loginradius_Sociallogin_Block_Auth extends Mage_Core_Block_Template implem
|
|
9 |
$ApiSecrete = trim($this->block_anyplace->getApiSecret());
|
10 |
$UserAuth = $this->block_anyplace->getApiResult($ApiKey, $ApiSecrete);
|
11 |
$titleText = $this->getLabelText();
|
12 |
-
$errormsg = '<p style ="color:red;">To activate your plugin, please log in to LoginRadius and get API Key & Secret. Web: <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
13 |
if ($this->block_anyplace->user_is_already_login()) {
|
14 |
$userName = Mage::getSingleton('customer/session')->getCustomer()->getName();
|
15 |
-
return '<span>Welcome!'.' '.$userName .'</span>';
|
16 |
}else{
|
17 |
if( $ApiKey == "" && $ApiSecrete == "" ){
|
18 |
return $errormsg;
|
19 |
}elseif( $UserAuth == false ){
|
20 |
-
return '<p style ="color:red;">Your LoginRadius API
|
21 |
}else {
|
22 |
$IsHttps = (!empty($UserAuth->IsHttps)) ? $UserAuth->IsHttps : '';
|
23 |
$iframeHeight = (!empty($UserAuth->height)) ? $UserAuth->height : 50;
|
@@ -25,9 +25,9 @@ class Loginradius_Sociallogin_Block_Auth extends Mage_Core_Block_Template implem
|
|
25 |
$http = ($IsHttps == 1) ? "https://" : "http://";
|
26 |
$loc = Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_LINK)."sociallogin/";
|
27 |
if (empty($titleText)) {
|
28 |
-
$titleText = 'Social Login';
|
29 |
}
|
30 |
-
$label = '<span ><b>' . $titleText . '</b></span>';
|
31 |
$iframe = '<div class="interfacecontainerdiv" style="margin-left:10px"></div>';
|
32 |
return $label.$iframe;
|
33 |
}
|
9 |
$ApiSecrete = trim($this->block_anyplace->getApiSecret());
|
10 |
$UserAuth = $this->block_anyplace->getApiResult($ApiKey, $ApiSecrete);
|
11 |
$titleText = $this->getLabelText();
|
12 |
+
$errormsg = '<p style ="color:red;">'. $this -> __('To activate your plugin, please log in to LoginRadius and get API Key & Secret. Web') .': <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
13 |
if ($this->block_anyplace->user_is_already_login()) {
|
14 |
$userName = Mage::getSingleton('customer/session')->getCustomer()->getName();
|
15 |
+
return '<span>'.__('Welcome').'!'.' '.$userName .'</span>';
|
16 |
}else{
|
17 |
if( $ApiKey == "" && $ApiSecrete == "" ){
|
18 |
return $errormsg;
|
19 |
}elseif( $UserAuth == false ){
|
20 |
+
return '<p style ="color:red;">'. $this -> __('Your LoginRadius API Key and Secret is not valid, please correct it or contact LoginRadius support at') .' <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
21 |
}else {
|
22 |
$IsHttps = (!empty($UserAuth->IsHttps)) ? $UserAuth->IsHttps : '';
|
23 |
$iframeHeight = (!empty($UserAuth->height)) ? $UserAuth->height : 50;
|
25 |
$http = ($IsHttps == 1) ? "https://" : "http://";
|
26 |
$loc = Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_LINK)."sociallogin/";
|
27 |
if (empty($titleText)) {
|
28 |
+
$titleText = __('Social Login');
|
29 |
}
|
30 |
+
$label = '<span ><b>' . __($titleText) . '</b></span>';
|
31 |
$iframe = '<div class="interfacecontainerdiv" style="margin-left:10px"></div>';
|
32 |
return $label.$iframe;
|
33 |
}
|
app/code/community/Loginradius/Sociallogin/Block/horizontalsharing.php
CHANGED
@@ -8,6 +8,10 @@ class Loginradius_Sociallogin_Block_Horizontalsharing extends Mage_Core_Block_Te
|
|
8 |
$content = "";
|
9 |
if ($this->loginRadiusHorizontalSharing->horizontalShareEnable() == "1" ){
|
10 |
$content = "<div class='loginRadiusHorizontalSharing'></div>";
|
|
|
|
|
|
|
|
|
11 |
}
|
12 |
return $content;
|
13 |
}
|
8 |
$content = "";
|
9 |
if ($this->loginRadiusHorizontalSharing->horizontalShareEnable() == "1" ){
|
10 |
$content = "<div class='loginRadiusHorizontalSharing'></div>";
|
11 |
+
$titleText = trim($this->getLabelText());
|
12 |
+
if($titleText != ""){
|
13 |
+
$content = "<div style='font-weight:bold'>" . __($titleText) . "</div>" . $content;
|
14 |
+
}
|
15 |
}
|
16 |
return $content;
|
17 |
}
|
app/code/community/Loginradius/Sociallogin/Model/Source/Iconsize.php
CHANGED
@@ -3,8 +3,8 @@ class Loginradius_Sociallogin_Model_Source_Iconsize
|
|
3 |
{
|
4 |
public function toOptionArray(){
|
5 |
$result = array();
|
6 |
-
$result[] = array('value' => 'medium', 'label'=>'Medium<br/>');
|
7 |
-
$result[] = array('value' => 'small', 'label'=>'Small<br/>');
|
8 |
return $result;
|
9 |
}
|
10 |
}
|
3 |
{
|
4 |
public function toOptionArray(){
|
5 |
$result = array();
|
6 |
+
$result[] = array('value' => 'medium', 'label'=>__('Medium').'<br/>');
|
7 |
+
$result[] = array('value' => 'small', 'label'=>__('Small').'<br/>');
|
8 |
return $result;
|
9 |
}
|
10 |
}
|
app/code/community/Loginradius/Sociallogin/Model/Source/SharingVerticalAlignment.php
CHANGED
@@ -4,10 +4,10 @@
|
|
4 |
public function toOptionArray()
|
5 |
{
|
6 |
$result = array();
|
7 |
-
$result[] = array('value' => 'top_left', 'label'=>'Top Left');
|
8 |
-
$result[] = array('value' => 'top_right', 'label'=>'Top Right');
|
9 |
-
$result[] = array('value' => 'bottom_left', 'label'=>'Bottom Left');
|
10 |
-
$result[] = array('value' => 'bottom_right', 'label'=>'Bottom Right');
|
11 |
return $result;
|
12 |
}
|
13 |
}
|
4 |
public function toOptionArray()
|
5 |
{
|
6 |
$result = array();
|
7 |
+
$result[] = array('value' => 'top_left', 'label'=>__('Top Left'));
|
8 |
+
$result[] = array('value' => 'top_right', 'label'=>__('Top Right'));
|
9 |
+
$result[] = array('value' => 'bottom_left', 'label'=>__('Bottom Left'));
|
10 |
+
$result[] = array('value' => 'bottom_right', 'label'=>__('Bottom Right'));
|
11 |
return $result;
|
12 |
}
|
13 |
}
|
app/code/community/Loginradius/Sociallogin/Model/Source/Uihover.php
CHANGED
@@ -3,9 +3,10 @@
|
|
3 |
{
|
4 |
public function toOptionArray(){
|
5 |
$result = array();
|
6 |
-
$result[] = array('value' => '
|
7 |
-
|
8 |
-
$result[] = array('value' => '
|
9 |
-
|
|
|
10 |
}
|
11 |
}
|
3 |
{
|
4 |
public function toOptionArray(){
|
5 |
$result = array();
|
6 |
+
$result[] = array('value' => 'same', 'label'=>__('Redirect to same page where the user logged in').'<br/>');
|
7 |
+
$result[] = array('value' => 'account', 'label'=>__('Redirect to account page').'<br/>');
|
8 |
+
$result[] = array('value' => 'index', 'label'=>__('Redirect to home page').'<br/>');
|
9 |
+
$result[] = array('value' => 'custom', 'label'=>__('Redirect to following url') );
|
10 |
+
return $result;
|
11 |
}
|
12 |
}
|
app/code/community/Loginradius/Sociallogin/Model/Source/Uihover2.php
CHANGED
@@ -4,9 +4,9 @@
|
|
4 |
public function toOptionArray()
|
5 |
{
|
6 |
$result = array();
|
7 |
-
$result[] = array('value' => 'varien', 'label'=>'Use "http_varien_client"');
|
8 |
-
$result[] = array('value' => 'curl', 'label'=>'Use cURL');
|
9 |
-
$result[] = array('value' => 'fopen', 'label'=>'Use FSOCKOPEN' );
|
10 |
return $result;
|
11 |
}
|
12 |
}
|
4 |
public function toOptionArray()
|
5 |
{
|
6 |
$result = array();
|
7 |
+
$result[] = array('value' => 'varien', 'label'=>__('Use').' "http_varien_client"');
|
8 |
+
$result[] = array('value' => 'curl', 'label'=>__('Use').' cURL');
|
9 |
+
$result[] = array('value' => 'fopen', 'label'=>__('Use').' FSOCKOPEN' );
|
10 |
return $result;
|
11 |
}
|
12 |
}
|
app/code/community/Loginradius/Sociallogin/Model/System/Config/Info.php
CHANGED
@@ -15,22 +15,22 @@ class Loginradius_Sociallogin_Model_System_Config_Info extends Mage_Adminhtml_Bl
|
|
15 |
?>
|
16 |
|
17 |
<fieldset class="loginRadiusFieldset" style="margin-right:13px; background-color:#EAF7FF; border-color:rgb(195, 239, 250); padding-bottom:25px; width:65%">
|
18 |
-
<h4 style="color:#000"><strong
|
19 |
-
<p
|
20 |
<p>
|
21 |
-
We also offer Social Plugins for <a href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms#wordpressplugin" target="_blank">Wordpress</a>, <a href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms#joomlaextension" target="_blank">Joomla</a>, <a href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms#drupalmodule" target="_blank">Drupal</a>, <a href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms#
|
22 |
</p>
|
23 |
<div style="margin-top:10px">
|
24 |
<a style="text-decoration:none;" href="https://www.loginradius.com/" target="_blank">
|
25 |
-
<input class="form-button" type="button" value="Set up my FREE account!">
|
26 |
</a>
|
27 |
-
<a class="loginRadiusHow" target="_blank" href="http://support.loginradius.com/customer/portal/articles/593954">(How to set up an account?)</a>
|
28 |
</div>
|
29 |
</fieldset>
|
30 |
<!-- Get Updates -->
|
31 |
<fieldset class="loginRadiusFieldset" style="width:26%; background-color: rgb(231, 255, 224); border: 1px solid rgb(191, 231, 176); padding-bottom:6px;">
|
32 |
-
<h4 style="border-bottom:#d7d7d7 1px solid;"><strong
|
33 |
-
<p
|
34 |
<div>
|
35 |
<div style="float:left">
|
36 |
<iframe rel="tooltip" scrolling="no" frameborder="0" allowtransparency="true" style="border: none; overflow: hidden; width: 46px;
|
@@ -41,28 +41,28 @@ class Loginradius_Sociallogin_Model_System_Config_Info extends Mage_Adminhtml_Bl
|
|
41 |
</fieldset>
|
42 |
<!-- Help & Documentation -->
|
43 |
<fieldset class="loginRadiusHelpDiv" style="margin-right:13px; width:65%">
|
44 |
-
<h4 style="border-bottom:#d7d7d7 1px solid;"><strong
|
45 |
<ul style="float:left; margin-right:43px">
|
46 |
-
<li><a target="_blank" href="http://support.loginradius.com/customer/portal/articles/1056696-magento-social-login-installation-configuration-and-troubleshooting"
|
47 |
-
<li><a target="_blank" href="http://support.loginradius.com/customer/portal/articles/677100-how-to-get-loginradius-api-key-and-secret"
|
48 |
-
<li><a target="_blank" href="http://support.loginradius.com/customer/portal/articles/1056696-magento-social-login-installation-configuration-and-troubleshooting#multisite"
|
49 |
-
<li><a target="_blank" href="
|
50 |
</ul>
|
51 |
<ul style="float:left; margin-right:43px">
|
52 |
-
<li><a target="_blank" href="http://community.loginradius.com/"
|
53 |
-
<li><a target="_blank" href="http://www.loginradius.com/loginradius/about"
|
54 |
-
<li><a target="_blank" href="
|
55 |
-
<li><a target="_blank" href="
|
56 |
</ul>
|
57 |
</fieldset>
|
58 |
<!-- Support Us -->
|
59 |
<fieldset class="loginRadiusFieldset" style="margin-right:5px; background-color: rgb(231, 255, 224); border: 1px solid rgb(191, 231, 176); width:26%; height:112px">
|
60 |
-
<h4 style="border-bottom:#d7d7d7 1px solid;"><strong
|
61 |
<p>
|
62 |
-
If you liked our FREE open-source plugin, please send your feedback/testimonial to <a href="mailto:feedback@loginradius.com">feedback@loginradius.com</a> !</p>
|
63 |
</fieldset>
|
64 |
<div style='clear:both'></div>
|
65 |
-
<div id="loginRadiusKeySecretNotification" style="background-color: rgb(255, 255, 224); border: 1px solid rgb(230, 219, 85); padding: 5px; margin-bottom: 11px; display:none"
|
66 |
<div style='clear:both'></div>
|
67 |
<script type="text/javascript">var islrsharing = true; var islrsocialcounter = true;</script>
|
68 |
<script type="text/javascript" src="//share.loginradius.com/Content/js/LoginRadius.js" id="lrsharescript"></script>
|
15 |
?>
|
16 |
|
17 |
<fieldset class="loginRadiusFieldset" style="margin-right:13px; background-color:#EAF7FF; border-color:rgb(195, 239, 250); padding-bottom:25px; width:65%">
|
18 |
+
<h4 style="color:#000"><strong><?php echo $this -> __('Thank you for installing the LoginRadius Social Plugin!') ?></strong></h4>
|
19 |
+
<p><?php echo $this -> __('To activate the extension, you will need to first configure it (manage your desired social networks, etc.) from your LoginRadius account. If you do not have an account, click') ?> <a target="_blank" href="http://www.loginradius.com/"><?php echo $this -> __('here') ?></a> <?php echo $this -> __('and create one for FREE!') ?></p>
|
20 |
<p>
|
21 |
+
<?php echo $this -> __('We also offer Social Plugins for') ?> <a href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms#wordpressplugin" target="_blank">Wordpress</a>, <a href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms#joomlaextension" target="_blank">Joomla</a>, <a href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms#drupalmodule" target="_blank">Drupal</a>, <a href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms#vbulletinplugin" target="_blank">vBulletin</a>, <a href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms#vanillaaddons" target="_blank">VanillaForum</a>, <a href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms#osCommerceaddons" target="_blank">osCommerce</a>, <a href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms#prestashopmodule" target="_blank">PrestaShop</a>, <a href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms#xcartextension" target="_blank">X-Cart</a>, <a href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms#zencartplugin" target="_blank">Zen-Cart</a> <?php echo $this -> __('and') ?> <a href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms#dotnetnukemodule" target="_blank">DotNetNuke</a>!
|
22 |
</p>
|
23 |
<div style="margin-top:10px">
|
24 |
<a style="text-decoration:none;" href="https://www.loginradius.com/" target="_blank">
|
25 |
+
<input class="form-button" type="button" value="<?php echo $this -> __('Set up my FREE account!') ?>">
|
26 |
</a>
|
27 |
+
<a class="loginRadiusHow" target="_blank" href="http://support.loginradius.com/customer/portal/articles/593954">(<?php echo $this -> __('How to set up an account?') ?>)</a>
|
28 |
</div>
|
29 |
</fieldset>
|
30 |
<!-- Get Updates -->
|
31 |
<fieldset class="loginRadiusFieldset" style="width:26%; background-color: rgb(231, 255, 224); border: 1px solid rgb(191, 231, 176); padding-bottom:6px;">
|
32 |
+
<h4 style="border-bottom:#d7d7d7 1px solid;"><strong><?php echo $this -> __('Get Updates') ?></strong></h4>
|
33 |
+
<p><?php echo $this -> __('To receive updates on new features, future releases, etc, please connect with us via Facebook-') ?></p>
|
34 |
<div>
|
35 |
<div style="float:left">
|
36 |
<iframe rel="tooltip" scrolling="no" frameborder="0" allowtransparency="true" style="border: none; overflow: hidden; width: 46px;
|
41 |
</fieldset>
|
42 |
<!-- Help & Documentation -->
|
43 |
<fieldset class="loginRadiusHelpDiv" style="margin-right:13px; width:65%">
|
44 |
+
<h4 style="border-bottom:#d7d7d7 1px solid;"><strong><?php echo $this -> __('Help & Documentations') ?></strong></h4>
|
45 |
<ul style="float:left; margin-right:43px">
|
46 |
+
<li><a target="_blank" href="http://support.loginradius.com/customer/portal/articles/1056696-magento-social-login-installation-configuration-and-troubleshooting"><?php echo $this -> __('Extension Installation, Configuration and Troubleshooting') ?></a></li>
|
47 |
+
<li><a target="_blank" href="http://support.loginradius.com/customer/portal/articles/677100-how-to-get-loginradius-api-key-and-secret"><?php echo $this -> __('How to get LoginRadius API Key & Secret') ?></a></li>
|
48 |
+
<li><a target="_blank" href="http://support.loginradius.com/customer/portal/articles/1056696-magento-social-login-installation-configuration-and-troubleshooting#multisite"><?php echo $this -> __('Magento Multisite Feature') ?></a></li>
|
49 |
+
<li><a target="_blank" href="https://www.loginradius.com/loginradius/product-overview"><?php echo $this -> __('LoginRadius Products') ?></a></li>
|
50 |
</ul>
|
51 |
<ul style="float:left; margin-right:43px">
|
52 |
+
<li><a target="_blank" href="http://community.loginradius.com/"><?php echo $this -> __('Discussion Forum') ?></a></li>
|
53 |
+
<li><a target="_blank" href="http://www.loginradius.com/loginradius/about"><?php echo $this -> __('About LoginRadius') ?></a></li>
|
54 |
+
<li><a target="_blank" href="https://www.loginradius.com/loginradius-for-developers/loginRadius-cms"><?php echo $this -> __('Social Plugins') ?></a></li>
|
55 |
+
<li><a target="_blank" href="https://www.loginradius.com/loginradius-for-developers/loginRadius-sdks"><?php echo $this -> __('Social SDKs') ?></a></li>
|
56 |
</ul>
|
57 |
</fieldset>
|
58 |
<!-- Support Us -->
|
59 |
<fieldset class="loginRadiusFieldset" style="margin-right:5px; background-color: rgb(231, 255, 224); border: 1px solid rgb(191, 231, 176); width:26%; height:112px">
|
60 |
+
<h4 style="border-bottom:#d7d7d7 1px solid;"><strong><?php echo $this -> __('Support Us') ?></strong></h4>
|
61 |
<p>
|
62 |
+
<?php echo $this -> __('If you liked our FREE open-source plugin, please send your feedback/testimonial to') ?> <a href="mailto:feedback@loginradius.com">feedback@loginradius.com</a> !</p>
|
63 |
</fieldset>
|
64 |
<div style='clear:both'></div>
|
65 |
+
<div id="loginRadiusKeySecretNotification" style="background-color: rgb(255, 255, 224); border: 1px solid rgb(230, 219, 85); padding: 5px; margin-bottom: 11px; display:none"><?php echo $this -> __('To activate the <strong>Social Login</strong>, insert LoginRadius API Key and Secret in the <strong>Social Login Basic Settings</strong> section below. <strong>Social Sharing does not require API Key and Secret</strong>') ?>.</div>
|
66 |
<div style='clear:both'></div>
|
67 |
<script type="text/javascript">var islrsharing = true; var islrsocialcounter = true;</script>
|
68 |
<script type="text/javascript" src="//share.loginradius.com/Content/js/LoginRadius.js" id="lrsharescript"></script>
|
app/code/community/Loginradius/Sociallogin/controllers/IndexController.php
CHANGED
@@ -19,14 +19,16 @@ class Loginradius_Sociallogin_IndexController extends Mage_Core_Controller_Front
|
|
19 |
$ApiSecrete = $this->blockObj->getApiSecret();
|
20 |
$user_obj = $this->blockObj->getProfileResult($ApiSecrete);
|
21 |
// validate the object
|
22 |
-
if(is_object($user_obj)){
|
23 |
$id = $user_obj->ID;
|
24 |
}else{
|
25 |
-
|
|
|
26 |
}
|
27 |
if(empty($id)){
|
28 |
//invalid user
|
29 |
-
|
|
|
30 |
}
|
31 |
// social linking variable
|
32 |
$socialLinking = false;
|
@@ -195,8 +197,8 @@ class Loginradius_Sociallogin_IndexController extends Mage_Core_Controller_Front
|
|
195 |
break;
|
196 |
}
|
197 |
}
|
198 |
-
}elseif(is_string($user_obj->Addresses)){
|
199 |
-
$socialloginProfileData['Address'] = $user_obj->Addresses != "" ? $user_obj->Addresses : "";
|
200 |
}else{
|
201 |
$socialloginProfileData['Address'] = "";
|
202 |
}
|
@@ -265,7 +267,13 @@ class Loginradius_Sociallogin_IndexController extends Mage_Core_Controller_Front
|
|
265 |
}
|
266 |
return $thumbnail;
|
267 |
}
|
268 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
269 |
function socialLoginUserLogin( $entityId, $socialId ) {
|
270 |
$session = Mage::getSingleton("customer/session");
|
271 |
$session->loginById($entityId);
|
@@ -292,7 +300,11 @@ class Loginradius_Sociallogin_IndexController extends Mage_Core_Controller_Front
|
|
292 |
exit();
|
293 |
return;
|
294 |
}else{
|
295 |
-
$
|
|
|
|
|
|
|
|
|
296 |
header( 'Location: '.$currentUrl);
|
297 |
exit();
|
298 |
return;
|
@@ -306,7 +318,7 @@ class Loginradius_Sociallogin_IndexController extends Mage_Core_Controller_Front
|
|
306 |
|
307 |
function loginRadiusEmail( $subject, $message, $to, $toName ){
|
308 |
$storeName = Mage::app()->getStore()->getGroup()->getName();
|
309 |
-
$mail = new Zend_Mail(); //class for mail
|
310 |
$mail->setBodyHtml( $message ); //for sending message containing html code
|
311 |
$mail->setFrom( "Owner", $storeName );
|
312 |
$mail->addTo( $to, $toName );
|
@@ -401,6 +413,8 @@ class Loginradius_Sociallogin_IndexController extends Mage_Core_Controller_Front
|
|
401 |
$address->telephone = $socialloginProfileData['PhoneNumber'];
|
402 |
$address->company = ucfirst( $socialloginProfileData['Industry'] );
|
403 |
$address->street = ucfirst( $socialloginProfileData['Address'] );
|
|
|
|
|
404 |
$address->save();
|
405 |
}
|
406 |
// add info in sociallogin table
|
@@ -421,13 +435,13 @@ class Loginradius_Sociallogin_IndexController extends Mage_Core_Controller_Front
|
|
421 |
if( $this->blockObj->notifyUser() == "1" ){
|
422 |
$loginRadiusMessage = $this->blockObj->notifyUserText();
|
423 |
if( $loginRadiusMessage == "" ){
|
424 |
-
$loginRadiusMessage = "Welcome to ".$store->getGroup()->getName().". You can login to the store using following e-mail address and password:-";
|
425 |
}
|
426 |
$loginRadiusMessage .= "<br/>".
|
427 |
"Email : ".$socialloginProfileData['Email'].
|
428 |
-
"<br/>Password : ".$loginRadiusPwd;
|
429 |
|
430 |
-
$this->loginRadiusEmail( "Welcome ".$loginRadiusUsername."!", $loginRadiusMessage, $socialloginProfileData['Email'], $loginRadiusUsername );
|
431 |
}
|
432 |
// new user notification to admin
|
433 |
if( $this->blockObj->notifyAdmin() == "1" ){
|
@@ -435,12 +449,12 @@ class Loginradius_Sociallogin_IndexController extends Mage_Core_Controller_Front
|
|
435 |
$loginRadiusAdminName = Mage::getStoreConfig('trans_email/ident_general/name');
|
436 |
$loginRadiusMessage = trim($this->blockObj->notifyAdminText());
|
437 |
if( $loginRadiusMessage == "" ){
|
438 |
-
$loginRadiusMessage = "New customer has been registered to your store with following details:-";
|
439 |
}
|
440 |
$loginRadiusMessage .= "<br/>".
|
441 |
-
"Name : ".$loginRadiusUsername."<br/>".
|
442 |
-
"Email : ".$socialloginProfileData['Email'];
|
443 |
-
$this->loginRadiusEmail( "New User Registration", $loginRadiusMessage, $loginRadiusAdminEmail, $loginRadiusAdminName );
|
444 |
}
|
445 |
}
|
446 |
//login and redirect user
|
@@ -529,12 +543,12 @@ class Loginradius_Sociallogin_IndexController extends Mage_Core_Controller_Front
|
|
529 |
// insert details in sociallogin table
|
530 |
$this->SocialLoginInsert( "sociallogin", $data );
|
531 |
// send verification mail
|
532 |
-
$message = trim($this->blockObj->verificationText());
|
533 |
if( $message == "" ){
|
534 |
-
$message = "Please click on the following link or paste it in browser to verify your email:-";
|
535 |
}
|
536 |
$message .= "<br/>".Mage::getBaseUrl()."sociallogin/?loginRadiusKey=".$vKey;
|
537 |
-
$this->loginRadiusEmail( "Email verification", $message, $email, $email);
|
538 |
// show popup message
|
539 |
SL_popUpWindow( "Confirmation link Has Been Sent To Your Email Address. Please verify your email by clicking on confirmation link.", "", false );
|
540 |
$this->SocialLoginShowLayout();
|
@@ -544,9 +558,9 @@ class Loginradius_Sociallogin_IndexController extends Mage_Core_Controller_Front
|
|
544 |
public function indexAction() {
|
545 |
$this->blockObj = new Loginradius_Sociallogin_Block_Sociallogin();
|
546 |
$this->loginRadiusPopMsg = trim($this->blockObj->getPopupText() );
|
547 |
-
$this->loginRadiusPopMsg = $this->loginRadiusPopMsg == "" ? "Please enter your email to proceed" : $this->loginRadiusPopMsg;
|
548 |
$this->loginRadiusPopErr = trim($this->blockObj->getPopupError() );
|
549 |
-
$this->loginRadiusPopErr = $this->loginRadiusPopErr == "" ? "Email you entered is either invalid or already registered. Please enter a valid email." : $this->loginRadiusPopErr;
|
550 |
if(isset($_REQUEST['token'])) {
|
551 |
$this->tokenHandle();
|
552 |
$this->loadLayout();
|
19 |
$ApiSecrete = $this->blockObj->getApiSecret();
|
20 |
$user_obj = $this->blockObj->getProfileResult($ApiSecrete);
|
21 |
// validate the object
|
22 |
+
if(is_object($user_obj) && isset($user_obj->ID)){
|
23 |
$id = $user_obj->ID;
|
24 |
}else{
|
25 |
+
header('Location:' . Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_LINK));
|
26 |
+
exit();
|
27 |
}
|
28 |
if(empty($id)){
|
29 |
//invalid user
|
30 |
+
header('Location:' . Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_LINK));
|
31 |
+
exit();
|
32 |
}
|
33 |
// social linking variable
|
34 |
$socialLinking = false;
|
197 |
break;
|
198 |
}
|
199 |
}
|
200 |
+
}elseif(isset($user_obj->Addresses) && is_string($user_obj->Addresses)){
|
201 |
+
$socialloginProfileData['Address'] = isset($user_obj->Addresses) && $user_obj->Addresses != "" ? $user_obj->Addresses : "";
|
202 |
}else{
|
203 |
$socialloginProfileData['Address'] = "";
|
204 |
}
|
267 |
}
|
268 |
return $thumbnail;
|
269 |
}
|
270 |
+
/**
|
271 |
+
* Validate url.
|
272 |
+
*/
|
273 |
+
function login_radius_validate_url($url){
|
274 |
+
$validUrlExpression = "/^(http:\/\/|https:\/\/|ftp:\/\/|ftps:\/\/|)?[a-z0-9_\-]+[a-z0-9_\-\.]+\.[a-z]{2,4}(\/+[a-z0-9_\.\-\/]*)?$/i";
|
275 |
+
return (bool)preg_match($validUrlExpression, $url);
|
276 |
+
}
|
277 |
function socialLoginUserLogin( $entityId, $socialId ) {
|
278 |
$session = Mage::getSingleton("customer/session");
|
279 |
$session->loginById($entityId);
|
300 |
exit();
|
301 |
return;
|
302 |
}else{
|
303 |
+
if(isset($_GET['redirect_to'])){
|
304 |
+
$currentUrl = trim($_GET['redirect_to']);
|
305 |
+
}else{
|
306 |
+
$currentUrl = $url;
|
307 |
+
}
|
308 |
header( 'Location: '.$currentUrl);
|
309 |
exit();
|
310 |
return;
|
318 |
|
319 |
function loginRadiusEmail( $subject, $message, $to, $toName ){
|
320 |
$storeName = Mage::app()->getStore()->getGroup()->getName();
|
321 |
+
$mail = new Zend_Mail('UTF-8'); //class for mail
|
322 |
$mail->setBodyHtml( $message ); //for sending message containing html code
|
323 |
$mail->setFrom( "Owner", $storeName );
|
324 |
$mail->addTo( $to, $toName );
|
413 |
$address->telephone = $socialloginProfileData['PhoneNumber'];
|
414 |
$address->company = ucfirst( $socialloginProfileData['Industry'] );
|
415 |
$address->street = ucfirst( $socialloginProfileData['Address'] );
|
416 |
+
// set default billing, shipping address and save in address book
|
417 |
+
$address -> setIsDefaultShipping('1') -> setIsDefaultBilling('1') -> setSaveInAddressBook('1');
|
418 |
$address->save();
|
419 |
}
|
420 |
// add info in sociallogin table
|
435 |
if( $this->blockObj->notifyUser() == "1" ){
|
436 |
$loginRadiusMessage = $this->blockObj->notifyUserText();
|
437 |
if( $loginRadiusMessage == "" ){
|
438 |
+
$loginRadiusMessage = __("Welcome to ").$store->getGroup()->getName().". ".__("You can login to the store using following e-mail address and password:-");
|
439 |
}
|
440 |
$loginRadiusMessage .= "<br/>".
|
441 |
"Email : ".$socialloginProfileData['Email'].
|
442 |
+
"<br/>".__("Password")." : ".$loginRadiusPwd;
|
443 |
|
444 |
+
$this->loginRadiusEmail( __("Welcome")." ".$loginRadiusUsername."!", $loginRadiusMessage, $socialloginProfileData['Email'], $loginRadiusUsername );
|
445 |
}
|
446 |
// new user notification to admin
|
447 |
if( $this->blockObj->notifyAdmin() == "1" ){
|
449 |
$loginRadiusAdminName = Mage::getStoreConfig('trans_email/ident_general/name');
|
450 |
$loginRadiusMessage = trim($this->blockObj->notifyAdminText());
|
451 |
if( $loginRadiusMessage == "" ){
|
452 |
+
$loginRadiusMessage = __("New customer has been registered to your store with following details:-");
|
453 |
}
|
454 |
$loginRadiusMessage .= "<br/>".
|
455 |
+
__("Name")." : ".$loginRadiusUsername."<br/>".
|
456 |
+
__("Email")." : ".$socialloginProfileData['Email'];
|
457 |
+
$this->loginRadiusEmail( __("New User Registration"), $loginRadiusMessage, $loginRadiusAdminEmail, $loginRadiusAdminName );
|
458 |
}
|
459 |
}
|
460 |
//login and redirect user
|
543 |
// insert details in sociallogin table
|
544 |
$this->SocialLoginInsert( "sociallogin", $data );
|
545 |
// send verification mail
|
546 |
+
$message = __(Mage::helper('core')->htmlEscape(trim($this->blockObj->verificationText())));
|
547 |
if( $message == "" ){
|
548 |
+
$message = __("Please click on the following link or paste it in browser to verify your email:-");
|
549 |
}
|
550 |
$message .= "<br/>".Mage::getBaseUrl()."sociallogin/?loginRadiusKey=".$vKey;
|
551 |
+
$this->loginRadiusEmail( __("Email verification"), $message, $email, $email);
|
552 |
// show popup message
|
553 |
SL_popUpWindow( "Confirmation link Has Been Sent To Your Email Address. Please verify your email by clicking on confirmation link.", "", false );
|
554 |
$this->SocialLoginShowLayout();
|
558 |
public function indexAction() {
|
559 |
$this->blockObj = new Loginradius_Sociallogin_Block_Sociallogin();
|
560 |
$this->loginRadiusPopMsg = trim($this->blockObj->getPopupText() );
|
561 |
+
$this->loginRadiusPopMsg = $this->loginRadiusPopMsg == "" ? __("Please enter your email to proceed") : $this->loginRadiusPopMsg;
|
562 |
$this->loginRadiusPopErr = trim($this->blockObj->getPopupError() );
|
563 |
+
$this->loginRadiusPopErr = $this->loginRadiusPopErr == "" ? __("Email you entered is either invalid or already registered. Please enter a valid email.") : $this->loginRadiusPopErr;
|
564 |
if(isset($_REQUEST['token'])) {
|
565 |
$this->tokenHandle();
|
566 |
$this->loadLayout();
|
app/code/community/Loginradius/Sociallogin/controllers/Popup.php
CHANGED
@@ -1,6 +1,8 @@
|
|
1 |
<?php
|
2 |
-
function SL_popUpWindow( $loginRadiusPopupTxt, $socialLoginMsg = "", $loginRadiusShowForm = true, $profileData = array(), $emailRequired = true, $hideZipcode = false){
|
|
|
3 |
?>
|
|
|
4 |
<!--css of email block -->
|
5 |
<style type="text/css">
|
6 |
.LoginRadius_overlay {
|
@@ -135,10 +137,11 @@ function SL_popUpWindow( $loginRadiusPopupTxt, $socialLoginMsg = "", $loginRadiu
|
|
135 |
}
|
136 |
// validate required fields form
|
137 |
function loginRadiusValidateForm(){
|
|
|
138 |
if(!loginRadiusPopupSubmit){
|
|
|
139 |
return true;
|
140 |
}
|
141 |
-
var loginRadiusForm = document.getElementById('loginRadiusForm');
|
142 |
var loginRadiusErrorDiv = document.getElementById('textmatter');
|
143 |
if(document.getElementById('loginRadiusCountry').value.trim() == "US"){
|
144 |
var validateProvince = true;
|
@@ -150,7 +153,7 @@ function SL_popUpWindow( $loginRadiusPopupTxt, $socialLoginMsg = "", $loginRadiu
|
|
150 |
continue;
|
151 |
}
|
152 |
if(loginRadiusForm.elements[i].value.trim() == ""){
|
153 |
-
loginRadiusErrorDiv.innerHTML = "Please fill all the fields";
|
154 |
loginRadiusErrorDiv.style.backgroundColor = "rgb(255, 235, 232)";
|
155 |
loginRadiusErrorDiv.style.border = "1px solid rgb(204, 0, 0)";
|
156 |
loginRadiusErrorDiv.style.padding = "2px 5px";
|
@@ -163,7 +166,7 @@ function SL_popUpWindow( $loginRadiusPopupTxt, $socialLoginMsg = "", $loginRadiu
|
|
163 |
var atPosition = email.indexOf("@");
|
164 |
var dotPosition = email.lastIndexOf(".");
|
165 |
if(atPosition < 1 || dotPosition < atPosition+2 || dotPosition+2>=email.length){
|
166 |
-
loginRadiusErrorDiv.innerHTML = "Please enter a valid email address";
|
167 |
loginRadiusErrorDiv.style.backgroundColor = "rgb(255, 235, 232)";
|
168 |
loginRadiusErrorDiv.style.border = "1px solid rgb(204, 0, 0)";
|
169 |
loginRadiusErrorDiv.style.padding = "2px 5px";
|
@@ -181,9 +184,9 @@ function SL_popUpWindow( $loginRadiusPopupTxt, $socialLoginMsg = "", $loginRadiu
|
|
181 |
<div id="fade" class="LoginRadius_overlay">
|
182 |
<div id="popupouter">
|
183 |
<div id="popupinner">
|
184 |
-
<div id="textmatter"><strong><?php echo $loginRadiusPopupTxt; ?></strong></div>
|
185 |
<div style="clear:both;"></div>
|
186 |
-
<div style="color:red; text-align:justify"><?php echo $socialLoginMsg ?></div>
|
187 |
<?php
|
188 |
if( $loginRadiusShowForm ){
|
189 |
?>
|
@@ -192,7 +195,7 @@ function SL_popUpWindow( $loginRadiusPopupTxt, $socialLoginMsg = "", $loginRadiu
|
|
192 |
if($emailRequired){
|
193 |
?>
|
194 |
<div class="loginRadiusDiv">
|
195 |
-
<label for="loginRadiusEmail"
|
196 |
<input type="text" name="loginRadiusEmail" id="loginRadiusEmail" class="loginRadiusText" />
|
197 |
</div>
|
198 |
<?php
|
@@ -200,7 +203,7 @@ function SL_popUpWindow( $loginRadiusPopupTxt, $socialLoginMsg = "", $loginRadiu
|
|
200 |
if(isset($profileData['Address']) && $profileData['Address'] == ""){
|
201 |
?>
|
202 |
<div class="loginRadiusDiv">
|
203 |
-
<label for="loginRadiusAddress"
|
204 |
<input type="text" name="loginRadiusAddress" id="loginRadiusAddress" class="loginRadiusText" />
|
205 |
</div>
|
206 |
<?php
|
@@ -208,7 +211,7 @@ function SL_popUpWindow( $loginRadiusPopupTxt, $socialLoginMsg = "", $loginRadiu
|
|
208 |
if(isset($profileData['City']) && $profileData['City'] == ""){
|
209 |
?>
|
210 |
<div class="loginRadiusDiv">
|
211 |
-
<label for="loginRadiusCity"
|
212 |
<input type="text" name="loginRadiusCity" id="loginRadiusCity" class="loginRadiusText" />
|
213 |
</div>
|
214 |
<?php
|
@@ -216,14 +219,14 @@ function SL_popUpWindow( $loginRadiusPopupTxt, $socialLoginMsg = "", $loginRadiu
|
|
216 |
if(!$hideZipcode){
|
217 |
?>
|
218 |
<div class="loginRadiusDiv">
|
219 |
-
<label for="loginRadiusCountry"
|
220 |
<?php
|
221 |
$countries = Mage::getResourceModel('directory/country_collection')
|
222 |
->loadData()
|
223 |
->toOptionArray(false);
|
224 |
if(count($countries) > 0){ ?>
|
225 |
<select onChange="if(this.value == 'US'){ document.getElementById('loginRadiusProvinceContainer').style.display = 'block' }else{ document.getElementById('loginRadiusProvinceContainer').style.display = 'none' }" name="loginRadiusCountry" id="loginRadiusCountry" class="loginRadiusText">
|
226 |
-
<option value="">-- Please Select --</option>
|
227 |
<?php foreach($countries as $country): ?>
|
228 |
<option value="<?php echo $country['value'] ?>">
|
229 |
<?php echo $country['label'] ?>
|
@@ -233,9 +236,9 @@ function SL_popUpWindow( $loginRadiusPopupTxt, $socialLoginMsg = "", $loginRadiu
|
|
233 |
</div>
|
234 |
<!-- United States province -->
|
235 |
<div style="display:none" id="loginRadiusProvinceContainer" class="loginRadiusDiv">
|
236 |
-
<label for="loginRadiusCountry"
|
237 |
<select id="loginRadiusProvince" name="loginRadiusProvince" class="loginRadiusText">
|
238 |
-
<option value="" selected="selected">-- Please select --</option><option value="1">Alabama</option><option value="2">Alaska</option><option value="3">American Samoa</option><option value="4">Arizona</option><option value="5">Arkansas</option><option value="6">Armed Forces Africa</option><option value="7">Armed Forces Americas</option><option value="8">Armed Forces Canada</option><option value="9">Armed Forces Europe</option><option value="10">Armed Forces Middle East</option><option value="11">Armed Forces Pacific</option><option value="12">California</option><option value="13">Colorado</option><option value="14">Connecticut</option><option value="15">Delaware</option><option value="16">District of Columbia</option><option value="17">Federated States Of Micronesia</option><option value="18">Florida</option><option value="19">Georgia</option><option value="20">Guam</option><option value="21">Hawaii</option><option value="22">Idaho</option><option value="23">Illinois</option><option value="24">Indiana</option><option value="25">Iowa</option><option value="26">Kansas</option><option value="27">Kentucky</option><option value="28">Louisiana</option><option value="29">Maine</option><option value="30">Marshall Islands</option><option value="31">Maryland</option><option value="32">Massachusetts</option><option value="33">Michigan</option><option value="34">Minnesota</option><option value="35">Mississippi</option><option value="36">Missouri</option><option value="37">Montana</option><option value="38">Nebraska</option><option value="39">Nevada</option><option value="40">New Hampshire</option><option value="41">New Jersey</option><option value="42">New Mexico</option><option value="43">New York</option><option value="44">North Carolina</option><option value="45">North Dakota</option><option value="46">Northern Mariana Islands</option><option value="47">Ohio</option><option value="48">Oklahoma</option><option value="49">Oregon</option><option value="50">Palau</option><option value="51">Pennsylvania</option><option value="52">Puerto Rico</option><option value="53">Rhode Island</option><option value="54">South Carolina</option><option value="55">South Dakota</option><option value="56">Tennessee</option><option value="57">Texas</option><option value="58">Utah</option><option value="59">Vermont</option><option value="60">Virgin Islands</option><option value="61">Virginia</option><option value="62">Washington</option><option value="63">West Virginia</option><option value="64">Wisconsin</option><option value="65">Wyoming</option></select>
|
239 |
<?php }else{
|
240 |
?>
|
241 |
<input type="text" name="loginRadiusCountry" id="loginRadiusCountry" class="loginRadiusText" />
|
@@ -244,7 +247,7 @@ function SL_popUpWindow( $loginRadiusPopupTxt, $socialLoginMsg = "", $loginRadiu
|
|
244 |
?>
|
245 |
</div>
|
246 |
<div class="loginRadiusDiv">
|
247 |
-
<label for="loginRadiusZipcode"
|
248 |
<input type="text" name="loginRadiusZipcode" id="loginRadiusZipcode" class="loginRadiusText" />
|
249 |
</div>
|
250 |
<?php
|
@@ -252,21 +255,21 @@ function SL_popUpWindow( $loginRadiusPopupTxt, $socialLoginMsg = "", $loginRadiu
|
|
252 |
if(isset($profileData['PhoneNumber']) && $profileData['PhoneNumber'] == ""){
|
253 |
?>
|
254 |
<div class="loginRadiusDiv">
|
255 |
-
<label for="loginRadiusPhone"
|
256 |
<input type="text" name="loginRadiusPhone" id="loginRadiusPhone" class="loginRadiusText" />
|
257 |
</div>
|
258 |
<?php
|
259 |
}
|
260 |
?>
|
261 |
<div class="loginRadiusDiv">
|
262 |
-
<input type="submit" id="LoginRadiusRedSliderClick" name="LoginRadiusRedSliderClick" value="Submit" onClick="loginRadiusPopupSubmit = true" class="inputbutton" />
|
263 |
-
<input type="submit" value="Cancel" class="inputbutton" name="LoginRadiusPopupCancel" onClick="loginRadiusPopupSubmit = false" />
|
264 |
</div>
|
265 |
</form>
|
266 |
<?php
|
267 |
}else{
|
268 |
?>
|
269 |
-
<input type="button" value="
|
270 |
<?php
|
271 |
}
|
272 |
?>
|
1 |
<?php
|
2 |
+
function SL_popUpWindow( $loginRadiusPopupTxt, $socialLoginMsg = "", $loginRadiusShowForm = true, $profileData = array(), $emailRequired = true, $hideZipcode = false){
|
3 |
+
$blockObj = new Loginradius_Sociallogin_Block_Sociallogin();
|
4 |
?>
|
5 |
+
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
|
6 |
<!--css of email block -->
|
7 |
<style type="text/css">
|
8 |
.LoginRadius_overlay {
|
137 |
}
|
138 |
// validate required fields form
|
139 |
function loginRadiusValidateForm(){
|
140 |
+
var loginRadiusForm = document.getElementById('loginRadiusForm');
|
141 |
if(!loginRadiusPopupSubmit){
|
142 |
+
loginRadiusForm.setAttribute('action', '<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_LINK); ?>');
|
143 |
return true;
|
144 |
}
|
|
|
145 |
var loginRadiusErrorDiv = document.getElementById('textmatter');
|
146 |
if(document.getElementById('loginRadiusCountry').value.trim() == "US"){
|
147 |
var validateProvince = true;
|
153 |
continue;
|
154 |
}
|
155 |
if(loginRadiusForm.elements[i].value.trim() == ""){
|
156 |
+
loginRadiusErrorDiv.innerHTML = "<?php echo __("Please fill all the fields."); ?>";
|
157 |
loginRadiusErrorDiv.style.backgroundColor = "rgb(255, 235, 232)";
|
158 |
loginRadiusErrorDiv.style.border = "1px solid rgb(204, 0, 0)";
|
159 |
loginRadiusErrorDiv.style.padding = "2px 5px";
|
166 |
var atPosition = email.indexOf("@");
|
167 |
var dotPosition = email.lastIndexOf(".");
|
168 |
if(atPosition < 1 || dotPosition < atPosition+2 || dotPosition+2>=email.length){
|
169 |
+
loginRadiusErrorDiv.innerHTML = "<?php echo trim($blockObj -> getPopupError()) != "" ? trim($blockObj -> getPopupError()) : __('Please enter a valid email address'); ?>";
|
170 |
loginRadiusErrorDiv.style.backgroundColor = "rgb(255, 235, 232)";
|
171 |
loginRadiusErrorDiv.style.border = "1px solid rgb(204, 0, 0)";
|
172 |
loginRadiusErrorDiv.style.padding = "2px 5px";
|
184 |
<div id="fade" class="LoginRadius_overlay">
|
185 |
<div id="popupouter">
|
186 |
<div id="popupinner">
|
187 |
+
<div id="textmatter"><strong><?php echo __(Mage::helper('core')->htmlEscape($loginRadiusPopupTxt)); ?></strong></div>
|
188 |
<div style="clear:both;"></div>
|
189 |
+
<div style="color:red; text-align:justify"><?php echo __(Mage::helper('core')->htmlEscape($socialLoginMsg)); ?></div>
|
190 |
<?php
|
191 |
if( $loginRadiusShowForm ){
|
192 |
?>
|
195 |
if($emailRequired){
|
196 |
?>
|
197 |
<div class="loginRadiusDiv">
|
198 |
+
<label for="loginRadiusEmail"><?php echo __("Email"); ?> *</label>
|
199 |
<input type="text" name="loginRadiusEmail" id="loginRadiusEmail" class="loginRadiusText" />
|
200 |
</div>
|
201 |
<?php
|
203 |
if(isset($profileData['Address']) && $profileData['Address'] == ""){
|
204 |
?>
|
205 |
<div class="loginRadiusDiv">
|
206 |
+
<label for="loginRadiusAddress"><?php echo __("Address"); ?> *</label>
|
207 |
<input type="text" name="loginRadiusAddress" id="loginRadiusAddress" class="loginRadiusText" />
|
208 |
</div>
|
209 |
<?php
|
211 |
if(isset($profileData['City']) && $profileData['City'] == ""){
|
212 |
?>
|
213 |
<div class="loginRadiusDiv">
|
214 |
+
<label for="loginRadiusCity"><?php echo __("City") ?> *</label>
|
215 |
<input type="text" name="loginRadiusCity" id="loginRadiusCity" class="loginRadiusText" />
|
216 |
</div>
|
217 |
<?php
|
219 |
if(!$hideZipcode){
|
220 |
?>
|
221 |
<div class="loginRadiusDiv">
|
222 |
+
<label for="loginRadiusCountry"><?php echo __("Country"); ?> *</label>
|
223 |
<?php
|
224 |
$countries = Mage::getResourceModel('directory/country_collection')
|
225 |
->loadData()
|
226 |
->toOptionArray(false);
|
227 |
if(count($countries) > 0){ ?>
|
228 |
<select onChange="if(this.value == 'US'){ document.getElementById('loginRadiusProvinceContainer').style.display = 'block' }else{ document.getElementById('loginRadiusProvinceContainer').style.display = 'none' }" name="loginRadiusCountry" id="loginRadiusCountry" class="loginRadiusText">
|
229 |
+
<option value="">-- <?php echo __("Please Select"); ?> --</option>
|
230 |
<?php foreach($countries as $country): ?>
|
231 |
<option value="<?php echo $country['value'] ?>">
|
232 |
<?php echo $country['label'] ?>
|
236 |
</div>
|
237 |
<!-- United States province -->
|
238 |
<div style="display:none" id="loginRadiusProvinceContainer" class="loginRadiusDiv">
|
239 |
+
<label for="loginRadiusCountry"><?php echo __("State/Province") ?> *</label>
|
240 |
<select id="loginRadiusProvince" name="loginRadiusProvince" class="loginRadiusText">
|
241 |
+
<option value="" selected="selected">-- <?php echo __("Please select") ?> --</option><option value="1">Alabama</option><option value="2">Alaska</option><option value="3">American Samoa</option><option value="4">Arizona</option><option value="5">Arkansas</option><option value="6">Armed Forces Africa</option><option value="7">Armed Forces Americas</option><option value="8">Armed Forces Canada</option><option value="9">Armed Forces Europe</option><option value="10">Armed Forces Middle East</option><option value="11">Armed Forces Pacific</option><option value="12">California</option><option value="13">Colorado</option><option value="14">Connecticut</option><option value="15">Delaware</option><option value="16">District of Columbia</option><option value="17">Federated States Of Micronesia</option><option value="18">Florida</option><option value="19">Georgia</option><option value="20">Guam</option><option value="21">Hawaii</option><option value="22">Idaho</option><option value="23">Illinois</option><option value="24">Indiana</option><option value="25">Iowa</option><option value="26">Kansas</option><option value="27">Kentucky</option><option value="28">Louisiana</option><option value="29">Maine</option><option value="30">Marshall Islands</option><option value="31">Maryland</option><option value="32">Massachusetts</option><option value="33">Michigan</option><option value="34">Minnesota</option><option value="35">Mississippi</option><option value="36">Missouri</option><option value="37">Montana</option><option value="38">Nebraska</option><option value="39">Nevada</option><option value="40">New Hampshire</option><option value="41">New Jersey</option><option value="42">New Mexico</option><option value="43">New York</option><option value="44">North Carolina</option><option value="45">North Dakota</option><option value="46">Northern Mariana Islands</option><option value="47">Ohio</option><option value="48">Oklahoma</option><option value="49">Oregon</option><option value="50">Palau</option><option value="51">Pennsylvania</option><option value="52">Puerto Rico</option><option value="53">Rhode Island</option><option value="54">South Carolina</option><option value="55">South Dakota</option><option value="56">Tennessee</option><option value="57">Texas</option><option value="58">Utah</option><option value="59">Vermont</option><option value="60">Virgin Islands</option><option value="61">Virginia</option><option value="62">Washington</option><option value="63">West Virginia</option><option value="64">Wisconsin</option><option value="65">Wyoming</option></select>
|
242 |
<?php }else{
|
243 |
?>
|
244 |
<input type="text" name="loginRadiusCountry" id="loginRadiusCountry" class="loginRadiusText" />
|
247 |
?>
|
248 |
</div>
|
249 |
<div class="loginRadiusDiv">
|
250 |
+
<label for="loginRadiusZipcode"><?php echo __("Zipcode") ?> *</label>
|
251 |
<input type="text" name="loginRadiusZipcode" id="loginRadiusZipcode" class="loginRadiusText" />
|
252 |
</div>
|
253 |
<?php
|
255 |
if(isset($profileData['PhoneNumber']) && $profileData['PhoneNumber'] == ""){
|
256 |
?>
|
257 |
<div class="loginRadiusDiv">
|
258 |
+
<label for="loginRadiusPhone"><?php echo __("Phone Number") ?> *</label>
|
259 |
<input type="text" name="loginRadiusPhone" id="loginRadiusPhone" class="loginRadiusText" />
|
260 |
</div>
|
261 |
<?php
|
262 |
}
|
263 |
?>
|
264 |
<div class="loginRadiusDiv">
|
265 |
+
<input type="submit" id="LoginRadiusRedSliderClick" name="LoginRadiusRedSliderClick" value="<?php echo __("Submit") ?>" onClick="loginRadiusPopupSubmit = true" class="inputbutton" />
|
266 |
+
<input type="submit" value="<?php echo __("Cancel") ?>" class="inputbutton" name="LoginRadiusPopupCancel" onClick="loginRadiusPopupSubmit = false" />
|
267 |
</div>
|
268 |
</form>
|
269 |
<?php
|
270 |
}else{
|
271 |
?>
|
272 |
+
<input type="button" value="<?php echo __("Okay") ?>" class="inputbutton" onClick="location.href = '<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_LINK); ?>'" />
|
273 |
<?php
|
274 |
}
|
275 |
?>
|
app/code/community/Loginradius/Sociallogin/etc/config.xml
CHANGED
@@ -46,7 +46,7 @@
|
|
46 |
</default>
|
47 |
<modules>
|
48 |
<Loginradius_Sociallogin>
|
49 |
-
<version>3.
|
50 |
</Loginradius_Sociallogin>
|
51 |
</modules>
|
52 |
<frontend>
|
@@ -130,6 +130,15 @@
|
|
130 |
</sociallogin>
|
131 |
</updates>
|
132 |
</layout>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
133 |
</adminhtml>
|
134 |
<global>
|
135 |
<models>
|
46 |
</default>
|
47 |
<modules>
|
48 |
<Loginradius_Sociallogin>
|
49 |
+
<version>3.6.0</version>
|
50 |
</Loginradius_Sociallogin>
|
51 |
</modules>
|
52 |
<frontend>
|
130 |
</sociallogin>
|
131 |
</updates>
|
132 |
</layout>
|
133 |
+
<translate>
|
134 |
+
<modules>
|
135 |
+
<Loginradius_Sociallogin>
|
136 |
+
<files>
|
137 |
+
<default>Loginradius_Sociallogin.csv</default>
|
138 |
+
</files>
|
139 |
+
</Loginradius_Sociallogin>
|
140 |
+
</modules>
|
141 |
+
</translate>
|
142 |
</adminhtml>
|
143 |
<global>
|
144 |
<models>
|
app/code/community/Loginradius/Sociallogin/etc/system.xml
CHANGED
@@ -44,8 +44,7 @@
|
|
44 |
<appid translate="label">
|
45 |
<label>LoginRadius API Key</label>
|
46 |
<frontend_type>text</frontend_type>
|
47 |
-
<comment><![CDATA[Paste LoginRadius API Key here. To get the API Key, login to <a href="http://www.loginradius.com" target="_blank">LoginRadius</a>]]>
|
48 |
-
</comment>
|
49 |
<sort_order>15</sort_order>
|
50 |
<show_in_default>1</show_in_default>
|
51 |
<show_in_website>1</show_in_website>
|
@@ -54,8 +53,7 @@
|
|
54 |
<appkey translate="label">
|
55 |
<label>LoginRadius API Secret</label>
|
56 |
<frontend_type>text</frontend_type>
|
57 |
-
<comment><![CDATA[Paste LoginRadius API Secret here. To get the API Secret, login to <a href="http://www.loginradius.com" target="_blank">LoginRadius</a>]]>
|
58 |
-
</comment>
|
59 |
<sort_order>16</sort_order>
|
60 |
<show_in_default>1</show_in_default>
|
61 |
<show_in_website>1</show_in_website>
|
@@ -64,8 +62,7 @@
|
|
64 |
<loginradius_title translate="label">
|
65 |
<label>Title</label>
|
66 |
<frontend_type>text</frontend_type>
|
67 |
-
<comment><![CDATA[Text displayed above Social login Interface]]>
|
68 |
-
</comment>
|
69 |
<sort_order>17</sort_order>
|
70 |
<show_in_default>1</show_in_default>
|
71 |
<show_in_website>1</show_in_website>
|
@@ -93,7 +90,7 @@
|
|
93 |
<backgroundColor translate="label">
|
94 |
<label>Background Color</label>
|
95 |
<frontend_type>text</frontend_type>
|
96 |
-
<comment><![CDATA[What background color would you like to use for the Social Login interface? (Leave empty for transparent. You can enter hexa-decimal code of the color as well as name of the color.)]]></comment>
|
97 |
<sort_order>20</sort_order>
|
98 |
<show_in_default>1</show_in_default>
|
99 |
<show_in_website>1</show_in_website>
|
@@ -102,8 +99,7 @@
|
|
102 |
<showdefault translate="label">
|
103 |
<label>Show Social Login interface in right side panel</label>
|
104 |
<frontend_type>select</frontend_type>
|
105 |
-
<comment><![CDATA[Select No you don't want to display module in right panel. You can also set widget in pages or any area of your site.
|
106 |
-
</comment>
|
107 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
108 |
<sort_order>23</sort_order>
|
109 |
<show_in_default>1</show_in_default>
|
@@ -113,8 +109,7 @@
|
|
113 |
<aboveLogin translate="label">
|
114 |
<label>Show Social Login interface above login form</label>
|
115 |
<frontend_type>select</frontend_type>
|
116 |
-
<comment><![CDATA[Select 'Yes' to enable Social Login interface above login form.]]>
|
117 |
-
</comment>
|
118 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
119 |
<sort_order>24</sort_order>
|
120 |
<show_in_default>1</show_in_default>
|
@@ -124,8 +119,7 @@
|
|
124 |
<belowLogin translate="label">
|
125 |
<label>Show Social Login interface below login form</label>
|
126 |
<frontend_type>select</frontend_type>
|
127 |
-
<comment><![CDATA[Select 'Yes' to enable Social Login interface below login form.]]>
|
128 |
-
</comment>
|
129 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
130 |
<sort_order>25</sort_order>
|
131 |
<show_in_default>1</show_in_default>
|
@@ -135,8 +129,7 @@
|
|
135 |
<aboveRegister translate="label">
|
136 |
<label>Show Social Login interface above registration form</label>
|
137 |
<frontend_type>select</frontend_type>
|
138 |
-
<comment><![CDATA[Select 'Yes' to enable Social Login interface above registration form.]]>
|
139 |
-
</comment>
|
140 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
141 |
<sort_order>26</sort_order>
|
142 |
<show_in_default>1</show_in_default>
|
@@ -146,8 +139,7 @@
|
|
146 |
<belowRegister translate="label">
|
147 |
<label>Show Social Login interface below registration form</label>
|
148 |
<frontend_type>select</frontend_type>
|
149 |
-
<comment><![CDATA[Select 'Yes' to enable Social Login interface below registration form.]]>
|
150 |
-
</comment>
|
151 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
152 |
<sort_order>27</sort_order>
|
153 |
<show_in_default>1</show_in_default>
|
@@ -157,8 +149,7 @@
|
|
157 |
<socialLinking translate="label">
|
158 |
<label>Social Linking</label>
|
159 |
<frontend_type>select</frontend_type>
|
160 |
-
<comment><![CDATA[Link existing user accounts with Social Login.]]>
|
161 |
-
</comment>
|
162 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
163 |
<sort_order>29</sort_order>
|
164 |
<show_in_default>1</show_in_default>
|
@@ -185,8 +176,7 @@
|
|
185 |
<api translate="label">
|
186 |
<label>API Connection Method</label>
|
187 |
<frontend_type>select</frontend_type>
|
188 |
-
<comment><![CDATA[cURL require 'cURL support = enabled' in your php.ini settings, FSOCKOPEN require 'allow_url_fopen = On' and 'safemode = off' in your php.ini settings]]>
|
189 |
-
</comment>
|
190 |
<source_model>sociallogin/source_uihover2</source_model>
|
191 |
<sort_order>45</sort_order>
|
192 |
<show_in_default>1</show_in_default>
|
@@ -226,8 +216,7 @@
|
|
226 |
<emailrequired translate="label">
|
227 |
<label>Email Required</label>
|
228 |
<frontend_type>select</frontend_type>
|
229 |
-
<comment><![CDATA[A few ID providers do not provide user's Email ID. Select YES if you would like an email pop-up after login or select NO if you would like to auto-generate the email address.]]>
|
230 |
-
</comment>
|
231 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
232 |
<sort_order>22</sort_order>
|
233 |
<show_in_default>1</show_in_default>
|
@@ -237,8 +226,7 @@
|
|
237 |
<verificationText translate="label">
|
238 |
<label>Email verification message</label>
|
239 |
<frontend_type>text</frontend_type>
|
240 |
-
<comment><![CDATA[This message will be used in verification email.]]>
|
241 |
-
</comment>
|
242 |
<sort_order>23</sort_order>
|
243 |
<show_in_default>1</show_in_default>
|
244 |
<show_in_website>1</show_in_website>
|
@@ -247,8 +235,7 @@
|
|
247 |
<popupText translate="label">
|
248 |
<label>"Email required" - Popup title</label>
|
249 |
<frontend_type>text</frontend_type>
|
250 |
-
<comment><![CDATA[This text will be displayed on "Email required" popup.]]>
|
251 |
-
</comment>
|
252 |
<sort_order>24</sort_order>
|
253 |
<show_in_default>1</show_in_default>
|
254 |
<show_in_website>1</show_in_website>
|
@@ -257,8 +244,7 @@
|
|
257 |
<popupError translate="label">
|
258 |
<label>Error message</label>
|
259 |
<frontend_type>text</frontend_type>
|
260 |
-
<comment><![CDATA[This text will be displayed on the popup if the entered email is already registered or invalid.]]>
|
261 |
-
</comment>
|
262 |
<sort_order>25</sort_order>
|
263 |
<show_in_default>1</show_in_default>
|
264 |
<show_in_website>1</show_in_website>
|
@@ -267,8 +253,7 @@
|
|
267 |
<notifyUser translate="label">
|
268 |
<label>Enable registration notification to user</label>
|
269 |
<frontend_type>select</frontend_type>
|
270 |
-
<comment><![CDATA[Send email to newly registered customer regarding login credentials.]]>
|
271 |
-
</comment>
|
272 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
273 |
<sort_order>26</sort_order>
|
274 |
<show_in_default>1</show_in_default>
|
@@ -278,8 +263,7 @@
|
|
278 |
<notifyUserText translate="label">
|
279 |
<label>User notification email message</label>
|
280 |
<frontend_type>textarea</frontend_type>
|
281 |
-
<comment><![CDATA[This message will be sent to user in notification email along with login credentials. If left empty, default message will be sent.]]>
|
282 |
-
</comment>
|
283 |
<sort_order>27</sort_order>
|
284 |
<show_in_default>1</show_in_default>
|
285 |
<show_in_website>1</show_in_website>
|
@@ -288,8 +272,7 @@
|
|
288 |
<notifyAdmin translate="label">
|
289 |
<label>Enable registration notification to owner</label>
|
290 |
<frontend_type>select</frontend_type>
|
291 |
-
<comment><![CDATA[Send email to store owner on new customer registration regarding customer details.]]>
|
292 |
-
</comment>
|
293 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
294 |
<sort_order>28</sort_order>
|
295 |
<show_in_default>1</show_in_default>
|
@@ -299,8 +282,7 @@
|
|
299 |
<notifyAdminText translate="label">
|
300 |
<label>Owner notification email message</label>
|
301 |
<frontend_type>textarea</frontend_type>
|
302 |
-
<comment><![CDATA[This message will be sent to admin in notification email.]]>
|
303 |
-
</comment>
|
304 |
<sort_order>29</sort_order>
|
305 |
<show_in_default>1</show_in_default>
|
306 |
<show_in_website>1</show_in_website>
|
@@ -320,8 +302,7 @@
|
|
320 |
<label>Enable Horizontal Social Sharing</label>
|
321 |
<frontend_type>select</frontend_type>
|
322 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
323 |
-
<comment><![CDATA[Do you want to enable Horizontal Social Sharing for your website?]]>
|
324 |
-
</comment>
|
325 |
<sort_order>31</sort_order>
|
326 |
<show_in_default>1</show_in_default>
|
327 |
<show_in_website>1</show_in_website>
|
@@ -348,8 +329,7 @@
|
|
348 |
<sharingTitle translate="label">
|
349 |
<label>Sharing Title</label>
|
350 |
<frontend_type>text</frontend_type>
|
351 |
-
<comment><![CDATA[Enter the text that you wish to be displayed above the Social Sharing Interface. Leave the field blank if you don't want any text to be displayed.]]>
|
352 |
-
</comment>
|
353 |
<sort_order>34</sort_order>
|
354 |
<show_in_default>1</show_in_default>
|
355 |
<show_in_website>1</show_in_website>
|
@@ -412,8 +392,7 @@
|
|
412 |
<label>Enable Vertical Social Sharing</label>
|
413 |
<frontend_type>select</frontend_type>
|
414 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
415 |
-
<comment><![CDATA[Do you want to enable Social Counter for your website?]]>
|
416 |
-
</comment>
|
417 |
<sort_order>43</sort_order>
|
418 |
<show_in_default>1</show_in_default>
|
419 |
<show_in_website>1</show_in_website>
|
44 |
<appid translate="label">
|
45 |
<label>LoginRadius API Key</label>
|
46 |
<frontend_type>text</frontend_type>
|
47 |
+
<comment><![CDATA[Paste LoginRadius API Key here. To get the API Key, login to <a href="http://www.loginradius.com" target="_blank">LoginRadius</a>]]></comment>
|
|
|
48 |
<sort_order>15</sort_order>
|
49 |
<show_in_default>1</show_in_default>
|
50 |
<show_in_website>1</show_in_website>
|
53 |
<appkey translate="label">
|
54 |
<label>LoginRadius API Secret</label>
|
55 |
<frontend_type>text</frontend_type>
|
56 |
+
<comment><![CDATA[Paste LoginRadius API Secret here. To get the API Secret, login to <a href="http://www.loginradius.com" target="_blank">LoginRadius</a>]]></comment>
|
|
|
57 |
<sort_order>16</sort_order>
|
58 |
<show_in_default>1</show_in_default>
|
59 |
<show_in_website>1</show_in_website>
|
62 |
<loginradius_title translate="label">
|
63 |
<label>Title</label>
|
64 |
<frontend_type>text</frontend_type>
|
65 |
+
<comment><![CDATA[Text displayed above Social login Interface]]></comment>
|
|
|
66 |
<sort_order>17</sort_order>
|
67 |
<show_in_default>1</show_in_default>
|
68 |
<show_in_website>1</show_in_website>
|
90 |
<backgroundColor translate="label">
|
91 |
<label>Background Color</label>
|
92 |
<frontend_type>text</frontend_type>
|
93 |
+
<comment><![CDATA[What background color would you like to use for the Social Login interface? (Leave empty for transparent. You can enter hexa-decimal code of the color as well as name of the color (in English language and small letters).)]]></comment>
|
94 |
<sort_order>20</sort_order>
|
95 |
<show_in_default>1</show_in_default>
|
96 |
<show_in_website>1</show_in_website>
|
99 |
<showdefault translate="label">
|
100 |
<label>Show Social Login interface in right side panel</label>
|
101 |
<frontend_type>select</frontend_type>
|
102 |
+
<comment><![CDATA[Select No, if you don't want to display module in right panel. You can also set widget in pages or any area of your site.]]></comment>
|
|
|
103 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
104 |
<sort_order>23</sort_order>
|
105 |
<show_in_default>1</show_in_default>
|
109 |
<aboveLogin translate="label">
|
110 |
<label>Show Social Login interface above login form</label>
|
111 |
<frontend_type>select</frontend_type>
|
112 |
+
<comment><![CDATA[Select 'Yes' to enable Social Login interface above login form.]]></comment>
|
|
|
113 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
114 |
<sort_order>24</sort_order>
|
115 |
<show_in_default>1</show_in_default>
|
119 |
<belowLogin translate="label">
|
120 |
<label>Show Social Login interface below login form</label>
|
121 |
<frontend_type>select</frontend_type>
|
122 |
+
<comment><![CDATA[Select 'Yes' to enable Social Login interface below login form.]]></comment>
|
|
|
123 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
124 |
<sort_order>25</sort_order>
|
125 |
<show_in_default>1</show_in_default>
|
129 |
<aboveRegister translate="label">
|
130 |
<label>Show Social Login interface above registration form</label>
|
131 |
<frontend_type>select</frontend_type>
|
132 |
+
<comment><![CDATA[Select 'Yes' to enable Social Login interface above registration form.]]></comment>
|
|
|
133 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
134 |
<sort_order>26</sort_order>
|
135 |
<show_in_default>1</show_in_default>
|
139 |
<belowRegister translate="label">
|
140 |
<label>Show Social Login interface below registration form</label>
|
141 |
<frontend_type>select</frontend_type>
|
142 |
+
<comment><![CDATA[Select 'Yes' to enable Social Login interface below registration form.]]></comment>
|
|
|
143 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
144 |
<sort_order>27</sort_order>
|
145 |
<show_in_default>1</show_in_default>
|
149 |
<socialLinking translate="label">
|
150 |
<label>Social Linking</label>
|
151 |
<frontend_type>select</frontend_type>
|
152 |
+
<comment><![CDATA[Link existing user accounts with Social Login.]]></comment>
|
|
|
153 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
154 |
<sort_order>29</sort_order>
|
155 |
<show_in_default>1</show_in_default>
|
176 |
<api translate="label">
|
177 |
<label>API Connection Method</label>
|
178 |
<frontend_type>select</frontend_type>
|
179 |
+
<comment><![CDATA[cURL require 'cURL support = enabled' in your php.ini settings, FSOCKOPEN require 'allow_url_fopen = On' and 'safemode = off' in your php.ini settings]]></comment>
|
|
|
180 |
<source_model>sociallogin/source_uihover2</source_model>
|
181 |
<sort_order>45</sort_order>
|
182 |
<show_in_default>1</show_in_default>
|
216 |
<emailrequired translate="label">
|
217 |
<label>Email Required</label>
|
218 |
<frontend_type>select</frontend_type>
|
219 |
+
<comment><![CDATA[A few ID providers do not provide user's Email ID. Select YES if you would like an email pop-up after login or select NO if you would like to auto-generate the email address.]]></comment>
|
|
|
220 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
221 |
<sort_order>22</sort_order>
|
222 |
<show_in_default>1</show_in_default>
|
226 |
<verificationText translate="label">
|
227 |
<label>Email verification message</label>
|
228 |
<frontend_type>text</frontend_type>
|
229 |
+
<comment><![CDATA[This message will be used in verification email.]]></comment>
|
|
|
230 |
<sort_order>23</sort_order>
|
231 |
<show_in_default>1</show_in_default>
|
232 |
<show_in_website>1</show_in_website>
|
235 |
<popupText translate="label">
|
236 |
<label>"Email required" - Popup title</label>
|
237 |
<frontend_type>text</frontend_type>
|
238 |
+
<comment><![CDATA[This text will be displayed on "Email required" popup.]]></comment>
|
|
|
239 |
<sort_order>24</sort_order>
|
240 |
<show_in_default>1</show_in_default>
|
241 |
<show_in_website>1</show_in_website>
|
244 |
<popupError translate="label">
|
245 |
<label>Error message</label>
|
246 |
<frontend_type>text</frontend_type>
|
247 |
+
<comment><![CDATA[This text will be displayed on the popup if the entered email is already registered or invalid.]]></comment>
|
|
|
248 |
<sort_order>25</sort_order>
|
249 |
<show_in_default>1</show_in_default>
|
250 |
<show_in_website>1</show_in_website>
|
253 |
<notifyUser translate="label">
|
254 |
<label>Enable registration notification to user</label>
|
255 |
<frontend_type>select</frontend_type>
|
256 |
+
<comment><![CDATA[Send email to newly registered customer regarding login credentials.]]></comment>
|
|
|
257 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
258 |
<sort_order>26</sort_order>
|
259 |
<show_in_default>1</show_in_default>
|
263 |
<notifyUserText translate="label">
|
264 |
<label>User notification email message</label>
|
265 |
<frontend_type>textarea</frontend_type>
|
266 |
+
<comment><![CDATA[This message will be sent to user in notification email along with login credentials. If left empty, default message will be sent.]]></comment>
|
|
|
267 |
<sort_order>27</sort_order>
|
268 |
<show_in_default>1</show_in_default>
|
269 |
<show_in_website>1</show_in_website>
|
272 |
<notifyAdmin translate="label">
|
273 |
<label>Enable registration notification to owner</label>
|
274 |
<frontend_type>select</frontend_type>
|
275 |
+
<comment><![CDATA[Send email to store owner on new customer registration regarding customer details.]]></comment>
|
|
|
276 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
277 |
<sort_order>28</sort_order>
|
278 |
<show_in_default>1</show_in_default>
|
282 |
<notifyAdminText translate="label">
|
283 |
<label>Owner notification email message</label>
|
284 |
<frontend_type>textarea</frontend_type>
|
285 |
+
<comment><![CDATA[This message will be sent to admin in notification email.]]></comment>
|
|
|
286 |
<sort_order>29</sort_order>
|
287 |
<show_in_default>1</show_in_default>
|
288 |
<show_in_website>1</show_in_website>
|
302 |
<label>Enable Horizontal Social Sharing</label>
|
303 |
<frontend_type>select</frontend_type>
|
304 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
305 |
+
<comment><![CDATA[Do you want to enable Horizontal Social Sharing for your website?]]></comment>
|
|
|
306 |
<sort_order>31</sort_order>
|
307 |
<show_in_default>1</show_in_default>
|
308 |
<show_in_website>1</show_in_website>
|
329 |
<sharingTitle translate="label">
|
330 |
<label>Sharing Title</label>
|
331 |
<frontend_type>text</frontend_type>
|
332 |
+
<comment><![CDATA[Enter the text that you wish to be displayed above the Social Sharing Interface. Leave the field blank if you don't want any text to be displayed.]]></comment>
|
|
|
333 |
<sort_order>34</sort_order>
|
334 |
<show_in_default>1</show_in_default>
|
335 |
<show_in_website>1</show_in_website>
|
392 |
<label>Enable Vertical Social Sharing</label>
|
393 |
<frontend_type>select</frontend_type>
|
394 |
<source_model>adminhtml/system_config_source_yesno</source_model>
|
395 |
+
<comment><![CDATA[Do you want to enable Social Counter for your website?]]></comment>
|
|
|
396 |
<sort_order>43</sort_order>
|
397 |
<show_in_default>1</show_in_default>
|
398 |
<show_in_website>1</show_in_website>
|
app/code/community/Loginradius/Sociallogin/etc/widget.xml
CHANGED
@@ -16,6 +16,15 @@
|
|
16 |
<sociallogin_horizontalsharing type="sociallogin/horizontalsharing" translate="name description" module="sociallogin">
|
17 |
<name>Social Sharing - Horizontal</name>
|
18 |
<description type="desc">Adds Social Sharing interface (horizontal theme) to the page.</description>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
19 |
</sociallogin_horizontalsharing>
|
20 |
<sociallogin_verticalsharing type="sociallogin/verticalsharing" translate="name description" module="sociallogin">
|
21 |
<name>Social Sharing - Vertical</name>
|
16 |
<sociallogin_horizontalsharing type="sociallogin/horizontalsharing" translate="name description" module="sociallogin">
|
17 |
<name>Social Sharing - Horizontal</name>
|
18 |
<description type="desc">Adds Social Sharing interface (horizontal theme) to the page.</description>
|
19 |
+
<parameters>
|
20 |
+
<label_text>
|
21 |
+
<required>0</required>
|
22 |
+
<visible>1</visible>
|
23 |
+
<label>Label Text</label>
|
24 |
+
<description>The text to display before Sharing interface.</description>
|
25 |
+
<type>text</type>
|
26 |
+
</label_text>
|
27 |
+
</parameters>
|
28 |
</sociallogin_horizontalsharing>
|
29 |
<sociallogin_verticalsharing type="sociallogin/verticalsharing" translate="name description" module="sociallogin">
|
30 |
<name>Social Sharing - Vertical</name>
|
app/code/community/Loginradius/Sociallogin/sql/sociallogin_setup/{mysql4-install-3.5.0.php → mysql4-install-3.6.0.php}
RENAMED
File without changes
|
app/design/adminhtml/default/default/layout/loginradius_sociallogin.xml
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
-
<layout version="3.
|
3 |
<default>
|
4 |
<reference name="head">
|
5 |
<action method="addJs"><script>../skin/frontend/base/default/Loginradius/Sociallogin/js/jquery.js</script></action>
|
1 |
<?xml version="1.0"?>
|
2 |
+
<layout version="3.6.0">
|
3 |
<default>
|
4 |
<reference name="head">
|
5 |
<action method="addJs"><script>../skin/frontend/base/default/Loginradius/Sociallogin/js/jquery.js</script></action>
|
app/design/frontend/default/default/layout/sociallogin.xml
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
-
<layout version="3.
|
3 |
<default>
|
4 |
<reference name="right">
|
5 |
<block type="sociallogin/sociallogin" name="sociallogin" template="sociallogin/sociallogin.phtml" before="-" />
|
1 |
<?xml version="1.0"?>
|
2 |
+
<layout version="3.6.0">
|
3 |
<default>
|
4 |
<reference name="right">
|
5 |
<block type="sociallogin/sociallogin" name="sociallogin" template="sociallogin/sociallogin.phtml" before="-" />
|
app/design/frontend/default/default/template/sociallogin/abovelogin.phtml
CHANGED
@@ -6,14 +6,14 @@ if( $this->loginEnable() == "1" && !$this->user_is_already_login() ){
|
|
6 |
$loginRadiusTitle = trim( $this->getLoginRadiusTitle() );
|
7 |
$UserAuth = $this->getApiResult($ApiKey, $ApiSecrete);
|
8 |
if ($aboveLogin == 1) {
|
9 |
-
echo '<div class="block" style="margin-top:15px"><div class="block-title"><strong><span>Social Login</span></strong></div><div class="block-content"><p class="empty">';
|
10 |
if($ApiKey == "" && $ApiSecrete == ""){
|
11 |
-
echo '<p style ="color:red;">To activate your plugin, please log in to LoginRadius and get API Key & Secret. Web: <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
12 |
}elseif ($UserAuth == false) {
|
13 |
-
echo '<p style ="color:red;">Your LoginRadius API
|
14 |
}
|
15 |
else {
|
16 |
-
echo '<div style="margin:5px"><div style="margin-bottom:5px">'
|
17 |
}
|
18 |
echo '</p></div></div>';
|
19 |
}
|
6 |
$loginRadiusTitle = trim( $this->getLoginRadiusTitle() );
|
7 |
$UserAuth = $this->getApiResult($ApiKey, $ApiSecrete);
|
8 |
if ($aboveLogin == 1) {
|
9 |
+
echo '<div class="block" style="margin-top:15px"><div class="block-title"><strong><span>'.__('Social Login').'</span></strong></div><div class="block-content"><p class="empty">';
|
10 |
if($ApiKey == "" && $ApiSecrete == ""){
|
11 |
+
echo '<p style ="color:red;">'. $this -> __('To activate your plugin, please log in to LoginRadius and get API Key & Secret. Web') .': <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
12 |
}elseif ($UserAuth == false) {
|
13 |
+
echo '<p style ="color:red;">'. $this -> __('Your LoginRadius API Key and Secret is not valid, please correct it or contact LoginRadius support at') .' <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
14 |
}
|
15 |
else {
|
16 |
+
echo '<div style="margin:5px"><div style="margin-bottom:5px">'.__(Mage::helper('core')->htmlEscape($loginRadiusTitle)).'</div><div class="interfacecontainerdiv"></div></div>';
|
17 |
}
|
18 |
echo '</p></div></div>';
|
19 |
}
|
app/design/frontend/default/default/template/sociallogin/aboveregister.phtml
CHANGED
@@ -6,14 +6,14 @@ if( $this->loginEnable() == "1" && !$this->user_is_already_login() ){
|
|
6 |
$loginRadiusTitle = trim( $this->getLoginRadiusTitle() );
|
7 |
$UserAuth = $this->getApiResult($ApiKey, $ApiSecrete);
|
8 |
if ($aboveRegister == 1) {
|
9 |
-
echo '<div class="block" style="margin-top:15px"><div class="block-title"><strong><span>Social Login</span></strong></div><div class="block-content"><p class="empty">';
|
10 |
if($ApiKey == "" && $ApiSecrete == ""){
|
11 |
-
echo '<p style ="color:red;">To activate your plugin, please log in to LoginRadius and get API Key & Secret. Web: <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
12 |
}elseif ($UserAuth == false) {
|
13 |
-
echo '<p style ="color:red;">Your LoginRadius API
|
14 |
}
|
15 |
else {
|
16 |
-
echo '<div style="margin:5px"><div style="margin-bottom:5px">'
|
17 |
}
|
18 |
echo '</p></div></div>';
|
19 |
}
|
6 |
$loginRadiusTitle = trim( $this->getLoginRadiusTitle() );
|
7 |
$UserAuth = $this->getApiResult($ApiKey, $ApiSecrete);
|
8 |
if ($aboveRegister == 1) {
|
9 |
+
echo '<div class="block" style="margin-top:15px"><div class="block-title"><strong><span>'.__('Social Login').'</span></strong></div><div class="block-content"><p class="empty">';
|
10 |
if($ApiKey == "" && $ApiSecrete == ""){
|
11 |
+
echo '<p style ="color:red;">'. $this -> __('To activate your plugin, please log in to LoginRadius and get API Key & Secret. Web') .': <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
12 |
}elseif ($UserAuth == false) {
|
13 |
+
echo '<p style ="color:red;">'. $this -> __('Your LoginRadius API Key and Secret is not valid, please correct it or contact LoginRadius support at') .' <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
14 |
}
|
15 |
else {
|
16 |
+
echo '<div style="margin:5px"><div style="margin-bottom:5px">'.__(Mage::helper('core')->htmlEscape($loginRadiusTitle)).'</div><div class="interfacecontainerdiv" ></div></div>';
|
17 |
}
|
18 |
echo '</p></div></div>';
|
19 |
}
|
app/design/frontend/default/default/template/sociallogin/belowlogin.phtml
CHANGED
@@ -6,14 +6,14 @@ if( $this->loginEnable() == "1" && !$this->user_is_already_login() ){
|
|
6 |
$loginRadiusTitle = trim( $this->getLoginRadiusTitle() );
|
7 |
$UserAuth = $this->getApiResult($ApiKey, $ApiSecrete);
|
8 |
if ($belowLogin == 1) {
|
9 |
-
echo '<div class="block" style="margin-top:15px"><div class="block-title"><strong><span>Social Login</span></strong></div><div class="block-content"><p class="empty">';
|
10 |
if($ApiKey == "" && $ApiSecrete == ""){
|
11 |
-
echo '<p style ="color:red;">To activate your plugin, please log in to LoginRadius and get API Key & Secret. Web: <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
12 |
}elseif ($UserAuth == false) {
|
13 |
-
echo '<p style ="color:red;">Your LoginRadius API
|
14 |
}
|
15 |
else {
|
16 |
-
echo '<div style="margin:5px"><div style="margin-bottom:5px">'
|
17 |
}
|
18 |
echo '</p></div></div>';
|
19 |
}
|
6 |
$loginRadiusTitle = trim( $this->getLoginRadiusTitle() );
|
7 |
$UserAuth = $this->getApiResult($ApiKey, $ApiSecrete);
|
8 |
if ($belowLogin == 1) {
|
9 |
+
echo '<div class="block" style="margin-top:15px"><div class="block-title"><strong><span>'.__('Social Login').'</span></strong></div><div class="block-content"><p class="empty">';
|
10 |
if($ApiKey == "" && $ApiSecrete == ""){
|
11 |
+
echo '<p style ="color:red;">'. $this -> __('To activate your plugin, please log in to LoginRadius and get API Key & Secret. Web') .': <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
12 |
}elseif ($UserAuth == false) {
|
13 |
+
echo '<p style ="color:red;">'. $this -> __('Your LoginRadius API Key and Secret is not valid, please correct it or contact LoginRadius support at') .' <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
14 |
}
|
15 |
else {
|
16 |
+
echo '<div style="margin:5px"><div style="margin-bottom:5px">'.__(Mage::helper('core')->htmlEscape($loginRadiusTitle)).'</div><div class="interfacecontainerdiv"></div></div>';
|
17 |
}
|
18 |
echo '</p></div></div>';
|
19 |
}
|
app/design/frontend/default/default/template/sociallogin/belowregister.phtml
CHANGED
@@ -6,14 +6,14 @@ if( $this->loginEnable() == "1" && !$this->user_is_already_login() ){
|
|
6 |
$loginRadiusTitle = trim( $this->getLoginRadiusTitle() );
|
7 |
$UserAuth = $this->getApiResult($ApiKey, $ApiSecrete);
|
8 |
if ($belowRegister == 1) {
|
9 |
-
echo '<div class="block" style="margin-top:15px"><div class="block-title"><strong><span>Social Login</span></strong></div><div class="block-content"><p class="empty">';
|
10 |
if($ApiKey == "" && $ApiSecrete == ""){
|
11 |
-
echo '<p style ="color:red;">To activate your plugin, please log in to LoginRadius and get API Key & Secret. Web: <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
12 |
}elseif ($UserAuth == false) {
|
13 |
-
echo '<p style ="color:red;">Your LoginRadius API
|
14 |
}
|
15 |
else {
|
16 |
-
echo '<div style="margin:5px"><div style="margin-bottom:5px">'
|
17 |
}
|
18 |
echo '</p></div></div>';
|
19 |
}
|
6 |
$loginRadiusTitle = trim( $this->getLoginRadiusTitle() );
|
7 |
$UserAuth = $this->getApiResult($ApiKey, $ApiSecrete);
|
8 |
if ($belowRegister == 1) {
|
9 |
+
echo '<div class="block" style="margin-top:15px"><div class="block-title"><strong><span>'.__('Social Login').'</span></strong></div><div class="block-content"><p class="empty">';
|
10 |
if($ApiKey == "" && $ApiSecrete == ""){
|
11 |
+
echo '<p style ="color:red;">'. $this -> __('To activate your plugin, please log in to LoginRadius and get API Key & Secret. Web') .': <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
12 |
}elseif ($UserAuth == false) {
|
13 |
+
echo '<p style ="color:red;">'. $this -> __('Your LoginRadius API Key and Secret is not valid, please correct it or contact LoginRadius support at') .' <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
14 |
}
|
15 |
else {
|
16 |
+
echo '<div style="margin:5px"><div style="margin-bottom:5px">'.__(Mage::helper('core')->htmlEscape($loginRadiusTitle)).'</div><div class="interfacecontainerdiv"></div></div>';
|
17 |
}
|
18 |
echo '</p></div></div>';
|
19 |
}
|
app/design/frontend/default/default/template/sociallogin/linking.phtml
CHANGED
@@ -10,7 +10,7 @@ if( $this->loginEnable() == "1" ){
|
|
10 |
<div class="col-1">
|
11 |
<div class="box">
|
12 |
<div class="box-title">
|
13 |
-
<h3
|
14 |
</div>
|
15 |
<div class="box-content">
|
16 |
<?php
|
@@ -18,21 +18,21 @@ if( $this->loginEnable() == "1" ){
|
|
18 |
if(isset($_GET['LoginRadiusLinked']) && trim($_GET['LoginRadiusLinked']) == 1){
|
19 |
?>
|
20 |
<div style="color:green; background-color: #eaffdc; border: 1px solid #84b47a; padding: 3px 5px; margin:10px 0">
|
21 |
-
Account linked successfully.
|
22 |
</div>
|
23 |
<?php
|
24 |
// account from this provider is already linked
|
25 |
}elseif(isset($_GET['LoginRadiusLinked']) && trim($_GET['LoginRadiusLinked']) == 2){
|
26 |
?>
|
27 |
<div style="color:red; background-color: rgb(255, 235, 232); border: 1px solid rgb(204, 0, 0); padding: 3px 5px; margin:10px 0">
|
28 |
-
Multiple accounts cannot be linked from the same Social ID Provider.
|
29 |
</div>
|
30 |
<?php
|
31 |
// account already mapped or exists
|
32 |
}elseif(isset($_GET['LoginRadiusLinked']) && trim($_GET['LoginRadiusLinked']) == 0){
|
33 |
?>
|
34 |
<div style="color:red; background-color: rgb(255, 235, 232); border: 1px solid rgb(204, 0, 0); padding: 3px 5px;; margin:10px 0">
|
35 |
-
Account already exists or mapped.
|
36 |
</div>
|
37 |
<?php
|
38 |
}
|
@@ -53,7 +53,7 @@ if( $this->loginEnable() == "1" ){
|
|
53 |
}
|
54 |
?>
|
55 |
<div style="color:green; background-color: #eaffdc; border: 1px solid #84b47a; padding: 3px 5px;">
|
56 |
-
Account removed successfully.
|
57 |
</div>
|
58 |
<?php
|
59 |
}
|
@@ -69,10 +69,10 @@ if( $this->loginEnable() == "1" ){
|
|
69 |
if($result["provider"] != NULL || $result["provider"] != ""){
|
70 |
echo '<div style="float:left">';
|
71 |
if(Mage::getSingleton("customer/session")->getloginRadiusId() == $result["sociallogin_id"]){
|
72 |
-
echo '<span style="color:green">Currently </span>';
|
73 |
}
|
74 |
-
echo 'Connected with <img alt="'.ucfirst($result['provider']).'" title="'.ucfirst($result['provider']).'" src="'.Mage::getDesign()->getSkinUrl("Loginradius".DS."Sociallogin".DS."images".DS."Linking".DS.$result["provider"].'.png', array('_area'=>'frontend')).'" />'.
|
75 |
-
'</div> <div style="float:right"><a href="'.Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_LINK).'customer/account/?LoginRadiusUnlink='.$result["sociallogin_id"].'" title="Unlink this ID from your account">Remove</a></div>'.
|
76 |
'<br />';
|
77 |
}
|
78 |
}
|
@@ -84,7 +84,7 @@ if( $this->loginEnable() == "1" ){
|
|
84 |
<div class="col-2">
|
85 |
<div class="box">
|
86 |
<div class="box-title">
|
87 |
-
<h3
|
88 |
</div>
|
89 |
<div class="box-content">
|
90 |
<div class="interfacecontainerdiv" style="margin-left:10px"></div>
|
10 |
<div class="col-1">
|
11 |
<div class="box">
|
12 |
<div class="box-title">
|
13 |
+
<h3><?php echo __('Linked Accounts') ?></h3>
|
14 |
</div>
|
15 |
<div class="box-content">
|
16 |
<?php
|
18 |
if(isset($_GET['LoginRadiusLinked']) && trim($_GET['LoginRadiusLinked']) == 1){
|
19 |
?>
|
20 |
<div style="color:green; background-color: #eaffdc; border: 1px solid #84b47a; padding: 3px 5px; margin:10px 0">
|
21 |
+
<?php echo __('Account linked successfully.') ?>
|
22 |
</div>
|
23 |
<?php
|
24 |
// account from this provider is already linked
|
25 |
}elseif(isset($_GET['LoginRadiusLinked']) && trim($_GET['LoginRadiusLinked']) == 2){
|
26 |
?>
|
27 |
<div style="color:red; background-color: rgb(255, 235, 232); border: 1px solid rgb(204, 0, 0); padding: 3px 5px; margin:10px 0">
|
28 |
+
<?php echo __('Multiple accounts cannot be linked from the same Social ID Provider.') ?>
|
29 |
</div>
|
30 |
<?php
|
31 |
// account already mapped or exists
|
32 |
}elseif(isset($_GET['LoginRadiusLinked']) && trim($_GET['LoginRadiusLinked']) == 0){
|
33 |
?>
|
34 |
<div style="color:red; background-color: rgb(255, 235, 232); border: 1px solid rgb(204, 0, 0); padding: 3px 5px;; margin:10px 0">
|
35 |
+
<?php echo __('Account already exists or mapped.') ?>
|
36 |
</div>
|
37 |
<?php
|
38 |
}
|
53 |
}
|
54 |
?>
|
55 |
<div style="color:green; background-color: #eaffdc; border: 1px solid #84b47a; padding: 3px 5px;">
|
56 |
+
<?php echo __('Account removed successfully.') ?>
|
57 |
</div>
|
58 |
<?php
|
59 |
}
|
69 |
if($result["provider"] != NULL || $result["provider"] != ""){
|
70 |
echo '<div style="float:left">';
|
71 |
if(Mage::getSingleton("customer/session")->getloginRadiusId() == $result["sociallogin_id"]){
|
72 |
+
echo '<span style="color:green">'.__("Currently").' </span>';
|
73 |
}
|
74 |
+
echo __('Connected with').' <img alt="'.ucfirst($result['provider']).'" title="'.ucfirst($result['provider']).'" src="'.Mage::getDesign()->getSkinUrl("Loginradius".DS."Sociallogin".DS."images".DS."Linking".DS.$result["provider"].'.png', array('_area'=>'frontend')).'" />'.
|
75 |
+
'</div> <div style="float:right"><a href="'.Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_LINK).'customer/account/?LoginRadiusUnlink='.$result["sociallogin_id"].'" title="'.__('Unlink this ID from your account').'">'.__('Remove').'</a></div>'.
|
76 |
'<br />';
|
77 |
}
|
78 |
}
|
84 |
<div class="col-2">
|
85 |
<div class="box">
|
86 |
<div class="box-title">
|
87 |
+
<h3><?php echo __('Link Social IDs to your Magento Account') ?></h3>
|
88 |
</div>
|
89 |
<div class="box-content">
|
90 |
<div class="interfacecontainerdiv" style="margin-left:10px"></div>
|
app/design/frontend/default/default/template/sociallogin/sociallogin.phtml
CHANGED
@@ -6,22 +6,22 @@ if( $this->loginEnable() == "1" ){
|
|
6 |
$loginRadiusTitle = trim( $this->getLoginRadiusTitle() );
|
7 |
$UserAuth = $this->getApiResult($ApiKey, $ApiSecrete);
|
8 |
if ($showdefault == 1) {
|
9 |
-
echo '<div class="block"><div class="block-title"><strong><span>Social Login</span></strong></div><div class="block-content"><p class="empty">';
|
10 |
if ($this->user_is_already_login()) {
|
11 |
$userName = Mage::getSingleton('customer/session')->getCustomer()->getName();
|
12 |
if( $loginRadiusAvatar = trim( $this->getAvatar( Mage::getSingleton('customer/session')->getCustomer()->getId() ) ) ){
|
13 |
echo "<img style='float:left' width='50' height='50' src='".$loginRadiusAvatar."' />";
|
14 |
}
|
15 |
-
echo "<span style='clear:both; float:left'>Welcome! $userName </span>";
|
16 |
}
|
17 |
else {
|
18 |
if($ApiKey == "" && $ApiSecrete == ""){
|
19 |
-
echo '<p style ="color:red;">To activate your plugin, please log in to LoginRadius and get API Key & Secret. Web: <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
20 |
}elseif ($UserAuth == false) {
|
21 |
-
echo '<p style ="color:red;">Your LoginRadius API
|
22 |
}
|
23 |
else {
|
24 |
-
echo $loginRadiusTitle.'<div class="interfacecontainerdiv" style="margin-left:10px"></div>';
|
25 |
}
|
26 |
}
|
27 |
echo '</p></div></div>';
|
6 |
$loginRadiusTitle = trim( $this->getLoginRadiusTitle() );
|
7 |
$UserAuth = $this->getApiResult($ApiKey, $ApiSecrete);
|
8 |
if ($showdefault == 1) {
|
9 |
+
echo '<div class="block"><div class="block-title"><strong><span>'.__('Social Login').'</span></strong></div><div class="block-content"><p class="empty">';
|
10 |
if ($this->user_is_already_login()) {
|
11 |
$userName = Mage::getSingleton('customer/session')->getCustomer()->getName();
|
12 |
if( $loginRadiusAvatar = trim( $this->getAvatar( Mage::getSingleton('customer/session')->getCustomer()->getId() ) ) ){
|
13 |
echo "<img style='float:left' width='50' height='50' src='".$loginRadiusAvatar."' />";
|
14 |
}
|
15 |
+
echo "<span style='clear:both; float:left'>".__("Welcome")."! $userName </span>";
|
16 |
}
|
17 |
else {
|
18 |
if($ApiKey == "" && $ApiSecrete == ""){
|
19 |
+
echo '<p style ="color:red;">'. $this -> __('To activate your plugin, please log in to LoginRadius and get API Key & Secret. Web') .': <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
20 |
}elseif ($UserAuth == false) {
|
21 |
+
echo '<p style ="color:red;">'. $this -> __('Your LoginRadius API Key and Secret is not valid, please correct it or contact LoginRadius support at') .' <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
22 |
}
|
23 |
else {
|
24 |
+
echo __($loginRadiusTitle).'<div class="interfacecontainerdiv" style="margin-left:10px"></div>';
|
25 |
}
|
26 |
}
|
27 |
echo '</p></div></div>';
|
app/design/frontend/default/default/template/sociallogin/sociallogincustom.phtml
CHANGED
@@ -7,12 +7,12 @@ if( $this->loginEnable() == "1" && !$this->user_is_already_login() ){
|
|
7 |
$UserAuth = $this->getApiResult($ApiKey, $ApiSecrete);
|
8 |
echo '<div><h2>OR</h2>';
|
9 |
if($ApiKey == "" && $ApiSecrete == ""){
|
10 |
-
echo '<p style ="color:red;">To activate your plugin, please log in to LoginRadius and get API Key & Secret. Web: <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
11 |
}elseif ($UserAuth == false) {
|
12 |
-
echo '<p style ="color:red;">Your LoginRadius API
|
13 |
}
|
14 |
else {
|
15 |
-
echo '<div style="margin-bottom:5px">'
|
16 |
}
|
17 |
echo '</div>';
|
18 |
}
|
7 |
$UserAuth = $this->getApiResult($ApiKey, $ApiSecrete);
|
8 |
echo '<div><h2>OR</h2>';
|
9 |
if($ApiKey == "" && $ApiSecrete == ""){
|
10 |
+
echo '<p style ="color:red;">'. $this -> __('To activate your plugin, please log in to LoginRadius and get API Key & Secret. Web') .': <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
11 |
}elseif ($UserAuth == false) {
|
12 |
+
echo '<p style ="color:red;">'. $this -> __('Your LoginRadius API Key and Secret is not valid, please correct it or contact LoginRadius support at') .' <b><a href ="http://www.loginradius.com" target = "_blank">www.LoginRadius.com</a></b></p>';
|
13 |
}
|
14 |
else {
|
15 |
+
echo '<div style="margin-bottom:5px">'.__(Mage::helper('core')->htmlEscape($loginRadiusTitle)).'</div><div class="interfacecontainerdiv"></div>';
|
16 |
}
|
17 |
echo '</div>';
|
18 |
}
|
app/design/frontend/default/default/template/sociallogin/socialshare_head.phtml
CHANGED
@@ -141,11 +141,11 @@ echo $sharingScript;
|
|
141 |
if( $this->loginEnable() == "1" ){
|
142 |
$loc = Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_LINK)."sociallogin/";
|
143 |
if($this->getLayout()->getBlock('head')->getTitle() == "Checkout"){
|
144 |
-
$loginRadiusCallback = $loc."?
|
145 |
}elseif($this->getLayout()->getBlock('head')->getTitle() == "My Account"){
|
146 |
$loginRadiusCallback = $loc."?loginRadiusLinking=1";
|
147 |
}else{
|
148 |
-
$loginRadiusCallback = $loc;
|
149 |
}
|
150 |
?>
|
151 |
<script src="//hub.loginradius.com/include/js/LoginRadius.js" ></script>
|
141 |
if( $this->loginEnable() == "1" ){
|
142 |
$loc = Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_LINK)."sociallogin/";
|
143 |
if($this->getLayout()->getBlock('head')->getTitle() == "Checkout"){
|
144 |
+
$loginRadiusCallback = $loc."?loginradiuscheckout=1";
|
145 |
}elseif($this->getLayout()->getBlock('head')->getTitle() == "My Account"){
|
146 |
$loginRadiusCallback = $loc."?loginRadiusLinking=1";
|
147 |
}else{
|
148 |
+
$loginRadiusCallback = $loc."?redirect_to=".Mage::helper('core/url')->getCurrentUrl();
|
149 |
}
|
150 |
?>
|
151 |
<script src="//hub.loginradius.com/include/js/LoginRadius.js" ></script>
|
app/design/frontend/default/default/template/sociallogin/socialshareproduct.phtml
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<?php
|
2 |
if( $this->horizontalShareEnable() == "1" && $this->horizontalShareProduct() == "1"){
|
3 |
if(trim($this->sharingTitle()) != ""){
|
4 |
-
echo '<div style="font-weight:bold">'.trim($this->sharingTitle()).'</div>';
|
5 |
}
|
6 |
echo '<div class="loginRadiusHorizontalSharing"></div>';
|
7 |
}
|
8 |
-
if($this->verticalShareEnable() == "1" && $this->
|
9 |
echo '<div class="loginRadiusVerticalSharing"></div>';
|
10 |
}
|
11 |
?>
|
1 |
<?php
|
2 |
if( $this->horizontalShareEnable() == "1" && $this->horizontalShareProduct() == "1"){
|
3 |
if(trim($this->sharingTitle()) != ""){
|
4 |
+
echo '<div style="font-weight:bold">'.__(trim($this->sharingTitle())).'</div>';
|
5 |
}
|
6 |
echo '<div class="loginRadiusHorizontalSharing"></div>';
|
7 |
}
|
8 |
+
if($this->verticalShareEnable() == "1" && $this->verticalShareProduct() == "1"){
|
9 |
echo '<div class="loginRadiusVerticalSharing"></div>';
|
10 |
}
|
11 |
?>
|
app/design/frontend/default/default/template/sociallogin/socialsharesuccess.phtml
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?php
|
2 |
if($this->horizontalShareEnable() == "1" && $this->horizontalShareSuccess() == "1"){
|
3 |
if(trim($this->sharingTitle()) != ""){
|
4 |
-
echo '<div style="font-weight:bold">'.trim($this->sharingTitle()).'</div>';
|
5 |
}
|
6 |
echo '<div class="loginRadiusHorizontalSharing"></div>';
|
7 |
}
|
1 |
<?php
|
2 |
if($this->horizontalShareEnable() == "1" && $this->horizontalShareSuccess() == "1"){
|
3 |
if(trim($this->sharingTitle()) != ""){
|
4 |
+
echo '<div style="font-weight:bold">'.__(trim($this->sharingTitle())).'</div>';
|
5 |
}
|
6 |
echo '<div class="loginRadiusHorizontalSharing"></div>';
|
7 |
}
|
package.xml
CHANGED
@@ -1,18 +1,18 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>LoginRadius</name>
|
4 |
-
<version>3.
|
5 |
<stability>stable</stability>
|
6 |
<license>GNU General Public License (GPL)</license>
|
7 |
<channel>community</channel>
|
8 |
<extends/>
|
9 |
-
<summary>Social Login
|
10 |
-
<description>Add Social Login
|
11 |
-
<notes>
|
12 |
<authors><author><name>LoginRadius Team</name><user>LoginRadius</user><email>developers@loginradius.com</email></author></authors>
|
13 |
-
<date>2013-
|
14 |
-
<time>
|
15 |
-
<contents><target name="magecommunity"><dir name="Loginradius"><dir name="Sociallogin"><dir name="Block"><file name="Auth.php" hash="
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php></required></dependencies>
|
18 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>LoginRadius</name>
|
4 |
+
<version>3.6.0</version>
|
5 |
<stability>stable</stability>
|
6 |
<license>GNU General Public License (GPL)</license>
|
7 |
<channel>community</channel>
|
8 |
<extends/>
|
9 |
+
<summary>Social Login and Sharing for Magento</summary>
|
10 |
+
<description>Add Social Login and Sharing to your Magento website and also get accurate User Profile Data and Social Analytics.</description>
|
11 |
+
<notes>Twelth release of social login</notes>
|
12 |
<authors><author><name>LoginRadius Team</name><user>LoginRadius</user><email>developers@loginradius.com</email></author></authors>
|
13 |
+
<date>2013-09-12</date>
|
14 |
+
<time>03:09:14</time>
|
15 |
+
<contents><target name="mageetc"><dir name="modules"><file name="Loginradius_Sociallogin.xml" hash="6c5bb03c460936006692aa1d01d142ba"/></dir></target><target name="magecommunity"><dir name="Loginradius"><dir name="Sociallogin"><dir name="Block"><file name="Auth.php" hash="7ec44bd9926175c0bc40662116050252"/><file name="Sociallogin.php" hash="5f9c77ac48bd10ca8b5139f48168c29d"/><file name="horizontalsharing.php" hash="daee7f72d53fd2492740cf546c897c37"/><file name="verticalsharing.php" hash="e2322a53ba7c97abbf495506d078e0fb"/></dir><dir name="Helper"><file name="Data.php" hash="7fe10f157031a33dd5c312f61f36f650"/></dir><dir name="Model"><dir name="Mysql4"><dir name="Sociallogin"><file name="Collection.php" hash="b4632ab82692843577c985a3ed23981f"/></dir><file name="Sociallogin.php" hash="8c8d5d266c57ea0400d5a560a943ea14"/></dir><file name="Sociallogin.php" hash="a49fc157930cd09fcbe522aabb1d986b"/><dir name="Source"><file name="HorizontalSharing.php" hash="5e1c18d133cd3117e0eb0c732544177c"/><file name="Iconsize.php" hash="072bf28bd0d145829cbbae420b898d36"/><file name="SharingVerticalAlignment.php" hash="be293d7c6bddf42341be05ff092f857d"/><file name="Uihover.php" hash="6115effdefc9b9a870a03c79b56557aa"/><file name="Uihover2.php" hash="eea7208694113c353853ee5838bd9449"/><file name="VerticalSharing.php" hash="01788a41fea1546ddd334bf9c3f9d7f4"/></dir><dir name="System"><dir name="Config"><file name="Info.php" hash="20a4ab4b9578df11f90bd01038dbf51a"/></dir></dir></dir><dir name="controllers"><file name="IndexController.php" hash="d10c1d9ed4286925aa1099f16dd337e3"/><file name="Popup.php" hash="1e34609b36f7959c8df3240522f833dd"/></dir><dir name="etc"><file name="config.xml" hash="f9101c44b9b334a6c72195dca7a71adf"/><file name="system.xml" hash="3c260701d136532347df788288186c36"/><file name="widget.xml" hash="f6e8a254aa3a9ff86f958710c4e8edca"/></dir><dir name="sql"><dir name="sociallogin_setup"><file name="mysql4-install-3.6.0.php" hash="a04e6f43b037bea1d40147e9b7df3ef9"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="loginradius_sociallogin.xml" hash="f5d1b065342c0fd25f0087f000100821"/></dir></dir></dir></dir><dir name="frontend"><dir name="default"><dir name="default"><dir name="template"><dir name="sociallogin"><file name="abovelogin.phtml" hash="76260ae94bc50ba7c2cd750f529747b4"/><file name="aboveregister.phtml" hash="fcc579c2bd34b2bc9877e61f6abfd0d5"/><file name="belowlogin.phtml" hash="cb854a34b1a5ef7262ffb1de3ff0f247"/><file name="belowregister.phtml" hash="b9a31437aa487f28f24cb046ad7a5239"/><file name="linking.phtml" hash="607c388e2d168b92978fb7978abcf54b"/><file name="linkingscript.phtml" hash="77f0e6348fed90c6cb24f064a8fac2e9"/><file name="sociallogin.phtml" hash="0b3979470d8dabde7f03fc09cde9ba90"/><file name="sociallogincustom.phtml" hash="04daac1337596641b2b3bdd38aad0dba"/><file name="socialshare_head.phtml" hash="7ec65623128c5230b9bc73192beca024"/><file name="socialshareproduct.phtml" hash="d4b16132913796507de4d2820b3302d2"/><file name="socialsharesuccess.phtml" hash="38e93ea63416c7fa84d498a994bcaf40"/></dir></dir><dir name="layout"><file name="sociallogin.xml" hash="779fdf9abafddea89ec87cdbd791b7ae"/></dir></dir></dir></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="Loginradius"><dir name="Sociallogin"><dir name="css"><file name="admin-ui.css" hash="ae62c698f97fb22f5c85d3d4fc3eb0ff"/><file name="lrshare_iconsprite32.png" hash="a016ded3f25653acf2fa9dfab8a38103"/></dir><dir name="images"><dir name="Linking"><file name="amazon.png" hash="961d0082ed4b433d8e0274c133072e2c"/><file name="aol.png" hash="4e51f60c1b8750c5b9dfa94f56fe13b1"/><file name="facebook.png" hash="141309628c58912076f00954b3fd19a6"/><file name="foursquare.png" hash="de2f4fcf5b3c1156f22ed546f5c3f0c5"/><file name="github.png" hash="45f8e1436fc5c5803ed9d4edb7cb59b6"/><file name="google.png" hash="ffeddc7d14c9b4de2efb6b8ea0f5f652"/><file name="hyves.png" hash="3c77fd2243b22c61915a950c3910f37c"/><file name="kaixin.png" hash="bc84991a5c9d15e20946fae5e9c27f4d"/><file name="linkedin.png" hash="7a9bc12ec91ab2a30442c56a9f70e9ea"/><file name="live.png" hash="9d747bae72fc0f2e3a04f32896d62fbc"/><file name="livejournal.png" hash="e21f34630444412ab3dd197884e0c2e6"/><file name="mixi.png" hash="909e7edc76e59b448d56043eee5e1412"/><file name="myopenid.png" hash="c8295969044cb9d99f8348091ba75319"/><file name="myspace.png" hash="42cd07decb5f4a1fba604ef8df32ef2e"/><file name="odnoklassniki.png" hash="34cd7d239583b015cdd1adb5b7fec085"/><file name="openid.png" hash="92bd4471ef1d5dd04855887806db74f0"/><file name="orange.png" hash="9b9b8f2da956a238e7d58c241423af8a"/><file name="paypal.png" hash="082f0b50411b1dfb1bfd86cfdeb92cea"/><file name="persona.png" hash="e0d926f89e9c428aece1e0f9dbb1f8f2"/><file name="qq.png" hash="8e6dc34bdf03f07277e0aadf8706a4a7"/><file name="renren.png" hash="040a0af8119b7f85bfc2df41ec56f915"/><file name="salesforce.png" hash="e41bcac63438bb04af3a9745b816a675"/><file name="stackexchange.png" hash="8ab952fe75d4a96d6752792ffdcbf0c3"/><file name="steamcommunity.png" hash="ad05c57a4ee01ebc01428b0da905d6b6"/><file name="twitter.png" hash="48044aca3a1d4864361f78c02ba86848"/><file name="verisign.png" hash="7a15fd820171218d803d26e7a3ec46a3"/><file name="virgilio.png" hash="f5c3b6e19c38903a192954934000f60a"/><file name="vkontakte.png" hash="ae1e98911fe9ea6da8a50a568c082133"/><file name="wordpress.png" hash="8ce8b46a2233b8497dd10d9c4d535e22"/><file name="yahoo.png" hash="5c159cc8fed73621b2c12600f8dac288"/></dir><dir name="Sharing"><dir name="Horizontal"><file name="horizonSharing16.png" hash="64188c128c8263c052153cf9708ac218"/><file name="horizonSharing32.png" hash="5e85ac81864885bcef5cc9691a9eba49"/><file name="horizontal.png" hash="6bb8038603bbf9cc70bac8365eebd7ba"/><file name="single-image-theme-large.png" hash="e6ff4a26149b631639b601d95e2dc361"/><file name="single-image-theme-small.png" hash="8c2b20fa0f276e33f3876783eb2cbd74"/><file name="vertical.png" hash="9c71cfb83ffb121a0ef89e263d474387"/></dir><dir name="Vertical"><file name="16VerticlewithBox.png" hash="73b3abf54889144e9188ffaa76cbb11f"/><file name="32VerticlewithBox.png" hash="37060e164ca4f7c00f430d5f1ab7eddd"/><file name="verticalhorizontal.png" hash="469ce5302d294dc987bdb070ef448446"/><file name="verticalvertical.png" hash="f59288edc8c87dde216b6616027aa72b"/></dir></dir></dir><dir name="js"><file name="admin-ui.js" hash="d0b05d81ca3cdcc53c0f394fd44f6b7c"/><file name="jquery.js" hash="5654b0561c66ca9c0ad2a1dd75e5d9b8"/><file name="jquery.ui.sortable.min.js" hash="b847eafb05bcc6ef0908ff07dcd2b0f1"/></dir></dir></dir></dir></dir></dir></target></contents>
|
16 |
<compatible/>
|
17 |
<dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php></required></dependencies>
|
18 |
</package>
|
skin/frontend/base/default/Loginradius/Sociallogin/css/admin-ui.css
CHANGED
@@ -70,6 +70,9 @@ loginradius_radio{
|
|
70 |
#row_sociallogin_options_horizontalSharing_horizontalSharingTheme td input{
|
71 |
vertical-align:top
|
72 |
}
|
|
|
|
|
|
|
73 |
#row_sociallogin_options_verticalSharing_verticalSharingTheme td.value{
|
74 |
width:400px !important;
|
75 |
}
|
70 |
#row_sociallogin_options_horizontalSharing_horizontalSharingTheme td input{
|
71 |
vertical-align:top
|
72 |
}
|
73 |
+
#row_sociallogin_options_horizontalSharing_horizontalSharingTheme td[class=value]{
|
74 |
+
width: 400px !important
|
75 |
+
}
|
76 |
#row_sociallogin_options_verticalSharing_verticalSharingTheme td.value{
|
77 |
width:400px !important;
|
78 |
}
|
skin/frontend/base/default/Loginradius/Sociallogin/images/Sharing/Vertical/verticalhorizontal.png
CHANGED
Binary file
|
skin/frontend/base/default/Loginradius/Sociallogin/images/Sharing/Vertical/verticalvertical.png
CHANGED
Binary file
|
skin/frontend/base/default/Loginradius/Sociallogin/js/admin-ui.js
CHANGED
@@ -4,9 +4,14 @@ if(typeof String.prototype.trim !== 'function') {
|
|
4 |
return this.replace(/^\s+|\s+$/g, '');
|
5 |
}
|
6 |
}
|
|
|
|
|
|
|
|
|
7 |
var $loginRadiusJquery = jQuery.noConflict();
|
8 |
// prepare admin UI on window load
|
9 |
function loginRadiusPrepareAdminUI(){
|
|
|
10 |
// highlight API Key and Secret notification
|
11 |
if($loginRadiusJquery('#loginRadiusKeySecretNotification')){
|
12 |
$loginRadiusJquery('#loginRadiusKeySecretNotification').animate({'backgroundColor' : 'rgb(241, 142, 127)'}, 1000).animate({'backgroundColor' : '#FFFFE0'}, 1000).animate({'backgroundColor' : 'rgb(241, 142, 127)'}, 1000).animate({'backgroundColor' : '#FFFFE0'}, 1000);
|
@@ -16,11 +21,37 @@ function loginRadiusPrepareAdminUI(){
|
|
16 |
if(this.value.trim() == document.getElementById('sociallogin_options_messages_appid').value.trim()){
|
17 |
if($loginRadiusJquery('#spanApiKeyError').html() == undefined){
|
18 |
$loginRadiusJquery('#sociallogin_options_messages_appkey').before('<span id="spanApiKeyError" style="color:red">API Key and Secret cannot be same. Please paste correct API Key and Secret from your LoginRadius account in the corresponding fields.</span>');
|
|
|
|
|
19 |
}
|
20 |
}else{
|
21 |
$loginRadiusJquery('#spanApiKeyError').html('');
|
22 |
}
|
23 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
24 |
var horizontalSharingTheme, verticalSharingTheme;
|
25 |
// fetch horizontal and vertical sharing providers dynamically from LoginRadius on window load
|
26 |
var sharingType = ['horizontal', 'vertical'];
|
4 |
return this.replace(/^\s+|\s+$/g, '');
|
5 |
}
|
6 |
}
|
7 |
+
// validate numeric data
|
8 |
+
function loginRadiusIsNumber(n) {
|
9 |
+
return !isNaN(parseFloat(n)) && isFinite(n);
|
10 |
+
}
|
11 |
var $loginRadiusJquery = jQuery.noConflict();
|
12 |
// prepare admin UI on window load
|
13 |
function loginRadiusPrepareAdminUI(){
|
14 |
+
|
15 |
// highlight API Key and Secret notification
|
16 |
if($loginRadiusJquery('#loginRadiusKeySecretNotification')){
|
17 |
$loginRadiusJquery('#loginRadiusKeySecretNotification').animate({'backgroundColor' : 'rgb(241, 142, 127)'}, 1000).animate({'backgroundColor' : '#FFFFE0'}, 1000).animate({'backgroundColor' : 'rgb(241, 142, 127)'}, 1000).animate({'backgroundColor' : '#FFFFE0'}, 1000);
|
21 |
if(this.value.trim() == document.getElementById('sociallogin_options_messages_appid').value.trim()){
|
22 |
if($loginRadiusJquery('#spanApiKeyError').html() == undefined){
|
23 |
$loginRadiusJquery('#sociallogin_options_messages_appkey').before('<span id="spanApiKeyError" style="color:red">API Key and Secret cannot be same. Please paste correct API Key and Secret from your LoginRadius account in the corresponding fields.</span>');
|
24 |
+
}else{
|
25 |
+
$loginRadiusJquery('#spanApiKeyError').html('API Key and Secret cannot be same. Please paste correct API Key and Secret from your LoginRadius account in the corresponding fields.');
|
26 |
}
|
27 |
}else{
|
28 |
$loginRadiusJquery('#spanApiKeyError').html('');
|
29 |
}
|
30 |
}
|
31 |
+
// show warning, if number of social login icons is < 2 or if non-numeric
|
32 |
+
document.getElementById('sociallogin_options_messages_iconsPerRow').onblur = function(){
|
33 |
+
if(document.getElementById('sociallogin_options_messages_iconsPerRow').value.trim() < 2 || !loginRadiusIsNumber(document.getElementById('sociallogin_options_messages_iconsPerRow').value.trim())){
|
34 |
+
if($loginRadiusJquery('#loginRadiusNoColumnsError').html() == undefined){
|
35 |
+
$loginRadiusJquery('#sociallogin_options_messages_iconsPerRow').before('<span id="loginRadiusNoColumnsError" style="color:red">Please enter a valid number greater than 1.</span>');
|
36 |
+
}else{
|
37 |
+
$loginRadiusJquery('#loginRadiusNoColumnsError').html('Please enter a valid number greater than 1.');
|
38 |
+
}
|
39 |
+
}else{
|
40 |
+
$loginRadiusJquery('#loginRadiusNoColumnsError').html('');
|
41 |
+
}
|
42 |
+
}
|
43 |
+
// show warning, if "top" offset is non-numeric
|
44 |
+
document.getElementById('sociallogin_options_verticalSharing_offset').onblur = function(){
|
45 |
+
if(!loginRadiusIsNumber(document.getElementById('sociallogin_options_verticalSharing_offset').value.trim())){
|
46 |
+
if($loginRadiusJquery('#loginRadiusOffsetError').html() == undefined){
|
47 |
+
$loginRadiusJquery('#sociallogin_options_verticalSharing_offset').before('<span id="loginRadiusOffsetError" style="color:red">Please enter a valid number.</span>');
|
48 |
+
}else{
|
49 |
+
$loginRadiusJquery('#loginRadiusOffsetError').html('Please enter a valid number.');
|
50 |
+
}
|
51 |
+
}else{
|
52 |
+
$loginRadiusJquery('#loginRadiusOffsetError').html('');
|
53 |
+
}
|
54 |
+
}
|
55 |
var horizontalSharingTheme, verticalSharingTheme;
|
56 |
// fetch horizontal and vertical sharing providers dynamically from LoginRadius on window load
|
57 |
var sharingType = ['horizontal', 'vertical'];
|