1. PROMO Upgrade to Pro Membership @ $99 / Lifetime & access all our 16+ premium Divi extensions: Divi Block, Carousel Toolkit, etc.LEARN MORE
Dismiss Notice
NEW Divi.Help Pro Carousel AI Toolkit - Magically turn your Divi design into carousel, simply by using our online toolkit. No plugins needed. Now it works with Divi 5 as well!Try our carousel AI toolkit
BEST Divi Block - A revolutionary drag & drop tool to easily mix & match 960+ premade blocks (Light & Dark) to kick start your Divi site design. Special module designs are included as well. Also newly added AI generator & color. Now it works with Divi 5 as well!
Learn More About Divi BlockFree Version ~ 340+ Free Blocks

Solved How to get link open in new window with menu bars closed

Discussion in 'Free Divi Community Forum' started by Nickk, Jun 3, 2020.

  1. Nickk

    Nickk New Member

    I have a blurb module that has a link and also has that link in the text field:

    `<a class="blurb_link" href="/lessons/lesson1/" target="_blank" rel="noopener noreferrer">Start</a>`

    Both the link as well as the url in the text field open in a new tab in the browser with all menu bars etc. open. Instead, I would like the link to open in a new window with all menu bars closed. How can I do this?

    I think the Javascript code would be something like below, but how can I add this javascript to the link?

    `window.open(/lessons/lesson1/,_blank,fullscreen=yes,location=yes,toolbar=no,menubar=no,resizable=yes,scrollbars=no,titlebar=no)`
     
    1. PRO MEMBER PERKS Beautifully crafted custom colored 'Industrial' Divi layout for all Pro members:View Demo
  2. Nickk

    Nickk New Member

    Oh, found my own solution:

    I added a code module:
    <script type="text/javascript">
    function myFunction() {
    var myWindow = window.open("/lessons/lesson1/","_blank","fullscreen=yes,location=yes,toolbar=no,menubar=no,resizable=yes,scrollbars=no,titlebar=no");
    }
    </script>

    I added a blurb module:
    <a class="blurb_link" onclick="myFunction()">Start</a>

    Only thing is the mouse cursor does not change to a hand when moving over the "Start" text.
     
  3. Nickk

    Nickk New Member

    Adding custom css `cursor: pointer;` also added the mouse pointer.
     
    1. PRO MEMBER PERKS Divi Block Pro - 30+ premade custom footer designs for you to choose from:View Demo