bernhard

is it possible to link directly to the content or delete tab?

5 posts in this topic

hi everybody!

i'm linking directly to some tabs in my processpageedit form and it works great for my custom tabs. it does not work for the system tabs unfortunately :(

/page/edit/?id=123&field=mycustomtab (fieldset tab in the template editor)

shows only the fields inside this tab. I tried this:

/page/edit/?id=123#ProcessPageEditDelete

...but this does not work inside a pw-panel :(

any ideas?

Share this post


Link to post
Share on other sites
3 hours ago, bernhard said:

/page/edit/?id=123#ProcessPageEditDelete

hi @bernhard Can't you just use the complete URL instead?

Share this post


Link to post
Share on other sites

A link like /page/edit/?id=123#ProcessPageEditDelete works as expected when used as a "normal" link, so I think this issue is about the limitations of pw-panel rather than the link itself. 

2 people like this

Share this post


Link to post
Share on other sites

@bernhard, try replacing this part of panel.js with...

if(typeof panelURL != 'undefined' && panelURL.length) {
    var hash = '';
    if(panelURL.indexOf('#') > -1) {
        var url_parts = panelURL.split('#');
        panelURL = url_parts[0];
        hash = '#' + url_parts[1];
    }
    panelURL += (panelURL.indexOf('?') > -1 ? '&' : '?') + 'modal=panel&pw_panel=';

    if($toggler !== null && $toggler.hasClass('pw-panel-links')) {
        panelURL += '2'; // don't update target of links in panel
    } else {
        panelURL += '1'; // update target of links in panel
    }
    panelURL += hash;
}

Let me know if it works for you and if so I'll suggest it on the PW GitHub.

4 people like this

Share this post


Link to post
Share on other sites

thank you robin, that worked!

it's not directly what i wanted but almost the same :)

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.