You are viewing a plain text version of this content. The canonical link for it is here.
Posted to l10n@openoffice.apache.org by Rob Weir <ro...@apache.org> on 2013/08/23 17:58:04 UTC

Brainstorming: Can we refactor the website to make translation easier?

(Responses to dev@openoffice.apache.org, please)

Obviously our website is quite large.  Google reports 21207 pages
indexed in the www subdomain, and a further 48075 pages in the wiki
subdomain.   But for purpose of this post, when I talk about the "home
page" I'm talking about the contents of our main index.html and the
most commonly visited pages directly linked to it, e.g., the
why/download/product/get-involved, etc. pages.

This core homepage content amounts to around 25 pages.

Today this content is scattered around the content tree.  Some of it
is in the root.  Some of it in /why and /download directories.  Some
of it is template-related and is in /templates rather than in
/content.

As a test I tried to create my own NL page, in the fictitious "xx"
locale.  You can see it here:  http://www.openoffice.org/xx/

It is not working correctly, but it already required a lot of
non-trivial hacking:

1) I had to hunt around and guess which files to copy.  Do I copy
scripts, images and CSS, or just content pages?   Some of the
directories had out-dated content that was not linked to my anyone.
It was hard to figure out what the minimum amount of content needed
was, and where it was located.

2) The main index.html file had to be edited to refer to CSS in the
root, rather than current directory

3)  Download page is missed up, missing CSS and/or scripts.
Presumably I need to copy something into the xx/download dir, or edit
scripts to make them refer /download off the root.

4) The /xx/why pages are not showing the right side navigation now.  I
must have missed something there as well.

Of course, I could figure the above out eventually.  It just requires
some time and effort and trial and error.  But none of this is
documented, and even if it were this is a fragile approach and
probably beyond th web development skills of a typical translator.

But we do know this has been done for some languages.  They got it to
work.  The German page is a good example:

http://www.openoffice.org/de/

Now this looks good, but it is still a messy thing from a maintenance
perspective.  If we make structural changes to the main English page,
then those changes need to be manually merged into to every NL page.

What can we do to improve this?

Here's my idea:

1) What if we refactored the home page so it was all self-contained
into these directories:   /scripts,  /styles,  /images and /en/?

2) Make the /en directory be pure content.  Only the stuff that needs
to be translated.  It loads everything else, scripts, images, etc.,
via URLs relative to the root, e.g.., in /scripts, /styles, etc.

3) Reduce or eliminate any embedded Javascript within pages.  For
example, refactor the code in download/index.html so it is external
and depends on JSON resource files for translated strings.  Aim so
translators never need to touch script.

4) Ultimate goal is for someone to be able to jump start a new NL home
page by simply requesting an svn copy of the /en directory, and then
editing the resulting files.  No one should ever need to do what I'm
doing with the "xx" pages.

5) Maintenance is far easier.  Most things like changing the scripts,
is done in one place only.  But even changes to the HTML are easier.
Since we then have a common branch point via the svn copy, when
structural changes are added to the main /en HTML, these can be merged
in more elegantly to the translated versions, using Subversion.

6) Via Apache redirects we can ensure that the default call to
www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
detection and send requests automatically to the appropriate NL home
page.

A variation on the above would be to use Pootle, rather than svn
copy/merge to maintain the translations.  But that would require the
same refactoring work to enable it.  And it would require further
investigation to identify a way of extracting and merging translation
strings in MDText files as well as (X)HTML files.

This is obviously more than a one-person task.  So I'd be interested
in hearing what you think in general about this approach, whether
there is a simpler alternative I've missed, and whether this is
something you'd be interested in helping with.

Regards,

-Rob

---------------------------------------------------------------------
To unsubscribe, e-mail: l10n-unsubscribe@openoffice.apache.org
For additional commands, e-mail: l10n-help@openoffice.apache.org


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by Rob Weir <ro...@apache.org>.
On Fri, Aug 23, 2013 at 3:17 PM, Marcus (OOo) <ma...@wtnet.de> wrote:
> Am 08/23/2013 05:58 PM, schrieb Rob Weir:
>
>> (Responses to dev@openoffice.apache.org, please)
>>
>> Obviously our website is quite large.  Google reports 21207 pages
>> indexed in the www subdomain, and a further 48075 pages in the wiki
>> subdomain.   But for purpose of this post, when I talk about the "home
>> page" I'm talking about the contents of our main index.html and the
>> most commonly visited pages directly linked to it, e.g., the
>> why/download/product/get-involved, etc. pages.
>>
>> This core homepage content amounts to around 25 pages.
>>
>> Today this content is scattered around the content tree.  Some of it
>> is in the root.  Some of it in /why and /download directories.  Some
>> of it is template-related and is in /templates rather than in
>> /content.
>>
>> As a test I tried to create my own NL page, in the fictitious "xx"
>> locale.  You can see it here:  http://www.openoffice.org/xx/
>>
>> It is not working correctly, but it already required a lot of
>> non-trivial hacking:
>>
>> 1) I had to hunt around and guess which files to copy.  Do I copy
>> scripts, images and CSS, or just content pages?   Some of the
>> directories had out-dated content that was not linked to my anyone.
>> It was hard to figure out what the minimum amount of content needed
>> was, and where it was located.
>>
>> 2) The main index.html file had to be edited to refer to CSS in the
>> root, rather than current directory
>>
>> 3)  Download page is missed up, missing CSS and/or scripts.
>> Presumably I need to copy something into the xx/download dir, or edit
>> scripts to make them refer /download off the root.
>>
>> 4) The /xx/why pages are not showing the right side navigation now.  I
>> must have missed something there as well.
>>
>> Of course, I could figure the above out eventually.  It just requires
>> some time and effort and trial and error.  But none of this is
>> documented, and even if it were this is a fragile approach and
>> probably beyond th web development skills of a typical translator.
>>
>> But we do know this has been done for some languages.  They got it to
>> work.  The German page is a good example:
>>
>> http://www.openoffice.org/de/
>>
>> Now this looks good, but it is still a messy thing from a maintenance
>> perspective.  If we make structural changes to the main English page,
>> then those changes need to be manually merged into to every NL page.
>>
>> What can we do to improve this?
>>
>> Here's my idea:
>>
>> 1) What if we refactored the home page so it was all self-contained
>> into these directories:   /scripts,  /styles,  /images and /en/?
>
>
> Do you mean to centralize all kind of files that are shared? Like button
> pics, download scripting, color definitions?
>

All the stuff that does not need language translation should be
shared.  We're doing that in some cases.  But our HTML pages are not
doing this right.

An easy example:

Our root index.html page uses external CSS files.  Good.  That's what
we should be doing.  But the HTML file refers to them as:

@import "home.css";
@import "styles.css";
@import "exceptions.css";

But this breaks when we copy index.html into a new subdirectory.   It
needs to then be something like:

@import url("../home.css");
@import url("../styles.css");
@import url("../exceptions.css");

or maybe:

@import url("http://www.openoffice.org/styles/home.css");
@import url("http://www.openoffice.org/styles/styles.css");
@import url("http://www.openoffice.org/styles/exceptions.css");

So the task is really two things:

1) centralize the non-language resources

2) Change the HTML so it loads from the canonical locations rather
than assuming these files are in the same directory.

> I thought about this already for the download area as then these files are
> all in a single location. But of course it's also possible to do this for
> the entire wesite.
>
>
>> 2) Make the /en directory be pure content.  Only the stuff that needs
>> to be translated.  It loads everything else, scripts, images, etc.,
>> via URLs relative to the root, e.g.., in /scripts, /styles, etc.
>
>
> Should the "en/" folder have another purpose than just to work as a big
> template?
>

I was thinking the en/ folder would be what we redirect
http://www.openoffice.org to show by default.  So it would be the real
live home page.

>
>> 3) Reduce or eliminate any embedded Javascript within pages.  For
>> example, refactor the code in download/index.html so it is external
>> and depends on JSON resource files for translated strings.  Aim so
>> translators never need to touch script.
>
>
> At least for the download webpage I thought, too, already to separate code
> and text because it makes it easier for other people to use the design of
> the main download webapge for their language.
>
> I've not yet committed anything but the idea is to separate a) HTML design,
> b) JS code and c) translate-able text strings from each other.
>
> However, I put already a Todo note into the Wiki (see the 2nd row from top):
>
> https://cwiki.apache.org/confluence/display/OOOUSERS/Improvements+for+the+download+webpages#Improvementsforthedownloadwebpages-ImmediateConcerns%2CShort%2FMidTermImprovements
>

The /download page is the hard one.  There is a lot going on there.

>
>> 4) Ultimate goal is for someone to be able to jump start a new NL home
>> page by simply requesting an svn copy of the /en directory, and then
>> editing the resulting files.  No one should ever need to do what I'm
>> doing with the "xx" pages.
>
>
> Yeah, indeed a hugh work to get to this dream.
>
>
>> 5) Maintenance is far easier.  Most things like changing the scripts,
>> is done in one place only.  But even changes to the HTML are easier.
>> Since we then have a common branch point via the svn copy, when
>> structural changes are added to the main /en HTML, these can be merged
>> in more elegantly to the translated versions, using Subversion.
>>
>> 6) Via Apache redirects we can ensure that the default call to
>> www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
>> detection and send requests automatically to the appropriate NL home
>> page.
>>
>> A variation on the above would be to use Pootle, rather than svn
>> copy/merge to maintain the translations.  But that would require the
>> same refactoring work to enable it.  And it would require further
>> investigation to identify a way of extracting and merging translation
>> strings in MDText files as well as (X)HTML files.
>>
>> This is obviously more than a one-person task.  So I'd be interested
>> in hearing what you think in general about this approach, whether
>> there is a simpler alternative I've missed, and whether this is
>> something you'd be interested in helping with.
>
>
> I think it's no secret when I tell you that this is a great idea from the
> view point of maintenance and to attrack new volunteers for not yet known
> and supported languages.
>
> However, I'm really wondering if this will be a success as it would mean
> nothing less than a complete rebuild of all files on the entire website.
>
> I believe it's better to split this up into some chunks. What's the most
> interesting ansd important part of our website? Start with this, build up
> some skills, knowledge and best pratices and then enroll it more and more
> over the remaining parts - and hopefully with more volunteers. ;-)
>

Take a look at what I put in "xx" directory:

https://svn.apache.org/repos/asf/openoffice/ooo-site/trunk/content/xx/

It is just the root index.html page, the download page and a handful
of others.  I think it is 25 pages total.  There might be others we
want to translate as well, but I think we can keep it to a reasonable
size.  At some point, 3 or 4 levels deep in hyperlinks, the user will
end up in an English language page.  But for the most-commonly used
pages, the ones that are 2 and 3 links from the home page, I think it
is a reasonable goal to translate those.

Regards,

-Rob


> My 2 ct.
>
> Marcus
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: l10n-unsubscribe@openoffice.apache.org
> For additional commands, e-mail: l10n-help@openoffice.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: l10n-unsubscribe@openoffice.apache.org
For additional commands, e-mail: l10n-help@openoffice.apache.org


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by "Marcus (OOo)" <ma...@wtnet.de>.
Am 08/23/2013 05:58 PM, schrieb Rob Weir:
> (Responses to dev@openoffice.apache.org, please)
>
> Obviously our website is quite large.  Google reports 21207 pages
> indexed in the www subdomain, and a further 48075 pages in the wiki
> subdomain.   But for purpose of this post, when I talk about the "home
> page" I'm talking about the contents of our main index.html and the
> most commonly visited pages directly linked to it, e.g., the
> why/download/product/get-involved, etc. pages.
>
> This core homepage content amounts to around 25 pages.
>
> Today this content is scattered around the content tree.  Some of it
> is in the root.  Some of it in /why and /download directories.  Some
> of it is template-related and is in /templates rather than in
> /content.
>
> As a test I tried to create my own NL page, in the fictitious "xx"
> locale.  You can see it here:  http://www.openoffice.org/xx/
>
> It is not working correctly, but it already required a lot of
> non-trivial hacking:
>
> 1) I had to hunt around and guess which files to copy.  Do I copy
> scripts, images and CSS, or just content pages?   Some of the
> directories had out-dated content that was not linked to my anyone.
> It was hard to figure out what the minimum amount of content needed
> was, and where it was located.
>
> 2) The main index.html file had to be edited to refer to CSS in the
> root, rather than current directory
>
> 3)  Download page is missed up, missing CSS and/or scripts.
> Presumably I need to copy something into the xx/download dir, or edit
> scripts to make them refer /download off the root.
>
> 4) The /xx/why pages are not showing the right side navigation now.  I
> must have missed something there as well.
>
> Of course, I could figure the above out eventually.  It just requires
> some time and effort and trial and error.  But none of this is
> documented, and even if it were this is a fragile approach and
> probably beyond th web development skills of a typical translator.
>
> But we do know this has been done for some languages.  They got it to
> work.  The German page is a good example:
>
> http://www.openoffice.org/de/
>
> Now this looks good, but it is still a messy thing from a maintenance
> perspective.  If we make structural changes to the main English page,
> then those changes need to be manually merged into to every NL page.
>
> What can we do to improve this?
>
> Here's my idea:
>
> 1) What if we refactored the home page so it was all self-contained
> into these directories:   /scripts,  /styles,  /images and /en/?

Do you mean to centralize all kind of files that are shared? Like button 
pics, download scripting, color definitions?

I thought about this already for the download area as then these files 
are all in a single location. But of course it's also possible to do 
this for the entire wesite.

> 2) Make the /en directory be pure content.  Only the stuff that needs
> to be translated.  It loads everything else, scripts, images, etc.,
> via URLs relative to the root, e.g.., in /scripts, /styles, etc.

Should the "en/" folder have another purpose than just to work as a big 
template?

> 3) Reduce or eliminate any embedded Javascript within pages.  For
> example, refactor the code in download/index.html so it is external
> and depends on JSON resource files for translated strings.  Aim so
> translators never need to touch script.

At least for the download webpage I thought, too, already to separate 
code and text because it makes it easier for other people to use the 
design of the main download webapge for their language.

I've not yet committed anything but the idea is to separate a) HTML 
design, b) JS code and c) translate-able text strings from each other.

However, I put already a Todo note into the Wiki (see the 2nd row from top):

https://cwiki.apache.org/confluence/display/OOOUSERS/Improvements+for+the+download+webpages#Improvementsforthedownloadwebpages-ImmediateConcerns%2CShort%2FMidTermImprovements

> 4) Ultimate goal is for someone to be able to jump start a new NL home
> page by simply requesting an svn copy of the /en directory, and then
> editing the resulting files.  No one should ever need to do what I'm
> doing with the "xx" pages.

Yeah, indeed a hugh work to get to this dream.

> 5) Maintenance is far easier.  Most things like changing the scripts,
> is done in one place only.  But even changes to the HTML are easier.
> Since we then have a common branch point via the svn copy, when
> structural changes are added to the main /en HTML, these can be merged
> in more elegantly to the translated versions, using Subversion.
>
> 6) Via Apache redirects we can ensure that the default call to
> www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
> detection and send requests automatically to the appropriate NL home
> page.
>
> A variation on the above would be to use Pootle, rather than svn
> copy/merge to maintain the translations.  But that would require the
> same refactoring work to enable it.  And it would require further
> investigation to identify a way of extracting and merging translation
> strings in MDText files as well as (X)HTML files.
>
> This is obviously more than a one-person task.  So I'd be interested
> in hearing what you think in general about this approach, whether
> there is a simpler alternative I've missed, and whether this is
> something you'd be interested in helping with.

I think it's no secret when I tell you that this is a great idea from 
the view point of maintenance and to attrack new volunteers for not yet 
known and supported languages.

However, I'm really wondering if this will be a success as it would mean 
nothing less than a complete rebuild of all files on the entire website.

I believe it's better to split this up into some chunks. What's the most 
interesting ansd important part of our website? Start with this, build 
up some skills, knowledge and best pratices and then enroll it more and 
more over the remaining parts - and hopefully with more volunteers. ;-)

My 2 ct.

Marcus

---------------------------------------------------------------------
To unsubscribe, e-mail: l10n-unsubscribe@openoffice.apache.org
For additional commands, e-mail: l10n-help@openoffice.apache.org


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by Pedro Albuquerque <pa...@gmail.com>.
Hi,
Em 23/08/2013 16:58, Rob Weir escreveu:
> (Responses to dev@openoffice.apache.org, please)
>
> As a test I tried to create my own NL page, in the fictitious "xx"
> locale.  You can see it here:  http://www.openoffice.org/xx/
>
> 1) I had to hunt around and guess which files to copy.  Do I copy
> scripts, images and CSS, or just content pages?   Some of the
> directories had out-dated content that was not linked to my anyone.
> It was hard to figure out what the minimum amount of content needed
> was, and where it was located.
Likewise here with the Portugal site!
> 2) The main index.html file had to be edited to refer to CSS in the
> root, rather than current directory
>
> 3)  Download page is missed up, missing CSS and/or scripts.
> Presumably I need to copy something into the xx/download dir, or edit
> scripts to make them refer /download off the root.
>
> 4) The /xx/why pages are not showing the right side navigation now.  I
> must have missed something there as well.
I suppose that's why I had to ask for help on the download link.
> Of course, I could figure the above out eventually.  It just requires
> some time and effort and trial and error.  But none of this is
> documented, and even if it were this is a fragile approach and
> probably beyond th web development skills of a typical translator.
Couldn't agree more!
> 1) What if we refactored the home page so it was all self-contained
> into these directories:   /scripts,  /styles,  /images and /en/?
>
> 2) Make the /en directory be pure content.  Only the stuff that needs
> to be translated.  It loads everything else, scripts, images, etc.,
> via URLs relative to the root, e.g.., in /scripts, /styles, etc.
Being a ignorant as I am, seems a lot more simple, anyone could choose 
what to do with the  localized site accordingly to its own skills.

> This is obviously more than a one-person task.  So I'd be interested
> in hearing what you think in general about this approach, whether
> there is a simpler alternative I've missed, and whether this is
> something you'd be interested in helping with.
>
As I'm not a developer or programmer but just a curious, I'm whiling to 
help in every way possible. So I'll give my opinion.
I think that basically there are not many mandatory things to be in an 
official localized site. Those should be automatically inserted (I think 
that they already are).
Other than that, a simple request to translate the /en directory (if 
this is the localized one) should be enough for most translators, and 
allow a continuous maintenance of the site for those available without 
much trouble for them. A simple warning mail would suffice.
To go a little bit further, maybe a list of the links in the site should 
be mandatory and perfectly distinguished from others (local ones) and 
automatically updated so that someone like me doesn't have to test all 
the previously existing ones just to verify that most of them are broken 
or out of date.
Besides this, for the experts or others alike, there should be an 
option, somewhere, to create or upload (?) there own ideas.  Subject to 
approval from the responsible (the one in charge;-) ), of course.
Above all, please keep it simple.
Best regards,
Pedro

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
For additional commands, e-mail: dev-help@openoffice.apache.org


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by Rob Weir <ro...@apache.org>.
On Fri, Aug 23, 2013 at 5:29 PM, Kay Schenk <ka...@gmail.com> wrote:
> On Fri, Aug 23, 2013 at 8:58 AM, Rob Weir <ro...@apache.org> wrote:
>
>> (Responses to dev@openoffice.apache.org, please)
>>
>> Obviously our website is quite large.  Google reports 21207 pages
>> indexed in the www subdomain, and a further 48075 pages in the wiki
>> subdomain.   But for purpose of this post, when I talk about the "home
>> page" I'm talking about the contents of our main index.html and the
>> most commonly visited pages directly linked to it, e.g., the
>> why/download/product/get-involved, etc. pages.
>>
>> This core homepage content amounts to around 25 pages.
>>
>> Today this content is scattered around the content tree.  Some of it
>> is in the root.  Some of it in /why and /download directories.  Some
>> of it is template-related and is in /templates rather than in
>> /content.
>>
>> As a test I tried to create my own NL page, in the fictitious "xx"
>> locale.  You can see it here:  http://www.openoffice.org/xx/
>>
>> It is not working correctly, but it already required a lot of
>> non-trivial hacking:
>>
>> 1) I had to hunt around and guess which files to copy.  Do I copy
>> scripts, images and CSS, or just content pages?   Some of the
>> directories had out-dated content that was not linked to my anyone.
>> It was hard to figure out what the minimum amount of content needed
>> was, and where it was located.
>>
>> 2) The main index.html file had to be edited to refer to CSS in the
>> root, rather than current directory
>>
>
> Some of what you are experiencing re the css issues are due to many
> migrations and css that applies ONLY to the home page and not others.
> There's no reason why this should be this way really. SOme of us dealing
> with this on a day to day basis knew this but were afraid to mess with it.
>
>
>>
>> 3)  Download page is missed up, missing CSS and/or scripts.
>> Presumably I need to copy something into the xx/download dir, or edit
>> scripts to make them refer /download off the root.
>>
>> 4) The /xx/why pages are not showing the right side navigation now.  I
>> must have missed something there as well.
>>
>
> hmmm...not seeing what you've done, this could be do to some  CMS setup.
>

I think I see what is missing.  I need to add:

/templates/xx/why/ssi.mdtext

That means that the NL homepages are not really self-contained.  They
are in /content/xx and also in /templates/xx.   That is OK, I suppose.

>
>> Of course, I could figure the above out eventually.  It just requires
>> some time and effort and trial and error.  But none of this is
>> documented, and even if it were this is a fragile approach and
>> probably beyond th web development skills of a typical translator.
>>
>> But we do know this has been done for some languages.  They got it to
>> work.  The German page is a good example:
>>
>> http://www.openoffice.org/de/
>>
>> Now this looks good, but it is still a messy thing from a maintenance
>> perspective.  If we make structural changes to the main English page,
>> then those changes need to be manually merged into to every NL page.
>>
>> What can we do to improve this?
>>
>> Here's my idea:
>>
>> 1) What if we refactored the home page so it was all self-contained
>> into these directories:   /scripts,  /styles,  /images and /en/?
>>
>> 2) Make the /en directory be pure content.  Only the stuff that needs
>> to be translated.  It loads everything else, scripts, images, etc.,
>> via URLs relative to the root, e.g.., in /scripts, /styles, etc.
>>
>> 3) Reduce or eliminate any embedded Javascript within pages.
>
>
> I didn't think we had a lot of this but maybe more than we should.
>
>
>>  For
>> example, refactor the code in download/index.html so it is external
>> and depends on JSON resource files for translated strings.  Aim so
>> translators never need to touch script.
>>
>
> Well I don't really know JSON so I can't speak to this. Will investigate.
> though we do/did make extensive use of JS data structures in the past.
>

You can read about one JSON-based approach here:

http://blog.mozilla.org/webdev/2011/10/06/i18njs-internationalize-your-javascript-with-a-little-help-from-json-and-the-server/


My original idea was to use such an approach only where we had
language strings tightly mixed with JS, like on the download page,
where we generate the boxes.  It might be overkill to do this approach
with normal HTML or MDText content.   The nice thing about HTML is a
translator has the context, they can test their work on their own
machines, and we have the W3C markup validator that they can use to
check the final page.  So I think translators can handle that.

>
>> 4) Ultimate goal is for someone to be able to jump start a new NL home
>> page by simply requesting an svn copy of the /en directory, and then
>> editing the resulting files.  No one should ever need to do what I'm
>> doing with the "xx" pages.
>>
>
> I think once upon a time -- maybe LONG ago -- the NL pages were
> standardized to be clone of the main index page. But, various NL groups
> wanted more of their own identity, and so we have what we have.
>

Possibly.  So I guess I'm pushing for moving in the other direction,
toward uniformity.  Or better yet:  uniformity with a structured way
of adding local content.

>
>>
>> 5) Maintenance is far easier.  Most things like changing the scripts,
>> is done in one place only.  But even changes to the HTML are easier.
>> Since we then have a common branch point via the svn copy, when
>> structural changes are added to the main /en HTML, these can be merged
>> in more elegantly to the translated versions, using Subversion.
>>
>> 6) Via Apache redirects we can ensure that the default call to
>> www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
>> detection and send requests automatically to the appropriate NL home
>> page.
>>
>> A variation on the above would be to use Pootle, rather than svn
>> copy/merge to maintain the translations.  But that would require the
>> same refactoring work to enable it.  And it would require further
>> investigation to identify a way of extracting and merging translation
>> strings in MDText files as well as (X)HTML files.
>>
>> This is obviously more than a one-person task.  So I'd be interested
>> in hearing what you think in general about this approach, whether
>> there is a simpler alternative I've missed, and whether this is
>> something you'd be interested in helping with.
>>
>> Regards,
>>
>> -Rob
>>
>
> I think most of the ideas are good as long as we don't introduce
> technologies into the web site that down the road would require anyone to
> know, or deal with, much more than basic HTML and JS. This has been a
> factor in maintenance in the past.  Even the complicated JS introduced in
> one the last revisions to the home page was really more complex than what
> we needed as far as I was concerned -- we're talking maybe 2006 here.
>
> I guess those of us interested can take a look at what you've started in
> "xx".
>

OK.  I'll continue prototyping the "xx" home pages.  We'll get some
immediate benefit by the refactoring.

-Rob



>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
> For additional commands, e-mail: dev-help@openoffice.apache.org
>
>
>
>
> --
> -------------------------------------------------------------------------------------------------
> MzK
>
> "When in doubt, cop an attitude."
>                 -- Cat laws

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
For additional commands, e-mail: dev-help@openoffice.apache.org


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by Kay Schenk <ka...@gmail.com>.
On Fri, Aug 23, 2013 at 8:58 AM, Rob Weir <ro...@apache.org> wrote:

> (Responses to dev@openoffice.apache.org, please)
>
> Obviously our website is quite large.  Google reports 21207 pages
> indexed in the www subdomain, and a further 48075 pages in the wiki
> subdomain.   But for purpose of this post, when I talk about the "home
> page" I'm talking about the contents of our main index.html and the
> most commonly visited pages directly linked to it, e.g., the
> why/download/product/get-involved, etc. pages.
>
> This core homepage content amounts to around 25 pages.
>
> Today this content is scattered around the content tree.  Some of it
> is in the root.  Some of it in /why and /download directories.  Some
> of it is template-related and is in /templates rather than in
> /content.
>
> As a test I tried to create my own NL page, in the fictitious "xx"
> locale.  You can see it here:  http://www.openoffice.org/xx/
>
> It is not working correctly, but it already required a lot of
> non-trivial hacking:
>
> 1) I had to hunt around and guess which files to copy.  Do I copy
> scripts, images and CSS, or just content pages?   Some of the
> directories had out-dated content that was not linked to my anyone.
> It was hard to figure out what the minimum amount of content needed
> was, and where it was located.
>
> 2) The main index.html file had to be edited to refer to CSS in the
> root, rather than current directory
>

Some of what you are experiencing re the css issues are due to many
migrations and css that applies ONLY to the home page and not others.
There's no reason why this should be this way really. SOme of us dealing
with this on a day to day basis knew this but were afraid to mess with it.


>
> 3)  Download page is missed up, missing CSS and/or scripts.
> Presumably I need to copy something into the xx/download dir, or edit
> scripts to make them refer /download off the root.
>
> 4) The /xx/why pages are not showing the right side navigation now.  I
> must have missed something there as well.
>

hmmm...not seeing what you've done, this could be do to some  CMS setup.


> Of course, I could figure the above out eventually.  It just requires
> some time and effort and trial and error.  But none of this is
> documented, and even if it were this is a fragile approach and
> probably beyond th web development skills of a typical translator.
>
> But we do know this has been done for some languages.  They got it to
> work.  The German page is a good example:
>
> http://www.openoffice.org/de/
>
> Now this looks good, but it is still a messy thing from a maintenance
> perspective.  If we make structural changes to the main English page,
> then those changes need to be manually merged into to every NL page.
>
> What can we do to improve this?
>
> Here's my idea:
>
> 1) What if we refactored the home page so it was all self-contained
> into these directories:   /scripts,  /styles,  /images and /en/?
>
> 2) Make the /en directory be pure content.  Only the stuff that needs
> to be translated.  It loads everything else, scripts, images, etc.,
> via URLs relative to the root, e.g.., in /scripts, /styles, etc.
>
> 3) Reduce or eliminate any embedded Javascript within pages.


I didn't think we had a lot of this but maybe more than we should.


>  For
> example, refactor the code in download/index.html so it is external
> and depends on JSON resource files for translated strings.  Aim so
> translators never need to touch script.
>

Well I don't really know JSON so I can't speak to this. Will investigate.
though we do/did make extensive use of JS data structures in the past.


> 4) Ultimate goal is for someone to be able to jump start a new NL home
> page by simply requesting an svn copy of the /en directory, and then
> editing the resulting files.  No one should ever need to do what I'm
> doing with the "xx" pages.
>

I think once upon a time -- maybe LONG ago -- the NL pages were
standardized to be clone of the main index page. But, various NL groups
wanted more of their own identity, and so we have what we have.


>
> 5) Maintenance is far easier.  Most things like changing the scripts,
> is done in one place only.  But even changes to the HTML are easier.
> Since we then have a common branch point via the svn copy, when
> structural changes are added to the main /en HTML, these can be merged
> in more elegantly to the translated versions, using Subversion.
>
> 6) Via Apache redirects we can ensure that the default call to
> www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
> detection and send requests automatically to the appropriate NL home
> page.
>
> A variation on the above would be to use Pootle, rather than svn
> copy/merge to maintain the translations.  But that would require the
> same refactoring work to enable it.  And it would require further
> investigation to identify a way of extracting and merging translation
> strings in MDText files as well as (X)HTML files.
>
> This is obviously more than a one-person task.  So I'd be interested
> in hearing what you think in general about this approach, whether
> there is a simpler alternative I've missed, and whether this is
> something you'd be interested in helping with.
>
> Regards,
>
> -Rob
>

I think most of the ideas are good as long as we don't introduce
technologies into the web site that down the road would require anyone to
know, or deal with, much more than basic HTML and JS. This has been a
factor in maintenance in the past.  Even the complicated JS introduced in
one the last revisions to the home page was really more complex than what
we needed as far as I was concerned -- we're talking maybe 2006 here.

I guess those of us interested can take a look at what you've started in
"xx".


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
For additional commands, e-mail: dev-help@openoffice.apache.org




-- 
-------------------------------------------------------------------------------------------------
MzK

"When in doubt, cop an attitude."
                -- Cat laws

Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by Dave Fisher <wa...@apache.org>.

Sent from my iPhone

On Aug 26, 2013, at 10:16 AM, Dave Fisher <wa...@apache.org> wrote:

> 
> 
> Sent from my iPhone
> 
> On Aug 26, 2013, at 9:20 AM, Rob Weir <ro...@apache.org> wrote:
> 
>> On Mon, Aug 26, 2013 at 9:57 AM, Dave Fisher <wa...@apache.org> wrote:
>>> Since some of us like me are on vacation would it possible to either put this into a cwiki page or other clear summary. I have a lot I can add about the current setup like why you lost the rightnav - ie you need a subdirectory in templates.
>> 
>> Great.  I was hoping that you in particular would weigh in on this,
>> since I know you have given this a lot of thought as well.
>> 
>> I'll continue hacking in the xx directory and start a new thread
>> summarizing the state of the work in a couple weeks.
> 
> Beautiful. If xx is checked in then I'll hack on it too and we can collaborate.
> 

I will look into changing the ssi.mdtext rules to either be auto built or moved to the content tree. Auto built is preferred.

We might want to have some translate and setup scripts as discussed some time ago.

Some consideration of download and other JavaScript setup can be similarly scripted. 

Time will tell but we can hook the setup scripts with po files for string translations. A side task of automating the ssi.mdtext will be to enumerate navigation and branding strings for pootle translation.

> I think we can also look into improving branding element standards which will need to fit in the framework.

Regards,
Dave
> 
> I wonder if there is an httpd module that can hold a database or lookup table of redirections? If so I need something like it for work too which gives me some cycles.
> 
> Regards,
> Dave
> 
>> 
>> -Rob
>> 
>> 
>>> Regards,
>>> Dave
>>> 
>>> Sent from my iPhone
>>> 
>>> On Aug 26, 2013, at 8:45 AM, Rob Weir <ro...@apache.org> wrote:
>>> 
>>>> On Fri, Aug 23, 2013 at 5:12 PM, janI <ja...@apache.org> wrote:
>>>>> On 23 August 2013 21:11, Rob Weir <ro...@apache.org> wrote:
>>>>> 
>>>>>> On Fri, Aug 23, 2013 at 12:21 PM, janI <ja...@apache.org> wrote:
>>>>>>> On 23 August 2013 17:58, Rob Weir <ro...@apache.org> wrote:
>>>>>>> 
>>>>>>>> (Responses to dev@openoffice.apache.org, please)
>>>>>>>> 
>>>>>>>> Obviously our website is quite large.  Google reports 21207 pages
>>>>>>>> indexed in the www subdomain, and a further 48075 pages in the wiki
>>>>>>>> subdomain.   But for purpose of this post, when I talk about the "home
>>>>>>>> page" I'm talking about the contents of our main index.html and the
>>>>>>>> most commonly visited pages directly linked to it, e.g., the
>>>>>>>> why/download/product/get-involved, etc. pages.
>>>>>>>> 
>>>>>>>> This core homepage content amounts to around 25 pages.
>>>>>>>> 
>>>>>>>> Today this content is scattered around the content tree.  Some of it
>>>>>>>> is in the root.  Some of it in /why and /download directories.  Some
>>>>>>>> of it is template-related and is in /templates rather than in
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
> For additional commands, e-mail: dev-help@openoffice.apache.org
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
For additional commands, e-mail: dev-help@openoffice.apache.org


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by Dave Fisher <wa...@apache.org>.

Sent from my iPhone

On Aug 26, 2013, at 9:20 AM, Rob Weir <ro...@apache.org> wrote:

> On Mon, Aug 26, 2013 at 9:57 AM, Dave Fisher <wa...@apache.org> wrote:
>> Since some of us like me are on vacation would it possible to either put this into a cwiki page or other clear summary. I have a lot I can add about the current setup like why you lost the rightnav - ie you need a subdirectory in templates.
> 
> Great.  I was hoping that you in particular would weigh in on this,
> since I know you have given this a lot of thought as well.
> 
> I'll continue hacking in the xx directory and start a new thread
> summarizing the state of the work in a couple weeks.

Beautiful. If xx is checked in then I'll hack on it too and we can collaborate.

I think we can also look into improving branding element standards which will need to fit in the framework.

I wonder if there is an httpd module that can hold a database or lookup table of redirections? If so I need something like it for work too which gives me some cycles.

Regards,
Dave

> 
> -Rob
> 
> 
>> Regards,
>> Dave
>> 
>> Sent from my iPhone
>> 
>> On Aug 26, 2013, at 8:45 AM, Rob Weir <ro...@apache.org> wrote:
>> 
>>> On Fri, Aug 23, 2013 at 5:12 PM, janI <ja...@apache.org> wrote:
>>>> On 23 August 2013 21:11, Rob Weir <ro...@apache.org> wrote:
>>>> 
>>>>> On Fri, Aug 23, 2013 at 12:21 PM, janI <ja...@apache.org> wrote:
>>>>>> On 23 August 2013 17:58, Rob Weir <ro...@apache.org> wrote:
>>>>>> 
>>>>>>> (Responses to dev@openoffice.apache.org, please)
>>>>>>> 
>>>>>>> Obviously our website is quite large.  Google reports 21207 pages
>>>>>>> indexed in the www subdomain, and a further 48075 pages in the wiki
>>>>>>> subdomain.   But for purpose of this post, when I talk about the "home
>>>>>>> page" I'm talking about the contents of our main index.html and the
>>>>>>> most commonly visited pages directly linked to it, e.g., the
>>>>>>> why/download/product/get-involved, etc. pages.
>>>>>>> 
>>>>>>> This core homepage content amounts to around 25 pages.
>>>>>>> 
>>>>>>> Today this content is scattered around the content tree.  Some of it
>>>>>>> is in the root.  Some of it in /why and /download directories.  Some
>>>>>>> of it is template-related and is in /templates rather than in

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
For additional commands, e-mail: dev-help@openoffice.apache.org


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by Rob Weir <ro...@apache.org>.
On Mon, Aug 26, 2013 at 9:57 AM, Dave Fisher <wa...@apache.org> wrote:
> Since some of us like me are on vacation would it possible to either put this into a cwiki page or other clear summary. I have a lot I can add about the current setup like why you lost the rightnav - ie you need a subdirectory in templates.
>

Great.  I was hoping that you in particular would weigh in on this,
since I know you have given this a lot of thought as well.

I'll continue hacking in the xx directory and start a new thread
summarizing the state of the work in a couple weeks.

-Rob


> Regards,
> Dave
>
> Sent from my iPhone
>
> On Aug 26, 2013, at 8:45 AM, Rob Weir <ro...@apache.org> wrote:
>
>> On Fri, Aug 23, 2013 at 5:12 PM, janI <ja...@apache.org> wrote:
>>> On 23 August 2013 21:11, Rob Weir <ro...@apache.org> wrote:
>>>
>>>> On Fri, Aug 23, 2013 at 12:21 PM, janI <ja...@apache.org> wrote:
>>>>> On 23 August 2013 17:58, Rob Weir <ro...@apache.org> wrote:
>>>>>
>>>>>> (Responses to dev@openoffice.apache.org, please)
>>>>>>
>>>>>> Obviously our website is quite large.  Google reports 21207 pages
>>>>>> indexed in the www subdomain, and a further 48075 pages in the wiki
>>>>>> subdomain.   But for purpose of this post, when I talk about the "home
>>>>>> page" I'm talking about the contents of our main index.html and the
>>>>>> most commonly visited pages directly linked to it, e.g., the
>>>>>> why/download/product/get-involved, etc. pages.
>>>>>>
>>>>>> This core homepage content amounts to around 25 pages.
>>>>>>
>>>>>> Today this content is scattered around the content tree.  Some of it
>>>>>> is in the root.  Some of it in /why and /download directories.  Some
>>>>>> of it is template-related and is in /templates rather than in
>>>>>> /content.
>>>>>>
>>>>>> As a test I tried to create my own NL page, in the fictitious "xx"
>>>>>> locale.  You can see it here:  http://www.openoffice.org/xx/
>>>>>>
>>>>>> It is not working correctly, but it already required a lot of
>>>>>> non-trivial hacking:
>>>>>>
>>>>>> 1) I had to hunt around and guess which files to copy.  Do I copy
>>>>>> scripts, images and CSS, or just content pages?   Some of the
>>>>>> directories had out-dated content that was not linked to my anyone.
>>>>>> It was hard to figure out what the minimum amount of content needed
>>>>>> was, and where it was located.
>>>>>>
>>>>>> 2) The main index.html file had to be edited to refer to CSS in the
>>>>>> root, rather than current directory
>>>>>>
>>>>>> 3)  Download page is missed up, missing CSS and/or scripts.
>>>>>> Presumably I need to copy something into the xx/download dir, or edit
>>>>>> scripts to make them refer /download off the root.
>>>>>>
>>>>>> 4) The /xx/why pages are not showing the right side navigation now.  I
>>>>>> must have missed something there as well.
>>>>>>
>>>>>> Of course, I could figure the above out eventually.  It just requires
>>>>>> some time and effort and trial and error.  But none of this is
>>>>>> documented, and even if it were this is a fragile approach and
>>>>>> probably beyond th web development skills of a typical translator.
>>>>>>
>>>>>> But we do know this has been done for some languages.  They got it to
>>>>>> work.  The German page is a good example:
>>>>>>
>>>>>> http://www.openoffice.org/de/
>>>>>>
>>>>>> Now this looks good, but it is still a messy thing from a maintenance
>>>>>> perspective.  If we make structural changes to the main English page,
>>>>>> then those changes need to be manually merged into to every NL page.
>>>>>>
>>>>>> What can we do to improve this?
>>>>>>
>>>>>> Here's my idea:
>>>>>>
>>>>>> 1) What if we refactored the home page so it was all self-contained
>>>>>> into these directories:   /scripts,  /styles,  /images and /en/?
>>>>>>
>>>>>> 2) Make the /en directory be pure content.  Only the stuff that needs
>>>>>> to be translated.  It loads everything else, scripts, images, etc.,
>>>>>> via URLs relative to the root, e.g.., in /scripts, /styles, etc.
>>>>>>
>>>>>> 3) Reduce or eliminate any embedded Javascript within pages.  For
>>>>>> example, refactor the code in download/index.html so it is external
>>>>>> and depends on JSON resource files for translated strings.  Aim so
>>>>>> translators never need to touch script.
>>>>>>
>>>>>> 4) Ultimate goal is for someone to be able to jump start a new NL home
>>>>>> page by simply requesting an svn copy of the /en directory, and then
>>>>>> editing the resulting files.  No one should ever need to do what I'm
>>>>>> doing with the "xx" pages.
>>>>>>
>>>>>> 5) Maintenance is far easier.  Most things like changing the scripts,
>>>>>> is done in one place only.  But even changes to the HTML are easier.
>>>>>> Since we then have a common branch point via the svn copy, when
>>>>>> structural changes are added to the main /en HTML, these can be merged
>>>>>> in more elegantly to the translated versions, using Subversion.
>>>>>>
>>>>>> 6) Via Apache redirects we can ensure that the default call to
>>>>>> www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
>>>>>> detection and send requests automatically to the appropriate NL home
>>>>>> page.
>>>>>>
>>>>>> A variation on the above would be to use Pootle, rather than svn
>>>>>> copy/merge to maintain the translations.  But that would require the
>>>>>> same refactoring work to enable it.  And it would require further
>>>>>> investigation to identify a way of extracting and merging translation
>>>>>> strings in MDText files as well as (X)HTML files.
>>>>>>
>>>>>> This is obviously more than a one-person task.  So I'd be interested
>>>>>> in hearing what you think in general about this approach, whether
>>>>>> there is a simpler alternative I've missed, and whether this is
>>>>>> something you'd be interested in helping with.
>>>>>
>>>>> I like a lot of your ideas, let me add my own experience.
>>>>
>>>> Thanks.
>>>>
>>>>> If the our pages do not contain text, but that is totally outsourced in
>>>> one
>>>>> or more json objects, then translation becomes easy, and the pages
>>>> themself
>>>>> stay simple. when the url is called without arguments the "en-json" is
>>>>> used, and if called with lang="xx" "xx-json" is used.
>>>>
>>>> I like the idea of content/code separation.  We certainly do this is
>>>> the code, for example.  But two challenges to taking this approach all
>>>> the way with the  website.
>>>>
>>>> 1) If we do JSON everywhere then we have a Javscript dependency
>>>> everywhere.  This has an impact for visibility of the pages to search
>>>> engines, but there are workarounds.  But it may be a bigger issue for
>>>> users who block Javascript.
>>>>
>>>> No we would do that solely on the server side, it would not be a good idea
>>> to have JS retrieve the json objects.
>>>
>>> We could eg. use php, that retrieved to correct json object, and
>>> transmitted a finished page.
>>
>> OK.  We're on the same page.
>>
>>>
>>>> 2) There may be cases where a translation requires direct access to
>>>> the HTML or CSS.  For example, I think the Tamil translation needed
>>>> access to specify a specific font.  And for some languages they might
>>>> need to set text direction to RTL.   These kinds of things make almost
>>>> any approach more complicated.
>>>
>>> Look at e.g. our mwiki that handles those details all on server side.
>>>
>>> And just as a suggestion, if we were to use wordpress, things like fonts
>>> would be solved. WP also have a possibility (not json) for multi language,
>>> which I could easy adopt in genLang (for translation).
>>>
>>>
>>>>
>>>> So the question we need to answer is how far we take this?   I think
>>>> we have some examples where the code is so intertwined with the text
>>>> that translation becomes very hard and risky.  For example, the
>>>> generation of the "boxes" on the download page.   But then we have
>>>> some other pages, especially the MDText pages, where I would be
>>>> comfortable handing it directly to a translator and expect they could
>>>> edit it without breaking anything.
>>> We can always find examples where it becomes hard, but typically you can
>>> reformulate the problem so it fits in a standard (boxes are no real
>>> problem). The only problem I see is with JS, where are ask and get answers
>>> e.g. YN.
>>>
>>>
>>>>
>>>> The Javascript dependency might be broken if we make this be a CMS
>>>> build-time text replacement rather than a runtime/Javascript
>>>> replacement.  So the CMS would detect when the Pootle files change and
>>>> automatically generate new HTML pages from them.  But even then we
>>>> still would need some runtime integration of strings, specifically on
>>>> the download page where language and OS are determined at runtime
>>>> based on browser request headers.
>>> I would consider not to use cms, because we basically dont need it.
>>
>> So within the realm of server-side software, what is possible?  My
>> impress was that Infra generally cautions against runtime server side
>> execution due to the greater opportunity for security problems.
>> That's why we're using build-time page generation.  This approach also
>> performs well, since it is static HTML pages at runtime, and is very
>> stable.
>>
>> But in any case, I think the refactoring work is approximately the
>> same thing regardless of how the pages are generated.
>>
>> -Rob
>>
>>
>>> rgds
>>> jan I.
>>>
>>>>
>>>> -Rob
>>>>
>>>>> If we use json objects, then pootle becomes an elegant tool for
>>>>> translation, because it knows how to handle xml, and if we want  to stay
>>>>> with po files its about 1 day work in genLang.
>>>>>
>>>>> A number of top companies (incl. the one I used to work for) do it like
>>>>> this, they of course then hire a translator to translate the json
>>>> objects.
>>>>>
>>>>> Splitting functionality and text is the key, when thats done the rest is
>>>>> trvial work.
>>>>>
>>>>> This will of course make cms a bit top kill, but I can live with that :-)
>>>>
>>>>
>>>>
>>>>
>>>>> rgds
>>>>> jan I.
>>>>>
>>>>>
>>>>>>
>>>>>> Regards,
>>>>>>
>>>>>> -Rob
>>>>>>
>>>>>> ---------------------------------------------------------------------
>>>>>> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
>>>>>> For additional commands, e-mail: dev-help@openoffice.apache.org
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
>>>> For additional commands, e-mail: dev-help@openoffice.apache.org
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
>> For additional commands, e-mail: dev-help@openoffice.apache.org
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
> For additional commands, e-mail: dev-help@openoffice.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
For additional commands, e-mail: dev-help@openoffice.apache.org


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by Dave Fisher <wa...@apache.org>.
Since some of us like me are on vacation would it possible to either put this into a cwiki page or other clear summary. I have a lot I can add about the current setup like why you lost the rightnav - ie you need a subdirectory in templates.

Regards,
Dave

Sent from my iPhone

On Aug 26, 2013, at 8:45 AM, Rob Weir <ro...@apache.org> wrote:

> On Fri, Aug 23, 2013 at 5:12 PM, janI <ja...@apache.org> wrote:
>> On 23 August 2013 21:11, Rob Weir <ro...@apache.org> wrote:
>> 
>>> On Fri, Aug 23, 2013 at 12:21 PM, janI <ja...@apache.org> wrote:
>>>> On 23 August 2013 17:58, Rob Weir <ro...@apache.org> wrote:
>>>> 
>>>>> (Responses to dev@openoffice.apache.org, please)
>>>>> 
>>>>> Obviously our website is quite large.  Google reports 21207 pages
>>>>> indexed in the www subdomain, and a further 48075 pages in the wiki
>>>>> subdomain.   But for purpose of this post, when I talk about the "home
>>>>> page" I'm talking about the contents of our main index.html and the
>>>>> most commonly visited pages directly linked to it, e.g., the
>>>>> why/download/product/get-involved, etc. pages.
>>>>> 
>>>>> This core homepage content amounts to around 25 pages.
>>>>> 
>>>>> Today this content is scattered around the content tree.  Some of it
>>>>> is in the root.  Some of it in /why and /download directories.  Some
>>>>> of it is template-related and is in /templates rather than in
>>>>> /content.
>>>>> 
>>>>> As a test I tried to create my own NL page, in the fictitious "xx"
>>>>> locale.  You can see it here:  http://www.openoffice.org/xx/
>>>>> 
>>>>> It is not working correctly, but it already required a lot of
>>>>> non-trivial hacking:
>>>>> 
>>>>> 1) I had to hunt around and guess which files to copy.  Do I copy
>>>>> scripts, images and CSS, or just content pages?   Some of the
>>>>> directories had out-dated content that was not linked to my anyone.
>>>>> It was hard to figure out what the minimum amount of content needed
>>>>> was, and where it was located.
>>>>> 
>>>>> 2) The main index.html file had to be edited to refer to CSS in the
>>>>> root, rather than current directory
>>>>> 
>>>>> 3)  Download page is missed up, missing CSS and/or scripts.
>>>>> Presumably I need to copy something into the xx/download dir, or edit
>>>>> scripts to make them refer /download off the root.
>>>>> 
>>>>> 4) The /xx/why pages are not showing the right side navigation now.  I
>>>>> must have missed something there as well.
>>>>> 
>>>>> Of course, I could figure the above out eventually.  It just requires
>>>>> some time and effort and trial and error.  But none of this is
>>>>> documented, and even if it were this is a fragile approach and
>>>>> probably beyond th web development skills of a typical translator.
>>>>> 
>>>>> But we do know this has been done for some languages.  They got it to
>>>>> work.  The German page is a good example:
>>>>> 
>>>>> http://www.openoffice.org/de/
>>>>> 
>>>>> Now this looks good, but it is still a messy thing from a maintenance
>>>>> perspective.  If we make structural changes to the main English page,
>>>>> then those changes need to be manually merged into to every NL page.
>>>>> 
>>>>> What can we do to improve this?
>>>>> 
>>>>> Here's my idea:
>>>>> 
>>>>> 1) What if we refactored the home page so it was all self-contained
>>>>> into these directories:   /scripts,  /styles,  /images and /en/?
>>>>> 
>>>>> 2) Make the /en directory be pure content.  Only the stuff that needs
>>>>> to be translated.  It loads everything else, scripts, images, etc.,
>>>>> via URLs relative to the root, e.g.., in /scripts, /styles, etc.
>>>>> 
>>>>> 3) Reduce or eliminate any embedded Javascript within pages.  For
>>>>> example, refactor the code in download/index.html so it is external
>>>>> and depends on JSON resource files for translated strings.  Aim so
>>>>> translators never need to touch script.
>>>>> 
>>>>> 4) Ultimate goal is for someone to be able to jump start a new NL home
>>>>> page by simply requesting an svn copy of the /en directory, and then
>>>>> editing the resulting files.  No one should ever need to do what I'm
>>>>> doing with the "xx" pages.
>>>>> 
>>>>> 5) Maintenance is far easier.  Most things like changing the scripts,
>>>>> is done in one place only.  But even changes to the HTML are easier.
>>>>> Since we then have a common branch point via the svn copy, when
>>>>> structural changes are added to the main /en HTML, these can be merged
>>>>> in more elegantly to the translated versions, using Subversion.
>>>>> 
>>>>> 6) Via Apache redirects we can ensure that the default call to
>>>>> www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
>>>>> detection and send requests automatically to the appropriate NL home
>>>>> page.
>>>>> 
>>>>> A variation on the above would be to use Pootle, rather than svn
>>>>> copy/merge to maintain the translations.  But that would require the
>>>>> same refactoring work to enable it.  And it would require further
>>>>> investigation to identify a way of extracting and merging translation
>>>>> strings in MDText files as well as (X)HTML files.
>>>>> 
>>>>> This is obviously more than a one-person task.  So I'd be interested
>>>>> in hearing what you think in general about this approach, whether
>>>>> there is a simpler alternative I've missed, and whether this is
>>>>> something you'd be interested in helping with.
>>>> 
>>>> I like a lot of your ideas, let me add my own experience.
>>> 
>>> Thanks.
>>> 
>>>> If the our pages do not contain text, but that is totally outsourced in
>>> one
>>>> or more json objects, then translation becomes easy, and the pages
>>> themself
>>>> stay simple. when the url is called without arguments the "en-json" is
>>>> used, and if called with lang="xx" "xx-json" is used.
>>> 
>>> I like the idea of content/code separation.  We certainly do this is
>>> the code, for example.  But two challenges to taking this approach all
>>> the way with the  website.
>>> 
>>> 1) If we do JSON everywhere then we have a Javscript dependency
>>> everywhere.  This has an impact for visibility of the pages to search
>>> engines, but there are workarounds.  But it may be a bigger issue for
>>> users who block Javascript.
>>> 
>>> No we would do that solely on the server side, it would not be a good idea
>> to have JS retrieve the json objects.
>> 
>> We could eg. use php, that retrieved to correct json object, and
>> transmitted a finished page.
> 
> OK.  We're on the same page.
> 
>> 
>>> 2) There may be cases where a translation requires direct access to
>>> the HTML or CSS.  For example, I think the Tamil translation needed
>>> access to specify a specific font.  And for some languages they might
>>> need to set text direction to RTL.   These kinds of things make almost
>>> any approach more complicated.
>> 
>> Look at e.g. our mwiki that handles those details all on server side.
>> 
>> And just as a suggestion, if we were to use wordpress, things like fonts
>> would be solved. WP also have a possibility (not json) for multi language,
>> which I could easy adopt in genLang (for translation).
>> 
>> 
>>> 
>>> So the question we need to answer is how far we take this?   I think
>>> we have some examples where the code is so intertwined with the text
>>> that translation becomes very hard and risky.  For example, the
>>> generation of the "boxes" on the download page.   But then we have
>>> some other pages, especially the MDText pages, where I would be
>>> comfortable handing it directly to a translator and expect they could
>>> edit it without breaking anything.
>> We can always find examples where it becomes hard, but typically you can
>> reformulate the problem so it fits in a standard (boxes are no real
>> problem). The only problem I see is with JS, where are ask and get answers
>> e.g. YN.
>> 
>> 
>>> 
>>> The Javascript dependency might be broken if we make this be a CMS
>>> build-time text replacement rather than a runtime/Javascript
>>> replacement.  So the CMS would detect when the Pootle files change and
>>> automatically generate new HTML pages from them.  But even then we
>>> still would need some runtime integration of strings, specifically on
>>> the download page where language and OS are determined at runtime
>>> based on browser request headers.
>> I would consider not to use cms, because we basically dont need it.
> 
> So within the realm of server-side software, what is possible?  My
> impress was that Infra generally cautions against runtime server side
> execution due to the greater opportunity for security problems.
> That's why we're using build-time page generation.  This approach also
> performs well, since it is static HTML pages at runtime, and is very
> stable.
> 
> But in any case, I think the refactoring work is approximately the
> same thing regardless of how the pages are generated.
> 
> -Rob
> 
> 
>> rgds
>> jan I.
>> 
>>> 
>>> -Rob
>>> 
>>>> If we use json objects, then pootle becomes an elegant tool for
>>>> translation, because it knows how to handle xml, and if we want  to stay
>>>> with po files its about 1 day work in genLang.
>>>> 
>>>> A number of top companies (incl. the one I used to work for) do it like
>>>> this, they of course then hire a translator to translate the json
>>> objects.
>>>> 
>>>> Splitting functionality and text is the key, when thats done the rest is
>>>> trvial work.
>>>> 
>>>> This will of course make cms a bit top kill, but I can live with that :-)
>>> 
>>> 
>>> 
>>> 
>>>> rgds
>>>> jan I.
>>>> 
>>>> 
>>>>> 
>>>>> Regards,
>>>>> 
>>>>> -Rob
>>>>> 
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
>>>>> For additional commands, e-mail: dev-help@openoffice.apache.org
>>> 
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
>>> For additional commands, e-mail: dev-help@openoffice.apache.org
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
> For additional commands, e-mail: dev-help@openoffice.apache.org
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
For additional commands, e-mail: dev-help@openoffice.apache.org


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by Rob Weir <ro...@apache.org>.
On Fri, Aug 23, 2013 at 5:12 PM, janI <ja...@apache.org> wrote:
> On 23 August 2013 21:11, Rob Weir <ro...@apache.org> wrote:
>
>> On Fri, Aug 23, 2013 at 12:21 PM, janI <ja...@apache.org> wrote:
>> > On 23 August 2013 17:58, Rob Weir <ro...@apache.org> wrote:
>> >
>> >> (Responses to dev@openoffice.apache.org, please)
>> >>
>> >> Obviously our website is quite large.  Google reports 21207 pages
>> >> indexed in the www subdomain, and a further 48075 pages in the wiki
>> >> subdomain.   But for purpose of this post, when I talk about the "home
>> >> page" I'm talking about the contents of our main index.html and the
>> >> most commonly visited pages directly linked to it, e.g., the
>> >> why/download/product/get-involved, etc. pages.
>> >>
>> >> This core homepage content amounts to around 25 pages.
>> >>
>> >> Today this content is scattered around the content tree.  Some of it
>> >> is in the root.  Some of it in /why and /download directories.  Some
>> >> of it is template-related and is in /templates rather than in
>> >> /content.
>> >>
>> >> As a test I tried to create my own NL page, in the fictitious "xx"
>> >> locale.  You can see it here:  http://www.openoffice.org/xx/
>> >>
>> >> It is not working correctly, but it already required a lot of
>> >> non-trivial hacking:
>> >>
>> >> 1) I had to hunt around and guess which files to copy.  Do I copy
>> >> scripts, images and CSS, or just content pages?   Some of the
>> >> directories had out-dated content that was not linked to my anyone.
>> >> It was hard to figure out what the minimum amount of content needed
>> >> was, and where it was located.
>> >>
>> >> 2) The main index.html file had to be edited to refer to CSS in the
>> >> root, rather than current directory
>> >>
>> >> 3)  Download page is missed up, missing CSS and/or scripts.
>> >> Presumably I need to copy something into the xx/download dir, or edit
>> >> scripts to make them refer /download off the root.
>> >>
>> >> 4) The /xx/why pages are not showing the right side navigation now.  I
>> >> must have missed something there as well.
>> >>
>> >> Of course, I could figure the above out eventually.  It just requires
>> >> some time and effort and trial and error.  But none of this is
>> >> documented, and even if it were this is a fragile approach and
>> >> probably beyond th web development skills of a typical translator.
>> >>
>> >> But we do know this has been done for some languages.  They got it to
>> >> work.  The German page is a good example:
>> >>
>> >> http://www.openoffice.org/de/
>> >>
>> >> Now this looks good, but it is still a messy thing from a maintenance
>> >> perspective.  If we make structural changes to the main English page,
>> >> then those changes need to be manually merged into to every NL page.
>> >>
>> >> What can we do to improve this?
>> >>
>> >> Here's my idea:
>> >>
>> >> 1) What if we refactored the home page so it was all self-contained
>> >> into these directories:   /scripts,  /styles,  /images and /en/?
>> >>
>> >> 2) Make the /en directory be pure content.  Only the stuff that needs
>> >> to be translated.  It loads everything else, scripts, images, etc.,
>> >> via URLs relative to the root, e.g.., in /scripts, /styles, etc.
>> >>
>> >> 3) Reduce or eliminate any embedded Javascript within pages.  For
>> >> example, refactor the code in download/index.html so it is external
>> >> and depends on JSON resource files for translated strings.  Aim so
>> >> translators never need to touch script.
>> >>
>> >> 4) Ultimate goal is for someone to be able to jump start a new NL home
>> >> page by simply requesting an svn copy of the /en directory, and then
>> >> editing the resulting files.  No one should ever need to do what I'm
>> >> doing with the "xx" pages.
>> >>
>> >> 5) Maintenance is far easier.  Most things like changing the scripts,
>> >> is done in one place only.  But even changes to the HTML are easier.
>> >> Since we then have a common branch point via the svn copy, when
>> >> structural changes are added to the main /en HTML, these can be merged
>> >> in more elegantly to the translated versions, using Subversion.
>> >>
>> >> 6) Via Apache redirects we can ensure that the default call to
>> >> www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
>> >> detection and send requests automatically to the appropriate NL home
>> >> page.
>> >>
>> >> A variation on the above would be to use Pootle, rather than svn
>> >> copy/merge to maintain the translations.  But that would require the
>> >> same refactoring work to enable it.  And it would require further
>> >> investigation to identify a way of extracting and merging translation
>> >> strings in MDText files as well as (X)HTML files.
>> >>
>> >> This is obviously more than a one-person task.  So I'd be interested
>> >> in hearing what you think in general about this approach, whether
>> >> there is a simpler alternative I've missed, and whether this is
>> >> something you'd be interested in helping with.
>> >>
>> >
>> > I like a lot of your ideas, let me add my own experience.
>> >
>>
>> Thanks.
>>
>> > If the our pages do not contain text, but that is totally outsourced in
>> one
>> > or more json objects, then translation becomes easy, and the pages
>> themself
>> > stay simple. when the url is called without arguments the "en-json" is
>> > used, and if called with lang="xx" "xx-json" is used.
>> >
>>
>> I like the idea of content/code separation.  We certainly do this is
>> the code, for example.  But two challenges to taking this approach all
>> the way with the  website.
>>
>> 1) If we do JSON everywhere then we have a Javscript dependency
>> everywhere.  This has an impact for visibility of the pages to search
>> engines, but there are workarounds.  But it may be a bigger issue for
>> users who block Javascript.
>>
>> No we would do that solely on the server side, it would not be a good idea
> to have JS retrieve the json objects.
>
> We could eg. use php, that retrieved to correct json object, and
> transmitted a finished page.
>

OK.  We're on the same page.

>
>> 2) There may be cases where a translation requires direct access to
>> the HTML or CSS.  For example, I think the Tamil translation needed
>> access to specify a specific font.  And for some languages they might
>> need to set text direction to RTL.   These kinds of things make almost
>> any approach more complicated.
>>
>
> Look at e.g. our mwiki that handles those details all on server side.
>
> And just as a suggestion, if we were to use wordpress, things like fonts
> would be solved. WP also have a possibility (not json) for multi language,
> which I could easy adopt in genLang (for translation).
>
>
>>
>> So the question we need to answer is how far we take this?   I think
>> we have some examples where the code is so intertwined with the text
>> that translation becomes very hard and risky.  For example, the
>> generation of the "boxes" on the download page.   But then we have
>> some other pages, especially the MDText pages, where I would be
>> comfortable handing it directly to a translator and expect they could
>> edit it without breaking anything.
>>
> We can always find examples where it becomes hard, but typically you can
> reformulate the problem so it fits in a standard (boxes are no real
> problem). The only problem I see is with JS, where are ask and get answers
> e.g. YN.
>
>
>>
>> The Javascript dependency might be broken if we make this be a CMS
>> build-time text replacement rather than a runtime/Javascript
>> replacement.  So the CMS would detect when the Pootle files change and
>> automatically generate new HTML pages from them.  But even then we
>> still would need some runtime integration of strings, specifically on
>> the download page where language and OS are determined at runtime
>> based on browser request headers.
>>
> I would consider not to use cms, because we basically dont need it.
>

So within the realm of server-side software, what is possible?  My
impress was that Infra generally cautions against runtime server side
execution due to the greater opportunity for security problems.
That's why we're using build-time page generation.  This approach also
performs well, since it is static HTML pages at runtime, and is very
stable.

But in any case, I think the refactoring work is approximately the
same thing regardless of how the pages are generated.

-Rob


> rgds
> jan I.
>
>>
>> -Rob
>>
>> > If we use json objects, then pootle becomes an elegant tool for
>> > translation, because it knows how to handle xml, and if we want  to stay
>> > with po files its about 1 day work in genLang.
>> >
>> > A number of top companies (incl. the one I used to work for) do it like
>> > this, they of course then hire a translator to translate the json
>> objects.
>> >
>> > Splitting functionality and text is the key, when thats done the rest is
>> > trvial work.
>> >
>> > This will of course make cms a bit top kill, but I can live with that :-)
>> >
>>
>>
>>
>>
>> > rgds
>> > jan I.
>> >
>> >
>> >>
>> >> Regards,
>> >>
>> >> -Rob
>> >>
>> >> ---------------------------------------------------------------------
>> >> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
>> >> For additional commands, e-mail: dev-help@openoffice.apache.org
>> >>
>> >>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
>> For additional commands, e-mail: dev-help@openoffice.apache.org
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
For additional commands, e-mail: dev-help@openoffice.apache.org


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by janI <ja...@apache.org>.
On 23 August 2013 21:11, Rob Weir <ro...@apache.org> wrote:

> On Fri, Aug 23, 2013 at 12:21 PM, janI <ja...@apache.org> wrote:
> > On 23 August 2013 17:58, Rob Weir <ro...@apache.org> wrote:
> >
> >> (Responses to dev@openoffice.apache.org, please)
> >>
> >> Obviously our website is quite large.  Google reports 21207 pages
> >> indexed in the www subdomain, and a further 48075 pages in the wiki
> >> subdomain.   But for purpose of this post, when I talk about the "home
> >> page" I'm talking about the contents of our main index.html and the
> >> most commonly visited pages directly linked to it, e.g., the
> >> why/download/product/get-involved, etc. pages.
> >>
> >> This core homepage content amounts to around 25 pages.
> >>
> >> Today this content is scattered around the content tree.  Some of it
> >> is in the root.  Some of it in /why and /download directories.  Some
> >> of it is template-related and is in /templates rather than in
> >> /content.
> >>
> >> As a test I tried to create my own NL page, in the fictitious "xx"
> >> locale.  You can see it here:  http://www.openoffice.org/xx/
> >>
> >> It is not working correctly, but it already required a lot of
> >> non-trivial hacking:
> >>
> >> 1) I had to hunt around and guess which files to copy.  Do I copy
> >> scripts, images and CSS, or just content pages?   Some of the
> >> directories had out-dated content that was not linked to my anyone.
> >> It was hard to figure out what the minimum amount of content needed
> >> was, and where it was located.
> >>
> >> 2) The main index.html file had to be edited to refer to CSS in the
> >> root, rather than current directory
> >>
> >> 3)  Download page is missed up, missing CSS and/or scripts.
> >> Presumably I need to copy something into the xx/download dir, or edit
> >> scripts to make them refer /download off the root.
> >>
> >> 4) The /xx/why pages are not showing the right side navigation now.  I
> >> must have missed something there as well.
> >>
> >> Of course, I could figure the above out eventually.  It just requires
> >> some time and effort and trial and error.  But none of this is
> >> documented, and even if it were this is a fragile approach and
> >> probably beyond th web development skills of a typical translator.
> >>
> >> But we do know this has been done for some languages.  They got it to
> >> work.  The German page is a good example:
> >>
> >> http://www.openoffice.org/de/
> >>
> >> Now this looks good, but it is still a messy thing from a maintenance
> >> perspective.  If we make structural changes to the main English page,
> >> then those changes need to be manually merged into to every NL page.
> >>
> >> What can we do to improve this?
> >>
> >> Here's my idea:
> >>
> >> 1) What if we refactored the home page so it was all self-contained
> >> into these directories:   /scripts,  /styles,  /images and /en/?
> >>
> >> 2) Make the /en directory be pure content.  Only the stuff that needs
> >> to be translated.  It loads everything else, scripts, images, etc.,
> >> via URLs relative to the root, e.g.., in /scripts, /styles, etc.
> >>
> >> 3) Reduce or eliminate any embedded Javascript within pages.  For
> >> example, refactor the code in download/index.html so it is external
> >> and depends on JSON resource files for translated strings.  Aim so
> >> translators never need to touch script.
> >>
> >> 4) Ultimate goal is for someone to be able to jump start a new NL home
> >> page by simply requesting an svn copy of the /en directory, and then
> >> editing the resulting files.  No one should ever need to do what I'm
> >> doing with the "xx" pages.
> >>
> >> 5) Maintenance is far easier.  Most things like changing the scripts,
> >> is done in one place only.  But even changes to the HTML are easier.
> >> Since we then have a common branch point via the svn copy, when
> >> structural changes are added to the main /en HTML, these can be merged
> >> in more elegantly to the translated versions, using Subversion.
> >>
> >> 6) Via Apache redirects we can ensure that the default call to
> >> www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
> >> detection and send requests automatically to the appropriate NL home
> >> page.
> >>
> >> A variation on the above would be to use Pootle, rather than svn
> >> copy/merge to maintain the translations.  But that would require the
> >> same refactoring work to enable it.  And it would require further
> >> investigation to identify a way of extracting and merging translation
> >> strings in MDText files as well as (X)HTML files.
> >>
> >> This is obviously more than a one-person task.  So I'd be interested
> >> in hearing what you think in general about this approach, whether
> >> there is a simpler alternative I've missed, and whether this is
> >> something you'd be interested in helping with.
> >>
> >
> > I like a lot of your ideas, let me add my own experience.
> >
>
> Thanks.
>
> > If the our pages do not contain text, but that is totally outsourced in
> one
> > or more json objects, then translation becomes easy, and the pages
> themself
> > stay simple. when the url is called without arguments the "en-json" is
> > used, and if called with lang="xx" "xx-json" is used.
> >
>
> I like the idea of content/code separation.  We certainly do this is
> the code, for example.  But two challenges to taking this approach all
> the way with the  website.
>
> 1) If we do JSON everywhere then we have a Javscript dependency
> everywhere.  This has an impact for visibility of the pages to search
> engines, but there are workarounds.  But it may be a bigger issue for
> users who block Javascript.
>
> No we would do that solely on the server side, it would not be a good idea
to have JS retrieve the json objects.

We could eg. use php, that retrieved to correct json object, and
transmitted a finished page.


> 2) There may be cases where a translation requires direct access to
> the HTML or CSS.  For example, I think the Tamil translation needed
> access to specify a specific font.  And for some languages they might
> need to set text direction to RTL.   These kinds of things make almost
> any approach more complicated.
>

Look at e.g. our mwiki that handles those details all on server side.

And just as a suggestion, if we were to use wordpress, things like fonts
would be solved. WP also have a possibility (not json) for multi language,
which I could easy adopt in genLang (for translation).


>
> So the question we need to answer is how far we take this?   I think
> we have some examples where the code is so intertwined with the text
> that translation becomes very hard and risky.  For example, the
> generation of the "boxes" on the download page.   But then we have
> some other pages, especially the MDText pages, where I would be
> comfortable handing it directly to a translator and expect they could
> edit it without breaking anything.
>
We can always find examples where it becomes hard, but typically you can
reformulate the problem so it fits in a standard (boxes are no real
problem). The only problem I see is with JS, where are ask and get answers
e.g. YN.


>
> The Javascript dependency might be broken if we make this be a CMS
> build-time text replacement rather than a runtime/Javascript
> replacement.  So the CMS would detect when the Pootle files change and
> automatically generate new HTML pages from them.  But even then we
> still would need some runtime integration of strings, specifically on
> the download page where language and OS are determined at runtime
> based on browser request headers.
>
I would consider not to use cms, because we basically dont need it.

rgds
jan I.

>
> -Rob
>
> > If we use json objects, then pootle becomes an elegant tool for
> > translation, because it knows how to handle xml, and if we want  to stay
> > with po files its about 1 day work in genLang.
> >
> > A number of top companies (incl. the one I used to work for) do it like
> > this, they of course then hire a translator to translate the json
> objects.
> >
> > Splitting functionality and text is the key, when thats done the rest is
> > trvial work.
> >
> > This will of course make cms a bit top kill, but I can live with that :-)
> >
>
>
>
>
> > rgds
> > jan I.
> >
> >
> >>
> >> Regards,
> >>
> >> -Rob
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
> >> For additional commands, e-mail: dev-help@openoffice.apache.org
> >>
> >>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
> For additional commands, e-mail: dev-help@openoffice.apache.org
>
>

Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by "Mr. Phan Anh" <pp...@gmail.com>.
1.* *I was so excited when I have just read your email about the html
files.I will have to do a lot of works for the file, but I will now make a
right away translation with the homepage.
2. I will send back to you the file of the main page but I wondered:
 How long will you "push" that reedited page to the official website?


On Sat, Aug 24, 2013 at 2:54 AM, Rob Weir <ro...@apache.org> wrote:

> On Fri, Aug 23, 2013 at 3:18 PM, Mr. Phan Anh <pp...@gmail.com> wrote:
> > 1. I dont understand at all the content (sorry for my retard mind) but I
> > would like to say just one thing.
> > 2. That is at the website interface of OO, there is still the
> announcement
> > of the previous translator group (Vietnamese). They wrote in it about the
> > MOST project.
> > What is it?
> > It is a group that is now maintaining the translation of Vietnamese
> > Localization for Libre.
> >
> > Since the changing maintainer from Oracle to Apace, and now, is Apache
> Open
> > Office, I think I will have to reedit that paragraph.
> >
> > Just a paragraph that displays in the front page of OO for Vietnamese.
> >
> > But I dont know much about web stuff.
> >
> > I would like to ask you guys for helping me to translate it now.
> > Because, letting the name of a team (now translating for Libre) is a
> > disaster.
> >
>
> The source files for the Vietnamese website are here:
>
> https://svn.apache.org/repos/asf/openoffice/ooo-site/trunk/content/vi/
>
> If you can edit the main page:
>
>
> https://svn.apache.org/repos/asf/openoffice/ooo-site/trunk/content/vi/index.html
>
> Then send me the new page and I can check it in.
>
> Another way is to use the Apache CMS to generate a patch
> automatically.   You can read about that here:
>
> http://openoffice.apache.org/developer-faqs.html#im_not_a_committer
>
> Regards,
>
> -Rob
>
>
> > So please give me instruction to do that.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: l10n-unsubscribe@openoffice.apache.org
> For additional commands, e-mail: l10n-help@openoffice.apache.org
>
>

Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by "Mr. Phan Anh" <pp...@gmail.com>.
I also would like to ask you and the other translator that: I would like to
get the web interface in English.
You have given me the Vi, but I also want to have English file for making
comparison.
Thank you.
Please answer this email as soon as you can.


On Sat, Aug 24, 2013 at 2:54 AM, Rob Weir <ro...@apache.org> wrote:

> On Fri, Aug 23, 2013 at 3:18 PM, Mr. Phan Anh <pp...@gmail.com> wrote:
> > 1. I dont understand at all the content (sorry for my retard mind) but I
> > would like to say just one thing.
> > 2. That is at the website interface of OO, there is still the
> announcement
> > of the previous translator group (Vietnamese). They wrote in it about the
> > MOST project.
> > What is it?
> > It is a group that is now maintaining the translation of Vietnamese
> > Localization for Libre.
> >
> > Since the changing maintainer from Oracle to Apace, and now, is Apache
> Open
> > Office, I think I will have to reedit that paragraph.
> >
> > Just a paragraph that displays in the front page of OO for Vietnamese.
> >
> > But I dont know much about web stuff.
> >
> > I would like to ask you guys for helping me to translate it now.
> > Because, letting the name of a team (now translating for Libre) is a
> > disaster.
> >
>
> The source files for the Vietnamese website are here:
>
> https://svn.apache.org/repos/asf/openoffice/ooo-site/trunk/content/vi/
>
> If you can edit the main page:
>
>
> https://svn.apache.org/repos/asf/openoffice/ooo-site/trunk/content/vi/index.html
>
> Then send me the new page and I can check it in.
>
> Another way is to use the Apache CMS to generate a patch
> automatically.   You can read about that here:
>
> http://openoffice.apache.org/developer-faqs.html#im_not_a_committer
>
> Regards,
>
> -Rob
>
>
> > So please give me instruction to do that.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: l10n-unsubscribe@openoffice.apache.org
> For additional commands, e-mail: l10n-help@openoffice.apache.org
>
>

Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by Rob Weir <ro...@apache.org>.
On Fri, Aug 23, 2013 at 3:18 PM, Mr. Phan Anh <pp...@gmail.com> wrote:
> 1. I dont understand at all the content (sorry for my retard mind) but I
> would like to say just one thing.
> 2. That is at the website interface of OO, there is still the announcement
> of the previous translator group (Vietnamese). They wrote in it about the
> MOST project.
> What is it?
> It is a group that is now maintaining the translation of Vietnamese
> Localization for Libre.
>
> Since the changing maintainer from Oracle to Apace, and now, is Apache Open
> Office, I think I will have to reedit that paragraph.
>
> Just a paragraph that displays in the front page of OO for Vietnamese.
>
> But I dont know much about web stuff.
>
> I would like to ask you guys for helping me to translate it now.
> Because, letting the name of a team (now translating for Libre) is a
> disaster.
>

The source files for the Vietnamese website are here:

https://svn.apache.org/repos/asf/openoffice/ooo-site/trunk/content/vi/

If you can edit the main page:

https://svn.apache.org/repos/asf/openoffice/ooo-site/trunk/content/vi/index.html

Then send me the new page and I can check it in.

Another way is to use the Apache CMS to generate a patch
automatically.   You can read about that here:

http://openoffice.apache.org/developer-faqs.html#im_not_a_committer

Regards,

-Rob


> So please give me instruction to do that.

---------------------------------------------------------------------
To unsubscribe, e-mail: l10n-unsubscribe@openoffice.apache.org
For additional commands, e-mail: l10n-help@openoffice.apache.org


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by "Mr. Phan Anh" <pp...@gmail.com>.
1. I dont understand at all the content (sorry for my retard mind) but I
would like to say just one thing.
2. That is at the website interface of OO, there is still the announcement
of the previous translator group (Vietnamese). They wrote in it about the
MOST project.
What is it?
It is a group that is now maintaining the translation of Vietnamese
Localization for Libre.

Since the changing maintainer from Oracle to Apace, and now, is Apache Open
Office, I think I will have to reedit that paragraph.

Just a paragraph that displays in the front page of OO for Vietnamese.

But I dont know much about web stuff.

I would like to ask you guys for helping me to translate it now.
Because, letting the name of a team (now translating for Libre) is a
disaster.

So please give me instruction to do that.

Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by janI <ja...@apache.org>.
On 23 August 2013 21:11, Rob Weir <ro...@apache.org> wrote:

> On Fri, Aug 23, 2013 at 12:21 PM, janI <ja...@apache.org> wrote:
> > On 23 August 2013 17:58, Rob Weir <ro...@apache.org> wrote:
> >
> >> (Responses to dev@openoffice.apache.org, please)
> >>
> >> Obviously our website is quite large.  Google reports 21207 pages
> >> indexed in the www subdomain, and a further 48075 pages in the wiki
> >> subdomain.   But for purpose of this post, when I talk about the "home
> >> page" I'm talking about the contents of our main index.html and the
> >> most commonly visited pages directly linked to it, e.g., the
> >> why/download/product/get-involved, etc. pages.
> >>
> >> This core homepage content amounts to around 25 pages.
> >>
> >> Today this content is scattered around the content tree.  Some of it
> >> is in the root.  Some of it in /why and /download directories.  Some
> >> of it is template-related and is in /templates rather than in
> >> /content.
> >>
> >> As a test I tried to create my own NL page, in the fictitious "xx"
> >> locale.  You can see it here:  http://www.openoffice.org/xx/
> >>
> >> It is not working correctly, but it already required a lot of
> >> non-trivial hacking:
> >>
> >> 1) I had to hunt around and guess which files to copy.  Do I copy
> >> scripts, images and CSS, or just content pages?   Some of the
> >> directories had out-dated content that was not linked to my anyone.
> >> It was hard to figure out what the minimum amount of content needed
> >> was, and where it was located.
> >>
> >> 2) The main index.html file had to be edited to refer to CSS in the
> >> root, rather than current directory
> >>
> >> 3)  Download page is missed up, missing CSS and/or scripts.
> >> Presumably I need to copy something into the xx/download dir, or edit
> >> scripts to make them refer /download off the root.
> >>
> >> 4) The /xx/why pages are not showing the right side navigation now.  I
> >> must have missed something there as well.
> >>
> >> Of course, I could figure the above out eventually.  It just requires
> >> some time and effort and trial and error.  But none of this is
> >> documented, and even if it were this is a fragile approach and
> >> probably beyond th web development skills of a typical translator.
> >>
> >> But we do know this has been done for some languages.  They got it to
> >> work.  The German page is a good example:
> >>
> >> http://www.openoffice.org/de/
> >>
> >> Now this looks good, but it is still a messy thing from a maintenance
> >> perspective.  If we make structural changes to the main English page,
> >> then those changes need to be manually merged into to every NL page.
> >>
> >> What can we do to improve this?
> >>
> >> Here's my idea:
> >>
> >> 1) What if we refactored the home page so it was all self-contained
> >> into these directories:   /scripts,  /styles,  /images and /en/?
> >>
> >> 2) Make the /en directory be pure content.  Only the stuff that needs
> >> to be translated.  It loads everything else, scripts, images, etc.,
> >> via URLs relative to the root, e.g.., in /scripts, /styles, etc.
> >>
> >> 3) Reduce or eliminate any embedded Javascript within pages.  For
> >> example, refactor the code in download/index.html so it is external
> >> and depends on JSON resource files for translated strings.  Aim so
> >> translators never need to touch script.
> >>
> >> 4) Ultimate goal is for someone to be able to jump start a new NL home
> >> page by simply requesting an svn copy of the /en directory, and then
> >> editing the resulting files.  No one should ever need to do what I'm
> >> doing with the "xx" pages.
> >>
> >> 5) Maintenance is far easier.  Most things like changing the scripts,
> >> is done in one place only.  But even changes to the HTML are easier.
> >> Since we then have a common branch point via the svn copy, when
> >> structural changes are added to the main /en HTML, these can be merged
> >> in more elegantly to the translated versions, using Subversion.
> >>
> >> 6) Via Apache redirects we can ensure that the default call to
> >> www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
> >> detection and send requests automatically to the appropriate NL home
> >> page.
> >>
> >> A variation on the above would be to use Pootle, rather than svn
> >> copy/merge to maintain the translations.  But that would require the
> >> same refactoring work to enable it.  And it would require further
> >> investigation to identify a way of extracting and merging translation
> >> strings in MDText files as well as (X)HTML files.
> >>
> >> This is obviously more than a one-person task.  So I'd be interested
> >> in hearing what you think in general about this approach, whether
> >> there is a simpler alternative I've missed, and whether this is
> >> something you'd be interested in helping with.
> >>
> >
> > I like a lot of your ideas, let me add my own experience.
> >
>
> Thanks.
>
> > If the our pages do not contain text, but that is totally outsourced in
> one
> > or more json objects, then translation becomes easy, and the pages
> themself
> > stay simple. when the url is called without arguments the "en-json" is
> > used, and if called with lang="xx" "xx-json" is used.
> >
>
> I like the idea of content/code separation.  We certainly do this is
> the code, for example.  But two challenges to taking this approach all
> the way with the  website.
>
> 1) If we do JSON everywhere then we have a Javscript dependency
> everywhere.  This has an impact for visibility of the pages to search
> engines, but there are workarounds.  But it may be a bigger issue for
> users who block Javascript.
>
> No we would do that solely on the server side, it would not be a good idea
to have JS retrieve the json objects.

We could eg. use php, that retrieved to correct json object, and
transmitted a finished page.


> 2) There may be cases where a translation requires direct access to
> the HTML or CSS.  For example, I think the Tamil translation needed
> access to specify a specific font.  And for some languages they might
> need to set text direction to RTL.   These kinds of things make almost
> any approach more complicated.
>

Look at e.g. our mwiki that handles those details all on server side.

And just as a suggestion, if we were to use wordpress, things like fonts
would be solved. WP also have a possibility (not json) for multi language,
which I could easy adopt in genLang (for translation).


>
> So the question we need to answer is how far we take this?   I think
> we have some examples where the code is so intertwined with the text
> that translation becomes very hard and risky.  For example, the
> generation of the "boxes" on the download page.   But then we have
> some other pages, especially the MDText pages, where I would be
> comfortable handing it directly to a translator and expect they could
> edit it without breaking anything.
>
We can always find examples where it becomes hard, but typically you can
reformulate the problem so it fits in a standard (boxes are no real
problem). The only problem I see is with JS, where are ask and get answers
e.g. YN.


>
> The Javascript dependency might be broken if we make this be a CMS
> build-time text replacement rather than a runtime/Javascript
> replacement.  So the CMS would detect when the Pootle files change and
> automatically generate new HTML pages from them.  But even then we
> still would need some runtime integration of strings, specifically on
> the download page where language and OS are determined at runtime
> based on browser request headers.
>
I would consider not to use cms, because we basically dont need it.

rgds
jan I.

>
> -Rob
>
> > If we use json objects, then pootle becomes an elegant tool for
> > translation, because it knows how to handle xml, and if we want  to stay
> > with po files its about 1 day work in genLang.
> >
> > A number of top companies (incl. the one I used to work for) do it like
> > this, they of course then hire a translator to translate the json
> objects.
> >
> > Splitting functionality and text is the key, when thats done the rest is
> > trvial work.
> >
> > This will of course make cms a bit top kill, but I can live with that :-)
> >
>
>
>
>
> > rgds
> > jan I.
> >
> >
> >>
> >> Regards,
> >>
> >> -Rob
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
> >> For additional commands, e-mail: dev-help@openoffice.apache.org
> >>
> >>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
> For additional commands, e-mail: dev-help@openoffice.apache.org
>
>

Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by Rob Weir <ro...@apache.org>.
On Fri, Aug 23, 2013 at 12:21 PM, janI <ja...@apache.org> wrote:
> On 23 August 2013 17:58, Rob Weir <ro...@apache.org> wrote:
>
>> (Responses to dev@openoffice.apache.org, please)
>>
>> Obviously our website is quite large.  Google reports 21207 pages
>> indexed in the www subdomain, and a further 48075 pages in the wiki
>> subdomain.   But for purpose of this post, when I talk about the "home
>> page" I'm talking about the contents of our main index.html and the
>> most commonly visited pages directly linked to it, e.g., the
>> why/download/product/get-involved, etc. pages.
>>
>> This core homepage content amounts to around 25 pages.
>>
>> Today this content is scattered around the content tree.  Some of it
>> is in the root.  Some of it in /why and /download directories.  Some
>> of it is template-related and is in /templates rather than in
>> /content.
>>
>> As a test I tried to create my own NL page, in the fictitious "xx"
>> locale.  You can see it here:  http://www.openoffice.org/xx/
>>
>> It is not working correctly, but it already required a lot of
>> non-trivial hacking:
>>
>> 1) I had to hunt around and guess which files to copy.  Do I copy
>> scripts, images and CSS, or just content pages?   Some of the
>> directories had out-dated content that was not linked to my anyone.
>> It was hard to figure out what the minimum amount of content needed
>> was, and where it was located.
>>
>> 2) The main index.html file had to be edited to refer to CSS in the
>> root, rather than current directory
>>
>> 3)  Download page is missed up, missing CSS and/or scripts.
>> Presumably I need to copy something into the xx/download dir, or edit
>> scripts to make them refer /download off the root.
>>
>> 4) The /xx/why pages are not showing the right side navigation now.  I
>> must have missed something there as well.
>>
>> Of course, I could figure the above out eventually.  It just requires
>> some time and effort and trial and error.  But none of this is
>> documented, and even if it were this is a fragile approach and
>> probably beyond th web development skills of a typical translator.
>>
>> But we do know this has been done for some languages.  They got it to
>> work.  The German page is a good example:
>>
>> http://www.openoffice.org/de/
>>
>> Now this looks good, but it is still a messy thing from a maintenance
>> perspective.  If we make structural changes to the main English page,
>> then those changes need to be manually merged into to every NL page.
>>
>> What can we do to improve this?
>>
>> Here's my idea:
>>
>> 1) What if we refactored the home page so it was all self-contained
>> into these directories:   /scripts,  /styles,  /images and /en/?
>>
>> 2) Make the /en directory be pure content.  Only the stuff that needs
>> to be translated.  It loads everything else, scripts, images, etc.,
>> via URLs relative to the root, e.g.., in /scripts, /styles, etc.
>>
>> 3) Reduce or eliminate any embedded Javascript within pages.  For
>> example, refactor the code in download/index.html so it is external
>> and depends on JSON resource files for translated strings.  Aim so
>> translators never need to touch script.
>>
>> 4) Ultimate goal is for someone to be able to jump start a new NL home
>> page by simply requesting an svn copy of the /en directory, and then
>> editing the resulting files.  No one should ever need to do what I'm
>> doing with the "xx" pages.
>>
>> 5) Maintenance is far easier.  Most things like changing the scripts,
>> is done in one place only.  But even changes to the HTML are easier.
>> Since we then have a common branch point via the svn copy, when
>> structural changes are added to the main /en HTML, these can be merged
>> in more elegantly to the translated versions, using Subversion.
>>
>> 6) Via Apache redirects we can ensure that the default call to
>> www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
>> detection and send requests automatically to the appropriate NL home
>> page.
>>
>> A variation on the above would be to use Pootle, rather than svn
>> copy/merge to maintain the translations.  But that would require the
>> same refactoring work to enable it.  And it would require further
>> investigation to identify a way of extracting and merging translation
>> strings in MDText files as well as (X)HTML files.
>>
>> This is obviously more than a one-person task.  So I'd be interested
>> in hearing what you think in general about this approach, whether
>> there is a simpler alternative I've missed, and whether this is
>> something you'd be interested in helping with.
>>
>
> I like a lot of your ideas, let me add my own experience.
>

Thanks.

> If the our pages do not contain text, but that is totally outsourced in one
> or more json objects, then translation becomes easy, and the pages themself
> stay simple. when the url is called without arguments the "en-json" is
> used, and if called with lang="xx" "xx-json" is used.
>

I like the idea of content/code separation.  We certainly do this is
the code, for example.  But two challenges to taking this approach all
the way with the  website.

1) If we do JSON everywhere then we have a Javscript dependency
everywhere.  This has an impact for visibility of the pages to search
engines, but there are workarounds.  But it may be a bigger issue for
users who block Javascript.

2) There may be cases where a translation requires direct access to
the HTML or CSS.  For example, I think the Tamil translation needed
access to specify a specific font.  And for some languages they might
need to set text direction to RTL.   These kinds of things make almost
any approach more complicated.

So the question we need to answer is how far we take this?   I think
we have some examples where the code is so intertwined with the text
that translation becomes very hard and risky.  For example, the
generation of the "boxes" on the download page.   But then we have
some other pages, especially the MDText pages, where I would be
comfortable handing it directly to a translator and expect they could
edit it without breaking anything.

The Javascript dependency might be broken if we make this be a CMS
build-time text replacement rather than a runtime/Javascript
replacement.  So the CMS would detect when the Pootle files change and
automatically generate new HTML pages from them.  But even then we
still would need some runtime integration of strings, specifically on
the download page where language and OS are determined at runtime
based on browser request headers.

-Rob

> If we use json objects, then pootle becomes an elegant tool for
> translation, because it knows how to handle xml, and if we want  to stay
> with po files its about 1 day work in genLang.
>
> A number of top companies (incl. the one I used to work for) do it like
> this, they of course then hire a translator to translate the json objects.
>
> Splitting functionality and text is the key, when thats done the rest is
> trvial work.
>
> This will of course make cms a bit top kill, but I can live with that :-)
>




> rgds
> jan I.
>
>
>>
>> Regards,
>>
>> -Rob
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
>> For additional commands, e-mail: dev-help@openoffice.apache.org
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: l10n-unsubscribe@openoffice.apache.org
For additional commands, e-mail: l10n-help@openoffice.apache.org


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by Rob Weir <ro...@apache.org>.
On Fri, Aug 23, 2013 at 12:21 PM, janI <ja...@apache.org> wrote:
> On 23 August 2013 17:58, Rob Weir <ro...@apache.org> wrote:
>
>> (Responses to dev@openoffice.apache.org, please)
>>
>> Obviously our website is quite large.  Google reports 21207 pages
>> indexed in the www subdomain, and a further 48075 pages in the wiki
>> subdomain.   But for purpose of this post, when I talk about the "home
>> page" I'm talking about the contents of our main index.html and the
>> most commonly visited pages directly linked to it, e.g., the
>> why/download/product/get-involved, etc. pages.
>>
>> This core homepage content amounts to around 25 pages.
>>
>> Today this content is scattered around the content tree.  Some of it
>> is in the root.  Some of it in /why and /download directories.  Some
>> of it is template-related and is in /templates rather than in
>> /content.
>>
>> As a test I tried to create my own NL page, in the fictitious "xx"
>> locale.  You can see it here:  http://www.openoffice.org/xx/
>>
>> It is not working correctly, but it already required a lot of
>> non-trivial hacking:
>>
>> 1) I had to hunt around and guess which files to copy.  Do I copy
>> scripts, images and CSS, or just content pages?   Some of the
>> directories had out-dated content that was not linked to my anyone.
>> It was hard to figure out what the minimum amount of content needed
>> was, and where it was located.
>>
>> 2) The main index.html file had to be edited to refer to CSS in the
>> root, rather than current directory
>>
>> 3)  Download page is missed up, missing CSS and/or scripts.
>> Presumably I need to copy something into the xx/download dir, or edit
>> scripts to make them refer /download off the root.
>>
>> 4) The /xx/why pages are not showing the right side navigation now.  I
>> must have missed something there as well.
>>
>> Of course, I could figure the above out eventually.  It just requires
>> some time and effort and trial and error.  But none of this is
>> documented, and even if it were this is a fragile approach and
>> probably beyond th web development skills of a typical translator.
>>
>> But we do know this has been done for some languages.  They got it to
>> work.  The German page is a good example:
>>
>> http://www.openoffice.org/de/
>>
>> Now this looks good, but it is still a messy thing from a maintenance
>> perspective.  If we make structural changes to the main English page,
>> then those changes need to be manually merged into to every NL page.
>>
>> What can we do to improve this?
>>
>> Here's my idea:
>>
>> 1) What if we refactored the home page so it was all self-contained
>> into these directories:   /scripts,  /styles,  /images and /en/?
>>
>> 2) Make the /en directory be pure content.  Only the stuff that needs
>> to be translated.  It loads everything else, scripts, images, etc.,
>> via URLs relative to the root, e.g.., in /scripts, /styles, etc.
>>
>> 3) Reduce or eliminate any embedded Javascript within pages.  For
>> example, refactor the code in download/index.html so it is external
>> and depends on JSON resource files for translated strings.  Aim so
>> translators never need to touch script.
>>
>> 4) Ultimate goal is for someone to be able to jump start a new NL home
>> page by simply requesting an svn copy of the /en directory, and then
>> editing the resulting files.  No one should ever need to do what I'm
>> doing with the "xx" pages.
>>
>> 5) Maintenance is far easier.  Most things like changing the scripts,
>> is done in one place only.  But even changes to the HTML are easier.
>> Since we then have a common branch point via the svn copy, when
>> structural changes are added to the main /en HTML, these can be merged
>> in more elegantly to the translated versions, using Subversion.
>>
>> 6) Via Apache redirects we can ensure that the default call to
>> www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
>> detection and send requests automatically to the appropriate NL home
>> page.
>>
>> A variation on the above would be to use Pootle, rather than svn
>> copy/merge to maintain the translations.  But that would require the
>> same refactoring work to enable it.  And it would require further
>> investigation to identify a way of extracting and merging translation
>> strings in MDText files as well as (X)HTML files.
>>
>> This is obviously more than a one-person task.  So I'd be interested
>> in hearing what you think in general about this approach, whether
>> there is a simpler alternative I've missed, and whether this is
>> something you'd be interested in helping with.
>>
>
> I like a lot of your ideas, let me add my own experience.
>

Thanks.

> If the our pages do not contain text, but that is totally outsourced in one
> or more json objects, then translation becomes easy, and the pages themself
> stay simple. when the url is called without arguments the "en-json" is
> used, and if called with lang="xx" "xx-json" is used.
>

I like the idea of content/code separation.  We certainly do this is
the code, for example.  But two challenges to taking this approach all
the way with the  website.

1) If we do JSON everywhere then we have a Javscript dependency
everywhere.  This has an impact for visibility of the pages to search
engines, but there are workarounds.  But it may be a bigger issue for
users who block Javascript.

2) There may be cases where a translation requires direct access to
the HTML or CSS.  For example, I think the Tamil translation needed
access to specify a specific font.  And for some languages they might
need to set text direction to RTL.   These kinds of things make almost
any approach more complicated.

So the question we need to answer is how far we take this?   I think
we have some examples where the code is so intertwined with the text
that translation becomes very hard and risky.  For example, the
generation of the "boxes" on the download page.   But then we have
some other pages, especially the MDText pages, where I would be
comfortable handing it directly to a translator and expect they could
edit it without breaking anything.

The Javascript dependency might be broken if we make this be a CMS
build-time text replacement rather than a runtime/Javascript
replacement.  So the CMS would detect when the Pootle files change and
automatically generate new HTML pages from them.  But even then we
still would need some runtime integration of strings, specifically on
the download page where language and OS are determined at runtime
based on browser request headers.

-Rob

> If we use json objects, then pootle becomes an elegant tool for
> translation, because it knows how to handle xml, and if we want  to stay
> with po files its about 1 day work in genLang.
>
> A number of top companies (incl. the one I used to work for) do it like
> this, they of course then hire a translator to translate the json objects.
>
> Splitting functionality and text is the key, when thats done the rest is
> trvial work.
>
> This will of course make cms a bit top kill, but I can live with that :-)
>




> rgds
> jan I.
>
>
>>
>> Regards,
>>
>> -Rob
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
>> For additional commands, e-mail: dev-help@openoffice.apache.org
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
For additional commands, e-mail: dev-help@openoffice.apache.org


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by janI <ja...@apache.org>.
On 23 August 2013 17:58, Rob Weir <ro...@apache.org> wrote:

> (Responses to dev@openoffice.apache.org, please)
>
> Obviously our website is quite large.  Google reports 21207 pages
> indexed in the www subdomain, and a further 48075 pages in the wiki
> subdomain.   But for purpose of this post, when I talk about the "home
> page" I'm talking about the contents of our main index.html and the
> most commonly visited pages directly linked to it, e.g., the
> why/download/product/get-involved, etc. pages.
>
> This core homepage content amounts to around 25 pages.
>
> Today this content is scattered around the content tree.  Some of it
> is in the root.  Some of it in /why and /download directories.  Some
> of it is template-related and is in /templates rather than in
> /content.
>
> As a test I tried to create my own NL page, in the fictitious "xx"
> locale.  You can see it here:  http://www.openoffice.org/xx/
>
> It is not working correctly, but it already required a lot of
> non-trivial hacking:
>
> 1) I had to hunt around and guess which files to copy.  Do I copy
> scripts, images and CSS, or just content pages?   Some of the
> directories had out-dated content that was not linked to my anyone.
> It was hard to figure out what the minimum amount of content needed
> was, and where it was located.
>
> 2) The main index.html file had to be edited to refer to CSS in the
> root, rather than current directory
>
> 3)  Download page is missed up, missing CSS and/or scripts.
> Presumably I need to copy something into the xx/download dir, or edit
> scripts to make them refer /download off the root.
>
> 4) The /xx/why pages are not showing the right side navigation now.  I
> must have missed something there as well.
>
> Of course, I could figure the above out eventually.  It just requires
> some time and effort and trial and error.  But none of this is
> documented, and even if it were this is a fragile approach and
> probably beyond th web development skills of a typical translator.
>
> But we do know this has been done for some languages.  They got it to
> work.  The German page is a good example:
>
> http://www.openoffice.org/de/
>
> Now this looks good, but it is still a messy thing from a maintenance
> perspective.  If we make structural changes to the main English page,
> then those changes need to be manually merged into to every NL page.
>
> What can we do to improve this?
>
> Here's my idea:
>
> 1) What if we refactored the home page so it was all self-contained
> into these directories:   /scripts,  /styles,  /images and /en/?
>
> 2) Make the /en directory be pure content.  Only the stuff that needs
> to be translated.  It loads everything else, scripts, images, etc.,
> via URLs relative to the root, e.g.., in /scripts, /styles, etc.
>
> 3) Reduce or eliminate any embedded Javascript within pages.  For
> example, refactor the code in download/index.html so it is external
> and depends on JSON resource files for translated strings.  Aim so
> translators never need to touch script.
>
> 4) Ultimate goal is for someone to be able to jump start a new NL home
> page by simply requesting an svn copy of the /en directory, and then
> editing the resulting files.  No one should ever need to do what I'm
> doing with the "xx" pages.
>
> 5) Maintenance is far easier.  Most things like changing the scripts,
> is done in one place only.  But even changes to the HTML are easier.
> Since we then have a common branch point via the svn copy, when
> structural changes are added to the main /en HTML, these can be merged
> in more elegantly to the translated versions, using Subversion.
>
> 6) Via Apache redirects we can ensure that the default call to
> www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
> detection and send requests automatically to the appropriate NL home
> page.
>
> A variation on the above would be to use Pootle, rather than svn
> copy/merge to maintain the translations.  But that would require the
> same refactoring work to enable it.  And it would require further
> investigation to identify a way of extracting and merging translation
> strings in MDText files as well as (X)HTML files.
>
> This is obviously more than a one-person task.  So I'd be interested
> in hearing what you think in general about this approach, whether
> there is a simpler alternative I've missed, and whether this is
> something you'd be interested in helping with.
>

I like a lot of your ideas, let me add my own experience.

If the our pages do not contain text, but that is totally outsourced in one
or more json objects, then translation becomes easy, and the pages themself
stay simple. when the url is called without arguments the "en-json" is
used, and if called with lang="xx" "xx-json" is used.

If we use json objects, then pootle becomes an elegant tool for
translation, because it knows how to handle xml, and if we want  to stay
with po files its about 1 day work in genLang.

A number of top companies (incl. the one I used to work for) do it like
this, they of course then hire a translator to translate the json objects.

Splitting functionality and text is the key, when thats done the rest is
trvial work.

This will of course make cms a bit top kill, but I can live with that :-)

rgds
jan I.


>
> Regards,
>
> -Rob
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
> For additional commands, e-mail: dev-help@openoffice.apache.org
>
>

Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by janI <ja...@apache.org>.
On 23 August 2013 17:58, Rob Weir <ro...@apache.org> wrote:

> (Responses to dev@openoffice.apache.org, please)
>
> Obviously our website is quite large.  Google reports 21207 pages
> indexed in the www subdomain, and a further 48075 pages in the wiki
> subdomain.   But for purpose of this post, when I talk about the "home
> page" I'm talking about the contents of our main index.html and the
> most commonly visited pages directly linked to it, e.g., the
> why/download/product/get-involved, etc. pages.
>
> This core homepage content amounts to around 25 pages.
>
> Today this content is scattered around the content tree.  Some of it
> is in the root.  Some of it in /why and /download directories.  Some
> of it is template-related and is in /templates rather than in
> /content.
>
> As a test I tried to create my own NL page, in the fictitious "xx"
> locale.  You can see it here:  http://www.openoffice.org/xx/
>
> It is not working correctly, but it already required a lot of
> non-trivial hacking:
>
> 1) I had to hunt around and guess which files to copy.  Do I copy
> scripts, images and CSS, or just content pages?   Some of the
> directories had out-dated content that was not linked to my anyone.
> It was hard to figure out what the minimum amount of content needed
> was, and where it was located.
>
> 2) The main index.html file had to be edited to refer to CSS in the
> root, rather than current directory
>
> 3)  Download page is missed up, missing CSS and/or scripts.
> Presumably I need to copy something into the xx/download dir, or edit
> scripts to make them refer /download off the root.
>
> 4) The /xx/why pages are not showing the right side navigation now.  I
> must have missed something there as well.
>
> Of course, I could figure the above out eventually.  It just requires
> some time and effort and trial and error.  But none of this is
> documented, and even if it were this is a fragile approach and
> probably beyond th web development skills of a typical translator.
>
> But we do know this has been done for some languages.  They got it to
> work.  The German page is a good example:
>
> http://www.openoffice.org/de/
>
> Now this looks good, but it is still a messy thing from a maintenance
> perspective.  If we make structural changes to the main English page,
> then those changes need to be manually merged into to every NL page.
>
> What can we do to improve this?
>
> Here's my idea:
>
> 1) What if we refactored the home page so it was all self-contained
> into these directories:   /scripts,  /styles,  /images and /en/?
>
> 2) Make the /en directory be pure content.  Only the stuff that needs
> to be translated.  It loads everything else, scripts, images, etc.,
> via URLs relative to the root, e.g.., in /scripts, /styles, etc.
>
> 3) Reduce or eliminate any embedded Javascript within pages.  For
> example, refactor the code in download/index.html so it is external
> and depends on JSON resource files for translated strings.  Aim so
> translators never need to touch script.
>
> 4) Ultimate goal is for someone to be able to jump start a new NL home
> page by simply requesting an svn copy of the /en directory, and then
> editing the resulting files.  No one should ever need to do what I'm
> doing with the "xx" pages.
>
> 5) Maintenance is far easier.  Most things like changing the scripts,
> is done in one place only.  But even changes to the HTML are easier.
> Since we then have a common branch point via the svn copy, when
> structural changes are added to the main /en HTML, these can be merged
> in more elegantly to the translated versions, using Subversion.
>
> 6) Via Apache redirects we can ensure that the default call to
> www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
> detection and send requests automatically to the appropriate NL home
> page.
>
> A variation on the above would be to use Pootle, rather than svn
> copy/merge to maintain the translations.  But that would require the
> same refactoring work to enable it.  And it would require further
> investigation to identify a way of extracting and merging translation
> strings in MDText files as well as (X)HTML files.
>
> This is obviously more than a one-person task.  So I'd be interested
> in hearing what you think in general about this approach, whether
> there is a simpler alternative I've missed, and whether this is
> something you'd be interested in helping with.
>

I like a lot of your ideas, let me add my own experience.

If the our pages do not contain text, but that is totally outsourced in one
or more json objects, then translation becomes easy, and the pages themself
stay simple. when the url is called without arguments the "en-json" is
used, and if called with lang="xx" "xx-json" is used.

If we use json objects, then pootle becomes an elegant tool for
translation, because it knows how to handle xml, and if we want  to stay
with po files its about 1 day work in genLang.

A number of top companies (incl. the one I used to work for) do it like
this, they of course then hire a translator to translate the json objects.

Splitting functionality and text is the key, when thats done the rest is
trvial work.

This will of course make cms a bit top kill, but I can live with that :-)

rgds
jan I.


>
> Regards,
>
> -Rob
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
> For additional commands, e-mail: dev-help@openoffice.apache.org
>
>

Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by Maciej Jaros <eg...@wp.pl>.
Starting re-factoring from en is a good idea. And automating translation 
of the various pages is even greater, but I think we should prepare and 
restructure content for this first (I don't mean only technical 
restructuring).

I think the home page could be greatly simplified to contain much less 
text while being even more useful (would be more focused). That would 
also make it very quick&easy to translate and to maintain. Also 
openoffice.apache.org seems largely like a duplicate of 
www.openoffice.org. De-duplication of information and deciding what goes 
where would be great (also great for translation). Did you know for 
example that after de-duplication the gov.uk website it went from 70k to 
only 3k pages! Imagine how much easier it is to maintain it. Would be 
nice if you could get Sara Wachter-Boettcher to help. I've seen her 
presentation on Mobilism about structuring data of companies and she 
seem to have already done things like OpenOffice website(s) needs. Not 
sure if she works pro bono though and (if she doesn't) I don't know if 
AOO has a budget for things like that.

Anyway here's my taking on restructuring data/content.

  * Home page
      o Download link (much like it is already done on the download page).
      o Composition of screenshots of the latest version (not
        necessarily in native language, but would be cool if automated).
        Something like a hand of cards showing the Writer and the Calc
        on the sides and maybe the welcome page in the middle but in the
        bottom layer. Or maybe whole suite showing example documents?
      o On the right there should only be links that are now on the left
        (I want/need links).
      o Below all that I would make 3 boxes (side-by-side) with the
        boxes from the download page (Help Spread the Word, Extensions
        and Dictionaries and Templates).
  * Overview page
      o The link "I want to learn more about OpenOffice" should point here.
      o Content of the main page of "why" seems to be duplicate of the
        main page of "product". I actually like "product" page more.
      o Add link to "why" in "More" submenu of the overview page.
      o So maybe just keep the product page and call it overview.
  * News page
      o The link "I want to stay in touch with OpenOffice" should point
        here.
      o News on the left (would be cool if news could be posted in many
        languages and a single language would get en-news and native news).
      o Blog posts on the right (similar sidebar that is on the right on
        the main page).
  * Get involved page
      o The link "I want to participate in OpenOffice" should point here.
      o Should be a short page.
      o I think I translated this so this is actually already in the
        Pottle - would be great to just use that (maybe with a bit of
        transformation e.g. parsing text URLs into HTML tags).
      o Add information about Pottle itself (or was it there already - I
        don't remember).
  * Menu
      o Overview (as described)
      o Download (as-is) - would be partially a duplicate of new home,
        but I believe it's OK here as it is generated anyway.
      o Support (as-is)
      o News (as described)
      o Get involved (as described)
      o Remove other - here's why:
          + Blog - external site; just keep links on the news page
          + Extend - duplicate of things on the download page
          + Develop - already on the main page and would be on get
            involved page; also it is a de facto external website
          + Focus Areas - remove doesn't seem very interesting for a
            regular user - maybe you could move it to openoffice.apache.org.
          + Native Language - this doesn't seem to be very useful -
            would be useful only if integrated with Pottle (giving
            information on current progress of translation).

Other stuff

  * Language switch - should be automatic and optionally there could be
    a switch above the menu on the right.
  * Search should be bigger (at least a bit wider).
  * Links to an external site should indicate they are external.
    Wikipedia has a quite nice way of doing that and it only requires a
    single CSS rule for all browsers that count.

Translation

  * I think would could use Pottle for basic strings with an addition of
    some transforming scripts.
      o "po" files could e.g. be translated to JSON style objects for
        JavaScript (if needed).
      o to make the site static we could pre-render HTML directly from
        po files treating HTML files as templates (e.g. replace
        "{{Product}}" with it's translation)
      o "templates" would still be standard HTML files and so CMS/SVN
        could still be used to edit what would now be templates
        (whatever CMS you are using - it would just edit different
        things that are shown)
  * Pushing changes
      o you could then add a job to CMS to render page (or pages) - this
        would just run prepared scripts
      o ...or use Jenkins for automatically rendering pages after
        changes in CMS (it could e.g. listen on changes in a certain
        directory of the SVN)
      o Jenkins could also be used to download and transform po files
        from Pottle (don't know if you are using any automation already)
  * Pottle packages (and levels of translation)
      o "Basic" - home page and all links in menu (i.e. everything
        visible on the new home/index page).
      o "Main pages" - translation of all main pages i.e.
          + product/index.html, but not product/writer.html
          + support/index.html - probably divided into sections (i.e.
            title of OpenOffice Documentation and it's content separately)
          + download/index.html (most would be in Basic package; so
            probably only links on the right would need translations -
            might just be a blob of HTML which would make it easy to add
            or remove links for some languages)
      o Subpages - if not translated then the submenu should not be shown
          + "Product subpages"
          + "Why subpages"
          + "Support subpages"

...
OK. This mail is much longer then I planned ;-). I hope someone reads it.

Regards,
Nux.


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by Maciej Jaros <eg...@wp.pl>.
Starting re-factoring from en is a good idea. And automating translation 
of the various pages is even greater, but I think we should prepare and 
restructure content for this first (I don't mean only technical 
restructuring).

I think the home page could be greatly simplified to contain much less 
text while being even more useful (would be more focused). That would 
also make it very quick&easy to translate and to maintain. Also 
openoffice.apache.org seems largely like a duplicate of 
www.openoffice.org. De-duplication of information and deciding what goes 
where would be great (also great for translation). Did you know for 
example that after de-duplication the gov.uk website it went from 70k to 
only 3k pages! Imagine how much easier it is to maintain it. Would be 
nice if you could get Sara Wachter-Boettcher to help. I've seen her 
presentation on Mobilism about structuring data of companies and she 
seem to have already done things like OpenOffice website(s) needs. Not 
sure if she works pro bono though and (if she doesn't) I don't know if 
AOO has a budget for things like that.

Anyway here's my taking on restructuring data/content.

  * Home page
      o Download link (much like it is already done on the download page).
      o Composition of screenshots of the latest version (not
        necessarily in native language, but would be cool if automated).
        Something like a hand of cards showing the Writer and the Calc
        on the sides and maybe the welcome page in the middle but in the
        bottom layer. Or maybe whole suite showing example documents?
      o On the right there should only be links that are now on the left
        (I want/need links).
      o Below all that I would make 3 boxes (side-by-side) with the
        boxes from the download page (Help Spread the Word, Extensions
        and Dictionaries and Templates).
  * Overview page
      o The link "I want to learn more about OpenOffice" should point here.
      o Content of the main page of "why" seems to be duplicate of the
        main page of "product". I actually like "product" page more.
      o Add link to "why" in "More" submenu of the overview page.
      o So maybe just keep the product page and call it overview.
  * News page
      o The link "I want to stay in touch with OpenOffice" should point
        here.
      o News on the left (would be cool if news could be posted in many
        languages and a single language would get en-news and native news).
      o Blog posts on the right (similar sidebar that is on the right on
        the main page).
  * Get involved page
      o The link "I want to participate in OpenOffice" should point here.
      o Should be a short page.
      o I think I translated this so this is actually already in the
        Pottle - would be great to just use that (maybe with a bit of
        transformation e.g. parsing text URLs into HTML tags).
      o Add information about Pottle itself (or was it there already - I
        don't remember).
  * Menu
      o Overview (as described)
      o Download (as-is) - would be partially a duplicate of new home,
        but I believe it's OK here as it is generated anyway.
      o Support (as-is)
      o News (as described)
      o Get involved (as described)
      o Remove other - here's why:
          + Blog - external site; just keep links on the news page
          + Extend - duplicate of things on the download page
          + Develop - already on the main page and would be on get
            involved page; also it is a de facto external website
          + Focus Areas - remove doesn't seem very interesting for a
            regular user - maybe you could move it to openoffice.apache.org.
          + Native Language - this doesn't seem to be very useful -
            would be useful only if integrated with Pottle (giving
            information on current progress of translation).

Other stuff

  * Language switch - should be automatic and optionally there could be
    a switch above the menu on the right.
  * Search should be bigger (at least a bit wider).
  * Links to an external site should indicate they are external.
    Wikipedia has a quite nice way of doing that and it only requires a
    single CSS rule for all browsers that count.

Translation

  * I think would could use Pottle for basic strings with an addition of
    some transforming scripts.
      o "po" files could e.g. be translated to JSON style objects for
        JavaScript (if needed).
      o to make the site static we could pre-render HTML directly from
        po files treating HTML files as templates (e.g. replace
        "{{Product}}" with it's translation)
      o "templates" would still be standard HTML files and so CMS/SVN
        could still be used to edit what would now be templates
        (whatever CMS you are using - it would just edit different
        things that are shown)
  * Pushing changes
      o you could then add a job to CMS to render page (or pages) - this
        would just run prepared scripts
      o ...or use Jenkins for automatically rendering pages after
        changes in CMS (it could e.g. listen on changes in a certain
        directory of the SVN)
      o Jenkins could also be used to download and transform po files
        from Pottle (don't know if you are using any automation already)
  * Pottle packages (and levels of translation)
      o "Basic" - home page and all links in menu (i.e. everything
        visible on the new home/index page).
      o "Main pages" - translation of all main pages i.e.
          + product/index.html, but not product/writer.html
          + support/index.html - probably divided into sections (i.e.
            title of OpenOffice Documentation and it's content separately)
          + download/index.html (most would be in Basic package; so
            probably only links on the right would need translations -
            might just be a blob of HTML which would make it easy to add
            or remove links for some languages)
      o Subpages - if not translated then the submenu should not be shown
          + "Product subpages"
          + "Why subpages"
          + "Support subpages"

...
OK. This mail is much longer then I planned ;-). I hope someone reads it.

Regards,
Nux.


Re: Brainstorming: Can we refactor the website to make translation easier?

Posted by "Marcus (OOo)" <ma...@wtnet.de>.
Am 08/23/2013 05:58 PM, schrieb Rob Weir:
> (Responses to dev@openoffice.apache.org, please)
>
> Obviously our website is quite large.  Google reports 21207 pages
> indexed in the www subdomain, and a further 48075 pages in the wiki
> subdomain.   But for purpose of this post, when I talk about the "home
> page" I'm talking about the contents of our main index.html and the
> most commonly visited pages directly linked to it, e.g., the
> why/download/product/get-involved, etc. pages.
>
> This core homepage content amounts to around 25 pages.
>
> Today this content is scattered around the content tree.  Some of it
> is in the root.  Some of it in /why and /download directories.  Some
> of it is template-related and is in /templates rather than in
> /content.
>
> As a test I tried to create my own NL page, in the fictitious "xx"
> locale.  You can see it here:  http://www.openoffice.org/xx/
>
> It is not working correctly, but it already required a lot of
> non-trivial hacking:
>
> 1) I had to hunt around and guess which files to copy.  Do I copy
> scripts, images and CSS, or just content pages?   Some of the
> directories had out-dated content that was not linked to my anyone.
> It was hard to figure out what the minimum amount of content needed
> was, and where it was located.
>
> 2) The main index.html file had to be edited to refer to CSS in the
> root, rather than current directory
>
> 3)  Download page is missed up, missing CSS and/or scripts.
> Presumably I need to copy something into the xx/download dir, or edit
> scripts to make them refer /download off the root.
>
> 4) The /xx/why pages are not showing the right side navigation now.  I
> must have missed something there as well.
>
> Of course, I could figure the above out eventually.  It just requires
> some time and effort and trial and error.  But none of this is
> documented, and even if it were this is a fragile approach and
> probably beyond th web development skills of a typical translator.
>
> But we do know this has been done for some languages.  They got it to
> work.  The German page is a good example:
>
> http://www.openoffice.org/de/
>
> Now this looks good, but it is still a messy thing from a maintenance
> perspective.  If we make structural changes to the main English page,
> then those changes need to be manually merged into to every NL page.
>
> What can we do to improve this?
>
> Here's my idea:
>
> 1) What if we refactored the home page so it was all self-contained
> into these directories:   /scripts,  /styles,  /images and /en/?

Do you mean to centralize all kind of files that are shared? Like button 
pics, download scripting, color definitions?

I thought about this already for the download area as then these files 
are all in a single location. But of course it's also possible to do 
this for the entire wesite.

> 2) Make the /en directory be pure content.  Only the stuff that needs
> to be translated.  It loads everything else, scripts, images, etc.,
> via URLs relative to the root, e.g.., in /scripts, /styles, etc.

Should the "en/" folder have another purpose than just to work as a big 
template?

> 3) Reduce or eliminate any embedded Javascript within pages.  For
> example, refactor the code in download/index.html so it is external
> and depends on JSON resource files for translated strings.  Aim so
> translators never need to touch script.

At least for the download webpage I thought, too, already to separate 
code and text because it makes it easier for other people to use the 
design of the main download webapge for their language.

I've not yet committed anything but the idea is to separate a) HTML 
design, b) JS code and c) translate-able text strings from each other.

However, I put already a Todo note into the Wiki (see the 2nd row from top):

https://cwiki.apache.org/confluence/display/OOOUSERS/Improvements+for+the+download+webpages#Improvementsforthedownloadwebpages-ImmediateConcerns%2CShort%2FMidTermImprovements

> 4) Ultimate goal is for someone to be able to jump start a new NL home
> page by simply requesting an svn copy of the /en directory, and then
> editing the resulting files.  No one should ever need to do what I'm
> doing with the "xx" pages.

Yeah, indeed a hugh work to get to this dream.

> 5) Maintenance is far easier.  Most things like changing the scripts,
> is done in one place only.  But even changes to the HTML are easier.
> Since we then have a common branch point via the svn copy, when
> structural changes are added to the main /en HTML, these can be merged
> in more elegantly to the translated versions, using Subversion.
>
> 6) Via Apache redirects we can ensure that the default call to
> www.openoffice.org/ goes to /en/.  Conceivably we could also do locale
> detection and send requests automatically to the appropriate NL home
> page.
>
> A variation on the above would be to use Pootle, rather than svn
> copy/merge to maintain the translations.  But that would require the
> same refactoring work to enable it.  And it would require further
> investigation to identify a way of extracting and merging translation
> strings in MDText files as well as (X)HTML files.
>
> This is obviously more than a one-person task.  So I'd be interested
> in hearing what you think in general about this approach, whether
> there is a simpler alternative I've missed, and whether this is
> something you'd be interested in helping with.

I think it's no secret when I tell you that this is a great idea from 
the view point of maintenance and to attrack new volunteers for not yet 
known and supported languages.

However, I'm really wondering if this will be a success as it would mean 
nothing less than a complete rebuild of all files on the entire website.

I believe it's better to split this up into some chunks. What's the most 
interesting ansd important part of our website? Start with this, build 
up some skills, knowledge and best pratices and then enroll it more and 
more over the remaining parts - and hopefully with more volunteers. ;-)

My 2 ct.

Marcus

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@openoffice.apache.org
For additional commands, e-mail: dev-help@openoffice.apache.org