Thanks a lot for this. I'll try it out as soon as I can.
I've decided to get my basic structure up and running in plain ol'
Cocoon first to
help clarify (and simplify) my thought processes, and migrate the
result later to Lenya.
I'll give you more feedback later.
Steve
On 23 Jan 2006, at 00:46, [EMAIL PROTECTED] wrote:
On 1/20/06, Stephen Winnall <[EMAIL PROTECTED]> wrote:
I can't find where to the pipeline to do this. I looked at all the
sitemaps in the Lenya delivery:
I understood that if I were to put my pipeline into one of the
sitemaps in lenya/lenya/pubs/default
it should work. I created the following pipeline:
<map:match pattern="vimia/css/*-*-*-*.css">
<!--
! {1} file name
! {2} language (de|en)
! {3} topic ([1..6])
! {4} browser (1=standards compliant, 2=minimal
PC, 3=text, 4=PDA, 5=cell phone)
-->
<map:generate type="file" src="resources/shared/css/
{1}.xcss" />
<map:transform type="i18n">
<map:parameter name="locale" value="{2}" />
</map:transform>
<map:transform src="resources/shared/css/{1}.xslt">
<map:parameter name="topic" value="{3}" />
<map:parameter name="browser" value="{4}" />
</map:transform>
<map:serialize mime-type="text/css" />
</map:match>
I have tried it in
lenya/lenya/pubs/default/publication-sitemap.xmap
lenya/lenya/pubs/default/sitemap.xmap
However I can't get Lenya to acknowledge its existence. Calls like
http://public/lenya/default/live/css/vimia-de-1-1.css
result in the following response:
The requested document does not exist
The requested document '/css/vimia-de-1-1.css' with
document-id '/
css/vimia-de-1-1' does not exist.
I get the impression that my <map:match pattern="vimia/css/*-*-*-
*.css"> is being masked by something
higher up the tree.
URL: http://public/lenya/default/live/css/vimia-de-1-1.css
If the "/lenya" is removed by Tomcat, then it is fine. Otherwise
global-sitemap.xmap will be send this to lenya/lenya.xmap. These is
code there for global CSS, but that is not what you want. So remove
it.
When
http://public/default/live/css/vimia-de-1-1.css
reaches pubs/default/publication-sitemap.xmap, the match is:
default/live/css/vimia-de-1-1.css
<map:match pattern="vimia/css/*-*-*-*.css">
will not match that. Try:
<map:match pattern="*/*/css/*-*-*-*.css">
{1} = pubID "default"
{2} = area "live"
{3) = "vimia"
{4} = language "de"
{5} = "1"
{6} = "1"
<map:generate type="file" src="resources/shared/css/{1}.xcss" />
Assuming the "x" was a typo, change it to:
<map:generate type="file" src="resources/shared/css/{3}.css"/>
To get pubs/default/resources/shared/css/vimia.css
Remove any transformation while testing if your pipeline is working.
Just finish with a serializer. type="text" is necessary because Lenya
defaults to type="html".
*** SOLUTION ***
FILE: {pub}/publication-sitemap.xmap
<map:match pattern="*/*/css/*-*-*-*.css">
<map:generate type="file" src="resources/shared/css/{3}.css"/>
<map:serialize type="text" mime-type="text/css"/>
</map:match>
URL: http://public/default/live/css/vimia-de-1-1.css
returns
FILE: {pub}/resources/shared/css/vimia.css
solprovider
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]