Top
Pop-up appears across other pages besides the intended page
  • 20 Jun 2025
  • 3 Minutes To Read
  • Dark
    Light
  • PDF

Pop-up appears across other pages besides the intended page

  • Dark
    Light
  • PDF

Article summary

Issue

A Pop-up that should appear only to the logged-in users on the application page appears to the non-logged-in users as well.

Probable Causes

  • Pop-up is evaluated across all pages of the application.

  • Pop-up Visibility Rules aren't set correctly.

    Debug Pop-up issues

    To get the Pop-up debug logs, use the following steps:

    1. Go to the page in your application where you are facing Pop-up issues.

    2. Open your browser's Developer Tools
      debug_flow_devtools.png

    3. Go to the Console tab.
      debug_console.png

    4. Type _wfx_settings.debug_mode=true; and press Enter.
      debug_mode.png

    Info:

    Here, you are setting the _wfx_settings.debug_mode variable to a true value, which instructs Whatfix to provide debug logs for Whatfix widgets whenever they load on a page.

    1. Type _wfx_refresh(); and press Enter.
      wfx_refresh.png
    Info:

    The _wfx_refresh(); command reloads all Whatfix content and widgets that are supposed to load on the page.

    1. Click Popup to expand its output.
      debug_popup.png

    The ArrayList object contains all the Pop-ups evaluated on that page. Expand each index (0, 1, 2, etc.) to see the details of each Pop-up.
    debug_popup_arraylist.png

    The following are some fields useful for identifying problems with your Pop-up:

    • name: The name of the Pop-up.
    • times_to_show: The number of times your Pop-up is set to show.
    • popup_view_count: The number of times you have viewed the Pop-up.
    • conditions: The Visibility Rules configured for your Pop-up to show.
    Note:

    If your Pop-up isn't configured to show on the page you are on, it is not part of the debug logs.

Suggested Solutions

  • Check whether user roles are used to configure the Pop-up Visibility Rules. If so, ensure that the appropriate user roles are added.

  • Check the Visibility Rules to determine the appearance of the Pop-up based on When, Where, and Who that are part of the Advanced Visibility Rules. For more information, see Understand Advanced Visibility Rules.

Note:

  • Advanced Visibility Rules are currently available only to selected customers and are supported across all widgets. For more information, contact support@whatfix.com.

  • Always test Pop-ups using the Whatfix Preview mode before they are visible to your users. For more information on how to Preview a Pop-up, see Preview pop-ups.

  • If the issue persists, contact support@whatfix.com.

  • To ensure that the Pop-up appears only on the intended application page, add unique CSS selectors for the page where you have created the Pop-up. If the CSS Selector used for the element is not unique and is shared by other elements on the page, it can result in the Pop-up to display in an incorrect position or across every page of the application. For more information, see Selected Element condition rules.

Steps to find out an element's CSS selectors in your browser    

  1. Open your browser's Developer Tools.  chrome_devtools.png  

  2. Go to Inspector Mode. chrome_inspect_mode.png  

  3. Select the element whose selectors you want to find. chrome_select_element_inspect.png  

  4. Identify the selectors of the highlighted tag in the Elements section of the Developer Tools window. chrome_highlighted_tag.png  

  5. Use an appropriate selector in your content's Display Rules.

    Note:

    Use CSS selectors in Display Rules such as Selected Element Is and Other Element On Page.

How to choose a good CSS selector?

Once you identify the CSS selectors of an element, you must choose a selector or a combination of selectors such that it uniquely describes your selected element. The following are some tips to do so:

  • If your element has an ID, use it as a CSS selector. The ID of an element is usually unique.  debug_select_id.png  

  • If your element has multiple classes, use a combination of them in your Display Rules.  debug_multiple_classes.png  

    Note:

    Specify multiple classes in a CSS selector by chaining them together. The following is an example of specifying 3 classes in a CSS selector:

    .class1.class2.class3

  • If your element doesn't have any unique attributes, check whether a parent element can uniquely identify your element. Ensure that the Parent element contains only the element you want to show your content on, else your content might show on any one of the Sibling element. debug_select_parent.png  


Was this article helpful?


Changing your password will log you out immediately. Use the new password to log back in.
First name must have atleast 2 characters. Numbers and special characters are not allowed.
Last name must have atleast 1 characters. Numbers and special characters are not allowed.
Enter a valid email
Enter a valid password
Your profile has been successfully updated.