Tell us what you are trying to do?
I am trying to show credits of a case study (custom field) via view in a page in which there is anoher view showing the hero of the case study (working correctly). The 2 are configured exactly the same way but for some reason the new one doesn't work. There is sorting limit at 1 to show just the view where the page is shown.
Is there any documentation that you are following? No
Is there a similar example that we can see?
This one is working: hidden link (hero)
The new one not working: hidden link (credits)
What is the link to your site?
hidden link (maintenance mode, can make an account)
Hi,
Welcome to Toolset support. I wonder if you can create a completely new view and use the same option as the credits and see if it works individually.
If yes then please use that new view in conjunction with the one that is working and delete the one which is not working.
If the issue persists, I'd appreciate it if you could give me the URL/User/Pass of your WordPress dashboard after you make sure that you have a backup of your website.
It is absolutely important that you give us a guarantee that you have a backup so if something happens you will have a point of restore.
Make sure you set the next reply as private.
Please also give me the link to the view that you newly created as mentioned in the steps above.
Hi,
Thank you for the login information. I create da test page and used the WORK - Credits view there.
I checked the view and the loop item just loads a template.
<wpv-loop wrap="1" pad="true">
[wpv-item index=1]
<div class="row ">
<div class="col-md-12">[wpv-post-body view_template="loop-item-in-sm-work-credits"]</div>
</div>
[wpv-item index=other]
<div class="col-md-12">[wpv-post-body view_template="loop-item-in-sm-work-credits"]</div>
[wpv-item index=pad]
<div class="col-md-12"></div>
[wpv-item index=pad-last]
<div class="col-md-12"></div>
</div>
It is completely different from the Hero view. So I am not sure what you want to achieve wit the Work credit view if you give me more information I will be happy to help.
Hello Christopher,
I am not sure what you did but I believe it's not relevant to what I am having issue with.
If you go to this page: hidden link
At the bottom of the page there is a view that is called: SM - Work (credits)
hidden link
This view, within the works (wiredmark for instance, the one I linked) is not working. In that specific page it should show the custom field 'credits' but instead is showing 'credits' from a different post.
Thanks,
Matteo
Hi,
Thank you now I get what you mean. In the Template section of the view you need to add this shortcode:
[types field='credits' item='$current_page']
You can generate that shortcode by clicking the "Fields and Views" button, selecting the Credits and under "Post Selection" tab you need to choose "The page where this View is shown" option.
Please check the screenshot.
I did that and now the view shows the current credits content.
Thanks.
Hi Christopher,
Thanks for the explanation and this is now great.
However I wanted to understand why do I have to specify it here this time and the other view is doing that automatically.
Also, I've always used views without using the '$current_page' value and it has always worked.
Is there something wrong with this view or with the website?
Thanks,
Matteo
Hi Matteo,
Nothing wrong is there, just if the view is used on a page you need to use that method and if it is used in a post template the default option will suffice.
Using the button and the dialog box to generate the shortcode will be the best option as it will generate all the necessary attributes.
Thanks.