User tests: Successful: Unsuccessful:
Pull Request for Improvement.
This PR is for adding a new method isHttpsForced
to JApplicationCms
.
This method can be used to check if the current (or given) client is configured (in the global config) to force HTTPS usage.
Please note this is different from JApplicationWeb::isSSLConnection()
that does a very different thing (uses the server environment variables to check if the current page is served trough HTTPS).
This PR also, as a PoC, applies this method to determining if the session cookie should be a secure cookie or not, replacing the old similiar code.
To check this method is working.
Code review, or:
Apply patch
index.php
file and after defined('_JEXEC') or die;
add:$app = JFactory::getApplication();
$app->enqueueMessage($app->isHttpsForced() ? 'HTTPS is forced' : '', 'notice');
index.php
fileStatus | New | ⇒ | Pending |
Labels |
Added:
?
|
Category | ⇒ | Libraries |
Status | Pending | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2016-09-05 21:55:39 |
Closed_By | ⇒ | andrepereiradasilva |
closing for last of interest