Add class not working in block advanced setting

By: Tom Boltwood | Asked: 08/19/2022
ForumsCategory: General questionsAdd class not working in block advanced setting
Tom BoltwoodTom Boltwood asked 2 years ago
Has anyone else got this? I've added my form as a block and then given it a class in the 'Advanced' block option, but it doesn't appear in the html.
Bobby Clapp replied 2 years ago

Sounds like a caching thing to me.

Tom BoltwoodTom Boltwood replied 2 years ago

Yeah, I'm not using caching, it's on a dev site.

Bobby Clapp replied 2 years ago

Server side caching possible? Can you share a public link and provide any explanation, if necessary?

1 Answers
Victor Font answered 2 years ago

I suggest you report this as a bug. I confirm it's not working. The block isn't playing nicely with Gutenberg. The advanced class field in the editor adds the class to the block wrapper, not the form itself. When you examine the HTML, there is no Gutenberg block wrapper being generated for the form block.

Simon van Stipriaan replied 1 year ago

Was this ever acknowledged as a bug? And/or what work around have people used?

Victor Font replied 1 year ago

We wouldn't know whether S11 acknowledged this as a bug. This is a Community Forum. We don't have any insight into what the S11developers do or plan. I can confirm, it's not working as of v6.4 The workaround is to use jQuery.

Simon van Stipriaan replied 1 year ago

Okay np, Thanks for you time in replying Victor!

Victor Font replied 1 year ago

That's the one reason I always embed the shortcode in a custom HTML block so I can use my own wrappers.

Making the Best WordPress Plugin even better - Together

Take on bigger projects with confidence knowing you have access to an entire community of Formidable Experts and Professionals who have your back when the going gets tough. You got this!
Join the community
crossarrow-right