\Twig\TokenParserIfTokenParser

Tests a condition.

{% if users %}
 
    {% for user in users %}
  • {{ user.username|e }}
  • {% endfor %}
{% endif %}

Summary

Methods
Properties
Constants
parse()
decideIfFork()
decideIfEnd()
getTag()
setParser()
No public properties found
No constants found
No protected methods found
$parser
N/A
No private methods found
No private properties found
N/A

Properties

Methods

parse()

parse(\Twig_Token  $token) 

Parameters

\Twig_Token $token

decideIfFork()

decideIfFork(\Twig_Token  $token) 

Parameters

\Twig_Token $token

decideIfEnd()

decideIfEnd(\Twig_Token  $token) 

Parameters

\Twig_Token $token

getTag()

getTag() 

setParser()

setParser(\Twig_Parser  $parser) 

Sets the parser associated with this token parser.

Parameters

\Twig_Parser $parser