[poedit-users] Plural detection fail
MASSUCHETTI Jonathan <[email protected]> Sat, 29 May 2010 19:55:54 +0000
| Newsgroups | gmane.editors.poedit.user |
|---|---|
| Message-ID | <[email protected]> |
--===============0641572884062260718==
Content-Type: multipart/alternative; boundary=0015174c3eacff49a50487c10202
--0015174c3eacff49a50487c10202
Content-Type: text/plain; charset=ISO-8859-1
Hi,
I'm using the Zend Framwork (v1.10) , and I want to use Zend_Translate with
Gettext adapter.
My Zend code looks like :
echo $translate->_("This is a line") . "\n";
> echo $translate->plural("There is one product in your cart","There are
> %1\$d products in your cart",$number) . "\n";
Using PoEdit , this is the .po file I obtain :
msgid ""
> msgstr ""
> "Project-Id-Version: test\n"
> "Report-Msgid-Bugs-To: \n"
> "POT-Creation-Date: 2010-05-29 19:53-0000\n"
> "PO-Revision-Date: 2010-05-29 19:54-0000\n"
> "Last-Translator: MASSUCHETTI Jonathan <[email protected]>\n"
> "Language-Team: Feng\n"
> "Language: \n"
> "MIME-Version: 1.0\n"
> "Content-Type: text/plain; charset=UTF-8\n"
> "Content-Transfer-Encoding: 8bit\n"
> "X-Poedit-KeywordsList: _;gettext;gettext_noop;plural\n"
> "X-Poedit-Basepath: /home/feng/projets/1ersite\n"
> "Plural-Forms: nplurals=2; plural=(n>1);\n"
> "X-Poedit-Language: French\n"
> "X-Poedit-Country: FRANCE\n"
> "X-Poedit-SourceCharset: utf-8\n"
> "X-Poedit-SearchPath-0: application\n"
>
> #: application/test.php:10
> msgid "This is a line"
> msgstr "Ceci est une ligne"
>
> #: application/test.php:11
> msgid "There is one product in your cart"
> msgstr "Il y a un produit dans votre panier"
>
>
As you see, my plural is ignored. Why and how to fix ?
Regards
--0015174c3eacff49a50487c10202
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Hi,<br><br>I'm using the Zend Framwork (v1.10) , and I want to use Zend=
_Translate with Gettext adapter.<br>My Zend code looks like :<br><br><br><b=
lockquote style=3D"margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(20=
4, 204, 204); padding-left: 1ex;" class=3D"gmail_quote">
echo $translate->_("This is a line") . "\n";<br>echo=
$translate->plural("There is one product in your cart","=
There are %1\$d products in your cart",$number) . "\n";</blo=
ckquote>
<div><br>Using PoEdit , this is the .po file I obtain :<br><br><blockquote =
style=3D"margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 20=
4); padding-left: 1ex;" class=3D"gmail_quote">msgid ""<br>msgstr =
""<br>
"Project-Id-Version: test\n"<br>"Report-Msgid-Bugs-To: \n&qu=
ot;<br>"POT-Creation-Date: 2010-05-29 19:53-0000\n"<br>"PO-R=
evision-Date: 2010-05-29 19:54-0000\n"<br>"Last-Translator: MASSU=
CHETTI Jonathan <<a href=3D"mailto:[email protected]">iletaitunfo=
[email protected]</a>>\n"<br>
"Language-Team: Feng\n"<br>"Language: \n"<br>"MIME=
-Version: 1.0\n"<br>"Content-Type: text/plain; charset=3DUTF-8\n&=
quot;<br>"Content-Transfer-Encoding: 8bit\n"<br>"X-Poedit-Ke=
ywordsList: _;gettext;gettext_noop;plural\n"<br>
"X-Poedit-Basepath: /home/feng/projets/1ersite\n"<br>"Plural=
-Forms: nplurals=3D2; plural=3D(n>1);\n"<br>"X-Poedit-Language=
: French\n"<br>"X-Poedit-Country: FRANCE\n"<br>"X-Poedi=
t-SourceCharset: utf-8\n"<br>
"X-Poedit-SearchPath-0: application\n"<br><br>#: application/test=
.php:10<br>msgid "This is a line"<br>msgstr "Ceci est une li=
gne"<br><br>#: application/test.php:11<br>msgid "There is one pro=
duct in your cart"<br>
msgstr "Il y a un produit dans votre panier"<br><br></blockquote>=
<div><br>As you see, my plural is ignored. Why and how to fix ?<br><br>Rega=
rds<br>=A0</div></div>
--0015174c3eacff49a50487c10202--
--===============0641572884062260718==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
------------------------------------------------------------------------------
--===============0641572884062260718==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
_______________________________________________
Poedit-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/poedit-users
--===============0641572884062260718==--