Mai 17, 201712:40 AM - bearbeitet Mai 17, 201712:40 AM
Teilnehmer/-in | Platinum Partner
Some Post List Content show blank in listing page
There're some posts that show blank content in the blog list page. Those posts got content like any other post in my blog. Here's my code for listing page:
{% for content in contents %} <div class="post-item b4y-post-item"> {% if not simple_list_page %} <img src="{{ content.post_list_summary_featured_image }}" alt="{{ content.featured_image_alt_text }}" class="blog-list-img">
<div class="post-body clearfix post-body-list">
{% if content.topic_list %} <p id="hubspot-topic_data"> {% for topic in content.topic_list %} <a class="topic-link" href="{{ group.absolute_url }}/topic/{{ topic.slug }}">{{ topic.name }}</a>{% if not loop.last %},{% endif %} {% endfor %} </p> {% endif %} <div class="post-header"> <h2>{{ content.name }}</h2> </div> <div class="post-list-item-content"> {{ content.post_list_content|truncatehtml(120, '...', false)}} </div>
I had the same issue. For me it ended up being caused by the text appearing after the "more..." widget. When I put the opening paragraph body (in the article), befor this widget it fixed the text rendering issue for the problem article.
I am trying to fetch recent posts from blog. It is working fine but for some posts description is coming blank. I have tried both post_list_content and summary but none of this working.