This thread is resolved. Here is a description of the problem and solution.
Problem:
Parent view not rendering on frontend - how to display parent post image
Solution:
To display parent custom field image in one-to-many relationship you can display it directly using image block. You can add the image block and selected the parent post.
Hi
I am developing a classified site and I want to show the user/author picture and caption on each single classified page. I have a one-to-many relationship between the (user) profile and cassifieds CPTs. In the classified single content template I have created a view to show the author user image and caption. The view works fine in the editor but it's not rendered on the page. If I inspect the page code I can see that the view code is there, but the block it's empty. Same on PC or iPAD. I am not using any caching. My theme is Kadence free.
Am I missing anything ?
Thanks
Hello. Thank you for contacting the Toolset support.
That is strange. Can I have a admin access details so I can check whats going wrong with your setup as well as problem URL where I can see the issue.
*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin and FTP) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.
I have set the next reply to private which means only you and I have access to it.
To display parent custom field in one-to-many relationship you can display it directly using image block. I've added the image block and selected the parent post field and as you can see with the above link it does display correct output.
You can just remove the view you added to display image custom field from parent post and instead of that you can use the image block. hidden link
Can you please check now:
- hidden link
- hidden link
I can see different images, you just need to add image block outside the view's loop. I've also removed the view's block you added to display the image: hidden link
I can see its working as expected. Can you please confirm it works at your end as well.