Including page settings when creating a translation request - translation

I'm currently running a Kentico 9 instance to support a large website that is available in multiple languages. I'm leveraging the built-in Translation and Translation Services modules to send content to our translators.
When I create a submission ticket for a new item to translate and look at the XLF that gets generated, there are <trans-unit> elements for all page type fields marked as translatable as well as one for the DocumentName field. These fields then get translated by our vendor and re-imported into the CMS.
My question is, can I include other document system fields in this XLF?
Specifically I'm looking to include the DocumentPageTitle, DocumentPageKeyWords, and DocumentTags fields.

I think it's impossible to do via the built-in Translation service because these fields are marked as without translation. Example, for DocumentPageTitle:

Related

Locale based information on International site

We're building an education platform. The site it's going to be published in different countries, having each country its own subfolder. For example,
France: http://myedusite.com/fr/
Spain: http://myedusite.com/es/
The site has courses belonging to providers
courses have different themes (Arts, Business, Science) and these themes have sub-themes (I'm planning to use ancestry to have a tree structure model)
Courses
providers can create courses if they have an account. The courses created will be published only in the domain they were created.
As an example, if I'm a course's provider and I create an account in http://myedusite.com/fr/, then the courses I create should only be published in http://myedusite.com/fr/.
For this purpose, I thought of defining a Country model with the field iso_3166. This field would be populated with the country codes defined in ISO 3166.
Then, the courses would have a target_country (class: Country), enabling the possibility of choosing where the course is published (if the course's target_country is France it should only be visible in http://myedusite.com/fr/).
Themes
For themes happens something similar, where for each country where the site exists there can be different themes. When a user arrives to http://myedusite.com/xx/, only themes existing in country "xx" will be shown. That implies that each theme should belong to a country.
On the other hand, each course would have one theme.
For dealing with country related information (for example loading cities for a country) I thought of using the country gem.
From the business perspective, we have chosen a bottom-top approach, meaning that only the necessary things are built now, adding features as it's needed.
I see this as a reasonable strategy to make the site international. What I'm afraid of is of choosing wrong and having trouble on the future as new features arrive. I would like to have as much flexibility as possible.
It's the first time I design an international project. Is the approach I've thought of something usual in this kind of sites? Anything I should pay attention to that I didn't mention?
I use navigator.language to get the locale and redirect from JS to whatever URL I want, or add it as a query string. In your case since you only want the language you should split it first, then redirect. In my case I use the full locale code because en is different from AU, US, CA, GB and so on, you'd probably want to consider doing the same especially if you will be displaying prices, dates and so on.
I think there is a way to get this with Rails too, see the Accept-language, accept charset headers.
Once you pass the language/locale to your controller you can then filter data as required.
This also leaves room for some nice SEO tricks if you set up a custom 404 page, engines will go for this.

Rails newbie - how to structure a calendar generating app

I'm working on a service to provide our students and faculty with one single calendar (ICS subscription) of their academic dates (start and end of term & exam periods, class dates and times, exam dates and times, etc). I'm a Ruby and Rails newbie; we're starting to work more with it here so I figured this would be a good learning opportunity. I'm having trouble figuring out how to structure and model (if at all) certain parts of the app.
The app is conceptually pretty basic:
User logs in and a user record is created for them. A UUID is generated and stored on the user's record; it's used to generate their ICS URL (http://myservice.foo/feeds/johndoe_ce4970706f320130588b109add5c7cb0.ics).
When the user requests their ICS file (through the above URL), I need to query a bunch of different systems in order to get information in order to build a calendar:
The Student Information System (SIS) contains the user's schedule (e.g. johndoe is taking ENGL 100 on MWF from 10:30 - 11:20). I need to parse this data and create events.
Our online learning management system, Canvas, provides a calendar of assignments for courses contained inside it. It's accessible as an ICS file, so I need to pull down that file, parse it and include it in the "master" calendar that my app will generate.
Instructors can specify an additional ICS URL for their course so that they can include arbitrary events not provided by either of the two above sources. Like the Canvas calendar, I need to download and parse that ICS.
I have the first part working; I can log in through our single sign-on system (CAS) and a user record is created with a generated UUID. I'm not sure how to handle the second part, though. I don't need to store much permanent data; basically, I only need to keep around the user record (which contains their username, the generated UUID, and some access tokens for the Canvas LMS). The feed will be generated the first time it's requested, cached for some period (and regenerated on-demand when needed).
Where should I be putting the parsing and generating code? I'd like it to be somewhat modular as I expect that we'd be adding other data sources as they crop up. Should I be creating calendar and event models if I'm not actually persisting that data?
No, there is no need to create an empty model for interaction with 3rd party services. I had a similar problem, where I needed to receive data from an external service and wanted it to be modular. One of recommended solutions I found was to create a class (that handles business logic of the interaction with the external service) in the "lib" folder under the root directory of your rails project.
It later can be required in your controller and used to receive date from the third party service. Or if you want it autoloaded, then you can add path to lib directory in your application.rb file under config.autoload_paths setting.

Best way to save localized static content

I am creating an application to have administrators enter the a localized static content of a page.
For ex. nowadays the "About Us" content is English, I would like an admin to be able to enter the same "About Us" content in Russian.
How should I store the localized content?
I'm thinking that the admin won't be able to edit the YAML files for each language.
i thought storing all the data in a table and have a reference language id to it stored in a cookie.
Having a call to the locale cookie each time a view loads checking out which language I am using, comparing it to the database and then calling the specific row where language = en/ru/whatever.
any better way?
Nowadays, you can simply put index.fr.html.erb and index.en.html.erb in the same folder and rails will do the rest.
odin is right, I do mean storing multiple versions of pages in different languages,
I thought I could just leave it in YAML and in-place edit it and I stumbled across this -
http://asciicasts.com/episodes/256-i18n-backends
We change the i18n backend to Key-Value backend (Hash) but then it would mean that each restart of the webserver the hash will be lost and thus the article suggests using Redis another key-value storage which calls itself
Redis is an open source, advanced key-value store. It is often referred to as a data structure server since keys can contain strings, hashes, lists, sets and sorted sets.
It seems fairly clever saving it like this, because I still use the Rails l18n, meaning I can route everything fairly easily, but I am enabling the user to edit the content for each locale.

Storing formatted text in Resource File .Is it Possible?

Building an asp.net mvc website that has to be multilingual and wondering if it's possible to store formatted text in a resource file and whether it makes sense.
Lots of pages are static and user can edit them and add their own formatting "Bold,italics etc.."
and was wondering what is the best way to approach it.
I dont want to create one page x language and storing in the database involves creating a structure to handle the same info in multiple languages.Seems hard to maintain.
Have you done it before? How did you do it
any suggestions
Thanks a lot
Is it possible?
Certainly.
Does it make sense?
It depends. I would not recommend resource files (via ResourceWriter) for storing dynamic content.
Your problem
Let me rephrase it (I am not sure if I understood you correctly). You want to give your users an ability to change presentation style. User will be able to change the style and that change would be somehow propagated to whatever languages the content is translated to.
In such case, I see some issues:
How to match English contents with translated one?
It is typical for translation to have different order and possibly different number of sentences. There is no way to match them unless...
Storing such information in resource files along with translatable strings would result in something that is hard to maintain. I believe you would need to either add formatting tags or content tags with styling information in order to achieve that. The result would be a mess; hardly readable, as tough to modify.
OK, so what can you do? Actually, what I could recommend is to create Customization Mechanism for CSS files. In your case you need:
Provide CSS classes as well as unique identifiers (HTML id attribute) to each structural elements (tags if you prefer), so that you have something like <div id="main" class="main"><p id="p1" class="normal">.... The id's will give users an ability to target precisely that element leaving others untouched (via #p1.normal { // definition here }).
Store CSS in the Database and create some editor for users.
Create a Handler to serve CSS from database upon web browser's request.
Even with such solution you won't avoid some problems. One is that you need to actually alter font family while translating into certain languages, so you might need language-based CSS files. Another problem pops up when user wants to put bold attribute on certain word - with such solution this is not possible (but to be honest if you want to allow that, this won't be i18n friendly for the reasons I mentioned earlier).
BTW. Bold fonts should be avoided for some languages. For example Chinese characters are pretty hard to read if you manage to output them with bold font.
If your users can post in multiple languages - its probably best to use a database to store the info and accompanying formatting. If it is for labels and other static text on the website - the resource files are a good solution. The resource files store the content as strings - but storing formatted text in there breaks the 'seperate the presentation from the logic' idealogy.

Prestashop Translation

I have imported some other languages to my shop. When I change the language, all the fields are changed (items, categories, etc...) but products (name, description) and categories are in English.
I understand these language will not change but I also want those languages to be changed. How can I do that?
you need to change them manually
when you create new language, you'll see its flag next to the input fields, just click it and you can enter the text in that language you select
Prestashop (1.4) comes in 5 languages, and you can get language packs for many other languages (some more complete than others), that were contributed by members.
However, Prestashop will not automatically translate anything that you manually added to your shop (IE Categories, Products, CMS pages, Modules, etc..), you can either manually enter the translations, or you can use a module to automatically translate those using google translate.
You can see an example of a module that does automatic translation at http://www.presto-changeo.com/en/prestashop-modules/19-website-translator.html
Yes, you have to translate them manually. The packs are only available for default products.
You also can install a module to translate it automatically (probably utilizing Google Translate). But if you are selling, I don't think you should do that. As the automatic translation sometimes sounds funny. IT HURTS YOUR PROSPECT CUSTOMERS and you are loosing sale.

Resources