Skip Navigation

[Resolved] Using a view in the archive, duplicating results

This support ticket is created 6 years, 9 months 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.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 -
- 13:00 – 18:00 13:00 – 18:00 13:00 – 18:00 14:00 – 18:00 13:00 – 18:00 -

Supporter timezone: America/Jamaica (GMT-05:00)

This topic contains 5 replies, has 2 voices.

Last updated by Rainforest Alliance 6 years, 9 months ago.

Assisted by: Shane.

Author
Posts
#550987
Screen Shot 2017-07-20 at 12.08.06 PM.png

I am trying to: Have a view display for a custom content type's archive page

My results are appearing twice, and I can't figure out why. Here is the Loop output I have for my archive:

[wpv-layout-start]
	[wpv-items-found]
	<!-- wpv-loop-start -->
		<wpv-loop>
          [wpv-view name="courses-list"]
		</wpv-loop>
	<!-- wpv-loop-end -->
	[/wpv-items-found]
	[wpv-no-items-found]
		<strong>[wpml-string context="wpv-views"]No items found[/wpml-string]</strong>
	[/wpv-no-items-found]
[wpv-layout-end]

Any idea why this is happening? Thanks!

#551057

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hello,

Thank you for contacting our support forum.

Would you mind providing me with admin access to this view so that I can have a look at it for you ?

The private fields will be enabled for your next response.

Thanks,
Shane

#551116

I'm unsure if what I'm posing is private or not, is there a way I can tell? I did just post login information I was able to see in another browser when I was logged out...

#551376

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hello,

It seems the fields were not enabled.

Could you try now.

Thanks,
Shane

#551480

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hello,

The reason why there are duplicates is because you have a view within the archive.

So an archive functions just the same as a view in terms of the loop output.

What You can do is to take the contents from the view loop and place it in the archive loop and as you see it will function the same.

Let me know if this helps.

Thanks,
Shane

#552071

That fixed my issue, thanks!

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.