You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@lenya.apache.org by Markus Angst <ma...@inventec.ch> on 2012/09/21 19:34:53 UTC

Re: Default language in template publication

Does somebody have an opinion / idea about this?

Thanks!
Markus Angst


On 05.06.2012 20:39, Markus Angst wrote:
> Hi,
> 
> I have two publications A and B where B (child) is a template publication of A
> (parent). I want to change the default language and the display order in the
> languageselector of publication B.
> There seems no official way to do this in the GUI (at least I didn't find it).
> Is it correct to do this directly in publication.xml?
> 
> publication.xml of publication A:
>   ...
>   <languages>
>     <language default="true">de</language>
>     <language>en</language>
>     <language>fr</language>
>     <language>it</language>
>   </languages>
>   ...
> 
> publication.xml of publication B:
>   ...
>   <languages>
>     <language default="true">fr</language>
>     <language>de</language>
>     <language>it</language>
>     <language>en</language>
>   </languages>
>   ...
> 
> The combination of the above configurations creates three problems:
> 
> - The sort order of the languageselector in Publication B is the same as in A.
>   Probably the languageselector always uses an alphabetical sort order?
> 
> - The links of the languageselector are broken
>   - Publication A (working):
>     deutsch:  (default)
>     français: http://<domain>/index_fr.html
>     italiano: http://<domain>/index_it.html
>   - Publication B (not working):
>     deutsch:  http://<domain>/.html
>     français: (default)
>     italiano: http://<domain>/_it.html
>   It seems like the default language of A would somehow be used to generate
>   the URLs in B.
> 
> - All image links are broken in B, although they look exactly the same in A
>   and B.
> 
> 
> Am I overlooking something? Did someone else already experience this problem
> (and has a solution)? Or is this a bug?
> 
> Thanks and best regards
> Markus Angst


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
For additional commands, e-mail: user-help@lenya.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
For additional commands, e-mail: user-help@lenya.apache.org


Re: Default language in template publication

Posted by Markus Angst <ma...@inventec.ch>.
Hi Florent,

Thanks for replying. I have tried to answer your questions; see below.

> I'm not sure to be great help on this subject, but hoping this give you 
> some pointers :
> 
> On 09/21/2012 07:34 PM, Markus Angst wrote:
>> Does somebody have an opinion / idea about this?
>>
>> Thanks!
>> Markus Angst
>>
>> On 05.06.2012 20:39, Markus Angst wrote:
>>> Hi,
>>>
>>> I have two publications A and B where B (child) is a template publication of A
>>> (parent). I want to change the default language and the display order in the
>>> languageselector of publication B.
>>> There seems no official way to do this in the GUI (at least I didn't find it).
>>> Is it correct to do this directly in publication.xml?
>>>
>>> publication.xml of publication A:
>>>    ...
>>>    <languages>
>>>      <language default="true">de</language>
>>>      <language>en</language>
>>>      <language>fr</language>
>>>      <language>it</language>
>>>    </languages>
>>>    ...
>>>
>>> publication.xml of publication B:
>>>    ...
>>>    <languages>
>>>      <language default="true">fr</language>
>>>      <language>de</language>
>>>      <language>it</language>
>>>      <language>en</language>
>>>    </languages>
>>>    ...
>>>
>>> The combination of the above configurations creates three problems:
>>>
>>> - The sort order of the languageselector in Publication B is the same as in A.
>>>    Probably the languageselector always uses an alphabetical sort order?
> 
> Or maybe only use languages defined in A.

Yes, that seems true; see below.

> I don't know if language definition in B override A or is added to A.

I hope it will override one day... If not, how would I change the default
language in B?

>>> - The links of the languageselector are broken
>>>    - Publication A (working):
>>>      deutsch:  (default)
>>>      français: http://<domain>/index_fr.html
>>>      italiano: http://<domain>/index_it.html
>>>    - Publication B (not working):
>>>      deutsch:  http://<domain>/.html
>>>      français: (default)
>>>      italiano: http://<domain>/_it.html
>>>    It seems like the default language of A would somehow be used to generate
>>>    the URLs in B.
> 
> May this 2 tests can help to spot the problem :
> * If you don't override "language" in B, do you still have this bug ?

I have to provide something in B. If I comment out <languages>...</languages> or
leave it empty in publication.xml of publication B, I get a build error.

> * if you just add a new language in B (say spanish), bug still here ?

Yes, the bug remains. No difference.

If instead I take spanish only in B; like this:
<languages>
  <language default="true">es</language>
</languages>
I get the language selector greyed out with the entries
deutsch | français | italiano (obviously from A) and a spanish error message
telling me that the document is not available in spanish (which is true).
The language list seems to be taken from A, no matter which languages I
configure in B.

>>> - All image links are broken in B, although they look exactly the same in A
>>>    and B.
> 
> what do you mean by "look" ? The url is the same ?

Yes, the URL is the same. They are all relative (without domain).

> May you B publication don't have the flag files or this files are not in 
> a shared by all publications folder.

I do not mean the language flags, I mean all images in the whole publication,
which are linked from within an editable document.

Thanks again, Florent. Unfortunately I have to put this aside for now and
urgently work on something else. I will get back to this in December, maybe...

Best regards
Markus

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
For additional commands, e-mail: user-help@lenya.apache.org


Re: Default language in template publication

Posted by Markus Angst <ma...@inventec.ch>.
Hi devs,

Should I file a bug for this?

Thanks and regards
Markus Angst


-----------------------------------------------------------------------------

Hi Florent,

Thanks for replying. I have tried to answer your questions; see below.

> I'm not sure to be great help on this subject, but hoping this give you 
> some pointers :
> 
> On 09/21/2012 07:34 PM, Markus Angst wrote:
>> Does somebody have an opinion / idea about this?
>>
>> Thanks!
>> Markus Angst
>>
>> On 05.06.2012 20:39, Markus Angst wrote:
>>> Hi,
>>>
>>> I have two publications A and B where B (child) is a template publication of A
>>> (parent). I want to change the default language and the display order in the
>>> languageselector of publication B.
>>> There seems no official way to do this in the GUI (at least I didn't find it).
>>> Is it correct to do this directly in publication.xml?
>>>
>>> publication.xml of publication A:
>>>    ...
>>>    <languages>
>>>      <language default="true">de</language>
>>>      <language>en</language>
>>>      <language>fr</language>
>>>      <language>it</language>
>>>    </languages>
>>>    ...
>>>
>>> publication.xml of publication B:
>>>    ...
>>>    <languages>
>>>      <language default="true">fr</language>
>>>      <language>de</language>
>>>      <language>it</language>
>>>      <language>en</language>
>>>    </languages>
>>>    ...
>>>
>>> The combination of the above configurations creates three problems:
>>>
>>> - The sort order of the languageselector in Publication B is the same as in A.
>>>    Probably the languageselector always uses an alphabetical sort order?
> 
> Or maybe only use languages defined in A.

Yes, that seems true; see below.

> I don't know if language definition in B override A or is added to A.

I hope it will override one day... If not, how would I change the default
language in B?

>>> - The links of the languageselector are broken
>>>    - Publication A (working):
>>>      deutsch:  (default)
>>>      français: http://<domain>/index_fr.html
>>>      italiano: http://<domain>/index_it.html
>>>    - Publication B (not working):
>>>      deutsch:  http://<domain>/.html
>>>      français: (default)
>>>      italiano: http://<domain>/_it.html
>>>    It seems like the default language of A would somehow be used to generate
>>>    the URLs in B.
> 
> May this 2 tests can help to spot the problem :
> * If you don't override "language" in B, do you still have this bug ?

I have to provide something in B. If I comment out <languages>...</languages> or
leave it empty in publication.xml of publication B, I get a build error.

> * if you just add a new language in B (say spanish), bug still here ?

Yes, the bug remains. No difference.

If instead I take spanish only in B; like this:
<languages>
  <language default="true">es</language>
</languages>
I get the language selector greyed out with the entries
deutsch | français | italiano (obviously from A) and a spanish error message
telling me that the document is not available in spanish (which is true).
The language list seems to be taken from A, no matter which languages I
configure in B.

>>> - All image links are broken in B, although they look exactly the same in A
>>>    and B.
> 
> what do you mean by "look" ? The url is the same ?

Yes, the URL is the same. They are all relative (without domain).

> May you B publication don't have the flag files or this files are not in 
> a shared by all publications folder.

I do not mean the language flags, I mean all images in the whole publication,
which are linked from within an editable document.

Thanks again, Florent. Unfortunately I have to put this aside for now and
urgently work on something else. I will get back to this in December, maybe...

Best regards
Markus

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
For additional commands, e-mail: user-help@lenya.apache.org


Re: Default language in template publication

Posted by florent andré <fl...@4sengines.com>.
Hi Markus,

Sorry for late reply.

I'm not sure to be great help on this subject, but hoping this give you 
some pointers :

On 09/21/2012 07:34 PM, Markus Angst wrote:
> Does somebody have an opinion / idea about this?
>
> Thanks!
> Markus Angst
>
>
> On 05.06.2012 20:39, Markus Angst wrote:
>> Hi,
>>
>> I have two publications A and B where B (child) is a template publication of A
>> (parent). I want to change the default language and the display order in the
>> languageselector of publication B.
>> There seems no official way to do this in the GUI (at least I didn't find it).
>> Is it correct to do this directly in publication.xml?
>>
>> publication.xml of publication A:
>>    ...
>>    <languages>
>>      <language default="true">de</language>
>>      <language>en</language>
>>      <language>fr</language>
>>      <language>it</language>
>>    </languages>
>>    ...
>>
>> publication.xml of publication B:
>>    ...
>>    <languages>
>>      <language default="true">fr</language>
>>      <language>de</language>
>>      <language>it</language>
>>      <language>en</language>
>>    </languages>
>>    ...
>>
>> The combination of the above configurations creates three problems:
>>
>> - The sort order of the languageselector in Publication B is the same as in A.
>>    Probably the languageselector always uses an alphabetical sort order?
>>

Or maybe only use languages defined in A.
I don't know if language definition in B override A or is added to A.

>> - The links of the languageselector are broken
>>    - Publication A (working):
>>      deutsch:  (default)
>>      français: http://<domain>/index_fr.html
>>      italiano: http://<domain>/index_it.html
>>    - Publication B (not working):
>>      deutsch:  http://<domain>/.html
>>      français: (default)
>>      italiano: http://<domain>/_it.html
>>    It seems like the default language of A would somehow be used to generate
>>    the URLs in B.
>>

May this 2 tests can help to spot the problem :
* If you don't override "language" in B, do you still have this bug ?
* if you just add a new language in B (say spanish), bug still here ?


>> - All image links are broken in B, although they look exactly the same in A
>>    and B.
>>

what do you mean by "look" ? The url is the same ?
May you B publication don't have the flag files or this files are not in 
a shared by all publications folder.

++
>>
>> Am I overlooking something? Did someone else already experience this problem
>> (and has a solution)? Or is this a bug?
>>
>> Thanks and best regards
>> Markus Angst
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
> For additional commands, e-mail: user-help@lenya.apache.org
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
> For additional commands, e-mail: user-help@lenya.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
For additional commands, e-mail: user-help@lenya.apache.org