Jump to content
thirty bees forum

Square Module doesn't recognize active SSL


Recommended Posts

Posted

I installed the Square module so that I can use their Point of Sale and swipe capabilities.

Id like to also use their payment gateway so everything is through one card processor for ease of reporting etc.

Everything about their module works perfectly. I can sync my entire catalog to my POS on my tablet. I can sync customers. Everything works....EXCEPT for the payment gateway.

I have SSL active and working on my site. In fact, if I try to login the admin area without using SSL, it warns me that I must use SSL to login for security reasons.

So when I try to make the square module active for payments, it displays a warning at the top that says " You need SSL enabled to use payments. "

Yet I HAVE SSL enabled.

Any thoughts or ideas as to what glitch or bug could be causing this issue?

Posted

The module depends on a PS settings that was never implemented in thirtybees. In prestashop there is a flag named PS_SSL_ENABLED_EVERYWHERE, because for some reason PS_SSL_ENABLED is not enough for them. In prestashop world, you need to as the system 'Please use SSL. Thank you, that's so nice that it works on standard front controllers. And now, if you could, please use SSL everywhere, even for modules controllers'.

Anyway, my rant about this will not help much.

To fix this issue, simply run this SQL command -- it will add this flag to configuration table (you might need to change tb_configuration and adjust db prefix). The module will use it, and the rest of the system will ignore it

insert into tb_configuration(name, value, date_add, date_upd) values ('PS_SSL_ENABLED_EVERYWHERE', true, now(), now());

Note that this is not the 'true' compatibility issue. The module would now work with ps version 1.6.1.11 either (this is the compatibility baseline), but only with latest 1.6.1.24. But that doesn't mean we shouldn't do something about this. Quick search in github shows that a lot of modules are using this switch, so we might emulate it dynamically to make the life easier and avoid unnecessary problems.

Posted

@datakick

thank you for the information!

 

I ran the SQL and it did indeed remove the warning. But the square payment option isn't working. It's active in Modules and Services>payments for all customer groups, active for the currency on my site, active for all countries and for all carriers.

It's enabled and working in every other way.

It's in production mode.

But doesn't show up on front office at checkout.

Any ideas?

Posted

The module is quite nicely written. It logs a lot of interesting information if enabled. Make sure logging is enabled, and then look into Advanced Parameters > Logs, there might be some hints

  • Like 1
  • 2 years later...

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
×
×
  • Create New...