- 10 Jan 2025
- 1 Minute To Read
-
Print
-
DarkLight
-
PDF
Set the precedence of Pop-ups using segment ID
- Updated On 10 Jan 2025
- 1 Minute To Read
-
Print
-
DarkLight
-
PDF
When you have more than one Pop-up on the same page of an application, you have a preference to choose the display order of the Pop-ups using segment ID.
Advanced customization enables you to add segment ID of Pop-ups to set their precedence. In this method, you add a code snippet in Advanced customization, and then you add the segment ID of the Pop-ups in the order in which you want the Pop-ups to be displayed. This method of setting precedence for Pop-ups works regardless of the Visibility Rules that you add.
Only an Account Manager can perform the following task. For more information about available roles, see Whatfix User Roles.
-
On the Whatfix Guidance dashboard, click Widgets.
-
Click Pop-ups.
-
Click the Pop-up that you want to display first.
-
Click Copy ID to copy the segment ID of the Pop-up.
-
Click Settings.
-
Go to Advanced customisation.
-
On the Code editor tab, copy and paste the following code snippet, to set the precedence in the order of display of Pop-ups.
wfxsettings.widgetSegmentPrecedence =
{'pop_up': ['segmentId1', 'segmentId2']};
-
The code snippet helps in setting the order of display of Pop-ups. SegmentId1 refers to the first pop-up that you want to display, followed by segmentId2 which refers to the next pop-up that you want to display. You can choose to set the order of display either for one Pop-up or for more than one Pop-ups.
-
If you can't access the code editor, contact support@whatfix.com for more information.
- Replace 'segmentId1' with the Segment ID of the Pop-up that you copied, and then click Save.
Here's a GIF that shows how to use Advanced customization to change the order of display of Pop-ups.
-
The method of using Advanced customization is applicable to all other widgets, and not just Pop-ups, to set their precedence. For more information, contact support@whatfix.com.
-
Advanced customization changes can be previewed only using the Preview extension.