Simon Toulson Registered Users
 Nuke Newbie Posts:2

 |
| 9/13/2005 2:20 PM |
|
I've just translated NewsArticles into Spanish (and will post the files when it's a little more polished). There were a couple of minor problems which I'll post, but I just have to vent about templates - yaaa! We finally have a great framework in DNN 3.0 which supports localization. And while the excellent NewsArticles supports this, templates blow it away with it's use of non-localizable text.
With new modules around for language selection and dynamic content there are going to be more sites out there that want to switch languages within the portal.
I know I can create a template for each language, but now News Articles is the only part of my site that doesn't change when the user's language does and, short of creating a portal per language, I don't see a way round it.
It's not going to stop me using the module and templates are a great extension, but it just doesn't look good on the site. |
|
|
|
|
Scott McCulloch Administrators
 Nuke Master Posts:12450


 |
| 9/13/2005 5:17 PM |
|
Posted By caroche on 9/13/2005 2:20:17 PM
I've just translated NewsArticles into Spanish (and will post the files when it's a little more polished). There were a couple of minor problems which I'll post, but I just have to vent about templates - yaaa! We finally have a great framework in DNN 3.0 which supports localization. And while the excellent NewsArticles supports this, templates blow it away with it's use of non-localizable text.
With new modules around for language selection and dynamic content there are going to be more sites out there that want to switch languages within the portal.
I know I can create a template for each language, but now News Articles is the only part of my site that doesn't change when the user's language does and, short of creating a portal per language, I don't see a way round it.
It's not going to stop me using the module and templates are a great extension, but it just doesn't look good on the site.
Thanks for the suggestions. What would work best in your scenario,
Templates with a different locale? e.g. default_DE-de
OR
Tokens in the same template [LOCALIZED-STRINGNAMEINLOCALEFILEHERE] |
|
Scott McCulloch Site Administrator |
|
|
Philipp Becker Gold Membership
 Nuke Wiz Posts:146


 |
| 9/14/2005 2:01 AM |
|
I have published an article that describes the necessary steps to use almost transparent content localization with News Articles. The site is actually using this setup.
Read it here |
|
Cheers, Philipp
 |
|
|
Dax Davis Gold Membership
 Nuke Master Posts:328


 |
| 9/14/2005 7:37 AM |
|
Whatever you do, don't get rid of templates!!! I would think you
would extend the tokens with a language identfier="text" type
approach. Treat them as attributes, and the first is the
default. Just an idea.
Dax
|
|
|
|
|
Simon Toulson Registered Users
 Nuke Newbie Posts:2

 |
| 9/14/2005 8:11 AM |
|
Phillipp, I've checked out your site and it looks like a good solution. I use Erik's modules as well and I just hadn't realised the potential of hiding pages. I'm going to use this approach on my site!
In answer to the template localization approach - my vote would be for Tokens. I assume that the strings could then be translated using the language options within DNN - all in one place. |
|
|
|
|
Scott McCulloch Administrators
 Nuke Master Posts:12450


 |
| 9/14/2005 4:24 PM |
|
Posted By dax on 9/14/2005 7:37:14 AM Whatever you do, don't get rid of templates!!! I would think you would extend the tokens with a language identfier="text" type approach. Treat them as attributes, and the first is the default. Just an idea.
Dax
I don't think it's the existing tokens that are the problem, it's the bits of text that go around them e.g.
Pages: [PAGECOUNT]
"Pages" would need to be localized, so something like this:-
[LOCALIZED-PAGES]
This would look in the resx file (that would be attached to the template) for the key "pages" and extract its value |
|
Scott McCulloch Site Administrator |
|
|
Philipp Becker Gold Membership
 Nuke Wiz Posts:146


 |
| 9/16/2005 1:16 AM |
|
I have to admit that I never really understood the new concept of using templates in so many modules these days...
Dnn comes with localization and this not only gives great flexibility for static content but also for use as templates. Scott, your example shows a (in my opinion) quite expensive track to take:
- Look for the string in the template
- Replace Article tokens
- Look for localized strings
- Replace them via GetString with values from the resource files
So why not simply use ONLY resource files? You could skip the whole template thing by keeping the functionality PLUS adding an easy way of localizing the templates.
My 2 cents. |
|
Cheers, Philipp
 |
|
|
Scott McCulloch Administrators
 Nuke Master Posts:12450


 |
| 9/16/2005 4:02 AM |
|
Posted By proeder on 9/16/2005 1:16:48 AM
I have to admit that I never really understood the new concept of using templates in so many modules these days...
Dnn comes with localization and this not only gives great flexibility for static content but also for use as templates. Scott, your example shows a (in my opinion) quite expensive track to take:
- Look for the string in the template
- Replace Article tokens
- Look for localized strings
- Replace them via GetString with values from the resource files
So why not simply use ONLY resource files? You could skip the whole template thing by keeping the functionality PLUS adding an easy way of localizing the templates.
My 2 cents.
Templates are there for free form layout, how would you do it otherwise? |
|
Scott McCulloch Site Administrator |
|
|
Scott McCulloch Administrators
 Nuke Master Posts:12450


 |
| 9/16/2005 4:04 AM |
|
Posted By smcculloch on 9/16/2005 4:02:57 AM
Posted By proeder on 9/16/2005 1:16:48 AM
I have to admit that I never really understood the new concept of using templates in so many modules these days...
Dnn comes with localization and this not only gives great flexibility for static content but also for use as templates. Scott, your example shows a (in my opinion) quite expensive track to take:
- Look for the string in the template
- Replace Article tokens
- Look for localized strings
- Replace them via GetString with values from the resource files
So why not simply use ONLY resource files? You could skip the whole template thing by keeping the functionality PLUS adding an easy way of localizing the templates.
My 2 cents.
Sorry, had to edit this post, i'm not sure what you mean by only using resource files?
|
|
Scott McCulloch Site Administrator |
|
|
Philipp Becker Gold Membership
 Nuke Wiz Posts:146


 |
| 9/18/2005 8:45 AM |
|
Well, if you have look at the GetSystemMessage method, that is used to e.g. send email notifications in dnn, it does exactly what is being done with templating systems. The difference is that the text string where tokens are being replaced comes from a localization resource file.
The advantage is that this way templates can be modified with the language editor of the portal. |
|
Cheers, Philipp
 |
|
|
caroig Gold Membership
 Nuke Master Posts:278

 |
| 9/29/2005 12:54 AM |
|
| I guess that the solution for the main news article templates can be applied to the Latest Article Templates and the email templates, both of which currently can't be translated - or rather won't support mutiple languages. |
|
|
|
|
caroig Gold Membership
 Nuke Master Posts:278

 |
| 9/11/2006 12:12 PM |
|
Hi, Another year, another subscription, another multi-language site to build. Some great new features for sure but still those annoying little unlocalizable texts in templates. 
|
|
|
|
|
Scott McCulloch Administrators
 Nuke Master Posts:12450


 |
| 9/12/2006 4:40 PM |
|
I agree, if you localize templates based on locale, you probably need to create articles in different locales too.
I think probably the best solution would be to have templates that are designed for a specific locale. e.g. /Templates/Default/en-AU/.....
Is this what you are after? |
|
Scott McCulloch Site Administrator |
|
|
caroig Gold Membership
 Nuke Master Posts:278

 |
| 9/13/2006 12:21 AM |
|
It would great to have locale specific articles - that would be the icing on the cake For now I'd just like to have a consitent framework based on my Users selected locale - it just looks tatty for a Spanish user to see bits of English dabbed around the screen or vice-versa.
Locale specific templates would do the job - all the flexibility of templates is retained. Would Latest Articles get a template as well? |
|
|
|
|
Scott McCulloch Administrators
 Nuke Master Posts:12450


 |
| 9/13/2006 1:40 AM |
|
| Would a token like [RESX:XXX] that would retrieve a value from the shared resource file of a module? Would that do in the meantime? |
|
Scott McCulloch Site Administrator |
|
|
caroig Gold Membership
 Nuke Master Posts:278

 |
| 9/13/2006 1:47 AM |
|
| That would work - Can it also be used in the XML - for tooltip for example? |
|
|
|
|