Return-Path: X-Original-To: apmail-openoffice-dev-archive@www.apache.org Delivered-To: apmail-openoffice-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id B0AC410319 for ; Fri, 23 Aug 2013 21:30:07 +0000 (UTC) Received: (qmail 64427 invoked by uid 500); 23 Aug 2013 21:30:07 -0000 Delivered-To: apmail-openoffice-dev-archive@openoffice.apache.org Received: (qmail 64362 invoked by uid 500); 23 Aug 2013 21:30:07 -0000 Mailing-List: contact dev-help@openoffice.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@openoffice.apache.org Delivered-To: mailing list dev@openoffice.apache.org Received: (qmail 64354 invoked by uid 99); 23 Aug 2013 21:30:07 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 23 Aug 2013 21:30:07 +0000 X-ASF-Spam-Status: No, hits=2.2 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of kay.schenk@gmail.com designates 209.85.192.171 as permitted sender) Received: from [209.85.192.171] (HELO mail-pd0-f171.google.com) (209.85.192.171) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 23 Aug 2013 21:30:00 +0000 Received: by mail-pd0-f171.google.com with SMTP id g10so1150139pdj.16 for ; Fri, 23 Aug 2013 14:29:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=57eGXmlYvm7SKtr5GohS5Yd/svpoxFx6cYjbyROU8/I=; b=Fmb2tQkRMgpCCz2pvbB/busaQi7mA1alIaVhDBWynh6YBmPtR0b9O47/7qznmxku1D pEKKwo+q5RG0fhFC2zzguRDS6Jxon016oeG+O4WWQhMT+IhNVFNyXb9wQtvJTpsrErQ3 yXRYF520/FFXL2fVuLA9+4gTymnGTfsR5PRHIMgKjHIey36HLZ93NTjc2Uy4Zj7sOpUs cz/ofFNN+4ebQ+GLcVEgR0b/kc2wIMYeC9H/7OiNlzeMsq9I/LqQnBLhuJfR92H04pbs 6b6mZ8OxBU+Boei3Ic7mrYkpnD2S48fHQrLt2dvnrm4Dqpz5rh0YeAEWDa8Prlm4xkG9 f2dQ== MIME-Version: 1.0 X-Received: by 10.68.220.1 with SMTP id ps1mr1864199pbc.30.1377293378742; Fri, 23 Aug 2013 14:29:38 -0700 (PDT) Received: by 10.70.48.225 with HTTP; Fri, 23 Aug 2013 14:29:38 -0700 (PDT) In-Reply-To: References: Date: Fri, 23 Aug 2013 14:29:38 -0700 Message-ID: Subject: Re: Brainstorming: Can we refactor the website to make translation easier? From: Kay Schenk To: devAOO Content-Type: multipart/alternative; boundary=e89a8ff1ca78976eec04e4a41aeb X-Virus-Checked: Checked by ClamAV on apache.org --e89a8ff1ca78976eec04e4a41aeb Content-Type: text/plain; charset=ISO-8859-1 On Fri, Aug 23, 2013 at 8:58 AM, Rob Weir 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 --e89a8ff1ca78976eec04e4a41aeb--