[symfony-users] Re: I18n in forms messages
You could set the messages on the view side in your template, e.g.: ?php $WidgetSchema = $Form-getWidgetSchema(); ? ?php $ValidatorSchema = $Form-getValidatorSchema(); ? ?php $WidgetSchema-setHelps(array('my_widget' = __('My widget help'))); ? ?php $WidgetSchema-setLabels(array('my_widget' = __('My widget label'))); ? ?php $ValidatorSchema['my_widget']-setMessages(array('required' = __ ('My widget required'))); ? Does that work for you? This can also be usefull in projects where you would like to override the form messages of a plugin form without overridding the messages and labels in the form itself or the controller. Kind regards, Marijn On Mar 6, 11:31 pm, boozee booze...@gmail.com wrote: Well, as it is being done in the forms system, I don't really use the __ method like you wrote, as it happens automatically. So I can't do what you wrote. But it's a creative idea, thanx. Anything else I can do ? suggestions ? On Mar 6, 3:06 am, jukea jkea...@gmail.com wrote: oops, typo error . What I meant was : maybe you could try this : __('Blbalba %parameter%',__($columnName)); instead of this : __('Blabla %parameter%', $columnName); --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -~--~~~~--~~--~--~---
[symfony-users] Re: I18n in forms messages
Well, as it is being done in the forms system, I don't really use the __ method like you wrote, as it happens automatically. So I can't do what you wrote. But it's a creative idea, thanx. Anything else I can do ? suggestions ? On Mar 6, 3:06 am, jukea jkea...@gmail.com wrote: oops, typo error . What I meant was : maybe you could try this : __('Blbalba %parameter%',__($columnName)); instead of this : __('Blabla %parameter%', $columnName); --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -~--~~~~--~~--~--~---
[symfony-users] Re: I18n in forms messages
anyone? please ? On Mar 5, 2:44 am, boozee booze...@gmail.com wrote: Hello, I have made a section in my messages.he.xml to translate the An object with the same %column% already exist. message, to my local language. However, while most of the sentence was translated fine, the content of %column% - the name of the column (username for example) - wasn't translated, and was kept in the english language, even though I have a section for username (and Username as well) in the messages.he.xml file. Am I missing something ? Can someone help ? Thanx --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -~--~~~~--~~--~--~---
[symfony-users] Re: I18n in forms messages
just an idea here .. maybe you could try this : __('Blbalba %parameter%',__($columnName)); instead of this : __('Blabla $parameter%', %columnName); On Mar 5, 6:04 pm, boozee booze...@gmail.com wrote: anyone? please ? On Mar 5, 2:44 am, boozee booze...@gmail.com wrote: Hello, I have made a section in my messages.he.xml to translate the An object with the same %column% already exist. message, to my local language. However, while most of the sentence was translated fine, the content of %column% - the name of the column (username for example) - wasn't translated, and was kept in the english language, even though I have a section for username (and Username as well) in the messages.he.xml file. Am I missing something ? Can someone help ? Thanx --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -~--~~~~--~~--~--~---
[symfony-users] Re: I18n in forms messages
oops, typo error . What I meant was : maybe you could try this : __('Blbalba %parameter%',__($columnName)); instead of this : __('Blabla %parameter%', $columnName); --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups symfony users group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en -~--~~~~--~~--~--~---