Example:
Returns True if the value is divisible by the argument.
{% if value|divisibleby:"2" %}
Even!
{% else %}
Odd!
{% else %}
Returns True if the value is divisible by the argument.
本文介绍了一个简单的条件判断示例,展示了如何使用特定语法来判断数值是否为偶数。通过这一例子,读者可以了解到基本的条件分支逻辑及其应用场景。
3万+

被折叠的 条评论
为什么被折叠?



