• Resolved damaru

    (@damaru)


    I hacked the code so that when you click on the suggestion it opens in a new page:

    Line 42 of assets/js/orders-autocomplete.js
    (which I copied to the .min file after
    line 42 I commented out the normal linking:

    // window.location.href = “post.php?post=” + suggestion.objectID + “&action=edit”;

    Then added these to make it open in a new window/tab

    window.open(
    “post.php?post=” + suggestion.objectID + “&action=edit”,
    ‘_blank’ // <- This is what makes it open in a new window.
    );

    Wondering if there could a setting to be able to open in a new window, which is often needed when editing orders.

Viewing 1 replies (of 1 total)
  • Plugin Author rayrutjes

    (@rayrutjes)

    Hello,

    Thanks a lot for sharing your solution to open orders on new tabs.

    I believe this is indeed really useful. I’m even wondering if this shouldn’t be the default.

    I’m personally a power user of the “Open in new tab” feature of the browser.

    I terms of work and maintenance, introducing a new setting is more demanding than making this new behavior the default.

    So I would tempted to wait until more users ask for the same.

    Thanks again for sharing!

Viewing 1 replies (of 1 total)
  • The topic ‘Open in a new window’ is closed to new replies.