Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
To link to Omni Panel and open it
#1
Example: This will open this page with 3rd panel open and scrolled down to the OPM location:  
https://www.shorehavenbhi.com/mental-hea..._3#p7OPM_1

so, after the page name, add
?opm
the panel name (third panel)
1_3#
and the name of the OPM

another example:
https://www.shorehavenbhi.com/mental-hea..._5#p7OPM_1

opens the 5th panel  



(if there were 2 OPMs on the page the second one would be called 
OPM_2)
Reply
#2
(01-04-2025, 06:57 PM)bizpat (Patrice) Wrote: Example: This will open this page with 3rd panel open and scrolled down to the OPM location:  
https://www.shorehavenbhi.com/mental-hea..._3#p7OPM_1
so, after the page name, add
?opm
the panel name (third panel)
1_3#
and the name of the OPM
another example:
https://www.shorehavenbhi.com/mental-hea..._5#p7OPM_1
opens the 5th panel  
(if there were 2 OPMs on the page the second one would be called 
OPM_2)

~~~~~~~~~ 12/25/25~~~~~
New, simpler answer:
On the page, add this script to bottom of OPM
<script>
document.addEventListener("DOMContentLoaded", function () {
    const params = new URLSearchParams(window.location.search);
    const panel = params.get("panel");

    if (panel) {
        const tabId = "p7OPMtg_1_" + panel;
        const tab = document.getElementById(tabId);

        if (tab) {
            // Delay ensures OPM is fully initialized
            setTimeout(function () {
                tab.click();
            }, 200);
        }
    }
});
</script>
Then to jump to or include in an email link, use the page name followed by ?panel=2 or whatever panel name is desired.
Example here https://biz-websites.com/2025-test-omp.php?panel=2
Reply
#3
For the link to scroll to the panel use this 



<script>
document.addEventListener("DOMContentLoaded", function () {
    const params = new URLSearchParams(window.location.search);
    const panel = params.get("panel");

    if (panel) {
        const tab = document.getElementById("p7OPMtg_1_" + panel);
        const panelWrap = document.getElementById("p7OPMpw_1");

        if (tab && panelWrap) {
            setTimeout(function () {
                // Open panel
                tab.click();

                // Smooth scroll to panel area
                panelWrap.scrollIntoView({
                    behavior: "smooth",
                    block: "start"
                });
            }, 250);
        }
    }
});
</script>
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)