[opencms-dev] Writing HTML directly into a vfs file

M Butcher mbutcher at grcomputing.net
Tue Jul 1 18:07:01 CEST 2003


So if I know my content is well formed, etc, etc. and I want to be able
to edit the page at some point, I can/should set the CDATA for both the
TEMPLATE and edittemplate elements, right? Or should I set the
edittemplate element and then run something to generate the contents of
TEMPLATE?

What I'd like to do is be able to automatically generate some content
based on system information, but then allow a user to change it.

Matt

On Tue, 2003-07-01 at 05:59, Alexander Kandzior wrote:
> This will depend if you want to be able to edit your auto-generated
> content manually in the WYSIWYG later on. If you do not need to edit it,
> you just need to fill the <TEMPLATE> section since this is what will get
> displayed by the template later. 
> 
> Best Regards,
> Alex.
> 
> Alexander Kandzior
> Alkacon Software - The OpenCms Experts
> http://www.alkacon.com
> 
> > -----Original Message-----
> > From: opencms-dev-admin at opencms.org 
> > [mailto:opencms-dev-admin at opencms.org] On Behalf Of Matthias Schmidt
> > Sent: Tuesday, July 01, 2003 1:46 PM
> > To: opencms-dev at opencms.org
> > Subject: Re: [opencms-dev] Writing HTML directly into a vfs file
> > 
> > 
> > Good question. Does anyone know? DAvid?
> > 
> > M Butcher wrote:
> > > So if I were to change the contents of the XML file in a 
> > Java class, 
> > > would changing the CDATA in <edittemplate> and saving be 
> > sufficient, 
> > > or would I need to call something to build the contents of TEMPLATE?
> > > 
> > > Matt
> > > 
> > > On Mon, 2003-06-30 at 21:28, David Seikel wrote:
> > > 
> > >>For some strange reason, my email editor is giving me problems with 
> > >>this
> > >>reply.  I suspect that there are too many > characters 
> > (which it uses 
> > >>for quoting).  My reply may come out strangely formatted.
> > >>
> > >>Matthias Schmidt wrote:
> > >>
> > >>>================
> > >>><?xml version="1.0" encoding="ISO-8859-1"?>
> > >>><XMLTEMPLATE>
> > >>>    <TEMPLATE><![CDATA[<strong>dfhjdfhdfhfh</strong>]]></TEMPLATE>
> > >>>    
> > >>><edittemplate><![CDATA[<STRONG>dfhjdfhdfhfh</STRONG>]]></ed
> > ittemplate>
> > >>></XMLTEMPLATE>
> > >>>================
> > >>
> > >><snip>
> > >>
> > >>>2) I'd rather not touch the xml myself, because I don't understand 
> > >>>what
> > >>>this saving things twice thing is used to.
> > >>
> > >>Going backwards, <edittemplate> is what is actually entered by the 
> > >>user, either via the WYSIWYG editor or the source code editor.  
> > >><TEMPLATE> is the result after OpenCMS parses the input (jTidy) and 
> > >>massages things, mostly the links I think.  <TEMPLATE> is what is 
> > >>actually displayed when you load the page into your 
> > browser.  In other 
> > >>words, <ELEMENT name="body"> returns the <TEMPLATE> just 
> > like in any 
> > >>other template file. The next time someone edits the page, they are 
> > >>shown <edittemplate>.
> > 
> > _______________________________________________
> > This mail is send to you from the opencms-dev mailing list
> > To change your list options, or to unsubscribe from the list, 
> > please visit http://mail.opencms.org/mailman/listinfo/opencms-dev
> > 
> > 
> 
> _______________________________________________
> This mail is send to you from the opencms-dev mailing list
> To change your list options, or to unsubscribe from the list, please visit
> http://mail.opencms.org/mailman/listinfo/opencms-dev
-- 
M Butcher <mbutcher at grcomputing.net>



More information about the opencms-dev mailing list