Re: [Resin-interest] XML View Question

2007-05-10 Thread Aaron Freeman
Thank you Scott and Bill -- this is just the solution I was looking for.

Aaron 

> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On Behalf Of Bill Au
> Sent: Wednesday, May 09, 2007 11:46 PM
> To: General Discussion for the Resin application server
> Subject: Re: [Resin-interest] XML View Question
> 
> Here is the link to an article on SDN on trimDirectiveWhitespaces:
> http://java.sun.com/developer/technicalArticles/J2EE/jsp_21/
> 
> Please be aware that with trimDirectiveWhitespaces enabled, 
> all whitespaces between two JSP tag are removed.  So something like:
> 
>  
> 
> will output:
> 
> HelloWorld
> 
> instead of:
> 
> Hello World
> 
> 
> Bill
> 
> On 5/8/07, Scott Ferguson <[EMAIL PROTECTED]> wrote:
> >
> > On May 8, 2007, at 9:51 AM, Aaron Freeman wrote:
> >
> > > Can anybody provide me with any links/hints on this?
> >
> > JSP 2.1 has a trimDirectiveWhitespace option for the <%@ 
> page %> tag.  
> > That would be the cleanest way to remove the extra whitespace.
> >
> > -- Scott
> >
> > >
> > > Thanks,
> > >
> > > Aaron
> > >
> > >
> > >> -Original Message-
> > >> From: [EMAIL PROTECTED] 
> > >> [mailto:[EMAIL PROTECTED] On Behalf Of Aaron 
> > >> Freeman
> > >> Sent: Thursday, May 03, 2007 10:59 AM
> > >> To: resin-interest@caucho.com
> > >> Subject: [Resin-interest] XML View Question
> > >>
> > >> We have a controller JSP that looks like this:
> > >>
> > >>  Begin Controller  <%@ taglib 
> > >> uri="http://java.sun.com/jsp/jstl/core"; prefix="c" %> <%@ taglib 
> > >> uri="http://java.sun.com/jsp/jstl/functions"; prefix="fn" %>
> > >>
> > >> 
> > >>
> > >> ... do some logic 
> > >>
> > >> 
> > >>
> > >> 
> > >> 
> > >>   > >> test="${empty exception}">
> > >> 
> > >> <%-- An exception occured. --%>
> > >> 
> > >>  
> 
> > >> 
> > >>
> > >> 
> > >>  End Controller 
> > >>
> > >> Then our xml/_view.jsp would look something like this:
> > >>
> > >>  Begin xml/_view.jsp   > >> version="2.0">
> > >>
> > >> http://java.sun.com/jsp/jstl/core";
> > >> prefix="c" />
> > >>
> > >>  
> > >> 
> > >>
> > >> ... output some XML tags 
> > >>
> > >> 
> > >> 
> > >>
> > >> 
> > >>  End xml/_view.jsp 
> > >>
> > >> The problem is sometimes the end result has a bunch of 
> white space 
> > >> at the beginning of the document and sometimes the  
> > >> generates lots of linefeeds which cause XML parsers to 
> fail.  What 
> > >> is the proper way to dump an XML view such that there are no 
> > >> linefeeds in between the XML tags and there isn't a lot of 
> > >> whitespace above the XML?
> > >>
> > >> Thanks,
> > >>
> > >> Aaron
> > >>
> > >>
> > >>
> > >> ___
> > >> resin-interest mailing list
> > >> resin-interest@caucho.com
> > >> http://maillist.caucho.com/mailman/listinfo/resin-interest
> > >>
> > >
> > >
> > >
> > > ___
> > > resin-interest mailing list
> > > resin-interest@caucho.com
> > > http://maillist.caucho.com/mailman/listinfo/resin-interest
> >
> >
> >
> > ___
> > resin-interest mailing list
> > resin-interest@caucho.com
> > http://maillist.caucho.com/mailman/listinfo/resin-interest
> >
> 
> 
> ___
> resin-interest mailing list
> resin-interest@caucho.com
> http://maillist.caucho.com/mailman/listinfo/resin-interest
> 



___
resin-interest mailing list
resin-interest@caucho.com
http://maillist.caucho.com/mailman/listinfo/resin-interest


Re: [Resin-interest] XML View Question

2007-05-09 Thread Bill Au
Here is the link to an article on SDN on trimDirectiveWhitespaces:
http://java.sun.com/developer/technicalArticles/J2EE/jsp_21/

Please be aware that with trimDirectiveWhitespaces enabled, all
whitespaces between two JSP tag are removed.  So something like:

 

will output:

HelloWorld

instead of:

Hello World


Bill

On 5/8/07, Scott Ferguson <[EMAIL PROTECTED]> wrote:
>
> On May 8, 2007, at 9:51 AM, Aaron Freeman wrote:
>
> > Can anybody provide me with any links/hints on this?
>
> JSP 2.1 has a trimDirectiveWhitespace option for the <%@ page %>
> tag.  That would be the cleanest way to remove the extra whitespace.
>
> -- Scott
>
> >
> > Thanks,
> >
> > Aaron
> >
> >
> >> -Original Message-
> >> From: [EMAIL PROTECTED]
> >> [mailto:[EMAIL PROTECTED] On Behalf Of Aaron Freeman
> >> Sent: Thursday, May 03, 2007 10:59 AM
> >> To: resin-interest@caucho.com
> >> Subject: [Resin-interest] XML View Question
> >>
> >> We have a controller JSP that looks like this:
> >>
> >>  Begin Controller  <%@ taglib
> >> uri="http://java.sun.com/jsp/jstl/core"; prefix="c" %> <%@
> >> taglib uri="http://java.sun.com/jsp/jstl/functions"; prefix="fn" %>
> >>
> >> 
> >>
> >> ... do some logic 
> >>
> >> 
> >>
> >> 
> >> 
> >>
> >> 
> >> 
> >> 
> >> <%-- An exception occured. --%>
> >> 
> >>  
> >> 
> >>
> >> 
> >>  End Controller 
> >>
> >> Then our xml/_view.jsp would look something like this:
> >>
> >>  Begin xml/_view.jsp   >> version="2.0">
> >>
> >> http://java.sun.com/jsp/jstl/core";
> >> prefix="c" />
> >>
> >> 
> >> 
> >> 
> >>
> >> ... output some XML tags 
> >>
> >> 
> >> 
> >>
> >> 
> >>  End xml/_view.jsp 
> >>
> >> The problem is sometimes the end result has a bunch of white
> >> space at the beginning of the document and sometimes the
> >>  generates lots of linefeeds which cause XML
> >> parsers to fail.  What is the proper way to dump an XML view
> >> such that there are no linefeeds in between the XML tags and
> >> there isn't a lot of whitespace above the XML?
> >>
> >> Thanks,
> >>
> >> Aaron
> >>
> >>
> >>
> >> ___
> >> resin-interest mailing list
> >> resin-interest@caucho.com
> >> http://maillist.caucho.com/mailman/listinfo/resin-interest
> >>
> >
> >
> >
> > ___
> > resin-interest mailing list
> > resin-interest@caucho.com
> > http://maillist.caucho.com/mailman/listinfo/resin-interest
>
>
>
> ___
> resin-interest mailing list
> resin-interest@caucho.com
> http://maillist.caucho.com/mailman/listinfo/resin-interest
>


___
resin-interest mailing list
resin-interest@caucho.com
http://maillist.caucho.com/mailman/listinfo/resin-interest


Re: [Resin-interest] XML View Question

2007-05-08 Thread Scott Ferguson

On May 8, 2007, at 9:51 AM, Aaron Freeman wrote:

> Can anybody provide me with any links/hints on this?

JSP 2.1 has a trimDirectiveWhitespace option for the <%@ page %>  
tag.  That would be the cleanest way to remove the extra whitespace.

-- Scott

>
> Thanks,
>
> Aaron
>
>
>> -Original Message-
>> From: [EMAIL PROTECTED]
>> [mailto:[EMAIL PROTECTED] On Behalf Of Aaron Freeman
>> Sent: Thursday, May 03, 2007 10:59 AM
>> To: resin-interest@caucho.com
>> Subject: [Resin-interest] XML View Question
>>
>> We have a controller JSP that looks like this:
>>
>>  Begin Controller  <%@ taglib
>> uri="http://java.sun.com/jsp/jstl/core"; prefix="c" %> <%@
>> taglib uri="http://java.sun.com/jsp/jstl/functions"; prefix="fn" %>
>>
>> 
>>
>> ... do some logic 
>>
>> 
>>
>> 
>> 
>>
>> 
>> 
>> 
>> <%-- An exception occured. --%>
>> 
>>  
>> 
>>
>> 
>>  End Controller 
>>
>> Then our xml/_view.jsp would look something like this:
>>
>>  Begin xml/_view.jsp  > version="2.0">
>>
>> http://java.sun.com/jsp/jstl/core";
>> prefix="c" />
>>
>> 
>> 
>> 
>>
>> ... output some XML tags 
>>
>> 
>> 
>>
>> 
>>  End xml/_view.jsp 
>>
>> The problem is sometimes the end result has a bunch of white
>> space at the beginning of the document and sometimes the
>>  generates lots of linefeeds which cause XML
>> parsers to fail.  What is the proper way to dump an XML view
>> such that there are no linefeeds in between the XML tags and
>> there isn't a lot of whitespace above the XML?
>>
>> Thanks,
>>
>> Aaron
>>
>>
>>
>> ___
>> resin-interest mailing list
>> resin-interest@caucho.com
>> http://maillist.caucho.com/mailman/listinfo/resin-interest
>>
>
>
>
> ___
> resin-interest mailing list
> resin-interest@caucho.com
> http://maillist.caucho.com/mailman/listinfo/resin-interest



___
resin-interest mailing list
resin-interest@caucho.com
http://maillist.caucho.com/mailman/listinfo/resin-interest


Re: [Resin-interest] XML View Question

2007-05-08 Thread Aaron Freeman
Can anybody provide me with any links/hints on this?

Thanks,

Aaron


> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On Behalf Of Aaron Freeman
> Sent: Thursday, May 03, 2007 10:59 AM
> To: resin-interest@caucho.com
> Subject: [Resin-interest] XML View Question
> 
> We have a controller JSP that looks like this:
> 
>  Begin Controller  <%@ taglib 
> uri="http://java.sun.com/jsp/jstl/core"; prefix="c" %> <%@ 
> taglib uri="http://java.sun.com/jsp/jstl/functions"; prefix="fn" %>
> 
> 
> 
> ... do some logic 
> 
> 
> 
> 
> 
>
> 
> 
> 
> <%-- An exception occured. --%>
> 
>  
> 
> 
> 
>  End Controller 
> 
> Then our xml/_view.jsp would look something like this:
> 
>  Begin xml/_view.jsp  
> 
> http://java.sun.com/jsp/jstl/core"; 
> prefix="c" />
> 
> 
> 
> 
> 
> ... output some XML tags 
> 
> 
> 
> 
> 
>  End xml/_view.jsp 
> 
> The problem is sometimes the end result has a bunch of white 
> space at the beginning of the document and sometimes the 
>  generates lots of linefeeds which cause XML 
> parsers to fail.  What is the proper way to dump an XML view 
> such that there are no linefeeds in between the XML tags and 
> there isn't a lot of whitespace above the XML?
> 
> Thanks,
> 
> Aaron
> 
> 
> 
> ___
> resin-interest mailing list
> resin-interest@caucho.com
> http://maillist.caucho.com/mailman/listinfo/resin-interest
> 



___
resin-interest mailing list
resin-interest@caucho.com
http://maillist.caucho.com/mailman/listinfo/resin-interest