NO BUG: Javascript BricksOpenPopup doesnt work anymore

In Bricks 1.9.9 i have a Icon (class=info-icon) with an id=(postID)
I have also an Bricks PopupTemplate with Ajax fetch enabled.

and in wpcodebox i have the code:

const elements = document.querySelectorAll(“.info-icon”);
elements.forEach(function(element) {
element.addEventListener(“click”, function(e) {
e.preventDefault();
bricksOpenPopup(
5940,0,{
popupContextId: parseInt(element.id),
popupContextType: ‘post’
}
);
});
});

This opens the Bricks Popuptemplate (with id 5940) and loads the Content from the given Post ID.

After update to Bricks 1.10.2 - i go straight to the frontside - make a refresh - and click the Icon - AND - nothing happens.
Then i put a line with console.log(parseInt(element.id)); in the javascript and the console gives me the correct Post-ID, so this part works . … but not the “bricksOpenPopup”…

Please see also my other Report about no parsing styles in Dynamic Popups.

Hi @LouieX ,

Please provide a link to your page and the setup screenshots of your Query loop and Popup settings.

Any specific reason to use custom code instead of native Interaction to trigger the popup?

Regards,
Jenn

Yes there is a reason:
The Icon sits in a Woocommerce Plugin Output (HTML) via Open Popup.

The Popup template has nothing special and sits in the Footer on the hole Site (i use this on different pages) - it has Ajax Fetching on - thats is.

Cant provide a Link its a Client system…

Short: in 1.9.9 works in 1.10.2 doesnt work (without any changes - just Bricks Update)…

Hi @LouieX ,

I just tested the bricksOpenPopup following your setup.

All working well.

The AJAX Popup triggered and showed. The ID style and global class styles are generated too.

It’s not possible for us to assist if no URL is provided. You can also send us an email if the URL is confidential. (help@bricksbuilder.io by using your license purchased email and include this forum thread as a reference)

Alternatively, if you could replicate this issue in try.bricksbuilder.io or a dummy website (not your client’s website), we can investigate too.

Regards,
Jenn

Hi Jenn,
I have sent a Email. There is a Login and an Explanation…
(The Email is from a other Adresse as the Lizence Mail - but in the Email Text i have wrote the Lizence Mail)

Best Thx, Ivo

Hi @LouieX ,

As per my email reply, there is a new setting to allow Render Popups in 1.10.2 if it’s Maintenance mode.

1 Like