On Mar 17, 2005, at 6:59 PM, David Sean Taylor wrote:
Im wondering if any of the Struts bridge can also be leveraged here.
Well I'm not an expert of the Struts bridge, but from my understanding the Struts bridge uses Struts' internal dispatching system to cut things in two : Struts action is processed in processAction, and the forwarding to the JSP happens in render().
Unfortunately for regular servlets this is not possible, as we don't necessarily have a two-phase process (controller -> view). If one wanted, they could do everything with just a JSP, or just a servlet, and it would still have to work.
Maybe Ate could look at the code and tell me if there are synergies I might have missed.
Looking at the HTMLPostProcess class, and it looks to me like it doesn't use the rewriter framework that Perl/PHP use, but instead uses straight Java logic and string processing.
Well actually I re-used the original code that Roger did in ScriptPostProcess (and renamed it to HTMLPostProcess), but I have to modify it to add some logic to bypass URL rewriting in the case of URLs that look like this :
<a href="javascript:doSomething()">action link</a>
<a href="portlet-download:http://localhost:8080/context/ servletThatOutputsDataStream">download link</a>
(portlet-download: is a marker that the parser recognizes as an URL that shouldn't be transformed. The prefix is stripped during post processing and sent to the browser starting at http://...)
I don't know if this behavior is desired in the default ScriptPostProcess behavior, but if it is we could remove the HTMLPostProcess class and simply use ScriptPostProcess (which was what I originally did until I had the problem with the javascript links and URLs that shouldn't be rewritten).
Regards, Serge Huber.
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]