Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

E-Commerce Modules /

Discuss about the various e-commerce modules available:
Ecommerce, SS Shop, SilverCart and SwipeStripe
Alternatively, have a look the shared mailinglist.

Moderators: martimiz, Nicolaas, Sean, frankmullenger, biapar, Willr, Ingo, Jedateach, swaiba, simon_w

Using HTTPS for just the e-commerce section (and log-on pages)


Reply


3 Posts   1682 Views

Avatar
HansR

Community Member, 140 Posts

18 February 2009 at 4:18pm

Is there a way to use HTTPS for just the e-commerce pages? I've already seen old discussions on this, including [url=http://groups.google.com/group/silverstripe-dev/browse_thread/thread/ade65994a11d3387]this one[/url], but it seems inconclusive. It looks like you can use Director::forceSSL() to switch to HTTPS, but that there is no method to switch back to HTTP for pages that don't need a secure connection.

Avatar
dospuntocero

Community Member, 54 Posts

4 March 2009 at 2:54pm

Edited: 04/03/2009 2:55pm

what about make a Director::Redirect('https://'.$Link) or something? to use https only in the payment page?

Avatar
keeny

Community Member, 48 Posts

14 July 2009 at 11:12am

Hi dospuntocero,

How would I do that exactly? something along the lines of:

if($_SERVER["SERVER_PORT"] == 443) {
   Director::Redirect('https://'.$Link)
}

I only want the checkout page to be secure. But if the user visits the home page again I want that to go back to non-secure.

Cheers,

Barry.