cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jason Johnston" <>
Subject Re: Cocoon Matching Problem
Date Wed, 08 Feb 2006 21:38:40 GMT
> Hi:
> We (my project group) are having a problem at work with the code
> reproduced
> below.  The first section of code is the pipeline portion of the Cocoon
> sitemap we are running.  The idea is that any URL requested by the user
> will
> be passed down by all of the pipelines with specific matches and match on
> the Frameset pipeline that will match on anything.  This Frameset pipeline
> will generate the frameset for the site using the XSL stylesheet in the
> second section of code.  The frameset generates requests for three
> additional URLs for the search Bar, Nav Bar, and Main Text Area.  The
> Search
> Bar and Navigation Bar URLs will match on specific pipelines, while the
> Main
> Text are URL will match on various pipelines depending on the exact URL.
> All of this works for the URL "", but for URLs with a "
>*" format, we experience the following problem.
> When we request URLs with the "*" format the Frameset
> pipeline works fine, it generates the frameset and sends the correct
> requests for the search Bar, Nav Bar, and Main Text Area.  The Search Bar
> and Navigation Bar pipelines work fine and generate those portions of the
> page.  The request for the Main Text Area fails to match on the  "
>*/Main_Text_Area" pipeline, however.  As a result the
> request is passed down and matches on the Frameset pipeline.  This leads
> to
> a loop in which the Search and Navigation Bars are inserted repeatedly.
> What is really odd is that while the "*/Main_Text_Area"
> request generated by the frameset---in response to a "
>*/Main_Text_Area" request---will not work, if we directly
> request a URL in the "*/Main_Text_Area" format, the
> pipeline that is supposed to match on that format works and generates the
> page.  We have checked the Main Text Area URL generated by the Framest,
> however, and it is correct.
> Three of us have been trying to figure this out for the past week and we
> just cannot figure it.  Any help would be much appreciated.

My guess is this has something to do with relative URLs in your src=""
attributes.  The web browser will resolve them relative to the current
document's base URL.  So if your frameset is requested by the URL:

and that frameset's XSLT produces:

 <frame src="">

then your browser will request this URL for that frame's contents:

...which would not be matched by either of your Main_Text_Area pipelines. 
The search/navigation bar pipelines are matching because you use "**".  To
fix it either make your Main_Text_Area matcher more generic, or begin your
src attributes with a "/" to make it resolve relative to the domain root.

Hopefully this is the right guess.  You'd be able to verify it by looking
in your access logs.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message