“read more” in django posts

LokiBoki

New Member
I am creating a blog on django/webfaction. Currently my home page displays all the contents from all the posts. I would like to tweak it to show only few lines from each post and each post ending with a "read more" link. How to achieve this? I am new to django and python. Kindly help me. Code in home.html:\[quote\]\[code\]{% block content %} {% for post in object_list %} <h2>{{ post.title }} </h2> <div class = "post_meta"> on {{ post.created}} </div> <div class = "post_body"> {{ post.body|safe|linebreaks}} </div> {% endfor %}{% endblock %}\[/code\]\[/quote\]Thanks in advance.
 
Back
Top