Support » Plugin: Tabify Edit Screen » Prevent empty tabs from showing

  • This is a brilliant little gem for anyone dealing with multiple metaboxes. Makes the UI so much more manageable. One issue though. On a certain occasions, we have a post type that has different metaboxes on different circumstances. For example, the Front-page page type can have a different configuration from a regular page.
    If create a tab dedicated to a specific page, that ends up showing on every page. Would it be possible hide tabs that don’t have metaboxes for given context?

    https://wordpress.org/plugins/tabify-edit-screen/

Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Author Marko Heijnen

    (@markoheijnen)

    Hey Luis,

    Good idea to not showing tabs that are empty. I’m surprised it isn’t that already so I will add this in the next version.

    Best, Marko

    Ops, missed your reply, thanks for the feedback Marko.
    I think this would solve another problem. On pages, where we can have multiple templates with different metaboxes, this would also allow to have different tabs appearing for different page templates.
    For example, on the site homepage I can have a set of metaboxes that won’t appear on the the about page. Because the metaboxes are set to only appear for the frontpage, we end up being able to use the metaboxes context abilities to control which tabs appear where.

    Thanks again.

    Plugin Author Marko Heijnen

    (@markoheijnen)

    Hey Luis,

    In case you want to try out the dev version, https://github.com/markoheijnen/tabify-edit-screen you can find the latest code that should fix your problem.

    Best,
    Marko

    Im certainly will Marko and give you feedback on how it goes.
    Thank you so much for sharing.

    Hi Marko,

    I was just testing this out today. I’ve pulled the master branch and installed on a site im working on where I have a few metaboxes just for the homepage. I’ve created some tabs for those and they do show on the homepage page, but on the other pages the tabs are still displayed, even though there are no metaboxes to display inside them.

    Anything else I could try to give you more feedback on this?

    Plugin Author Marko Heijnen

    (@markoheijnen)

    How are those meta boxes added? Could easily be that they do exist but are hidden through Javascript. That is the only way my code would not work.

    Plugin Author Marko Heijnen

    (@markoheijnen)

    I just released the adjustments I made. Can you give me more information on how you do it? Like are you using ACF or something a like?

    Sorry Marko, I missed your previous comment.
    Yes, I am using ACF and only after your comment I realised it hides the fields via JS to that explains the behaviour.

    Plugin Author Marko Heijnen

    (@markoheijnen)

    After some previous discussions around an issue I had with him, he decided to go that way.
    Which wasn’t my preferred solution and which also makes the issue around your problem a bit harder to solve. I don’t think I can solve it without incorporate some ACF functionality.

    Thank you Marko. Considering that, is there any filter available that would allow me to control which tabs would appear? My main issue now is that I have a lot of pages displaying empty tabs due to the way ACF works.

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Prevent empty tabs from showing’ is closed to new replies.