forrest-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sjur Nørstebø Moshagen <sjur.mosha...@kolumbus.fi>
Subject Re: i18n errors, bad downgrading
Date Fri, 12 Mar 2004 11:07:08 GMT
På 12. mar. 2004 kl. 12.31 skrev Juan Jose Pablos:

> Sjur Nørstebø Moshagen wrote:
> <snip how I8n works/>
>
> I think that most of this has been already implemented on httpd, so I 
> do not think that we should be doing it again.

And in Cocoon as well (still need to test this;)

> Before This I think that mostly we need to define the goal. What is 
> the output file name  that you want for static and there URI request 
> for dynamic sites?.
>
> For Apache httpd server to work:
>
> index.html.{locale}  should be fine for static, but if you want to 
> request this uri: localhost:8888/index.html.{locale} This will fail 
> badly mainly because forrest relay on .html as the final extension.

httpd and cocoon (and thus Forrest?) has different conventions for 
adding locale info to filenames, which explains why it fails. Normally 
you would _not_ ask for a file index.html.{locale} or 
index_{locale}.html, the server should take care of serving you the 
right file given the locale info in the request. (on the other hand, it 
can be useful to be _able_ to access a specific localised file in this 
way, at least for debugging purposes.)

> So you could:
>
> 1) Use index.{locale}.html on dynamic sites and create .var filenames 
> with the list of files per directory.

Agree with Upayavira - don't do it.

> 2) Forget Dynamic and only use static

You can't be serious about that? ;)

> 3) Use CLI to run as many times as locales defined on a config file.

That's fine, we just need to agree upon the behaviour of CLI when a 
page is not found for a given locale - what should the output be?

>> One more example - the site I'm working on:
> <snip Example/>
>
> I think that this user case seems very common. ( I hope that you would 
> not expect us to do you homework :-) )

Definitely not;)

What I don't get is that if this scenario is so common (which I also 
believe), why isn't it already in place - I mean, Cocoon has it 
(_still_ needs to be tested, but they're at version 2.1.x, so any major 
problem here should have been discovered and rectified a long time 
ago), and as soon as you have that machinery in place, it should be a 
piece of cake after that. Or is there something fundamental in the 
relationship between Forrest and Cocoon that I don't get?

> But at the moment we are more focus on the "limits of static content 
> creation". :-)

I disagree;) (but I'm a newcomer)

At least the Forrest docs say otherwise;) - see my e-mail from 
yesterday.

>> One question that comes to mind, is: what happens when a page is 
>> _not_  available in the requested locale? Presently Cocoon/Forrest 
>> fails.
>
> This is a bug, and on another mail I told you, that this funcionality 
> was missing.

OK.

> There is an error code for this 406, but I am afraid that the best 
> approach is to show the user any content rather than an error page.

Agree.

>  The fallback file
>> could either be the regular content in the language decided upon by 
>> the  webmaster, or a simple page telling the user that the page/site 
>> is only  available in some specified languages, perhaps with a link 
>> to a page  explaining how to set the languages/locales for a browser.
>
> I would not do that, I would display the content

Probably, but what if the content is totally gibberish to you?

Sjur


Mime
View raw message