CMS Development

russelltnails
Participant

simple_list_page: blog listing and sidebar are not children of the same parent

SOLVE

Hey All,

It appears the Simple List Page / Blog/All is not respecting the structure of the blog content module and blog sidebar.


The template is laid out like this

the above works as expected on the blog listing page, however once you click into .blog/all the listings and the sidebar are no longer children of the same div, and the blog content module is .span12

 

I need halp. I am not smart.

0 Upvotes
1 Accepted solution
ndwilliams3
Solution
Key Advisor

simple_list_page: blog listing and sidebar are not children of the same parent

SOLVE

Check your blog listing template for a mismatched HTML element and if statement. The opening tag and ending tag both need to be inside or outside the if statement.

 

You've likely got something like:

 

{% if... %}

<div>
Content
{% endif %}
</div>

 

Or this:

 

<div>

{% if... %}

Content
<\div>
{% endif %}

 

In either case the opening or ending tag will not be rendered causing you layout to break.

 

Make sure they're either both outside.

<div>

{% if... %}

Content

{% endif %}

</div>

 

Or they're both inside:

 

{% if... %}

<div>

Content

<\div>

{% endif %}

This can be tricky to find when there are several nested HTML elements or if statements.

 

View solution in original post

2 Replies 2
ndwilliams3
Solution
Key Advisor

simple_list_page: blog listing and sidebar are not children of the same parent

SOLVE

Check your blog listing template for a mismatched HTML element and if statement. The opening tag and ending tag both need to be inside or outside the if statement.

 

You've likely got something like:

 

{% if... %}

<div>
Content
{% endif %}
</div>

 

Or this:

 

<div>

{% if... %}

Content
<\div>
{% endif %}

 

In either case the opening or ending tag will not be rendered causing you layout to break.

 

Make sure they're either both outside.

<div>

{% if... %}

Content

{% endif %}

</div>

 

Or they're both inside:

 

{% if... %}

<div>

Content

<\div>

{% endif %}

This can be tricky to find when there are several nested HTML elements or if statements.

 

russelltnails
Participant

simple_list_page: blog listing and sidebar are not children of the same parent

SOLVE

this was exactly the issue, thank you very much!

0 Upvotes