Schultz, Gary - COMM wrote:
I have cinclude working to bring in external source. I now need to solve two
more problems.


Problem 1:
I can bring in entire documents, but I cannot get specific element(s). I was
getting empty element, but used the following found on the Cocoon wiki

select="//*[local-name()='html']/*"

Now I can bring in the document fine, but I cannot tweak this to bring in
specific element(s).


Problem 2:
I tried bringing into an xml document an external source that is html. I use
the default generator which is set to xml. I believe I need to bring in the
resource, JTidy, and serialize as xml before using in the cinclude. I've
tried some things based on what I have seen in the Cocoon samples, but
nothing works. I'm at a loss as to where I should go from here.

Suggestions are greatly appreciated.


Don't know about problem 1, but it may help to use xpointer, maybe. For 2), I suppose the solution is to:

create a pipeline for serializing the html to xml:
<map:match pattern="name_toxml">
  <map:generate type="html" src="http://your_url"/>
  <map:serialize type="xml"/>
</map:match>

and use the pseudo-protocol cocoon:/ in the src of your cinclude element.

--
Aurélien

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to