El mié, 15-03-2006 a las 19:56 -0600, Brian M Dube escribió:
> Hi,
>
> Sorry for the cross-post. Perhaps the dev list was the wrong place to
> send this one.
>
Sorry, that this mail sliped through my radar. ;)
> I'm working to recreate a custom Forrest 0.7 skin with the 0.8-dev
> dispatcher.
ok
> I started by modifying the blank contract template to get some test
> output.
How does the contract looks after you modified it?
BTW IMO the best way to start is using the master.ft.
> I encounter the following error message:
>
> ---
> dispatcherError: 500 - Internal server error
> The contract "content" has thrown thrown an exception by resolving raw
> data from "cocoon://index.body.xml".
>
So your contract that is throwing an exception is called "content" and
was thrown by resolving the raw data.
> dispatcherErrorStack:
> org.xml.sax.SAXParseException: The markup in the document following
> the root element must be well-formed.
> ---
>
> When I inspect the result of index.body.xml, I can see why it's
> complaining. The root element of the output is the empty tag
> <meta-data/>, followed by the content.
Hmm, that is not right and should not be. I just tried with the
fresh-site and cannot reproduce the problem.
Which plugins are you using (the exact name in forrest.properties)?
Did you implemented a custom <map:match pattern="**.body.xml"/>?
How does your index.xml looks like?
> In 0.7 the skin's
> document-to-html (or document2html) stylesheet inserted the meta-data
> tag; what's doing it now?
The dispatcher uses its own document2html.xsl that is not connected
directly with the one from skins.
You can find the match in
org.apache.forrest.plugin.internal.dispatcher/dataModel.xmap
<map:pipeline>
<!-- HTML rendered from intermediate format -->
<map:match pattern="**.body.xml">
<map:generate src="cocoon:/{1}.source.rewritten.xml" />
<map:transform src="{lm:dataModel-html-document-to-html.xsl}">
<map:parameter name="path" value="{1}.html" />
</map:transform>
<map:serialize />
</map:match>
</map:pipeline>
Where {lm:dataModel-html-document-to-html.xsl} is defined in the
dispatcher locationmap.xml
<match pattern="dataModel-html-**.xsl">
<select type="exists">
<location
src="{project:skins-dir}{project:theme}/xslt/html/{1}.xsl" />
<location
src="{project:structurer}/resources/stylesheets/html/{1}.xsl"
/>
<location
src="{defaults:structurer}/resources/stylesheets/html/{1}.xsl" />
</select>
</match>
Assuming you are not using your own implementation of
document-to-html.xsl the dispatcher uses
org.apache.forrest.plugin.internal.dispatcher/resources/stylesheets/html/document-to-html.xsl
but there I do not see any match for meta-data, nor in the import
../common/xslt/html/document-to-html.xsl
> Is the skin system still active when using the
> dispatcher?
No. The dispatcher overrides skins.
> I'm not sure how the dispatcher interacts with skins.
The interaction that may still exist till we solve
http://issues.apache.org/jira/browse/FOR-808 are due to go but there
should be no interaction between skins and the dispatcher anymore.
> I
> don't have a skin set in forrest.properties for this test.
That is perfectly alright.
>
> Thanks,
> Brian
Welcome to the dispatcher Brain and thanks for testing. :)
salu2
--
thorsten
"Together we stand, divided we fall!"
Hey you (Pink Floyd)