Beta7 Layoutbuilder and MEC-Single

Hi there! :grinning:

I’m in the early stages of concepting a Site for a theater and am using the beta7 (which is awesome by the way!) to dive into that a little too.
Since there will be lots of events built with MEC, will there be a way to create a new events-single including the modules they now have in their single-mec-events in a more flexible way using the Layoutbuilder? EG with dynamic content or shortcodes?

Cheers Patrik

I am building a new site starting from Beta 7. MEC is the key part of it, for me as well.

I see that many of MEC custom Dynamic keys are available. For example, mec_allday returns 1 if the event is set as an All day event.

I wonder if it is possible to set a condition on an element like Text, that would do something like this. IF mec_allday = 1, Display the Element.

Also, MEC and many other plugins have well documented ways to override their Single Event page. For example, they say that this is needed to display their QR widget: $single->display_qrcode_widget($single_event_obj);.

To a non-developer, that doesn’t mean much. :slight_smile: I wonder if there is a way to display such widget from native Dynamic content?

Also, I have tried to find a way to display a background-image on a Homepage section. This background image should be called from the Ongoing MEC event. It seems that this is not possible because there are only Current, Next, Previous and Specific Post. Then I have remembered that I could use the new Loopers for this, but with no luck. :slight_smile: I have tried to change the Looper Provider on the post element to “Event”, but the Element continues to show WordPress posts.

Hey there, regretfully the Layout Builder won’t have first class integration with MEC for this release. I could see it potentially being something we build out similar to how there are special WooCommerce modes of the Layout Builder.

@Misho I believe the post type control was broken in beta7 and earlier. Beta 8 will let you properly filter by post type.

1 Like

@alexander, I have noticed that a MEC shortcode placed inside a certain section will cause the subsequent sections to disappear on the front-end. In the Content builder they are showing up normally. Footer is not disappearing, only the Content builder sections.

Not sure if that is a Plugin bug or something about Beta.

@Misho gotcha! It sounds like the same issue as this: B8: Bug - Looper consumer: Text element with Excerpt dynamic content breaks looper

Could you try beta9? Just pushed it out. Let me know if that works for you.

1 Like

@alexander, it is working now! As soon as I updated to Beta 9, the missing sections appeared. Thanks!

Ok great! Thanks for confirming.

1 Like