Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
lib
unicaen
auth
Commits
46430698
Commit
46430698
authored
Feb 27, 2014
by
Bertrand Gauthier
Browse files
Modif page 403 Unauthorized.
parent
aec8be9e
Changes
2
Hide whitespace changes
Inline
Side-by-side
config/module.config.php
View file @
46430698
...
...
@@ -109,7 +109,7 @@ $bjyauthorize = array(
// strategy service name for the strategy listener to be used when permission-related errors are detected
// 'unauthorized_strategy' => 'BjyAuthorize\View\RedirectionStrategy',
'unauthorized_strategy'
=>
'UnicaenAuth\View\RedirectionStrategy'
,
/* Currently, only controller and route guards exist
*/
'guards'
=>
array
(
...
...
@@ -192,6 +192,9 @@ return array(
),
),
'view_manager'
=>
array
(
'template_map'
=>
array
(
'error/403'
=>
__DIR__
.
'/../view/error/403.phtml'
,
),
'template_path_stack'
=>
array
(
'unicaen-auth'
=>
__DIR__
.
'/../view'
,
),
...
...
view/error/403.phtml
0 → 100644
View file @
46430698
<?php
$this
->
headTitle
()
->
append
(
$title
=
$this
->
translate
(
"403 - Accès interdit"
))
?>
<div
class=
"jumbotron"
>
<h1>
<?php
echo
$title
?>
</h1>
<?php
if
(
\
BjyAuthorize\Guard\Controller
::
ERROR
===
$error
||
\
BjyAuthorize\Guard\Route
::
ERROR
===
$error
)
:
?>
<h2
class=
"text-danger"
>
<?php
echo
$message
=
$this
->
translate
(
"Vous n'êtes pas autorisé(e) à accéder à cette page."
)
?>
</h2>
<?php
elseif
(
$error
==
'error-unauthorized'
)
:
?>
<h2
class=
"text-danger"
>
<?php
echo
$message
?>
</h2>
<h3>
<?php
echo
$this
->
translate
(
$reason
);
?>
</h3>
<?php
else
:
?>
<h2
class=
"text-danger"
>
<?php
echo
$this
->
translate
(
"Erreur inattendue."
)
?>
</h2>
<?php
endif
;
?>
</div>
\ No newline at end of file
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment