WordPress.org

Ready to get started?Download WordPress

Forums

Post Status Menu Items
[resolved] Translation of Drafts and Trash (10 posts)

  1. Lea Cohen
    Member
    Posted 1 year ago #

    Hi

    Thanks for a great plugin.
    Where question though - how can I translate the words Trash and Drafts that are in the posts menu?

    Thanks

    http://wordpress.org/extend/plugins/post-status-menu-items/

  2. mrwweb
    Member
    Plugin Author

    Posted 1 year ago #

    The plugin follows WordPress standards for internationalization (or "i18n" for short). There is a .pot file ready for translation in the /languages folder of the plugin.

    Unfortunately, I don't have experience as a translator, so I can't help you much beyond there. The Codex page I linked to in the last paragraph is a good place to start. If you do end up doing a full translation in another language, I'd be happy to include the translation file in future versions of the plugin!

    Though is feels like overkill for just a few words, there are plugins that allow you to translate plugins in the WordPress interface such as WPML or CodeStyling Localization (the latter of which I've used to test the "translate-ability" of the plugin).

    -----------------------

    I should also mention that if you're not actually looking to translate to another language but just to change the labels to other English words, the function uses the get_post_stati() function to generate the list of statuses in the menu. That means if you can manage to filter the $wp_post_statuses global, the plugin should use the result. You could also use the Edit Flow custom statuses feature to manage the statuses.

    -----------------------

    Hope this sends you down the right path!

  3. Lea Cohen
    Member
    Posted 1 year ago #

    Hi,

    Thank you for your quick and detailed reply. It helped in looking more at your plugin, and I saw that there's a difference in the display of the post statuses:

    In the writing options, there is a translation of the statuses (without me translating your plugin), as you can see here.

    But in the Posts menu, there isn't a translation, as you can see here. And this is where I want it to translate.

    I see that the code that retrieves the statuses is different in each case. Could that be the reason? If so, what can I do?

  4. mrwweb
    Member
    Plugin Author

    Posted 1 year ago #

    I see what you're saying now, sorry for being a little slow. It does look like there's some underlying issue I need to fix.

    I'll try to take a look and report back soon if there's a fix to be made.

  5. mrwweb
    Member
    Plugin Author

    Posted 1 year ago #

    I just wanted to give you an update on this issue.

    I've confirmed that the menu items shouldn't be translatable as they are currently setup. That's certainly not what either of us want, but it gives me a direction for working out a solution and it means I can confirm with you that it's nothing you're doing causing the issue :)

    I'm hoping to figure this out by week's end and I'll post here if/when I push an update that resolves the issue.

  6. Lea Cohen
    Member
    Posted 1 year ago #

    Thanks a lot for the update.
    I'm looking forward to your solution :)

  7. Lea Cohen
    Member
    Posted 1 year ago #

    Hi,

    Is there any good news? :)

    Thanks
    Lea

  8. mrwweb
    Member
    Plugin Author

    Posted 1 year ago #

    Good news: I have a few new possible paths forward.
    Bad news: I haven't had time to try them.

    I've got some time optimistically blocked off for this next week, so I'm hoping to get to it sooner rather than later! Thanks for pinging me, though. A friendly nudge is always appreciated.

  9. mrwweb
    Member
    Plugin Author

    Posted 1 year ago #

    Lea,

    I've been able to fix the problem—at least in my tests—and pushed out version 1.1.3. Give it a try when you get a moment and let me know if it's working for you.

  10. Lea Cohen
    Member
    Posted 1 year ago #

    Hi

    Thank you very much - it works!
    I really appreciate your effort!

    Lea

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic