Tell us what you are trying to do?
We have two post types:
-- Wineries, which contain the address and information about a specific location. These are created by administrators
-- Winery Visits, which users can use to record notes and dates about visits to specific wineries (connected to the Winery post type by a one winery to multiple winery visits relationship)
I have been able to create a view that shows the winery visit posts, including the winery address from the relationship to the winery.
I want to create a map for each user that shows pins for all the wineries they have created "Winery Visits" posts for. But I'm stuck - not sure how the get the address from the Winery content to show on the map.
Is there any documentation that you are following?
I looked at this, but the marker solution didn't help. But it looks like I'm trying to do something similar.
https://toolset.com/forums/topic/how-to-display-map-markers-if-the-address-field-is-in-a-child-relationship-post/
Is there a similar example that we can see?
Not sure
What is the link to your site?
hidden link
I can share admin login, and login for a visitor-type user for which I've created test content.
Hi,
Thank you for contacting us and I'd be happy to assist.
Your requirement sounds different than the one discussed in the other support forum thread.
To suggest the next steps, I'll need to see exactly how this address field and the content template/view are set up.
Can you please share temporary admin login details, along with the example page where you'd like to show this map?
Note: Your next reply will be private and making a complete backup copy is recommended before sharing the access details.
regards,
Waqar
Thank you for sharing the access details.
During troubleshooting, I was able to fix the map marker not showing from the connected parent 'Wineries' posts, updating the following map marker shortcode in the view 'My Winery Visits', from:
[wpv-map-marker map_id='map-43' marker_id='marker-42' marker_field='wpcf-address' item='$parent'][/wpv-map-marker]
To:
[wpv-map-marker map_id='map-43' marker_id='marker-[wpv-post-id]' marker_field='wpcf-address' item='@winery-to-winery-visit.parent'][/wpv-map-marker]
Note: The actual relationship that is being used on the website is the one-to-many relationship "Wineries to Winery Visits". But in the custom field group 'Field Group for Winery Visits', I see there is a post reference field 'Winery Address' too, which also connects the 'Wineries' to 'Winery Visits', which can cause confusion.
Thank you! I've removed the custom field - that was another angle I was trying. I appreciate your help on this!!!