Contact Us

If you still have questions or prefer to get help directly from an agent, please submit a request.
We’ll get back to you as soon as possible.

Please fill out the contact form below and we will reply as soon as possible.

    English (US)
    US English (US)
    FR French
    DE German
    ES Spanish
    IT Italian
    JP Japanese
    • Home
    • User Guides
    • Locator + Pages

    How to add an outside element in Locator & Pages

    Outlines a basic HTML injection into the local pages of the Locator.

    Written by Marco Degano

    Updated at September 2nd, 2025

    Contact Us

    If you still have questions or prefer to get help directly from an agent, please submit a request.
    We’ll get back to you as soon as possible.

    Please fill out the contact form below and we will reply as soon as possible.

    • Getting Started
      API Guides 'Near Me' 360 Product descriptions New here Configuration and Connection Guides
    • Uberall Academy and Learning Resources
      Learning Resources - Best Practices Uberall Academy
    • User Guides
      AI What's New Platform Status and General FAQs Homepage The Dashboard Location Hub Review Management Messages Social Locator + Pages Analytics Directories Mobile App Directories
    • Connecting Tools
      Connection Troubleshooting API
    • Org Settings
      Users Billing API Keys Webhooks Legal Documentation Product Descriptions
    + More

    Table of Contents

    ScopeIntroductionScriptHow it worksApply to other elements

    Scope

    This article offers a generic and basic solution to add an outside component to Locator & Pages via JavaScript.

    Introduction

    Disclaimer

    The following attempt was created and tested with a certain Locator and Pages version. Please note, that this solution might not be supported at a given point in future and we do not guarantee support for it. This is to be used as a proof-of-concept.

    The presented solution to inject an external HTML element to Locator & Pages uses JavaScript to insert the element after a specific element of Locator & Pages.

    Script

    window.setInterval(function() {
    if(document.getElementsByClassName('myAddedParagraph').length == 0 && document.getElementsByClassName('ubsf_details-box-wrapper ubsf_categories-box').length > 0){
    const cats = document.getElementsByClassName('ubsf_details-box-wrapper ubsf_categories-box')[0];
    var html = "<p class=\"myAddedParagraph ubsf_details-box-wrapper\">newly added paragraph</p>";
    cats.insertAdjacentHTML("afterend", html);
    }
    }, 500);

    How it works

    The JavaScript triggers every 500 millisecond and then looks for two things:

    1- Does an element with class myAddedParagraph exist in this page?

    2- Does an element with class ubsf_details-box-wrapper ubsf_categories-box exist in this page? (This is necessary since the new element is added after the Categories element)

    If the answer of check 1 is No and the answer of check 2 is Yes, then a new HTML element is defined (cats) and added after the element with class ubsf_details-box-wrapper ubsf_categories-box.

    Having the script run at fixed intervals means that it will keep working if the user changes to another page of the Locator.

    Apply to other elements

    A few things need to be modified in the script to be able to apply it to another use-case. In the provided example, a new paragraph is added under the Categories element of the Local Page.

    - html string needs to contain the html structure of the new element

    - The class name of the new element needs to stay consistent in the script (myAddedParagraph in this case)

    - The class name of the element after which the new element needs to be added (ubsf_details-box-wrapper ubsf_categories-box in this case)

    - The following can be changed to add the new element before the targeted element: afterend (https://developer.mozilla.org/en-US/docs/Web/API/Element/insertAdjacentHTML)

    locator incorporate

    Was this article helpful?

    Yes
    No
    Give feedback about this article

    Related Articles

    • FAQ about Self Serve Locator & Pages
    • What is embedded Locator + Pages (Self Serve)?
    • Customizations of Locator + Pages via CSS
    • Locator and Pages attributes
    • Filters for Locator & Pages

    Copyright 2025 – uberall.

    Knowledge Base Software powered by Helpjuice

    Expand