You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@forrest.apache.org by Cyriaque Dupoirieux <Cy...@pcotech.fr> on 2006/01/13 13:58:25 UTC
[Dispatcher v3] Problem chaining hooks with the same name
Thorsten,
Here is an example where I have a problem :
<forrest:hook class="logo">
<forrest:contract name="branding-logo"> ...
</forrest:hook>
<forrest:hook class="logo">
<forrest:contract name="branding-logo"/> ...
</forrest:hook>
Gives this :
<div class="logo">
<!--+ start Logo +-->
...
<!--+ end group Logo +-->
<!--+ start Logo +-->
...
<!--+ end group Logo +-->
</div>
<div class="logo" />
The first div - that is hook - is not closed after the first logo but
after the second ?
The second hook generate an empty div tag - which is as we all know
something that several browsers don't like at all :-) .
For the moment, I comment the second logo of the pelt theme...
--
Salutations,
Cyriaque,
Re: [Dispatcher v3] Problem chaining hooks with the same name
Posted by Thorsten Scherler <th...@apache.org>.
El vie, 13-01-2006 a las 13:58 +0100, Cyriaque Dupoirieux escribió:
> Thorsten,
>
> Here is an example where I have a problem :
>
> <forrest:hook class="logo">
> <forrest:contract name="branding-logo"> ...
> </forrest:hook>
> <forrest:hook class="logo">
> <forrest:contract name="branding-logo"/> ...
> </forrest:hook>
>
> Gives this :
> <div class="logo">
> <!--+ start Logo +-->
> ...
> <!--+ end group Logo +-->
> <!--+ start Logo +-->
> ...
> <!--+ end group Logo +-->
> </div>
>
> <div class="logo" />
>
> The first div - that is hook - is not closed after the first logo but
> after the second ?
that is a bug in
package org.apache.forrest.dispatcher.transformation;
public class DispatcherTransformer.
Somewhere in
private void hookProcessingStart
I reckon we have to enhance the
String tempPath = path + "/" + name;
with xpath expression such as [position()=1]
Can you fill an issue. TIA.
> The second hook generate an empty div tag - which is as we all know
> something that several browsers don't like at all :-) .
>
hmm, thats sound more that the bug is in
private void contractProcessingEnd
I reckon we have to enhance the
location = "result/" + location;
with xpath expression such as [position()=1]
> For the moment, I comment the second logo of the pelt theme...
>
>
perfect, thx.
salu2
--
thorsten
"Together we stand, divided we fall!"
Hey you (Pink Floyd)