<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 5.5.2653.12">
<TITLE>RE: [opencms-dev] jsp and html page</TITLE>
</HEAD>
<BODY>
<BR>
<P><FONT SIZE=2>Hi Jens,</FONT>
</P>
<P><FONT SIZE=2>Thank you for your reply.</FONT>
<BR><FONT SIZE=2>A little hope for my problem:-)</FONT>
</P>
<P><FONT SIZE=2>The include() method gets a String parameter-That is what I'm looking for but now I'm facing another error:</FONT>
</P>
<P><FONT SIZE=2>"Incompatible type for method. Can't convert void to java.lang.Object. out.print(cms.include(filename)); ^ 1 error, 1 warning "</FONT></P>
<P><FONT SIZE=2>Have you ever met this error message?</FONT>
<BR><FONT SIZE=2>Could you please help me once more time?</FONT>
</P>
<P><FONT SIZE=2>Thank you,</FONT>
<BR><FONT SIZE=2>Yendung</FONT>
</P>
<BR>
<P><FONT SIZE=2>-----Original Message-----</FONT>
<BR><FONT SIZE=2>From: Jens Rickhoff [<A HREF="mailto:jens@visualteam.de">mailto:jens@visualteam.de</A>]</FONT>
<BR><FONT SIZE=2>Sent: 12 August 2003 18:25</FONT>
<BR><FONT SIZE=2>To: opencms-dev@opencms.org</FONT>
<BR><FONT SIZE=2>Subject: Re: [opencms-dev] jsp and html page</FONT>
</P>
<BR>
<P><FONT SIZE=2>jsp and html pageHi Yendung,</FONT>
</P>
<P><FONT SIZE=2>try using</FONT>
</P>
<P><FONT SIZE=2><%=cms.include(filename) %></FONT>
</P>
<P><FONT SIZE=2>instead. cms is a CmsJspActionElement object.</FONT>
</P>
<P><FONT SIZE=2>Hope that helps. I think the cms tags are evaluated before the JSP code is</FONT>
<BR><FONT SIZE=2>executed.</FONT>
<BR><FONT SIZE=2>Correct me if I'm wrong.</FONT>
</P>
<P><FONT SIZE=2>Cheers,</FONT>
<BR><FONT SIZE=2>Jens</FONT>
</P>
<P><FONT SIZE=2>----- Original Message -----</FONT>
<BR><FONT SIZE=2>From: Nguyen La Yen Dung</FONT>
<BR><FONT SIZE=2>To: opencms-dev@opencms.org</FONT>
<BR><FONT SIZE=2>Sent: Tuesday, August 12, 2003 1:07 PM</FONT>
<BR><FONT SIZE=2>Subject: RE: [opencms-dev] jsp and html page</FONT>
</P>
<BR>
<P><FONT SIZE=2>Hi,</FONT>
</P>
<P><FONT SIZE=2>I don't know if it is correct or not, but it only works with</FONT>
</P>
<P><FONT SIZE=2><cms:include file="mypage.html" /></FONT>
</P>
<P><FONT SIZE=2>If any one knows the reason, please explain me. Thanks.</FONT>
</P>
<P><FONT SIZE=2>Another problem I've met is: I don't want to hardcode the file name, I want</FONT>
<BR><FONT SIZE=2>to use a String variable here,</FONT>
</P>
<P><FONT SIZE=2>but <cms:include file="<%= filename %>" /> will raise an exception File not</FONT>
<BR><FONT SIZE=2>found.</FONT>
</P>
<P><FONT SIZE=2>I see the value of <%= filename %> doesnot parse.</FONT>
</P>
<P><FONT SIZE=2>Why?</FONT>
</P>
<P><FONT SIZE=2>Please help me.</FONT>
</P>
<P><FONT SIZE=2>Yendung</FONT>
</P>
<BR>
<BR>
<BR>
<BR>
<P><FONT SIZE=2> -----Original Message-----</FONT>
<BR><FONT SIZE=2>From: Nguyen La Yen Dung</FONT>
<BR><FONT SIZE=2>Sent: 12 August 2003 11:36</FONT>
<BR><FONT SIZE=2>To: opencms-dev@opencms.org</FONT>
<BR><FONT SIZE=2>Subject: [opencms-dev] jsp and html page</FONT>
</P>
<BR>
<BR>
<BR>
<P><FONT SIZE=2> Hi,</FONT>
<BR><FONT SIZE=2> I meet a problem with <jsp:include> tag. Please help.</FONT>
<BR><FONT SIZE=2> I create a simple html page in Opencms (mypage.html):</FONT>
<BR><FONT SIZE=2> <![CDATA[</FONT>
<BR><FONT SIZE=2> Hello</FONT>
<BR><FONT SIZE=2> ]]></FONT>
</P>
<BR>
<P><FONT SIZE=2> In jsp file, I use</FONT>
<BR><FONT SIZE=2><jsp:include page="mypage.html" flush="true"/></FONT>
<BR><FONT SIZE=2> Run this jsp, an empty page is shown.</FONT>
<BR><FONT SIZE=2> What's wrong?</FONT>
</P>
<P><FONT SIZE=2>Thank you,</FONT>
<BR><FONT SIZE=2> Yendung</FONT>
</P>
<P><FONT SIZE=2>_______________________________________________</FONT>
<BR><FONT SIZE=2>This mail is send to you from the opencms-dev mailing list</FONT>
<BR><FONT SIZE=2>To change your list options, or to unsubscribe from the list, please visit</FONT>
<BR><FONT SIZE=2><A HREF="http://mail.opencms.org/mailman/listinfo/opencms-dev" TARGET="_blank">http://mail.opencms.org/mailman/listinfo/opencms-dev</A></FONT>
</P>
</BODY>
</HTML>