Hi Eska,<br><br>That did not work.<br><br>I get the error <br><br> javax.servlet.jsp.JspException: Error reading resource from path "/sites/default/TAIG/personal/MyTip1.html".<br><br>I changed the element file code to : <br>
<cms:template element="insider_tip"> <br> <%<br> CmsJspActionElement cms = new CmsJspActionElement(pageContext, request, response); <br> String tfilename = cms.property("tip_file");<br>
cms.include(tfilename);<br> %><br></cms:template><br><br><br clear="all">-- Yogesh<br><br>Believe with all your heart that how you live your life makes a difference. --Colin Beavan <br>
<br><br><div class="gmail_quote">On Fri, Feb 12, 2010 at 3:21 PM, Eska <span dir="ltr"><<a href="mailto:sven.kiesow@interone.de">sven.kiesow@interone.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
Hi Yogesh,<br>
<br>
It seems you set the tip_file property in a wrong way. Do not set it to<br>
<div class="im"><br>
/opencms/opencms/test/mytip.html<br>
<br>
</div>but to something like<br>
<br>
/sites/abc/test/mytip.html<br>
<br>
Eska<br>
<div><div></div><div class="h5"><br>
<br>
yogiam wrote:<br>
><br>
> Dear All,<br>
><br>
> I have a simple template which is supposed to show the page content. The<br>
> template has a Tips section where I need to display tips. These<br>
> requirement<br>
> is that the tips have to be editable at page level. Tips will be HTML<br>
> content(*xmlpage*).<br>
><br>
> The solution that I came across(*which does not work*) was to define a<br>
> property called as *tip_file* for every page and specify a file name which<br>
> needs to be shown as a tip. In the template I get the property(*tip_file*)<br>
> of the page and make a URI to the file using the context uri and<br>
> foldername<br>
> and the tip filename. I then include this file in the template with<br>
> include<br>
> method of CmsJspActionElement object. When I view the file with<br>
> *tip_file*property set to some<br>
> *xmlpage*, I get and error which says<br>
> *"/opencms/opencms/test/mytip.html"*is not accessible, though it is<br>
> available in the folder and is accessible if<br>
> viewed independently.<br>
><br>
> Any other quick and smart way of doing it?<br>
><br>
> -- Yogesh<br>
><br>
> Believe with all your heart that how you live your life makes a<br>
> difference.<br>
> --Colin Beavan<br>
><br>
><br>
</div></div><div class="im">> _______________________________________________<br>
> This mail is sent to you from the opencms-dev mailing list<br>
> To change your list options, or to unsubscribe from the list, please visit<br>
> <a href="http://lists.opencms.org/mailman/listinfo/opencms-dev" target="_blank">http://lists.opencms.org/mailman/listinfo/opencms-dev</a><br>
><br>
<br>
</div><font color="#888888">--<br>
View this message in context: <a href="http://old.nabble.com/include-xmlpage-content-from-template-tp27560296p27561060.html" target="_blank">http://old.nabble.com/include-xmlpage-content-from-template-tp27560296p27561060.html</a><br>
Sent from the OpenCMS - Dev mailing list archive at Nabble.com.<br>
</font><div><div></div><div class="h5"><br>
<br>
_______________________________________________<br>
This mail is sent to you from the opencms-dev mailing list<br>
To change your list options, or to unsubscribe from the list, please visit<br>
<a href="http://lists.opencms.org/mailman/listinfo/opencms-dev" target="_blank">http://lists.opencms.org/mailman/listinfo/opencms-dev</a><br>
</div></div></blockquote></div><br>