This is the mail archive of the docbook-apps@lists.oasis-open.org mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [docbook-apps] docbook-website and jsp


Arnaud Vandyck <arnaud.vandyck@ulg.ac.be> writes:

> Arnaud Vandyck <arnaud.vandyck@ulg.ac.be> writes:
>
>> I'd like to have all my jsp pages processed from the xml files (by the
>> docbook-website xsl files)...
>
> I've been able to nearly produce jsp page with docbook by changing the
> ouput type from html to xhtml.
>
> But I need to remove the DOCTYPE line and to exchange the <html> and the
> <jsp:root> tags at the beginning and at the end because it seems
> autolayout don't like it when <webpage> is not the root tag.

I did add an horrible hack to get the jsp's usable:

this is how to call the script after the pages are generated from the
build.xml file:

    <exec dir="${webapp}" executable="${src}/jspfix.sh"/> 

And here is the jspfix.sh script:

                               ----><----

#! /bin/sh

for jspfile in $(find -name '*.jsp')
  do
  NBLIGNES=$(( $(wc -l $jspfile | cut -d ' ' -f 1) - 2 ))
  echo '<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page"; version="1.2">' \
  > temp.jsp
  tail -n $NBLIGNES $jspfile >> temp.jsp
  echo '</jsp:root>' >> temp.jsp
  mv temp.jsp $jspfile
done


                               ----><----

If someone has a better idea...

Cheers,

-- 
Arnaud

To unsubscribe from this list, send a post to docbook-apps-unsubscribe@lists.oasis-open.org, or visit http://www.oasis-open.org/mlmanage/.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]