Skip Navigation

[Resolved] Loop assistant insterts after the loop but no corresponds

This support ticket is created 7 years ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 -
- 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 -

Supporter timezone: Europe/London (GMT+00:00)

This topic contains 5 replies, has 2 voices.

Last updated by eci38.fr 7 years ago.

Assisted by: Nigel.

Author
Posts
#588391

I discovered that the loop assistant is adding a </div> in all my loops but there is no <div> before. I thought it was a typo issue from my side but I checked all my loops are like this and I used the assistant with bootstrap grid each time.*

Here is an example (the one before the </wpv-loop>) :
[wpv-layout-start]
[wpv-items-found]
<!-- wpv-loop-start -->
<wpv-loop wrap="2" pad="true">
[wpv-item index=1]
<div class="row ">
<div class="col-sm-6">[wpv-post-body view_template="Loop posts in Accueil View"]</div>
[wpv-item index=other]
<div class="col-sm-6">[wpv-post-body view_template="Loop posts in Accueil View"]</div>
[wpv-item index=2]
<div class="col-sm-6">[wpv-post-body view_template="Loop posts in Accueil View"]</div>
</div>
[wpv-item index=pad]
<div class="col-sm-6"></div>
[wpv-item index=pad-last]
<div class="col-sm-6"></div>
</div>
</wpv-loop>
<!-- wpv-loop-end -->
[/wpv-items-found]
[wpv-no-items-found]
[wpml-string context="wpv-views"]No items found[/wpml-string]
[/wpv-no-items-found]
[wpv-layout-end]

Can you tell me why? and Should I remove it? Could there be any impact on the rendering?

Thanks
Christophe

#588525

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

Hi Christophe

I tested this and reproduced the problem.

It is an error with the Loop Wizard, the close div tag is redundant and you can and should delete it to avoid it interfering with how your content is rendered on the front-end.

Thanks for bringing it to our attention.

I'm reporting it internally so that it can be fixed.

#588611
wrong_page_bottom.JPG
wrong_page_top.JPG
correct_page.JPG

Hi Nigel,
Thanks for this input. I just tried this on my views but then unfortunately I observe a very strange and incorrect behavior:
=> the right hand sidebar (where I have connection and some info/links) switches from right to the bottom.

This is the case for all pages I removed the </div> before the </wpv-loop>.

So there might be some other problem there.
Could you check? In the meantime I add back all the </div> in views.
Thanks

#588618

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

Hi Christophe

Could I see it on your site for myself?

Can you tell me a View which has this extra div and the page it is displayed on?

I will mark your next reply as private so that I can get log-in credentials from you—you may want to create a temporary admin user for me to use that you can later delete. And be sure to have a current backup of your site.

#588641

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+00:00)

Hi Christophe

It seems I was too quick to declare the closing div tag as redundant. It closes a div which is opened by one of the shortcodes.

Hence removing it is responsible for the layout issues you described.

The markup as created by the Loop Wizard is correct and should be left intact.

#588650

Hi Nigel,
OK so now I have set back all the views with the </div> tag. It works better!

However it seems a bit strange to have this tag outside of the loop while the <div> is created by previous shortcode (so invisible).
Is there any documentation about this?
Can't it be hidden in the loop to avoid this unbalanced design?
b
Thanks for your support
Christophe