Re: [Hypercontent-users] editable areas
Brought to you by:
alexvigdor
From: Alex V. <av...@co...> - 2004-11-11 16:06:49
|
Hi Carl, If you want to provide WYSIWYG editing for visually distinct parts of the page, there are two approaches. You can build up the content in one file, for example if you have a page which has an abstract, body text and an optional sidebar: <!ELEMENT page (abstract,body,sidebar?)> <!ELEMENT abstract (html)> <!ELEMENT body (html)> <!ELEMENT sidebar (html)> The XML editor replaces any instance of the 'html' tag with a WYSIWYG area, so this would give you three distinct editable areas, which you could refer to by the name of their enclosing element in XSL <xsl:variable name="sidebar" select="/cms:wrapper/cms:source/page/sidebar/html"/> The other possible approach is to break the editable areas out into separate files, which may not have their own form of output, but which are included into the target page at build time. There are two reasons you might want to do this; either because you want to apply different permissions to these sub-components, or because the sub-component is of a repeating type and you don't want your page file to get too large. A classic example is announcements for the home page; there can be any number of announcements, and you may want to allow someone to edit announcements without changing anything else on the home page. e.g. <xml-doctype path="/announcements/*" label="Announcement" root="html"/> <xml-doctype path="/index.xml" ...> <output type="text/html> <include source="/announcements/* data="yes" metadata="yes"/> <transform ... /> </output> </xml-doctype> -Alex On Nov 11, 2004, at 4:46 AM, Carl Barrow wrote: > Hi > > I have a template set up with one main editable area and a second > editable area which displays the page description. I need to add two > more editable areas to the page. What would be the best/simplest way > to do this? > > Many thanks > Carl > > > -- > ************************************ > > Carl Barrow > Web Developer > e-Services > The University of Hull > Cottingham Road > Hull > HU6 7RX > Ext. 6838 > ************************************ > > > > ------------------------------------------------------- > This SF.Net email is sponsored by: > Sybase ASE Linux Express Edition - download now for FREE > LinuxWorld Reader's Choice Award Winner for best database on Linux. > http://ads.osdn.com/?ad_id=5588&alloc_id=12065&op=click > _______________________________________________ > Hypercontent-users mailing list > Hyp...@li... > https://lists.sourceforge.net/lists/listinfo/hypercontent-users |