You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Johannes Hoechstaedter <j....@memocomp.de> on 2008/06/13 11:45:47 UTC
include css
Hi everybody,
it seems to be a never ending story for me. Why can't I access my css file?
My style works when I put it in <style> tags, but when I try to acces by
a xsl file (transform.xsl), nothing happens.
My block structure is as follows:
/sitemap
/resource/internal/style/style-main.css
/resource/tranform.xsl
I have the following code in transform.xsl:
<html>
<head>
<title>Cocoon App - Test 1.0</title>
<link rel="stylesheet" type="text/css"
href="resource/internal/style/style-main.css" />
</head>
<body>
.....
Can you help me? I have already tried an absolute path, but this doesn't
work, too, this time. I am able to access it absolute by the browser.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
AW: include css
Posted by Christofer Dutz <ch...@c-ware.de>.
Hi,
Did you setup a pipeline for serving the css file in your sitemap?
You have to add something like this:
<map:match pattern="internal/style/style-main.css">
<map:read src="internal/style/style-main.css"/>
</map:match>
... or use *, ** and {1},{2} if you want it a little more general ;-)
Hope this helps
Chris
-----Ursprüngliche Nachricht-----
Von: Johannes Hoechstaedter [mailto:j.hoechstaedter@memocomp.de]
Gesendet: Freitag, 13. Juni 2008 11:46
An: users@cocoon.apache.org
Betreff: include css
Hi everybody,
it seems to be a never ending story for me. Why can't I access my css file?
My style works when I put it in <style> tags, but when I try to acces by
a xsl file (transform.xsl), nothing happens.
My block structure is as follows:
/sitemap
/resource/internal/style/style-main.css
/resource/tranform.xsl
I have the following code in transform.xsl:
<html>
<head>
<title>Cocoon App - Test 1.0</title>
<link rel="stylesheet" type="text/css"
href="resource/internal/style/style-main.css" />
</head>
<body>
.....
Can you help me? I have already tried an absolute path, but this doesn't
work, too, this time. I am able to access it absolute by the browser.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: include css
Posted by Johannes Hoechstaedter <j....@memocomp.de>.
Hi Andre :) I did it by
href="../resource/external/style/style-main.css"
thank you
Johannes Hoechstaedter schrieb:
> No, I am able to access the directory. Theres nothing special about it.
>
> Andre Juffer schrieb:
>> Johannes Hoechstaedter wrote:
>>> Thank you for your response Andre,
>>>
>>> I left the default pipelines for internal-resource and
>>> extrenal-resource in my sitemap untouched, ok you are right. I
>>> copied my file and I tried the follwing:
>>>
>>> href="cocoon://resource/external/style/style-main.css"
>>> href="cocoon:/resource/external/style/style-main.css"
>>> href="resource/external/style/style-main.css"
>>> href="file//C:/.../resource/external/style/style-main.css"
>>>
>>> The results stays the same. Is there anything else?
>>
>> The first two would not work in a browser. The last one refers to a
>> file locally on the machine where the browser runs. The third one
>> should be fine. I cannot see what it would not work. As a matter I
>> have exactly the same in my applications (except for a different name
>> for the CSS file). Is the directory itself not accessible? Maybe
>> wrong permissions?
>>
>>>
>>> My pipeline for external-resources:
>>>
>>> <map:pipeline id="external-resource">
>>> <!-- Put matchers for external (accessible to the outside
>>> world, e.g. browser) resources here.
>>> More details:
>>> http://cocoon.zones.apache.org/daisy/cdocs-site-main/g2/1345.html -->
>>> <map:match pattern="resource/external/**">
>>> <map:read src="resource/external/{1}"/>
>>> </map:match>
>>> </map:pipeline>
>>>
>>>
>>> Andre Juffer schrieb:
>>>> Johannes,
>>>>
>>>> the /resource/internal is meant for internal access only (check
>>>> your sitemap) and is consequently not accessible from outside
>>>> requests. The other location /resource/external is meant for
>>>> external access (again check your sitemap.
>>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>>> For additional commands, e-mail: users-help@cocoon.apache.org
>>>
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: include css
Posted by Johannes Hoechstaedter <j....@memocomp.de>.
No, I am able to access the directory. Theres nothing special about it.
Andre Juffer schrieb:
> Johannes Hoechstaedter wrote:
>> Thank you for your response Andre,
>>
>> I left the default pipelines for internal-resource and
>> extrenal-resource in my sitemap untouched, ok you are right. I copied
>> my file and I tried the follwing:
>>
>> href="cocoon://resource/external/style/style-main.css"
>> href="cocoon:/resource/external/style/style-main.css"
>> href="resource/external/style/style-main.css"
>> href="file//C:/.../resource/external/style/style-main.css"
>>
>> The results stays the same. Is there anything else?
>
> The first two would not work in a browser. The last one refers to a
> file locally on the machine where the browser runs. The third one
> should be fine. I cannot see what it would not work. As a matter I
> have exactly the same in my applications (except for a different name
> for the CSS file). Is the directory itself not accessible? Maybe wrong
> permissions?
>
>>
>> My pipeline for external-resources:
>>
>> <map:pipeline id="external-resource">
>> <!-- Put matchers for external (accessible to the outside world,
>> e.g. browser) resources here.
>> More details:
>> http://cocoon.zones.apache.org/daisy/cdocs-site-main/g2/1345.html -->
>> <map:match pattern="resource/external/**">
>> <map:read src="resource/external/{1}"/>
>> </map:match>
>> </map:pipeline>
>>
>>
>> Andre Juffer schrieb:
>>> Johannes,
>>>
>>> the /resource/internal is meant for internal access only (check your
>>> sitemap) and is consequently not accessible from outside requests.
>>> The other location /resource/external is meant for external access
>>> (again check your sitemap.
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>> For additional commands, e-mail: users-help@cocoon.apache.org
>>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: include css
Posted by Andre Juffer <An...@oulu.fi>.
Johannes Hoechstaedter wrote:
> Thank you for your response Andre,
>
> I left the default pipelines for internal-resource and extrenal-resource
> in my sitemap untouched, ok you are right. I copied my file and I tried
> the follwing:
>
> href="cocoon://resource/external/style/style-main.css"
> href="cocoon:/resource/external/style/style-main.css"
> href="resource/external/style/style-main.css"
> href="file//C:/.../resource/external/style/style-main.css"
>
> The results stays the same. Is there anything else?
The first two would not work in a browser. The last one refers to a file
locally on the machine where the browser runs. The third one should be
fine. I cannot see what it would not work. As a matter I have exactly
the same in my applications (except for a different name for the CSS
file). Is the directory itself not accessible? Maybe wrong permissions?
>
> My pipeline for external-resources:
>
> <map:pipeline id="external-resource">
> <!-- Put matchers for external (accessible to the outside world,
> e.g. browser) resources here.
> More details:
> http://cocoon.zones.apache.org/daisy/cdocs-site-main/g2/1345.html -->
> <map:match pattern="resource/external/**">
> <map:read src="resource/external/{1}"/>
> </map:match>
> </map:pipeline>
>
>
> Andre Juffer schrieb:
>> Johannes,
>>
>> the /resource/internal is meant for internal access only (check your
>> sitemap) and is consequently not accessible from outside requests. The
>> other location /resource/external is meant for external access (again
>> check your sitemap.
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
--
Andre H. Juffer | Phone: +358-8-553 1161
The Biocenter and | Fax: +358-8-553-1141
the Dep. of Biochemistry | Email: Andre.Juffer@oulu.fi
University of Oulu, Finland | WWW: www.biochem.oulu.fi/Biocomputing/
NordProt | WWW: www.nordprot.org
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: include css
Posted by Johannes Hoechstaedter <j....@memocomp.de>.
Thank you for your response Andre,
I left the default pipelines for internal-resource and extrenal-resource
in my sitemap untouched, ok you are right. I copied my file and I tried
the follwing:
href="cocoon://resource/external/style/style-main.css"
href="cocoon:/resource/external/style/style-main.css"
href="resource/external/style/style-main.css"
href="file//C:/.../resource/external/style/style-main.css"
The results stays the same. Is there anything else?
My pipeline for external-resources:
<map:pipeline id="external-resource">
<!-- Put matchers for external (accessible to the outside world,
e.g. browser) resources here.
More details:
http://cocoon.zones.apache.org/daisy/cdocs-site-main/g2/1345.html -->
<map:match pattern="resource/external/**">
<map:read src="resource/external/{1}"/>
</map:match>
</map:pipeline>
Andre Juffer schrieb:
> Johannes,
>
> the /resource/internal is meant for internal access only (check your
> sitemap) and is consequently not accessible from outside requests. The
> other location /resource/external is meant for external access (again
> check your sitemap.
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: include css
Posted by Andre Juffer <An...@oulu.fi>.
Johannes,
the /resource/internal is meant for internal access only (check your
sitemap) and is consequently not accessible from outside requests. The
other location /resource/external is meant for external access (again
check your sitemap.
Johannes Hoechstaedter wrote:
> Hi everybody,
>
> it seems to be a never ending story for me. Why can't I access my css file?
>
> My style works when I put it in <style> tags, but when I try to acces by
> a xsl file (transform.xsl), nothing happens.
>
> My block structure is as follows:
>
> /sitemap
> /resource/internal/style/style-main.css
> /resource/tranform.xsl
>
> I have the following code in transform.xsl:
>
> <html>
> <head>
> <title>Cocoon App - Test 1.0</title>
> <link rel="stylesheet" type="text/css"
> href="resource/internal/style/style-main.css" />
> </head>
> <body>
> .....
>
> Can you help me? I have already tried an absolute path, but this doesn't
> work, too, this time. I am able to access it absolute by the browser.
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
--
Andre H. Juffer | Phone: +358-8-553 1161
The Biocenter and | Fax: +358-8-553-1141
the Dep. of Biochemistry | Email: Andre.Juffer@oulu.fi
University of Oulu, Finland | WWW: www.biochem.oulu.fi/Biocomputing/
NordProt | WWW: www.nordprot.org
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org