-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
var if defined = true, but not found when i try to dump it #28
Comments
What do you mean by property color not found? |
What's your configuration file? How your |
ok, tell the order)
} and UserIdentity component here:
} so I have custom properties (firstName, lastName, rank, sinceDate) // of course, this "if" is true or: I'm trying to play a similar logic in TWIG templates but it does not work: (expect that this condition is not satisfied because the property does not exist) in configs i have: my class WebUser until empty and simply inherits CWebUser why the "IS DEFINED" is true if it is not really so? |
user have a custom property (e,g, Yii::app()->user->color).
how can i use it from twig view ?
I tried this design
{% if app.user.color is defined %}
test msg
{{app.user.color}}
{% endif %}
if returns true but property color not found.
how can this happen?
The text was updated successfully, but these errors were encountered: