I would think that a new bar would be something that the interpreter of your
XML file would put in based on content it sees in the xml file...

(i.e. <SectionThatGrows> would imply that the section would be prefaced with
a new bar before it was output...)

The new bar itself probably doesn't belong in an xml file unless that xml
file is going to be spat out to some kind of web browser, but you probably
have your reason for wanting to do it that way in the first place...

Sorry I can't be of more help.

Ryan


On 1/9/07 10:43 AM, "Ben Brock" <[email protected]> wrote:

> Thanks for the reply. I'm actually trying to create an XML file (not an
> HTML file) using a JSP template. Putting the new bar into an xml/jsp
> template probably isn't the best way to go about this, but I'm not sure
> what the best alternative is.
> 
> 
> Regards,
>  
> Ben 
> 
> -----Original Message-----
> From: [email protected] [mailto:[EMAIL PROTECTED]
> Sent: 09 January 2007 17:36
> To: [email protected]
> Subject: Re: [magnolia-user] XML templates
> 
> Are you asking about how to make the JSP templates using the xml format,
> or something else?
> 
> All of the template pages I've made for magnolia have been done in the
> xml format. 
> 
> Here's an exceprt of the start of one of my jsp templates. Some of the
> taglibs I'm using will not apply in your case, but maybe this will help
> you:
> 
> <jsp:root version="2.0" xmlns:jsp="http://java.sun.com/JSP/Page";
> xmlns:cms="urn:jsptld:cms-taglib"
>   xmlns:cmsu="urn:jsptld:cms-util-taglib"
> xmlns:c="urn:jsptld:http://java.sun.com/jsp/jstl/core";
>   xmlns:fmt="urn:http://java.sun.com/jsp/jstl/fmt";
>   xmlns:fn="http://java.sun.com/jsp/jstl/functions";
>   xmlns:img="urn:jsptld:/WEB-INF/taglibs-image.tld">
>   <jsp:directive.page contentType="text/html; charset=UTF-8"
> session="false"/>
>   <jsp:text>
>     <![CDATA[<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
>     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";> ]]>
>   </jsp:text>
>   
>   <html xmlns="http://www.w3.org/1999/xhtml"; xml:lang="en" lang="en">
>   <head>
>       <link rel="stylesheet" type="text/css"
> href="${pageContext.request.contextPath}/docroot/sb/css/sb_style.css" />
>      <title> 
>           <c:out value="${actpage.title}"/>
>       </title> 
>       <meta name="description"
> content="${pageProperties.metaDescription}"
> />
>      <meta name="keywords" content="${pageProperties.metaKeywords}" />
>   </head>
> <cms:setNode var="pageProperties" /> <!-- this lets me later use the
> {$pageProperties} to access this page's variables inside a tag -->
> <body>  <cms:mainBar paragraph="sbPageProperties"/>
> 
> The part of my template that includes the CMS "new" bar thing is later
> on, and it reads like this:
> 
> <cms:contentNodeIterator
> contentNodeCollectionName="mainColumnParagraphs">
>   <cms:out nodeDataName="lineAbove" var="lineAbove" />
>   <cms:editBar adminOnly="true" />
>   <cms:includeTemplate />
> </cms:contentNodeIterator>
> 
> This might not answer your question at all, but figured I would throw it
> back in case it helped.
> 
> Ryan
>  
> 
> 
> On 1/9/07 9:57 AM, "Ben Brock" <[email protected]> wrote:
> 
>> Hello List.
>>  
>> I have a need to create some simple XML templates. If I'm not
>> mistaken, the imports are the most important thing to get correct.
>> When my template renders as XML, it has problems w/ the Magnolia cms
>> bars. Is there a simple fix for this?
>>  
>> <?xml version="1.0" encoding="iso-8859-1" ?>
>>  
>> <jsp:root version="1.2" xmlns:jsp="http://java.sun.com/JSP/Page";
>> xmlns:cms="urn:jsptld:cms-taglib"
>>     xmlns:cmsu="urn:jsptld:cms-util-taglib"
>> xmlns:c="urn:jsptld:http://java.sun.com/jsp/jstl/core";>
>>     <jsp:directive.page import="info.magnolia.cms.util.Resource"/>
>>     
>> <Container>
>> <Contents>
>>   <Content Type="paragraph">
>>     <![CDATA[ 
>>           <c:import url="/templates/jsp/marketing/global/content.jsp"
> />
>>           <c:import
>> url="/templates/jsp/marketing/global/contentNewBar.jsp" />
>>      ]]> 
>>     </Content>
>> </Contents>
>> </Container>
>> </jsp:root>
>>  
>>  
>> Regards,
>>  
>> Ben Brock
>> 
>> ----------------------------------------------------------------
>> for list details see
>> http://www.magnolia.info/en/magnolia/developer.html
>> ----------------------------------------------------------------
> 
> 
> ----------------------------------------------------------------
> for list details see
> http://www.magnolia.info/en/magnolia/developer.html
> ----------------------------------------------------------------
> 
> ----------------------------------------------------------------
> for list details see
> http://www.magnolia.info/en/magnolia/developer.html
> ----------------------------------------------------------------


----------------------------------------------------------------
for list details see
http://www.magnolia.info/en/magnolia/developer.html
----------------------------------------------------------------

Reply via email to