Re: Internationalization in Django 1.4 doesn't seem to work
On Sat, 2012-06-02 at 02:58 -0700, Houmie wrote: > The good news is the problem is solved. A friendly chap in > stackoverflow > actually bothered to look into it. > > The problem is as simple as the translation files couldn't be found. > For > some odd reason the important information about how Django locates > them is > at the very last section of the documentation. It is really easy to > miss. > > All you have to do is to move the locale directory with the > translation > files into your Application directory. Thats it !!! it may have solved your problem. But actually nowadays django looks into settings.LOCALE_PATHS - could you check whether the svn revision number you are using is less than 17860 or greater. -- regards Kenneth Gonsalves -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Re: Internationalization in Django 1.4 doesn't seem to work
> > Hi Kenneth, The good news is the problem is solved. A friendly chap in stackoverflow actually bothered to look into it. The problem is as simple as the translation files couldn't be found. For some odd reason the important information about how Django locates them is at the very last section of the documentation. It is really easy to miss. All you have to do is to move the locale directory with the translation files into your Application directory. Thats it !!! If you need to recreate the translation files you need top use the terminal, browse to the Application directory and run your command 'django-admin.py makemessages -l de' from there. You can't do this from Aptana Studio 3.0, since it requires you to run any Django command from the root rather than from application directory. Hence you need to do it in the terminal. Just download my test app and try what I just said here, as I intend to remove the test project within the next few days. Regards, Houman -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion on the web visit https://groups.google.com/d/msg/django-users/-/RpGtuMns31oJ. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Re: Internationalization in Django 1.4 doesn't seem to work
On Fri, 2012-06-01 at 10:58 -0700, Houmie wrote: > I would really appreciate it if somebody could help me with this. > Working on this since this morning and am totally stuck.. > > could you try with revision 17860 and see if it works. I have the same problem, and am stuck with 17860 - unfortunately I have been unable to replicate the problem with a simple example. -- regards Kenneth Gonsalves -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Re: Internationalization in Django 1.4 doesn't seem to work
Guys, I have created a new simple test project to demonstrate the problem. It is a very simple project and you can switch between German & English at main page. You see the selected Language code actually changes, which is a good sign but the translation simply doesn't happen. I wonder if this is a bug that needs reported. Your cooperation is highly appreciated. Please download from here: http://www.chasebot.com/TestProject.zip Please let me know if you can reproduce it. Many Thanks, Houman -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion on the web visit https://groups.google.com/d/msg/django-users/-/_KRPZ3R2PlMJ. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Re: Internationalization in Django 1.4 doesn't seem to work
Hi Ivan, Thank you for your help. I have already lazy translation implemented for the forms like this: from django.utils.translation import ugettext_lazy as _ class FriendInviteForm(forms.Form): name = forms.CharField(label=_("Friend's Name")) email = forms.EmailField(label= _("Friend's Email")) Surely at least the form should then change the words according to the drop down settings. But still no luck. Its really hard to get this working. Do you have any simple working example for me by any chance? So I could compare line by line? :) On Jun 1, 8:49 pm, Iván Raskovskywrote: > Besides changing the language per request as you've been indicated in > SO you might want to look at lazy > translations:https://docs.djangoproject.com/en/dev/topics/i18n/translation/#lazy-t... > > Regards, > Iván > > > > > > > > On Fri, Jun 1, 2012 at 2:58 PM, Houmie wrote: > > Hey everyone, > > > I would really appreciate it if somebody could help me with this. > > Working on this since this morning and am totally stuck.. > > > I have posted it with proper formatting on stack overflow. > > >http://stackoverflow.com/questions/10854330/internationalization-in-d... > > > Thank you very much, > > Houman > > > -- > > You received this message because you are subscribed to the Google Groups > > "Django users" group. > > To post to this group, send email to django-users@googlegroups.com. > > To unsubscribe from this group, send email to > > django-users+unsubscr...@googlegroups.com. > > For more options, visit this group > > athttp://groups.google.com/group/django-users?hl=en. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Re: Internationalization in Django 1.4 doesn't seem to work
Besides changing the language per request as you've been indicated in SO you might want to look at lazy translations: https://docs.djangoproject.com/en/dev/topics/i18n/translation/#lazy-translation Regards, Iván On Fri, Jun 1, 2012 at 2:58 PM, Houmiewrote: > Hey everyone, > > I would really appreciate it if somebody could help me with this. > Working on this since this morning and am totally stuck.. > > I have posted it with proper formatting on stack overflow. > > http://stackoverflow.com/questions/10854330/internationalization-in-django-doesnt-get-activated > > Thank you very much, > Houman > > -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To post to this group, send email to django-users@googlegroups.com. > To unsubscribe from this group, send email to > django-users+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/django-users?hl=en. > -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.