diff options
| author | 2013-08-21 16:04:18 +0200 | |
|---|---|---|
| committer | 2013-08-21 16:04:18 +0200 | |
| commit | 54541608ac979dfc6044c89cb30493704dcc94c8 (patch) | |
| tree | 68c73aebd62f59e0d86c04526732a37bfaf7db07 /app/views/index | |
| parent | 456c95d2dbb40d358d79f426f68eb03f5f447945 (diff) | |
Fix issue #127 : ajout système de token
Ajout du système de token pour accéder aux flux RSS même quand la
connexion a été paramétrée.
Pour l'utiliser, il faut simplement ajouter le paramètre
?token=<votre_token> à l'url
Diffstat (limited to 'app/views/index')
| -rw-r--r-- | app/views/index/index.phtml | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/app/views/index/index.phtml b/app/views/index/index.phtml index 4bf82f9b4..73e5fcc4d 100644 --- a/app/views/index/index.phtml +++ b/app/views/index/index.phtml @@ -1,10 +1,14 @@ <?php $output = Request::param ('output', 'normal'); +$token = $this->conf->token(); +$token_param = Request::param ('token', ''); +$token_is_ok = ($token != '' && $token == $token_param); if(!login_is_conf ($this->conf) || is_logged() || - $this->conf->anonAccess() == 'yes') { + $this->conf->anonAccess() == 'yes' || + ($output == 'rss' && $token_is_ok)) { if($output == 'rss') { $this->renderHelper ('view/rss_view'); } elseif($output == 'reader') { |
