Bricks 1.9.4 added AJAX support for Popups via its Popup Builder.
popupContextId
can be now set in bricksOpenPopup()
which means a popup can be set to show dynamic data from any post with the specified ID.
This Pro tutorial provides the steps for setting up a dynamic Popup that opens on page load and shows data like Post Title and Post Excerpt pertaining to the post whose ID is passed in the id
URL parameter.
Ex.: example.com/?id=103 will show a popup having featured image, post title, excerpt and a button linking to the permalink of the post whose ID is 103.
example.com/?id=106 will show a popup having featured image, post title, excerpt and a button linking to the permalink of the post whose ID is 106 and so on.
Step 1
Go to Bricks → Templates and import the following "Post Popup" template.
This is a BricksLabs Pro tutorial.
For full access login below or create your BricksLabs Pro account