How to serve Guest = HTTP and User = HTTPS for same routes

8 years ago

mishak
Member | 100
+
0
-

Is it possible to serve guest HTTP content and user HTTPS?

Current implementation redirects to http variant because of canonicalize. If I turn it off I can at least browse https without being redirected to http but I lose feature of automated canonicalization. And I have to still adjust generated absolute links.

Last edited by mishak (2012-02-26 00:27)

8 years ago

Patrik Votoček
Member | 2249
+
0
-
$container->router[] = new Route(
	'<presenter>/<action>[/<id>]',
	'Homepage:default',
	$container->user->loggedIn ? Route::SECURED : 0
);

Last edited by Patrik Votoček (2012-02-26 00:53)

8 years ago

mishak
Member | 100
+
0
-

Thanks, any drawbacks?