Hello
I have a weird situation here. I spent a few days building up a page using "View" to display a list of posts. I was following the "create view" course. BTW your training resources are really great!
Everything worked fine in the draft mode. However, once I publish the page, it goes to an Archive page where it simply lists all the posts one by one. All the formatting and additional elements such as map view, search filters that I made in the draft mode do not show at all.
If I switch back from publish to draft mode, then it's fine. In the draft mode, if I click "Preview" , it does show the View container I built. But once I click publish, it goes to Archive page again.
I also noticed that in the Toolset Dashboard, it says I need to create an Archive (See screenshot below). I'm not sure if these two things are relevant?
Hello and thank you for contacting the Toolset support.
First of all, I would like to note the differences between a view and an archive template. Check our glossary pages for a quick definition:
- View: https://toolset.com/glossary/view/
- Archive template: https://toolset.com/glossary/archive/
From the attached screenshot, it seems that you were not building an archive template, but you were building a view. I assume that the view is built using the blocks editor inside a new page. If the page is still in draft mode, you can successfully check its preview. But once you publish the page, you can't see your design in the frontend, right? I would suspect that the page slug is the same as the custom post type(which is used for the archive page), so WordPress uses the default archive template instead of your view. I'll suggest that you change the page's slug or the custom post type slug and check again.
If the above does not help, I'll need more details to better assist you:
- URL in the frontend.
- URL of the view in the backed.
- Maybe additional screenshots.
Preferably, I would like access to your admin area to check all the above closely. Your next reply will be private to let you share credentials safely. ** Make a database backup before sharing credentials. **
Hi Jamal
Thank you sooo much! I changed the page slug and it worked immediately! It must be because I created the same page many times as I am trying different tools and plugins, so the old slug is registered as the Archive page.
Since I have got you, I have two further questions about the Archive page. I'm sorry for my naive questions. I'm very new to this.
1. Now I have watched the video for both "View" and "Archive", I'm wondering if I should abandon the page I already built (even though it now works), and do the same formatting and everything in the "Archive" page instead? Because according to the video, "Archive page" can be found by Google search quickly once my site is launched? Is my understanding correct?
2. If I am going to build the Archive page, can I use the "distance filter"? I am currently using distance filter in my page, and I saw an old ticket saying "distance filter" is not supported in Archive page. It was in 2018 thought. I'm wondering if this is now fixed? Here is the old ticket: https://toolset.com/forums/topic/location-filter-is-not-working-on-archive-page/
Thank you again!
Awesome, I am glad I could help.
1. Yes, I would suggest using an archive template.
2. Yes, you are right. Distance filter is not yet available on archive templates.
You may use a view, and disable the archive for that custom post type completely. Check this option in the custom post type definition hidden link
However, for support rules, we are able to handle only one issue at a time. This helps us to bring you a better service and also helps other users to find all the information here exposed. For that reason, I have to kindly ask you to open a new thread if you need further assistance or have more questions.
Thank you Jamal. I will open a new ticket for the "distance filter" feature request