Skip Navigation

[Resolved] Maps with Blocks

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

Problem:

Display Views block in other page builder.

Solution:

Toolset Blocks plugin is based on WordPress Blocks editor, if you are using other page builders to design the page, and display shortcodes in other page builders, it is not recommended to setup the view block or map block, this will conduct unexpected results.

To avoid those unexpected results, you need to setup views with classic editor, and display views with shortcodes.

Relevant Documentation:

This support ticket is created 2 years, 11 months ago. There's a good chance that you are reading advice that it now obsolete.

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.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Hong_Kong (GMT+08:00)

This topic contains 6 replies, has 2 voices.

Last updated by Pete 2 years, 11 months ago.

Assisted by: Luo Yang.

Author
Posts
#2060875
aaa Toolset 1.png

Hi there,

Currently we have a few Legacy Views, these we use extensively thought our sites and they work great.
However to build the Loop Item using blocks may give us greater flexibility.

As you can see, the Loop Item has two maps in them, one for desktop and one for mobile.

If we use a Block Editor where do we create the maps?

We really do not wish to change any other aspect of the View.

This how they typically look using URL params: hidden link

#2060957

Hello,

With Blocks editor, you can put the map blocks in any place of same page as the view block, and in the map block setting, choose the option "Source for the marker"-> View block, choose the post view, see our document:
https://toolset.com/course-lesson/displaying-a-list-of-posts-on-a-map/
Screenshot:
https://toolset.com/wp-content/uploads/2019/11/maps-view-as-the-source.png

That means you can setup multiple map's data source from same view block.

#2060991
aa ts 2.png

Great,

So can I still add as shortcodes as we have done in the past?

I'm only asking these questions as I tried this, broke tings and didn't know why.

Thank you.

#2061007

Nope, as I mentioned above, you should use WordPress Blocks editor to edit the page, and display Maps blocks in that page, if you use shortcodes, then you won't be able to see the settings as the screenshot I mentioned above:
https://toolset.com/wp-content/uploads/2019/11/maps-view-as-the-source.png

#2061027

Hmmm ok!

Currently we use one View on up to 20 pages, changing the outputs of these via shortchodes.

These we do using content templates. Are you saying we can't do it this way anymore and building page by page?

#2061029

Toolset Blocks plugin is based on WordPress Blocks editor, if you are using other page builders to design the page, and display shortcodes in other page builders, it is not recommended to setup the view block or map block, this will conduct unexpected results.

To avoid those unexpected results, you need to setup views with classic editor, and display views with shortcodes, same as your current settings.

#2065465

My issue is resolved now. Thank you!

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.