Hi there!
I've finally gave the new pre-alpha 4 dev a try. Looks brilliant!
One small bug - the advanced_forum.module has those forum_tools links defined.
But the names of those links are not placed inside t().
Hence one can't use translations for them...

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Michelle’s picture

Whoops, that definitely needs to get fixed. Thanks for reporting!

Michelle

__Sander__’s picture

And here
$variables['total_posts_count'] = format_plural($posts, '1 post', '@count posts');
in includes/theme.inc

Michelle’s picture

#2 is intentional. You don't send translated strings to format_plural.

Michelle

__Sander__’s picture

Got your point.
But looks like it makes impossible to use translations for this...
What if you have it in the form
9 total / 3 new
?
But of course I can edit the code manually

Michelle’s picture

The translation system is meant for translating to other languages. While it can be used for changing to a completely different English word, that's not the design. In this case, yeah, you would have to edit the template because you're not going to want to translate post/posts to total. That's not an AF issue, though, just a limitation of the translation system that translates words across the board.

Michelle

Michelle’s picture

Version: 6.x-2.x-dev » 7.x-2.x-dev
Status: Active » Patch (to be ported)
FileSize
3.27 KB

Ok, t() added around forum tools menu items in D6. Bumping this up to D7 for porting.

Michelle

__Sander__’s picture

Sorry, but the patch file is missing...

troky’s picture

Status: Patch (to be ported) » Fixed

Try this

Already ported to D7.

__Sander__’s picture

Confirming that it's been fixed in the latest dev.
And I've learned finally how to handle the translation of plural forms - one searches for @count[2] posts
Thanks!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

Ingumsky’s picture

Status: Needs review » Active

Same for the line 913:
$number_new = t("(!new new)", array('!new' => $number_new_comments));
shouldn't it be like:
$number_new = format_plural($number_new_comments, '(1 new)', '(@count new)');
to be translated properly?

Michelle’s picture

Title: Translation template missing for "Forum tools" » Translation template missing in AF files
Version: 7.x-2.x-dev » 6.x-2.x-dev
Status: Closed (fixed) » Active

Well, either way will translate so it's not missing but, yeah, format_plural makes more sense. I may not have known about the function when that line was written. :)

I'm basing my response purely on #11. I haven't looked at the code to see if there's a reason why it was done that way but I can't think of any off the top of my head.

Ingumsky’s picture

Yeah. It is definitely not 'missing' because I can translate it :) I haven't noticed this subject updated by me wasn't anywhere near the real issue :)

Ingumsky’s picture

Text for the links to the new comments in the Posts column (Topics list) cannot be translated at the moment and it should be changed too. Current version of Views module (6.x-2.16 in my case) does support translations including plural forms for translatable strings. To make it working you just need to replace this:
advanced_forum_active_topics.view: 312

    'prefix' => 'View ',
    'suffix' => ' new',

with this:

    'format_plural' => 1,
    'format_plural_singular' => 'View 1 new',
    'format_plural_plural' => 'View @count new',
    'prefix' => '',
    'suffix' => '',

And it will work as it should.

Ingumsky’s picture

Status: Active » Needs review
FileSize
582 bytes

And here's the patch... You should place it to /includes/views and then apply.

mcdruid’s picture

Assigned: Unassigned » Ingumsky
Status: Active » Needs review

Assigning issues you've worked on to you Ingumsky, so I can see which ones you haven't.