[ 
https://issues.apache.org/jira/browse/TAPESTRY-1532?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12501728
 ] 

Hugo Palma commented on TAPESTRY-1532:
--------------------------------------

That approach would require for the application to be configure to just support 
the en and pt locales.
That actually is my use case, so yes, creating Home.html and Home_pt.html would 
be an option. As it would be Home_en.html and Home.html.

Still none of these seems as intuitive as Home_pt.html and Home_en.html. I find 
it much clearer from the developer point of view what the expected behaviour 
behaviour is if i have two _pt and _en templates.

Also, it's only in template localization that it's required to have a file 
without explicit locale. All other ways of localizing your application(messages 
and assets) don't require this. You can just have Home_pt.properties and 
Home_en.properties.
In my opinion the behaviour should be uniform for all forms of localization.

> Shouldn't have to create a specification to use localized templates
> -------------------------------------------------------------------
>
>                 Key: TAPESTRY-1532
>                 URL: https://issues.apache.org/jira/browse/TAPESTRY-1532
>             Project: Tapestry
>          Issue Type: Improvement
>          Components: Framework
>    Affects Versions: 4.1.2
>            Reporter: Hugo Palma
>            Priority: Minor
>
> Use case:
> I want to provide an english and portuguese version of my Home page. I'm 
> using annotation so i don't want/need a page spec. I have two options:
> - Create three templates, Home.html, Home_pt.html and Home_en.html.
> - Create an empty Home.page spec.
> None of these is the ideal solution. I should be able to just create the 
> Home_pt.html and Home_en.html files.
> My guess is that PageSpecificationResolverImpl doesn't take localization into 
> account when resolving to a page.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to