Jump to content
Latest News: (loading..)

Recommended Posts

Based on EzSocial v1.01 add-on for OsCommerce 2.3 Written by Christopher Trigg.

Easy and friendly way to add social logins to your site. Uses PHP for backend work to login and CSS to display buttons

Consists of:

Base module which installs a social login box on your login.php page; and
Sub-modules for each social login provider.

No core files overwritten, just upload then follow installation instructions. Requires you to create an app for each provider you require (Facebook, Google, LinkedIn) - instructions are included.

You can also add other providers such as Twitter, Instagram, Github, Microsoft, Yahoo etc with minimal effort (some technical knowledge required)

All feedback, problems, suggestions welcome

Find it here https://apps.oscommerce.com/vVTNW&ezsocial-for-osc2-3-4bs-v1-0a


Let's make things easier for new osCommerce users http://forums.oscommerce.com/topic/402638-discussion-about-hard-coded-database-tables/?p=1718900  Getting there with osCommerce 2.4! :thumbsup:

Share this post


Link to post
Share on other sites

Hi there

been having a play with this

One of my domains switches from http://www.mmmmm.com.au to https://mmmmx.com.au and I am unsure what to input into developer where.

eg app domain  and URI under Valid OAuth redirect URIs

I got to the login on facebook but the redirect back  said the uri was not whitelisted in OAuth redirect URIs

 

 

 

Share this post


Link to post
Share on other sites
20 minutes ago, crimble crumble said:

also the LinkedIn login doesn't return back to osCommerce if the cancel button is selected.

That is true just checked mine :huh:

 

Share this post


Link to post
Share on other sites
On 8/6/2017 at 8:33 AM, crimble crumble said:

I managed to force SSL on ezsocial_success.php but it breaks and throws a password error upon form submission. I believe it has something to do with mc_decrypt. I read this function has been deprecated. Is it possible to use openssl_encrypt instead? In my opinion any page that contains forms where customers enter sensitive information should be secure.

The mc_encrypt and mc_decrypt functions are in the ezsocial folder and use openssl_encrypt and openssl_decrypt


Let's make things easier for new osCommerce users http://forums.oscommerce.com/topic/402638-discussion-about-hard-coded-database-tables/?p=1718900  Getting there with osCommerce 2.4! :thumbsup:

Share this post


Link to post
Share on other sites
On 8/5/2017 at 4:32 PM, crimble crumble said:

also the LinkedIn login doesn't return back to osCommerce if the cancel button is selected.

@douglaswalker and @crimble crumble

Add https://www.domain.com/login.php to the OAuth 1.0a Default "Cancel" Redirect URL:  setting on your LinkedIn app authentication page


Let's make things easier for new osCommerce users http://forums.oscommerce.com/topic/402638-discussion-about-hard-coded-database-tables/?p=1718900  Getting there with osCommerce 2.4! :thumbsup:

Share this post


Link to post
Share on other sites

I have a problem. It works fine in Swedish, but if I change to English this happens when trying to log in with facebook:

Warning: Cannot modify header information - headers already sent by (output started at /customers/b/0/c/gimsteinn.se/httpd.www/includes/languages/english/create_account.php:55) in /customers/b/0/c/gimsteinn.se/httpd.www/includes/functions/general.php on line 49

Someone having any clue to why?

/Jeanette

Share this post


Link to post
Share on other sites
14 hours ago, frankl said:

Very much Thank You

Solved my problem and learned me some more of php

 

/Jeanette

Share this post


Link to post
Share on other sites
7 hours ago, glamocanilaktasi said:

Hi frank,

Pleas how to disable cookies, and request every time whan customers log with social button to log again, not to log in automatically.

thank for your help

The cookies are set by the social login providers themselves.

Making customers log in again each time they visit would kind of defeat the convenience and seamlessness of social logins, no?


Let's make things easier for new osCommerce users http://forums.oscommerce.com/topic/402638-discussion-about-hard-coded-database-tables/?p=1718900  Getting there with osCommerce 2.4! :thumbsup:

Share this post


Link to post
Share on other sites
On 9/4/2017 at 1:26 PM, douglaswalker said:

is that at Linked in or in the osc files /ezsocial

Well, it didn't work. And do not find any option to accept on Linkedin as per the docs

Share this post


Link to post
Share on other sites

Hi, I've having some issues in this addon, it works fine when the account is already created it just login correctly, but when it's a new one (as my login.php control the create_account, login (with guest) and password_forgotten when it gets to ezsocial_success.php to create a new account it get stuck into index.php and didn't login. Any had this issue? If necessary I show all the files.

Share this post


Link to post
Share on other sites

Initially solution:

<?php echo tep_draw_form('create_account', tep_href_link(FILENAME_LOGIN, '', 'SSL'), 'post', 'onsubmit="return check_form(create_account);"', true) . tep_draw_hidden_field('action', 'account'); ?>
<?php //echo tep_draw_form('create_account', tep_href_link(FILENAME_LOGIN, '', 'SSL'), 'post', 'onsubmit="return check_form(create_account);"', true) . tep_draw_hidden_field('action', 'process'); ?>

Anyways I've to later insert this to login.php so it won't register in another page (this case: ezsocial_success.php).

Share this post


Link to post
Share on other sites

Hi, I just installed the addon but the facebook/google/linkedin icons on the social login module appear as boxes, I don't know what I'm missing, it looks like it's not accepting the fontawesome code. I've tried different things and cannot make it work.

 

Thanks in advance for any help!

sociallogin.png

Edited by armsve

Share this post


Link to post
Share on other sites

I remember having this same problem awhile back, but it only affected the FB icon in my case. I changed the css rule .loginBtn--facebook:before located in \includes\modules\social_login_modules\templates\facebook.php

I changed

    content: "\f230";

to

    content: "\f082";

You can lookup alternate icons here:

https://fontawesome.com/

 


The water in a vessel is sparkling; the water in the sea is dark. The small truth has words which are clear; the great truth has great silence.

- Rabindranath Tagore

Share this post


Link to post
Share on other sites

Hi I did a lousy fix, I added 

<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">

to login.php

also I found that to use several languages you need to change this from /includes/modules/content/login/templates/social_logins.php

line 45

      <h2>Social Login</h2>

to:

      <h2><?php echo MODULE_CONTENT_SOCIAL_LOGINS_TITLE; ?></h2>

since it's not reading the languages file information.

 

Share this post


Link to post
Share on other sites

I just installed this addon and had the same issue with the font awesome icons not displaying. However, my challenge is slightly different, in that I upgraded my Font Awesome version to the latest version (v5.2.0).

This requires slightly different code for some icons and other changes in CSS if that is what you choose to use to display those icons. The new font awesome changes in CSS did not work for me so, I changed the button link function to that of osC and adjusted some of the CSS button code. Even with these changes not all font awesome icon classes worked. As an example, here is what my Facebook sub-module file looks like.

/includes/modules/social_login_modules/templates/facebook.php

<style>
.loginBtn-facebook { background-color:#4267b2; background-image:linear-gradient(#4267b2, #3B55A0); text-shadow:0 -1px 0 #354C8C; }
.loginBtn-facebook:hover, .loginBtn-facebook:focus { background-color:#5B7BD5; background-image:linear-gradient(#5B7BD5, #4864B1); color:#fff; }
</style>

<div class="buttonSet buttonDiv"><?php echo tep_draw_button(MODULE_SOCIAL_LOGINS_FACEBOOK_PUBLIC_TEXT, 'fab fa-facebook-square fa-lg', tep_href_link('login_with_facebook.php'), 'primary', null, 'btn-lg loginBtn loginBtn-facebook'); ?></div>


If you have v4.7.0 of Font Awesome, you would just change the font awesome class in that link code and I think you only have to remove the "b" (stands for brand) from "fab" so it would be fa fa-facebook-square fa-lg. The fa-lg is the sizing of the icon. A bit further in the link code is btn-lg, this is the Bootstrap code for the button size. There is also btn-md for medium and btn-sm for small, which is the default and does not need to be added.

And it would be good for anyone using this addon to read the following article on the pros and cons of using social logins. One of the things I got out of this article is that you want to limit your social login options to 3 or 4. Having too many is not good.

https://www.humix.be/blog/10-advantages-disadvantages-social-logins/


As for selecting which social logins to use, here is an article on it with a list of top social media sites. Surprisingly, Google+, Twitter, and LinkedIn are not in the top 5.

https://www.dreamgrow.com/top-15-most-popular-social-networking-sites/

 

social-login-btns.png.bee7d1769f274fc5d9c81ebf900ea08b.png

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×