Version Notes
Stable Version 1.0.3 - included Buttons on Checkout, improved landing page after login.
Download this release
Release Info
Developer | Soclever Social |
Extension | soclever_login |
Version | 1.0.3 |
Comparing to | |
See all releases |
Code changes from version 1.0.2 to 1.0.3
- app/code/local/Soclever/Sociallogin/Block/Adminhtml/Positions.php +1 -1
- app/code/local/Soclever/Sociallogin/Block/Scslheadfb.php +13 -0
- app/code/local/Soclever/Sociallogin/Block/Scsltrackpixel.php +13 -0
- app/code/local/Soclever/Sociallogin/controllers/IndexController.php +25 -8
- app/design/frontend/base/default/layout/sociallogin.xml +10 -4
- app/design/frontend/base/default/template/sociallogin/scsl_buttons.phtml +5 -169
- package.xml +20 -22
app/code/local/Soclever/Sociallogin/Block/Adminhtml/Positions.php
CHANGED
@@ -11,7 +11,7 @@ class Soclever_Sociallogin_Block_Adminhtml_Positions extends Mage_Adminhtml_Bloc
|
|
11 |
$api_secret=Mage::getStoreConfig('sociallogin_options/apisettings/scsl_appsecret');
|
12 |
$api_key=Mage::getStoreConfig('sociallogin_options/apisettings/scsl_appid');
|
13 |
|
14 |
-
$valid_data=file_get_contents("https://www.socleversocial.com/dashboard/
|
15 |
if($valid_data && $valid_data[0]!='0')
|
16 |
{
|
17 |
$selectedButtons=Mage::getStoreConfig('sociallogin_options/displaysettings/buttonstyle');
|
11 |
$api_secret=Mage::getStoreConfig('sociallogin_options/apisettings/scsl_appsecret');
|
12 |
$api_key=Mage::getStoreConfig('sociallogin_options/apisettings/scsl_appid');
|
13 |
|
14 |
+
$valid_data=file_get_contents("https://www.socleversocial.com/dashboard/mage_activate.php?site_id=".$site_id."&api_key=".$api_key."&api_secret=".$api_secret."&csplatform=magentologin&type=preview");
|
15 |
if($valid_data && $valid_data[0]!='0')
|
16 |
{
|
17 |
$selectedButtons=Mage::getStoreConfig('sociallogin_options/displaysettings/buttonstyle');
|
app/code/local/Soclever/Sociallogin/Block/Scslheadfb.php
ADDED
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
class Soclever_Sociallogin_Block_Scslheadfb extends Mage_Core_Block_Template
|
3 |
+
{
|
4 |
+
protected function _construct(){
|
5 |
+
parent::_construct();
|
6 |
+
|
7 |
+
}
|
8 |
+
public function _prepareLayout(){
|
9 |
+
return parent::_prepareLayout();
|
10 |
+
}
|
11 |
+
}
|
12 |
+
|
13 |
+
?>
|
app/code/local/Soclever/Sociallogin/Block/Scsltrackpixel.php
ADDED
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
class Soclever_Sociallogin_Block_Scsltrackpixel extends Mage_Core_Block_Template
|
3 |
+
{
|
4 |
+
protected function _construct(){
|
5 |
+
parent::_construct();
|
6 |
+
|
7 |
+
}
|
8 |
+
public function _prepareLayout(){
|
9 |
+
return parent::_prepareLayout();
|
10 |
+
}
|
11 |
+
}
|
12 |
+
|
13 |
+
?>
|
app/code/local/Soclever/Sociallogin/controllers/IndexController.php
CHANGED
@@ -15,9 +15,15 @@ class Soclever_Sociallogin_IndexController extends Mage_Core_Controller_Front_Ac
|
|
15 |
if(isset($_GET['lc']) && $_GET['lc']!='')
|
16 |
{
|
17 |
setcookie('lc',$_GET['lc'],time()+100,'/');
|
|
|
18 |
|
19 |
}
|
20 |
-
|
|
|
|
|
|
|
|
|
|
|
21 |
$get_fb=file_get_contents("https://www.socleversocial.com/dashboard/get_fb_data.php?siteid=".Mage::getStoreConfig('sociallogin_options/apisettings/scsl_siteid')."");
|
22 |
|
23 |
if($get_fb!='0')
|
@@ -120,8 +126,13 @@ $customer = Mage::getModel("customer/customer");
|
|
120 |
$customer->setWebsiteId(Mage::app()->getWebsite()->getId());
|
121 |
$customer->loadByEmail($username);
|
122 |
|
123 |
-
$redirect_location=($
|
124 |
-
|
|
|
|
|
|
|
|
|
|
|
125 |
?>
|
126 |
<script type="text/javascript">
|
127 |
|
@@ -168,7 +179,7 @@ $customer = Mage::getModel("customer/customer");
|
|
168 |
/*}, 3000);*/
|
169 |
</script>
|
170 |
<?php
|
171 |
-
echo"<img src='https://www.socleversocial.com/dashboard/images/pw.gif' alt='wait!' title='wait!'>";
|
172 |
$this->getSession()->loginById($customer->getId());
|
173 |
exit;
|
174 |
}
|
@@ -182,7 +193,7 @@ $customer = Mage::getModel("customer/customer");
|
|
182 |
}
|
183 |
public function pploginAction()
|
184 |
{
|
185 |
-
|
186 |
|
187 |
$resource = Mage::getSingleton('core/resource');
|
188 |
$tableName = $resource->getTableName('customer_entity');
|
@@ -221,12 +232,14 @@ $customer = Mage::getModel("customer/customer");
|
|
221 |
$customer->setWebsiteId(Mage::app()->getWebsite()->getId());
|
222 |
$customer->loadByEmail($username);
|
223 |
$redirect_location=($_GET['lc']=='c')?Mage::getBaseUrl()."checkout/onepage/":Mage::getBaseUrl()."customer/account/";
|
|
|
|
|
224 |
?>
|
225 |
<script type="text/javascript">
|
226 |
-
setTimeout(function(){ window.location.href="<?php echo $redirect_location; ?>"; },
|
227 |
</script>
|
228 |
<?php
|
229 |
-
echo"<img src='https://www.socleversocial.com/dashboard/images/pw.gif' alt='wait!' title='wait!'>";
|
230 |
$this->getSession()->loginById($customer->getId());
|
231 |
exit;
|
232 |
}
|
@@ -280,6 +293,8 @@ try
|
|
280 |
{
|
281 |
if($openid->validate())
|
282 |
{
|
|
|
|
|
283 |
$d = $openid->getAttributes();
|
284 |
//echo "https://www.socleversocial.com/dashboard/track_register_new.php?is_yh=1&is_from=5&siteid=".Mage::getStoreConfig('sociallogin_options/apisettings/scsl_siteid')."&other=".json_encode($d)."";
|
285 |
/*$response_content=file_get_contents("https://www.socleversocial.com/dashboard/track_register_new.php?is_yh=1&is_from=5&siteid=".Mage::getStoreConfig('sociallogin_options/apisettings/scsl_siteid')."&other=".json_encode($d)."");
|
@@ -348,7 +363,7 @@ xmlhttp.send();
|
|
348 |
|
349 |
|
350 |
<?php
|
351 |
-
exit
|
352 |
|
353 |
|
354 |
}
|
@@ -409,6 +424,8 @@ $customer = Mage::getModel("customer/customer");
|
|
409 |
|
410 |
if(Mage::getSingleton('customer/session')->isLoggedIn())
|
411 |
{
|
|
|
|
|
412 |
exit("1");
|
413 |
}
|
414 |
|
15 |
if(isset($_GET['lc']) && $_GET['lc']!='')
|
16 |
{
|
17 |
setcookie('lc',$_GET['lc'],time()+100,'/');
|
18 |
+
setcookie('lch',$_GET['lch'],time()-100,'/');
|
19 |
|
20 |
}
|
21 |
+
if(isset($_GET['lch']) && $_GET['lch']!='')
|
22 |
+
{
|
23 |
+
setcookie('lch',$_GET['lch'],time()+100,'/');
|
24 |
+
setcookie('lc',$_GET['lc'],time()-100,'/');
|
25 |
+
|
26 |
+
}
|
27 |
$get_fb=file_get_contents("https://www.socleversocial.com/dashboard/get_fb_data.php?siteid=".Mage::getStoreConfig('sociallogin_options/apisettings/scsl_siteid')."");
|
28 |
|
29 |
if($get_fb!='0')
|
126 |
$customer->setWebsiteId(Mage::app()->getWebsite()->getId());
|
127 |
$customer->loadByEmail($username);
|
128 |
|
129 |
+
$redirect_location=($_COOKIE['lc']=='c')?Mage::getBaseUrl()."checkout/onepage/":Mage::getBaseUrl()."customer/account/";
|
130 |
+
if(isset($_COOKIE['lch']) && $_COOKIE['lch']!='')
|
131 |
+
{
|
132 |
+
$redirect_location=$_COOKIE['lch'];
|
133 |
+
}
|
134 |
+
$is_from='1';
|
135 |
+
Mage::getSingleton('core/session')->setSessionVariable($is_from);
|
136 |
?>
|
137 |
<script type="text/javascript">
|
138 |
|
179 |
/*}, 3000);*/
|
180 |
</script>
|
181 |
<?php
|
182 |
+
//echo"<img src='https://www.socleversocial.com/dashboard/images/pw.gif' alt='wait!' title='wait!'>";
|
183 |
$this->getSession()->loginById($customer->getId());
|
184 |
exit;
|
185 |
}
|
193 |
}
|
194 |
public function pploginAction()
|
195 |
{
|
196 |
+
$paypal_data=json_decode($_GET['data']);
|
197 |
|
198 |
$resource = Mage::getSingleton('core/resource');
|
199 |
$tableName = $resource->getTableName('customer_entity');
|
232 |
$customer->setWebsiteId(Mage::app()->getWebsite()->getId());
|
233 |
$customer->loadByEmail($username);
|
234 |
$redirect_location=($_GET['lc']=='c')?Mage::getBaseUrl()."checkout/onepage/":Mage::getBaseUrl()."customer/account/";
|
235 |
+
$is_from='7';
|
236 |
+
Mage::getSingleton('core/session')->setSessionVariable($is_from);
|
237 |
?>
|
238 |
<script type="text/javascript">
|
239 |
+
setTimeout(function(){ window.location.href="<?php echo $redirect_location; ?>"; },1000);
|
240 |
</script>
|
241 |
<?php
|
242 |
+
//echo"<img src='https://www.socleversocial.com/dashboard/images/pw.gif' alt='wait!' title='wait!'>";
|
243 |
$this->getSession()->loginById($customer->getId());
|
244 |
exit;
|
245 |
}
|
293 |
{
|
294 |
if($openid->validate())
|
295 |
{
|
296 |
+
$is_from='5';
|
297 |
+
Mage::getSingleton('core/session')->setSessionVariable($is_from);
|
298 |
$d = $openid->getAttributes();
|
299 |
//echo "https://www.socleversocial.com/dashboard/track_register_new.php?is_yh=1&is_from=5&siteid=".Mage::getStoreConfig('sociallogin_options/apisettings/scsl_siteid')."&other=".json_encode($d)."";
|
300 |
/*$response_content=file_get_contents("https://www.socleversocial.com/dashboard/track_register_new.php?is_yh=1&is_from=5&siteid=".Mage::getStoreConfig('sociallogin_options/apisettings/scsl_siteid')."&other=".json_encode($d)."");
|
363 |
|
364 |
|
365 |
<?php
|
366 |
+
exit;
|
367 |
|
368 |
|
369 |
}
|
424 |
|
425 |
if(Mage::getSingleton('customer/session')->isLoggedIn())
|
426 |
{
|
427 |
+
$is_from=$_POST['is_from'];
|
428 |
+
Mage::getSingleton('core/session')->setSessionVariable($is_from);
|
429 |
exit("1");
|
430 |
}
|
431 |
|
app/design/frontend/base/default/layout/sociallogin.xml
CHANGED
@@ -2,9 +2,10 @@
|
|
2 |
<layout version="1.0.0">
|
3 |
<default>
|
4 |
<reference name="head">
|
5 |
-
<block type="sociallogin/scslhead" name="sociallogin_head" template="sociallogin/sociallogin_head.phtml" />
|
6 |
-
|
7 |
-
|
|
|
8 |
<checkout_onepage_index>
|
9 |
<reference name="checkout.onepage.login.before">
|
10 |
<block type="sociallogin/scslshow" before="-" name="sociallogin_show">
|
@@ -14,9 +15,14 @@
|
|
14 |
</checkout_onepage_index>
|
15 |
<customer_account_login>
|
16 |
<reference name="content">
|
17 |
-
<block type="sociallogin/scslshow"
|
18 |
|
19 |
</block>
|
20 |
</reference>
|
21 |
</customer_account_login>
|
|
|
|
|
|
|
|
|
|
|
22 |
</layout>
|
2 |
<layout version="1.0.0">
|
3 |
<default>
|
4 |
<reference name="head">
|
5 |
+
<block type="sociallogin/scslhead" name="sociallogin_head" template="sociallogin/sociallogin_head.phtml" />
|
6 |
+
<block type="sociallogin/scslheadfb" name="sociallogin_headfb" template="sociallogin/sociallogin_fb.phtml" />
|
7 |
+
</reference>
|
8 |
+
</default>
|
9 |
<checkout_onepage_index>
|
10 |
<reference name="checkout.onepage.login.before">
|
11 |
<block type="sociallogin/scslshow" before="-" name="sociallogin_show">
|
15 |
</checkout_onepage_index>
|
16 |
<customer_account_login>
|
17 |
<reference name="content">
|
18 |
+
<block type="sociallogin/scslshow" before="-" name="sociallogin_show">
|
19 |
|
20 |
</block>
|
21 |
</reference>
|
22 |
</customer_account_login>
|
23 |
+
<checkout_onepage_success>
|
24 |
+
<reference name="content">
|
25 |
+
<block type="sociallogin/scsltrackpixel" name="sociallogin_trackpixel" template="sociallogin/sociallogin_trackpixel.phtml" />
|
26 |
+
</reference>
|
27 |
+
</checkout_onepage_success>
|
28 |
</layout>
|
app/design/frontend/base/default/template/sociallogin/scsl_buttons.phtml
CHANGED
@@ -2,179 +2,15 @@
|
|
2 |
$site_id=Mage::getStoreConfig('sociallogin_options/apisettings/scsl_siteid');
|
3 |
$api_secret=Mage::getStoreConfig('sociallogin_options/apisettings/scsl_appsecret');
|
4 |
$api_key=Mage::getStoreConfig('sociallogin_options/apisettings/scsl_appid');
|
|
|
|
|
5 |
|
6 |
-
$valid_data=file_get_contents("https://www.socleversocial.com/dashboard/
|
7 |
|
8 |
if($valid_data && $valid_data!='0~~0')
|
9 |
{
|
10 |
-
$
|
11 |
-
|
12 |
-
$selectedProviders="https://www.socleversocial.com/dashboard/img/social_icon/social_login_fc_30.png";
|
13 |
-
$btn_style=Mage::getStoreConfig('sociallogin_options/displaysettings/buttonstyle');
|
14 |
-
$button_size=Mage::getStoreConfig('sociallogin_options/displaysettings/buttonsize');
|
15 |
-
$SITE_URL="https://www.socleversocial.com/dashboard/";
|
16 |
-
if($btn_style=="ic") {
|
17 |
-
$btn_width=$button_size;
|
18 |
-
}
|
19 |
-
else if($btn_style=="fc" || $btn_style=="fg")
|
20 |
-
{
|
21 |
-
if($button_size=="30") {$btn_width="78"; }
|
22 |
-
if($button_size=="40") {$btn_width="104"; }
|
23 |
-
if($button_size=="50") {$btn_width="130"; }
|
24 |
-
if($button_size=="60") {$btn_width="156"; }
|
25 |
-
if($button_size=="65") {$btn_width="169"; }
|
26 |
-
}
|
27 |
-
|
28 |
-
$network=explode(",",$valid_data_arr[0]);
|
29 |
-
$imgdiv="";
|
30 |
-
$img='social_login_'.$btn_style.'_'.$button_size.'.png';
|
31 |
-
/*if(in_array('2',$network))
|
32 |
-
{
|
33 |
-
$bg_position=$btn_width;
|
34 |
-
$imgdiv .='<div style="float: left; margin-right: 10px;margin-top: 10px;width: '.$btn_width.'px; height: '.$button_size.'px; background-image: url('.$SITE_URL.'img/social_icon/'.$img.'); background-position: -'.$bg_position.'px 0px;"></div>';
|
35 |
-
|
36 |
-
|
37 |
-
}
|
38 |
-
|
39 |
-
if(in_array('4',$network))
|
40 |
-
{
|
41 |
-
$bg_position=((3)*$btn_width);
|
42 |
-
|
43 |
-
$imgdiv .='<div style="float: left; margin-right: 10px;margin-top: 10px; width: '.$btn_width.'px; height: '.$button_size.'px; background-image: url('.$SITE_URL.'img/social_icon/'.$img.'); background-position: -'.$bg_position.'px 0px;"></div>';
|
44 |
-
|
45 |
-
|
46 |
-
}
|
47 |
-
|
48 |
-
if(in_array('7',$network))
|
49 |
-
{
|
50 |
-
$bg_position=((6)*$btn_width);
|
51 |
-
|
52 |
-
$imgdiv .='<div style="float: left; margin-right: 10px;margin-top: 10px; width: '.$btn_width.'px; height: '.$button_size.'px; background-image: url('.$SITE_URL.'img/social_icon/'.$img.'); background-position: -'.$bg_position.'px 0px;"></div>';
|
53 |
-
|
54 |
-
|
55 |
-
}
|
56 |
-
|
57 |
-
if(in_array('13',$network))
|
58 |
-
{
|
59 |
-
$bg_position=((12)*$btn_width);
|
60 |
-
|
61 |
-
$imgdiv .='<div style="float: left; margin-right: 10px;margin-top: 10px; width: '.$btn_width.'px; height: '.$button_size.'px; background-image: url('.$SITE_URL.'img/social_icon/'.$img.'); background-position: -'.$bg_position.'px 0px;"></div>';
|
62 |
-
|
63 |
-
|
64 |
-
}
|
65 |
-
|
66 |
-
if(in_array('15',$network))
|
67 |
-
{
|
68 |
-
$bg_position=((14)*$btn_width);
|
69 |
-
|
70 |
-
$imgdiv .='<div style="float: left; margin-right: 10px;margin-top: 10px; width: '.$btn_width.'px; height: '.$button_size.'px; background-image: url('.$SITE_URL.'img/social_icon/'.$img.'); background-position: -'.$bg_position.'px 0px;"></div>';
|
71 |
-
|
72 |
-
}
|
73 |
-
|
74 |
-
if(in_array('16',$network))
|
75 |
-
{
|
76 |
-
$bg_position=((15)*$btn_width); //change when image is added
|
77 |
-
|
78 |
-
$imgdiv .='<div style="float: left; margin-right: 10px;margin-top: 10px; width: '.$btn_width.'px; height: '.$button_size.'px; background-image: url('.$SITE_URL.'img/social_icon/'.$img.'); background-position: -'.$bg_position.'px 0px;"></div>';
|
79 |
-
|
80 |
-
}
|
81 |
-
|
82 |
-
if(in_array('5',$network))
|
83 |
-
{
|
84 |
-
$bg_position=((4)*$btn_width);
|
85 |
-
|
86 |
-
$imgdiv .='<div style="float: left; margin-right: 10px;margin-top: 10px; width: '.$btn_width.'px; height: '.$button_size.'px; background-image: url('.$SITE_URL.'img/social_icon/'.$img.'); background-position: -'.$bg_position.'px 0px;"></div>';
|
87 |
-
|
88 |
-
|
89 |
-
}
|
90 |
-
*/
|
91 |
-
|
92 |
-
$fb_div="";
|
93 |
-
if(in_array('2',$network))
|
94 |
-
{
|
95 |
-
$bg_position=$btn_width;
|
96 |
-
$fb_div .='<script type="text/javascript">';
|
97 |
-
$imgdiv='<div style="float: left; margin-right: 10px;margin-top: 10px; width: '.$btn_width.'px; height: '.$button_size.'px; background-image: url('.$SITE_URL.'img/social_icon/'.$img.'); background-position: -'.$bg_position.'px 0px;"></div>';
|
98 |
-
$fb_div .='csbutton.init([\''.$imgdiv.'\',\''.$btn_width.'px\' ,\''.$button_size.'\',\'login_fb\']);'.PHP_EOL;
|
99 |
-
$fb_div .='csbutton.putCsbutton();
|
100 |
-
</script>';
|
101 |
-
|
102 |
-
|
103 |
-
}
|
104 |
-
$gp_div="";
|
105 |
-
if(in_array('4',$network))
|
106 |
-
{
|
107 |
-
$bg_position=((3)*$btn_width);
|
108 |
-
$gp_div .='<script type="text/javascript">';
|
109 |
-
$imgdiv='<div style="float: left; margin-right: 10px;margin-top: 10px; width: '.$btn_width.'px; height: '.$button_size.'px; background-image: url('.$SITE_URL.'img/social_icon/'.$img.'); background-position: -'.$bg_position.'px 0px;"></div>';
|
110 |
-
$gp_div .='csbutton.init([\''.$imgdiv.'\',\''.$btn_width.'px\' ,\''.$button_size.'px\',\'login\',\''.$valid_data_arr[1].'\']);'.PHP_EOL;
|
111 |
-
$gp_div .='csbutton.putCsbutton();
|
112 |
-
</script>';
|
113 |
-
|
114 |
-
}
|
115 |
-
$li_div="";
|
116 |
-
if(in_array('7',$network))
|
117 |
-
{
|
118 |
-
$bg_position=((6)*$btn_width);
|
119 |
-
$li_div .='<script type="text/javascript">';
|
120 |
-
$imgdiv='<div style="float: left; margin-right: 10px;margin-top: 10px; width: '.$btn_width.'px; height: '.$button_size.'px; background-image: url('.$SITE_URL.'img/social_icon/'.$img.'); background-position: -'.$bg_position.'px 0px;"></div>';
|
121 |
-
$li_div .='csbutton.init([\''.$imgdiv.'\',\''.$btn_width.'px\' ,\''.$button_size.'px\',\'login\',\'li\']);'.PHP_EOL;
|
122 |
-
$li_div .='csbutton.putCsbutton();
|
123 |
-
</script>';
|
124 |
-
|
125 |
-
}
|
126 |
-
$tw_div="";
|
127 |
-
if(in_array('13',$network))
|
128 |
-
{
|
129 |
-
$bg_position=((12)*$btn_width);
|
130 |
-
$tw_div .='<script type="text/javascript">';
|
131 |
-
$imgdiv='<div style="float: left; margin-right: 10px; margin-top: 10px; width: '.$btn_width.'px; height: '.$button_size.'px; background-image: url('.$SITE_URL.'img/social_icon/'.$img.'); background-position: -'.$bg_position.'px 0px;"></div>';
|
132 |
-
$tw_div .='csbutton.init([\''.$imgdiv.'\',\''.$btn_width.'px\' ,\''.$button_size.'px\',\'login\',\'twitter\']);'.PHP_EOL;
|
133 |
-
$tw_div .='csbutton.putCsbutton();
|
134 |
-
</script>';
|
135 |
-
|
136 |
-
}
|
137 |
-
$yh_div="";
|
138 |
-
if(in_array('15',$network))
|
139 |
-
{
|
140 |
-
$bg_position=((14)*$btn_width);
|
141 |
-
$yh_div .='<script type="text/javascript">';
|
142 |
-
$imgdiv='<div style="float: left; margin-right: 10px;margin-top: 10px; width: '.$btn_width.'px; height: '.$button_size.'px; background-image: url('.$SITE_URL.'img/social_icon/'.$img.'); background-position: -'.$bg_position.'px 0px;"></div>';
|
143 |
-
$yh_div .='csbutton.init([\''.$imgdiv.'\',\''.$btn_width.'px\' ,\''.$button_size.'px\',\'login\',\'yahoo\']);'.PHP_EOL;
|
144 |
-
$yh_div .='csbutton.putCsbutton();
|
145 |
-
</script>';
|
146 |
-
|
147 |
-
}
|
148 |
-
$pp_div="";
|
149 |
-
if(in_array('16',$network))
|
150 |
-
{
|
151 |
-
$bg_position=((15)*$btn_width); //change when image is added
|
152 |
-
$pp_div .='<script type="text/javascript">';
|
153 |
-
$imgdiv='<div style="float: left; margin-right: 10px;margin-top: 10px; width: '.$btn_width.'px; height: '.$button_size.'px; background-image: url('.$SITE_URL.'img/social_icon/'.$img.'); background-position: -'.$bg_position.'px 0px;"></div>';
|
154 |
-
$pp_div .='csbutton.init([\''.$imgdiv.'\',\''.$btn_width.'px\' ,\''.$button_size.'px\',\'login\',\'paypal\']);'.PHP_EOL;
|
155 |
-
$pp_div .='csbutton.putCsbutton();
|
156 |
-
</script>';
|
157 |
-
|
158 |
-
}
|
159 |
-
$ig_div="";
|
160 |
-
if(in_array('5',$network))
|
161 |
-
{
|
162 |
-
$bg_position=((4)*$btn_width);
|
163 |
-
$ig_div .='<script type="text/javascript">';
|
164 |
-
$imgdiv='<div style="float: left; margin-right: 10px;margin-top: 10px; width: '.$btn_width.'px; height: '.$button_size.'px; background-image: url('.$SITE_URL.'img/social_icon/'.$img.'); background-position: -'.$bg_position.'px 0px;"></div>';
|
165 |
-
$ig_div .='csbutton.init([\''.$imgdiv.'\',\''.$btn_width.'px\' ,\''.$button_size.'px\',\'login\',\'instagram\']);'.PHP_EOL;
|
166 |
-
$ig_div .='csbutton.putCsbutton();
|
167 |
-
</script>';
|
168 |
-
|
169 |
-
}
|
170 |
-
|
171 |
-
$imgdiv='<script type="text/javascript" src="https://www.socleversocial.com/dashboard/client_share_js/csloginbuttons_'.$site_id.'.js"></script>'.PHP_EOL.$fb_div.PHP_EOL.$gp_div.PHP_EOL.$li_div.PHP_EOL.$tw_div.PHP_EOL.$yh_div.PHP_EOL.$ig_div.PHP_EOL.$pp_div;
|
172 |
-
|
173 |
-
|
174 |
-
echo '<div style="margin-bottom:20px;width:96%;margin-bottom:10px;border:1px solid #bbb6a5;padding:14px 21px;clear:both;"><div><b>Login by your social profile.</b></div>'.$imgdiv.'<div style="clear: both;text-align:left;padding-top:10px;"><b>Powered by </b><a href="https://www.socleversocial.com/" target="_blank">Socleversocial.com</a></div></div>';
|
175 |
-
|
176 |
-
|
177 |
-
}
|
178 |
else
|
179 |
{
|
180 |
echo"<h1>Please provide valid API setting</h1>";
|
2 |
$site_id=Mage::getStoreConfig('sociallogin_options/apisettings/scsl_siteid');
|
3 |
$api_secret=Mage::getStoreConfig('sociallogin_options/apisettings/scsl_appsecret');
|
4 |
$api_key=Mage::getStoreConfig('sociallogin_options/apisettings/scsl_appid');
|
5 |
+
$btn_style=Mage::getStoreConfig('sociallogin_options/displaysettings/buttonstyle');
|
6 |
+
$button_size=Mage::getStoreConfig('sociallogin_options/displaysettings/buttonsize');
|
7 |
|
8 |
+
$valid_data=file_get_contents("https://www.socleversocial.com/dashboard/mage_activate.php?site_id=".$site_id."&api_key=".$api_key."&api_secret=".$api_secret."&csplatform=magentologin&rt=gp&bstyle=".$btn_style."&bsize=".$button_size);
|
9 |
|
10 |
if($valid_data && $valid_data!='0~~0')
|
11 |
{
|
12 |
+
echo $valid_data;
|
13 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
14 |
else
|
15 |
{
|
16 |
echo"<h1>Please provide valid API setting</h1>";
|
package.xml
CHANGED
@@ -1,40 +1,38 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>soclever_login</name>
|
4 |
-
<version>1.0.
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://opensource.org/licenses/osl-3.0.php">OSL</license>
|
7 |
<channel>community</channel>
|
8 |
<extends/>
|
9 |
<summary>This module enables Social Login (Facebook and more), User Profile Data & Social Analytics on your site.</summary>
|
10 |
-
<description><
|
11 |
-
<p>
|
12 |
-
<p>
|
13 |
-
<p>
|
14 |
-
PS: You'll need a SoClever API to use it. API Keys are free; paid subscriptions are available for advanced reporting, analytics and demographic data. Download now, Free to try, no contracts or credit card required.</p>
|
15 |
-
<p>Thanks for choosing our plugin, feel free to leave a review or contact us for any feedback. If you want to know more about the features we offer, keep reading below. 
|
16 |

|
17 |
</p>
|
18 |
<h3><strong>Features</strong></h3>
|
19 |
<p><strong>Social Login
|
20 |

|
21 |
-
</strong><br
|
22 |
-
|
23 |
-
<p><strong>Track Revenue</strong><br
|
24 |
-
Have an e-commerce site? Track revenue per social user, download customer segments to personalise your
|
25 |
-
<p><strong>Top Facebook likes</strong><br
|
26 |
-
Download our reports on top Facebook Liked pages of your customers/visitors, filter to add top revenue customers and their top likes. Quick upload to Facebook
|
27 |
-
<p><strong>User Profile Data & Social Analytics</strong><br
|
28 |
Build a rich profile of your customers with our unique reporting dashboard. Get access to full name, email address, DOB, gender, relationship status, home town, place of birth, like, interests and much more with SoClever’s social login.</p>
|
29 |
-
<p><strong>Birthday Reports</strong><br
|
30 |
-
Send
|
31 |
-
<p><strong>Dynamic JavaScript</strong><br
|
32 |
-
Our asynchronous javascript
|
33 |
-
<notes>Stable Version 1.0.
|
34 |
<authors><author><name>Soclever Social</name><user>Socleversocial</user><email>hemang@socleversocial.com</email></author></authors>
|
35 |
-
<date>2015-01-
|
36 |
-
<time>
|
37 |
-
<contents><target name="magelocal"><dir name="Soclever"><dir name="Sociallogin"><dir name="Block"><dir name="Adminhtml"><file name="Help.php" hash="a7c10479a7065e82bbe616eef62e71dd"/><file name="Positions.php" hash="
|
38 |
<compatible/>
|
39 |
<dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php><package><name>Magento_Core_Modules</name><channel>community</channel><min>1.6.0.0</min><max>1.7</max></package></required></dependencies>
|
40 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>soclever_login</name>
|
4 |
+
<version>1.0.3</version>
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://opensource.org/licenses/osl-3.0.php">OSL</license>
|
7 |
<channel>community</channel>
|
8 |
<extends/>
|
9 |
<summary>This module enables Social Login (Facebook and more), User Profile Data & Social Analytics on your site.</summary>
|
10 |
+
<description><p>SoClevers provides social login tools to help increase conversions, basket values and lower cart abandonment. Our Plugin works with all the major social networks like Facebook, Google+ LinkedIn, PayPal, Yahoo! &amp; Instagram. Our JavaScript is asynchronous ensuring fast load time, and it’s also dynamic so you can A-B test from our dashboard without needing to re-code.</p>
|
11 |
+
<p>Our button icons are 100% Customizable, size, shape and position. Select our buttons or load your own designs.</p>
|
12 |
+
<p>PS: You'll need a SoClever API to use it. API Keys are free; paid subscriptions are available for advanced reporting, analytics and demographic data. Al new customers get access to our reporting dashboard for 30 days. Free to try, no contracts or credit card required. Download now.</p>
|
13 |
+
<p>Thank you for choosing our plugin, feel free to leave a review or contact us for any feedback. If you want to know more about the features we offer, keep reading below. 
|
|
|
|
|
14 |

|
15 |
</p>
|
16 |
<h3><strong>Features</strong></h3>
|
17 |
<p><strong>Social Login
|
18 |

|
19 |
+
</strong><br />
|
20 |
+
Increase conversion and registration rates by eliminating registration forms and let your customer / visitors sign-up in few seconds using trusted IDs like Facebook, Twitter, Google, Yahoo, and more. Increase your sign-up rates and start building a loyal customer list today. </p>
|
21 |
+
<p><strong>Track Revenue</strong><br />
|
22 |
+
Have an e-commerce site? Track revenue per social user, download customer segments to personalise your marketing messages. </p>
|
23 |
+
<p><strong>Top Facebook likes</strong><br />
|
24 |
+
Download our reports on top Facebook Liked pages of your customers/visitors, filter to add top revenue customers and their top likes. Quick CSV upload of this data to Facebook, you can create a new and more targeted advertising campaigns. </p>
|
25 |
+
<p><strong>User Profile Data &amp; Social Analytics</strong><br />
|
26 |
Build a rich profile of your customers with our unique reporting dashboard. Get access to full name, email address, DOB, gender, relationship status, home town, place of birth, like, interests and much more with SoClever’s social login.</p>
|
27 |
+
<p><strong>Birthday Reports</strong><br />
|
28 |
+
Send personalised message to your visitors by using our birthday reports. </p>
|
29 |
+
<p><strong>Dynamic JavaScript</strong><br />
|
30 |
+
Our asynchronous javascript loads faster without interfearing with the display or behaviour of the page. Dynamic JavaScript makes it easy to choose/sort social netork buttons for display.</p></description>
|
31 |
+
<notes>Stable Version 1.0.3 - included Buttons on Checkout, improved landing page after login.</notes>
|
32 |
<authors><author><name>Soclever Social</name><user>Socleversocial</user><email>hemang@socleversocial.com</email></author></authors>
|
33 |
+
<date>2015-01-24</date>
|
34 |
+
<time>05:42:28</time>
|
35 |
+
<contents><target name="magelocal"><dir name="Soclever"><dir name="Sociallogin"><dir name="Block"><dir name="Adminhtml"><file name="Help.php" hash="a7c10479a7065e82bbe616eef62e71dd"/><file name="Positions.php" hash="b9c1515f49a4955e8aa0443f0e175cba"/></dir><file name="Scslhead.php" hash="19915d8ad186673c4e068abcd2f700d8"/><file name="Scslshow.php" hash="3e868132953b63c93af6cb7b396b095a"/><file name="Scsltrackpixel.php" hash="865c3da829f0dc1cd384fb113e771c34"/><file name="Scslheadfb.php" hash="01f8e5fca1e7a59dcc7009a9d79d31f5"/></dir><dir name="controllers"><file name="IndexController.php" hash="07ee4a12951bd97e4ee720aae509d6e7"/><file name="openid.php" hash="421d5936957b8ddda543b679d1876f04"/></dir><dir name="etc"><file name="config.xml" hash="b45be9b0c6d60cba1178f7b7c71a7916"/><file name="system.xml" hash="e46124b2c3fb57db8b88938469d52449"/></dir><dir name="Helper"><file name="Data.php" hash="89f8191f1442a7e56f7a4d0b54049d3a"/></dir><dir name="Model"><file name="Providers.php" hash="11cee6aa202a18a0a27a7e7526a712c5"/></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="sociallogin"><file name="sociallogin_fb.phtml" hash=""/><file name="sociallogin_trackpixel.phtml" hash=""/></dir></dir></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="sociallogin.xml" hash="444082a425071b527e955ecd0ebedce8"/></dir><dir name="template"><dir name="sociallogin"><file name="scsl_buttons.phtml" hash="23c607180fd8f63fb1951bd55b1afa2c"/><file name="sociallogin_head.phtml" hash="0695cf4d2acdaf0ee2971604e016e8b4"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="soclever_sociallogin.xml" hash="8f1fa6f55fc92b4474f696f3678c0281"/></dir></target></contents>
|
36 |
<compatible/>
|
37 |
<dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php><package><name>Magento_Core_Modules</name><channel>community</channel><min>1.6.0.0</min><max>1.7</max></package></required></dependencies>
|
38 |
</package>
|