That is great. Thank you so much.
On Apr 8, 5:42 pm, "Larry E. Masters aka PhpNut" <[EMAIL PROTECTED]> wrote: > Martin, > I have already fixed this in the core. Please update to the latest branch > 1.2.x.x from svn. > > Related ticket:https://trac.cakephp.org/ticket/4420 > > -- > /** > * @author Larry E. Masters > * @var string $userName > * @param string $realName > * @returns string aka PhpNut > * @access public > */ > > On Tue, Apr 8, 2008 at 8:24 AM, [EMAIL PROTECTED] < > > [EMAIL PROTECTED]> wrote: > > > Larry: Sorry, I did not see your message at first (google web- > > interface). Here is what my Mac spits out: > > int(4294967295) > > int(2500072158) > > int(-1794895138) > > > My Apache/PHP setup is "out of the box" Apple-standard. Apache-confs > > are only added to setup vhosts and to allow Cake's .htaccess files to > > take over. > > I am pretty sure this is a problem because of the 64bit OS. Apache is > > displayed as a 64bit process. Besides, the .mo-files work perfectly on > > my Ubuntu server. > > > I put my full phpinfo in the bin if you are interested. > >http://bin.cakephp.org/saved/30732 > > > /Martin > > > On Apr 1, 4:18 pm, "Larry E. Masters aka PhpNut" <[EMAIL PROTECTED]> > > wrote: > > > Martin, > > > Run the code from this paste:http://bin.cakephp.org/saved/30507 > > > > You should get the same output as in the "note" > > > > If this is not the case your php is not configured properly. > > > > Please provide more information about your server environment. > > > > -- > > > /** > > > * @author Larry E. Masters > > > * @var string $userName > > > * @param string $realName > > > * @returns string aka PhpNut > > > * @access public > > > */ > > > > On Tue, Apr 1, 2008 at 4:38 AM, [EMAIL PROTECTED] < > > > > [EMAIL PROTECTED]> wrote: > > > > > Those variables are undeclared because they come from the extract > > > > statement and DO contain values. > > > > > So I changed the topic to reflect the real question: > > > > Why is MY mo-file not accepted? > > > > > My "magic" value in the header is "-1794895138". > > > > Apparently it should be "2500072158". > > > > I come to this conclusion since both expressions in the if-statement > > > > result in that number. > > > > If I tweak the if-statement to accept my file it is parsed and > > > > translation works without any apparent problem. > > > > > What is the "magic" number? A checksum? How do I go about "debugging" > > > > my (also working) po-file? PoEdit has no problem and spits out no > > > > errors. > > > > > On Apr 1, 11:27 am, "[EMAIL PROTECTED]" > > > > <[EMAIL PROTECTED]> wrote: > > > > > I have had a lot of problems getting i18n translation working but I > > > > > think this may be one for the trac. THis is a sanity check before > > > > > posting a ticket... please read on and tell me I am wrong :) (which > > is > > > > > always fun) > > > > > > I have debugged a bit in cake/libs/i18n.php and found that my > > > > > "default.mo" is loaded but then I found some strange code where the > > > > > file should begin parsing: > > > > > --- line 390-391 --- > > > > > if (($magic == (-1794895138 & 0xFFFFFFFF) || $magic == (2500072158 & > > > > > 0xFFFFFFFF)) && $version == 0) { > > > > > for ($n = 0; $n < $count; $n++) { > > > > > --- > > > > > > $magic and $count are never assigned values and thus the file will > > > > > never be parsed. This is what I assume is a bug. The reason I doubt > > > > > myself even though logically the file will never be parsed is that > > my > > > > > previous questions have turned up people happily using "mo-files". > > > > > > My setup in the app: > > > > > > in config/core.php all caching is turned off (when debugging to > > avoid > > > > > cached locale data). > > > > > > optional: in config/core.php I have set the language to Swedish: > > > > > Configure::write('Config.language', 'swe'); > > > > > > the file locale/???/LS_MESSAGES/default.mo contains translations > > > > > compiled by poedit. (??? = swe or eng if using default) > > > > > > That is it. Does not display any translated texts. Translations are > > > > > displayed using the __() function and all working with the > > uncompiled > > > > > default.po. When I activate caching The cached translation-file > > > > > contains the following which amounts to nothing: > > > > > ---- > > > > > 1207044332 > > > > > a:1:{s:11:"LC_MESSAGES";a:1:{s:7:"default";a:0:{}}} > > > > > ---- --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---
