I've noticed code samples like the following that use the find()
method.
{% for entry in craft.entries.section('blog').limit(5).find() %}
<li><a href="{{ entry.url }}">{{ entry.title }}</a></li>
{% endfor %}
I've noticed that this code sample works just as well without the find()
method attached. Is there a particular reason we use find()
? Are there instances where it's required? Should I be using it even if the code works without it?
.find()
is implied. Craft will do it automatically and it won't hurt anything if you call it. There are other times wherefind()
is implied but I forget what that is. There are other cases though where you do need to callfind()
.