Dear @spicerldn ,
Thanks for sharing with us.
Judging from the info we had so far it’s a style conflict.
So, if it worked the other day correctly but not now, could you tell us what changed? Maybe you installed a new plugin/theme or updated one?
Something should have caused this and we would like to know what changes were made before.
Thanks beforehand.
Hi there
Thanks for the reply.
All I did was change the size and the line height of 2 headings fonts in the customiser. It was after I did this that the button styling disappeared on the frontend. I reverted the changes but it still looks as per my attached images.
Dear @spicerldn ,
Could you let us know whether you cleared cache after reverting the changes? It’s possible some caching issue exists and that’s why the button appearance didn’t change to the original one.
Please, let us know.
Hi there
Yes, I cleared the cache each time I made a change but it’s still the same.
It seems to be treating the button as a link, not a button (colours are the same as the link display settings in the customiser.)
I have also raised a ticket with Generatepress to see if they can help.
Whatever I do, it doesn’t show button styling on the frontend.
Dear @spicerldn ,
Could you export the popup and send it to support@popup-builder.com?
You can use wetransfer.com to send the file.
In case you need the article on exporting the popup, please, find it under the following link:
How to Import/Export Popups
P.S. When sending, please, mention this thread so the case can be easily identified.
Hi there
Support at GeneratePress said the following:
GenerateBlocks styling is built to work within your content area.
When it comes to third-party locations, integration needs to be specifically added: https://docs.generateblocks.com/article/adding-content-sources-for-dynamic-css-generation/
I have tried to add this to functions.php but I’m not sure if I have the plugin id correct?
add_filter( 'generateblocks_do_content', function( $content ) {
$post_ids = array( 5772, 5841, 5843 ); // A post ID to check the content of. Can be dynamically set.
foreach ( $post_ids as $post_id ) {
if ( has_blocks( $post_id ) ) {
$block_element = get_post( $post_id );
if ( ! $block_element || 'sg-popup' !== $block_element->post_type ) {
return $content;
}
if ( 'publish' !== $block_element->post_status || ! empty( $block_element->post_password ) ) {
return $content;
}
$content .= $block_element->post_content;
}
}
return $content;
} );
Please can you advise?
Many thanks!
Spicer
I have been provided with a solution!
add_filter( 'generateblocks_do_content', function( $content ) {
$args = array(
'post_type' => 'popupbuilder',
// Other args if you need them.
);
$posts = get_posts( $args );
foreach ( (array) $posts as $post ) {
if ( isset( $post->post_content ) ) {
$content .= $post->post_content;
}
}
return $content;
} );
Thank you for all your help and for looking into this for me.
π
Dear @spicerldn ,
You are welcome π
We are glad to be a help.
If anything else comes up, do not hesitate on getting back to us.
Thanks,
Popup Builder Team