When I run extractor.php on cart.module,v 1.64 2005/10/08 22:05:06, I get this error:

Invalid marker content in cart.module:474
* format_plural($product->qty,t('1 order'),t('%count orders'))

What could be the problem?

CommentFileSizeAuthor
#2 ec-head-translation-fix_0_0.patch4.42 KBsyllance

Comments

syllance’s picture

Assigned: Unassigned » syllance
Category: support » bug

the problem is that there's no need to call t() inside a format_plural() call, as t() is called by format_plural iself.

format_plural($product->qty,t('1 order'),t('%count orders')) should be
format_plural($product->qty,'%count order','%count orders')

note that this not the only issue with translation. i started a patch for these but i need to resync it with head. use this thread to post any other translation related issue you find, i'll then be able to check the one i missed, and will send the patch here once finished.

syllance’s picture

Status: Active » Needs review
StatusFileSize
new4.42 KB

here is a patch to fix various translation issues for head, including the one above in cart.module.

the patch is head port of http://drupal.org/node/31936.

fgm’s picture

Version: master » 4.6.x-1.x-dev
Component: cart.module » cart

Reclassified: uses the 4.6 API.

fgm’s picture

Status: Needs review » Needs work

In addition, the issue remains present, at least for product.module/product_unit_nice_name, in the 4.7 version.

Patch should be updated for 4.7 by replacing the form_* calls by FAPI forms.

brmassa’s picture

Version: 4.6.x-1.x-dev » 5.x-3.0
Status: Needs work » Fixed
Anonymous’s picture

Status: Fixed » Closed (fixed)