Skip Navigation

[Resolved] Two CPT with address field

This thread is resolved. Here is a description of the problem and solution.

Problem:

The site had two custom post types (CPTs), each with its own address field used to display markers on separate Google Maps. While CPT#1 displayed correctly, CPT#2’s map showed no markers, and the user wondered if multiple address fields were unsupported.

Solution:

Confirmed that Toolset fully supports multiple CPTs and multiple address fields. The issue was not a limitation but a configuration mismatch. The user was advised to:

Ensure the CPT#2 field is a genuine Address field (not text).

Verify the field group is assigned to CPT#2.

Configure the View/Block for CPT#2’s map to use the correct address field as its marker source.
After recreating the map and confirming the correct field assignment, markers appeared properly.

Relevant Documentation:

https://toolset.com/course-lesson/displaying-a-list-of-posts-on-a-map/

https://toolset.com/course-lesson/installing-toolset-maps-and-adding-address-fields/

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.

This topic contains 1 reply, has 1 voice.

Last updated by pierre-yvesC 1 hour, 25 minutes ago.

Assisted by: Christopher Amirian.

Author
Posts
#2839255

Hi,

I'm wonder about something: I have a website with 2 CPT. Bth of them have an address field. Those address fields are intended to display posts on a google map (2 different map. 1 indivudual map per CPT).

CPT#1 is displaying correctly, CPT#2 is not displaying anything.

Is it because it's not possible to have 2 diffrent address fields?

Thx

#2839317

Christopher Amirian
Supporter

Languages: English (English )

Hi,

Welcome to Toolset support.

No, this is not a limitation. You can have multiple CPTs and multiple address fields, and show each on its own map.

Please check these points for CPT#2:

Field type

Go to Toolset → Custom Fields and confirm the field on CPT#2 is really an Address field (not a plain text field). For more information:
https://toolset.com/course-lesson/installing-toolset-maps-and-adding-address-fields/

Field group assigned to CPT#2

Make sure the field group with that address field is assigned to CPT#2 so each post actually has a saved address.

Map source matches CPT#2 address field

In the View or Block for the second map, set the marker’s dynamic source/shortcode to the address field of CPT#2, not the one from CPT#1. For more information:
https://toolset.com/course-lesson/displaying-a-list-of-posts-on-a-map/?

Markers not appearing at all

If the map shows but no markers, it usually means the marker is pointing to a field that is empty or not on that post type. Example:
https://toolset.com/forums/topic/view-not-displaying-on-map/

If CPT#1 works, your Maps setup/API key is fine – it’s almost certainly a field assignment or marker-source issue on CPT#2.

Thanks.

#2839354

I checked all of this, then redone the process to create the map from scratch and everything is fine.

Many thx!