Re: XCSS?

2006-01-13 Thread Steve Metcalfe
Hi,

I havent seen the JXCSS library before, i'll have a look at that when
I get time.

I can't remember where I got this format of XML from, I think it was a
W3C mailing list, but nothing ever came of it.

Assuming an XCSS file like:

?xml version=1.0 encoding=UTF-8?
   style type=text/xcss
 rule
   selectors
 selector element= class=theme-href pseudo=/
   /selectors
   properties
 property name=color#fff/property
 property name=background-color#fff/property
 property name=margin-left1px/property
 property name=margin-right2px/property
   /properties
 /rule
 rule
   selectors
 selector element= class=theme-href pseudo=
   selector element=a class= pseudo=link/
 /selector
   /selectors
   properties
 property name=background-color#fff/property
 property name=color#fff/property
   /properties
 /rule
 rule
   selectors
 selector element= class=theme-href pseudo=
   selector element=a class= pseudo=visited/
 /selector
   /selectors
   properties
 property name=background-color#fff/property
 property name=color#fff/property
   /properties
 /rule
 rule
   selectors
 selector element= class=theme-para pseudo=/
   /selectors
   properties
 property name=background-color#fff/property
 property name=color#fff/property
   /properties
 /rule
   /style



XSLT:

xsl:stylesheet version=1.0 xmlns:xsl=http://www.w3.org/1999/XSL/Transform;
 xsl:output omit-xml-declaration=yes method=text/

 xsl:template match=[EMAIL PROTECTED] = 'text/xcss']
   xsl:apply-templates /
 /xsl:template

   xsl:template match=rulexsl:if test=count(
properties/property[text() != ''] )
   xsl:apply-templates select=selectors/selector/{
   xsl:apply-templates select=properties/property/
   }
   /xsl:if/xsl:template

   xsl:template match=selector
   xsl:value-of select=@element/
   xsl:if test=@class != ''.xsl:value-of select=@class//xsl:if
   xsl:if test=@pseudo != '':xsl:value-of
select=@pseudo//xsl:if
   xsl:text /xsl:text
   xsl:apply-templates select=selector/
   xsl:if test=position() != last(), /xsl:if
   /xsl:template

   xsl:template match=property
 xsl:if test=. != ''xsl:value-of select=@name/:
xsl:value-of select=./;
   /xsl:if/xsl:template

   /xsl:stylesheet

I have some perl scripts that will do a one-off conversion from CSS to
XCSS (if thats what the above is) if you want a look.

Steve Metcalfe

On 12/01/06, Stephen Winnall [EMAIL PROTECTED] wrote:
 Thanks, Chris. I find your solution rather clever. It avoids the
 necessity of an XCSS altogether,
 doesn't it? I like that.

 Steve

 On 12 Jan 2006, at 22:21, Chris Marasti-Georg wrote:

  source.css:
 
  css
  whatever {
  css: source;
  in: here;
  }
  and {
  an: i18n:tag here=/
  }
  /css
 
  ie.xslt:
 
  xsl:transform...
xsl:template match=/css
css
xsl:copy-of select=*
some {
ie: specific;
css: here;
}
with {
an: i18n:tag here=/
}
/css
/xsl:template
  /xsl:transform
 
  css.xslt:
 
  xsl:transform
xsl:template match=/css
xsl:value-of select=./
/xsl:template
  /xsl:transform
 
  Sitemap (pseudo):
 
  map:match *.css
map:generate source.css/
if browser is standards- and security-challenged {
map:transform ie.xslt/
}
map:transform I18N/
map:transform css.xslt/
map:serialise text/
  /map:match
 
  -Original Message-
  From: Stephen Winnall [mailto:[EMAIL PROTECTED]
  Sent: Thursday, January 12, 2006 3:49 PM
  To: users@cocoon.apache.org
  Cc: Bob Harner; Chris Marasti-Georg
  Subject: Re: XCSS?
 
  Thanks to Bob and Chris for their feedback.
 
  However, my question is not how to serve up different CSS
  files depending on the target browser. What I would like to
  do is create those different CSS files from a single source
  (e.g. a transformer creates different CSS files from a common
  source depending on what the target browser is). It seems to
  me that it would be trivial if CSS had an XML syntax: my
  questions are:
 
  1) is there a suitable XML DTD or schema for something (let's call it
  XCSS) which is 1-to-1
  mappable to CSS?
  2) does an appropriate transformation (or serialisation) from
  XCSS to CSS exist?
 
  One answer to 1) is yes, see JXCSS. An answer to 2) is what
  I am looking for.
 
  The pipeline should look something like the following (if
  you'll excuse the meta-syntax):
 
  match *.css
   generate XCSS from a single source
   if browser is standards- and security-challenged {
   transform the XCSS stream to suit
   }
   transform for I18N
   transform from XCSS to CSS
   

Cocoon 2.1.8 on Windows 2003 Server?

2006-01-13 Thread Derek Hohls
If anyone has any experience getting Cocoon to work
properly on a Windows 2003 Server, I would appreciate
hearing from you - some parts of an app are not working
and I think there might be security-related problems.

Thanks
Derek


-- 
This message is subject to the CSIR's copyright, terms and conditions and
e-mail legal notice. Views expressed herein do not necessarily represent the
views of the CSIR.
 
CSIR E-mail Legal Notice
http://mail.csir.co.za/CSIR_eMail_Legal_Notice.html 
 
CSIR Copyright, Terms and Conditions
http://mail.csir.co.za/CSIR_Copyright.html 
 
For electronic copies of the CSIR Copyright, Terms and Conditions and the CSIR
Legal Notice send a blank message with REQUEST LEGAL in the subject line to
[EMAIL PROTECTED]


This message has been scanned for viruses and dangerous content by MailScanner, 
and is believed to be clean.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Cocoon 2.1.8 on Windows 2003 Server?

2006-01-13 Thread Thomas.Soddemann

Derek Hohls wrote:


If anyone has any experience getting Cocoon to work
properly on a Windows 2003 Server, I would appreciate
hearing from you - some parts of an app are not working
and I think there might be security-related problems.

Thanks
Derek


 


Hi,

for testing purposes we had quite recently a tomcat/cocoon - jboss 
installation on Windows XP and Server 2003 running flawlessly. The only 
thing which needed fixing were paths in the configuration(s).


Regards,
Thomas


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



AW: Coplet and generator question

2006-01-13 Thread Christian Barth

Is it such a silly question? Or isn't it possible?
I'm new to Cocoon and really don't know how to manage it.
Is there a hint in the docu I missed?

Thanks,
Barthi
 

 -Ursprüngliche Nachricht-
 Von: Christian Barth [mailto:[EMAIL PROTECTED] 
 Gesendet: Donnerstag, 12. Januar 2006 17:40
 An: users@cocoon.apache.org
 Betreff: Coplet and generator question
 
 Hi, it's me again!
  
 I just wrote a new generator calculating some things in Java 
 and returning the results in an XML. This works fine.
  
 But...
  
 I need two coplets, one showing a kind of overview of the 
 result and the second one showing details of the result.
 
 Both have to be displayed on the same page. It would also be 
 nice if I could click something in the overview-coplet and 
 the details-coplet is updated.
 
 So how can I build two coplets from one data-source?
 
 Thanks,
 BArthi
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: XCSS?

2006-01-13 Thread Stephen Winnall
Thanks for this, Steve. It's what I originally asked for, but at the  
moment I tend towards
the solution which Chris came up with (stick css and /css round a  
straight CSS
file and treat everything inbetween as mixed) because it seems  
simpler (for some

subjective value of simple...).

Steve

On 13 Jan 2006, at 10:17, Steve Metcalfe wrote:


Hi,

I havent seen the JXCSS library before, i'll have a look at that when
I get time.

I can't remember where I got this format of XML from, I think it was a
W3C mailing list, but nothing ever came of it.

Assuming an XCSS file like:

?xml version=1.0 encoding=UTF-8?
   style type=text/xcss
 rule
   selectors
 selector element= class=theme-href pseudo=/
   /selectors
   properties
 property name=color#fff/property
 property name=background-color#fff/property
 property name=margin-left1px/property
 property name=margin-right2px/property
   /properties
 /rule
 rule
   selectors
 selector element= class=theme-href pseudo=
   selector element=a class= pseudo=link/
 /selector
   /selectors
   properties
 property name=background-color#fff/property
 property name=color#fff/property
   /properties
 /rule
 rule
   selectors
 selector element= class=theme-href pseudo=
   selector element=a class= pseudo=visited/
 /selector
   /selectors
   properties
 property name=background-color#fff/property
 property name=color#fff/property
   /properties
 /rule
 rule
   selectors
 selector element= class=theme-para pseudo=/
   /selectors
   properties
 property name=background-color#fff/property
 property name=color#fff/property
   /properties
 /rule
   /style



XSLT:

xsl:stylesheet version=1.0 xmlns:xsl=http://www.w3.org/1999/XSL/ 
Transform

 xsl:output omit-xml-declaration=yes method=text/

 xsl:template match=[EMAIL PROTECTED] = 'text/xcss']
   xsl:apply-templates /
 /xsl:template

   xsl:template match=rulexsl:if test=count(
properties/property[text() != ''] )
   xsl:apply-templates select=selectors/selector/{
   xsl:apply-templates select=properties/property/
   }
   /xsl:if/xsl:template

   xsl:template match=selector
   xsl:value-of select=@element/
   xsl:if test=@class != ''.xsl:value-of  
select=@class//xsl:if

   xsl:if test=@pseudo != '':xsl:value-of
select=@pseudo//xsl:if
   xsl:text /xsl:text
   xsl:apply-templates select=selector/
   xsl:if test=position() != last(), /xsl:if
   /xsl:template

   xsl:template match=property
 xsl:if test=. != ''xsl:value-of select=@name/:
xsl:value-of select=./;
   /xsl:if/xsl:template

   /xsl:stylesheet

I have some perl scripts that will do a one-off conversion from CSS to
XCSS (if thats what the above is) if you want a look.

Steve Metcalfe

On 12/01/06, Stephen Winnall [EMAIL PROTECTED] wrote:

Thanks, Chris. I find your solution rather clever. It avoids the
necessity of an XCSS altogether,
doesn't it? I like that.

Steve

On 12 Jan 2006, at 22:21, Chris Marasti-Georg wrote:


source.css:

css
whatever {
css: source;
in: here;
}
and {
an: i18n:tag here=/
}
/css

ie.xslt:

xsl:transform...
  xsl:template match=/css
  css
  xsl:copy-of select=*
  some {
  ie: specific;
  css: here;
  }
  with {
  an: i18n:tag here=/
  }
  /css
  /xsl:template
/xsl:transform

css.xslt:

xsl:transform
  xsl:template match=/css
  xsl:value-of select=./
  /xsl:template
/xsl:transform

Sitemap (pseudo):

map:match *.css
  map:generate source.css/
  if browser is standards- and security-challenged {
  map:transform ie.xslt/
  }
  map:transform I18N/
  map:transform css.xslt/
  map:serialise text/
/map:match


-Original Message-
From: Stephen Winnall [mailto:[EMAIL PROTECTED]
Sent: Thursday, January 12, 2006 3:49 PM
To: users@cocoon.apache.org
Cc: Bob Harner; Chris Marasti-Georg
Subject: Re: XCSS?

Thanks to Bob and Chris for their feedback.

However, my question is not how to serve up different CSS
files depending on the target browser. What I would like to
do is create those different CSS files from a single source
(e.g. a transformer creates different CSS files from a common
source depending on what the target browser is). It seems to
me that it would be trivial if CSS had an XML syntax: my
questions are:

1) is there a suitable XML DTD or schema for something (let's  
call it

XCSS) which is 1-to-1
mappable to CSS?
2) does an appropriate transformation (or serialisation) from
XCSS to CSS exist?

One answer to 1) is yes, see JXCSS. An answer to 2) is what
I am looking for.

The pipeline should look something like the following (if
you'll excuse the meta-syntax):

match *.css
 generate 

RE: Coplet and generator question

2006-01-13 Thread Ard Schrijvers

 
 Is it such a silly question? Or isn't it possible?

Probably not, but I do not really, and I suppose others as well, entirely grasp 
your problem. Lot's of people want to help at this list, but when a question is 
unclear, few answers are given. Probably silly of me, but I for example don't 
know what you mean with a coplet...If you explain a little more we can probably 
help you out

AS


 I'm new to Cocoon and really don't know how to manage it.
 Is there a hint in the docu I missed?
 
 Thanks,
 Barthi
  
 
  -Ursprüngliche Nachricht-
  Von: Christian Barth [mailto:[EMAIL PROTECTED] 
  Gesendet: Donnerstag, 12. Januar 2006 17:40
  An: users@cocoon.apache.org
  Betreff: Coplet and generator question
  
  Hi, it's me again!
   
  I just wrote a new generator calculating some things in Java 
  and returning the results in an XML. This works fine.
   
  But...
   
  I need two coplets, one showing a kind of overview of the 
  result and the second one showing details of the result.
  
  Both have to be displayed on the same page. It would also be 
  nice if I could click something in the overview-coplet and 
  the details-coplet is updated.
  
  So how can I build two coplets from one data-source?
  
  Thanks,
  BArthi
  
  
  
 -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
  
  
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: XCSS?

2006-01-13 Thread Peter Flynn
On Thu, 2006-01-12 at 18:37, Stephen Winnall wrote:
 I am setting up a website using Cocoon and want to generate XHTML and
 use CSS to handle the presentation. Like everyone else I am being
 bitten by the fact that 90% of all browsers conform to the CSS
 standard, but the browser that 90% of the users use does not :-(

grin
http://explorerdestroyer.com/
/grin

 Does anyone know of a way of writing something that could be called
 XCSS, i.e. CSS written in an XML syntax, which can be
 transformed/serialised into proper CSS?

This would be a useful project: to codify all known differences in CSS
support and behaviour between the browsers. DocBook already has the
structure needed to support effectivities and it would be fairly easy to
add or modify (eg making the vendor attribute IDREFS so you can make
robust references to the browser versions

funcsynopsis id=attr conformance=css2 vendor=ff1.5 ff1.4
  funcprototype
funcdefattr/funcdef
paramdefattribute name/paramdef
  /funcprototype
  funcsynopsisinfoReturns the value of the named attribute for
  the currently-selected element type./funcsynopsisinfo
/funcsynopsis

///Peter


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Cocoon 2.1.8 on Windows 2003 Server?

2006-01-13 Thread Schultz, Gary - COMM
I have Cocoon running on a Windows 2003 Server with no problems. Here is my
setup:

Compaq Deskpro 866 Mhz Pentium 3 256 MB Ram
Windows 2003 Server - Standard Edition Service Pack 1
Apache 2.0.55 (via XAMPP 1.5.0)
Java - j2sdk1.4.2_10
Tomcat 5.0.28 (configured to use the default 64 MB ram)
Cocoon 2.1.8

I had problems with Cocoon 2.1.8 when running under j2sdk 1.5.0_5. The
switch back to j2sdk 1.4.2_10 fixed the problems. For me it was more
important to use the latest version of Cocoon than the latest version of
j2sdk.

Here is a link to a web site running on this server
(http://comwebt.commerce.wi.gov). The home page is served by Apache, all
other pages are served by Cocoon.

Gary T. Schultz
IT Administrator
Wisconsin Department of Commerce
201 W. Washington Ave 
Madison, WI 53214
608-266-1283
[EMAIL PROTECTED]



-Original Message-
From: Derek Hohls [mailto:[EMAIL PROTECTED] 
Sent: Friday, January 13, 2006 3:32 AM
To: users@cocoon.apache.org
Subject: Cocoon 2.1.8 on Windows 2003 Server?

If anyone has any experience getting Cocoon to work properly on a Windows
2003 Server, I would appreciate hearing from you - some parts of an app are
not working and I think there might be security-related problems.

Thanks
Derek


--
This message is subject to the CSIR's copyright, terms and conditions and
e-mail legal notice. Views expressed herein do not necessarily represent the
views of the CSIR.
 
CSIR E-mail Legal Notice
http://mail.csir.co.za/CSIR_eMail_Legal_Notice.html 
 
CSIR Copyright, Terms and Conditions
http://mail.csir.co.za/CSIR_Copyright.html 
 
For electronic copies of the CSIR Copyright, Terms and Conditions and the
CSIR Legal Notice send a blank message with REQUEST LEGAL in the subject
line to [EMAIL PROTECTED]


This message has been scanned for viruses and dangerous content by
MailScanner, and is believed to be clean.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: XSP - What wrong??

2006-01-13 Thread Lars Huttar

Did you already figure out the fix to this problem?
Looking at your code, it seems to me that merkmal2 is defined in every 
context where it's accessed. Maybe if you look at the full generated 
Java code for this XSP page, you can determine why it cannot be resolved.


The generated Java code is usually in a place like
C:\Program Files\Apache Group\Tomcat 
5.5\work\Catalina\localhost\_\cocoon-files\org\apache\cocoon\www\mount\gem\error_xsp.java

(for an xsp page at cocoon\build\webapp\mount\gem\error.xsp).

Regards,
Lars

Christian Barth wrote:

Hi! I get an Error, that merkmal2 cannot be resolved. Why?

xsp:logic
Set keys = gewichte.keySet();
Iterator key_iter = keys.iterator();
int index = 0;
while (key_iter.hasNext()) {
String merkmal = (String) key_iter.next();
index++;
zeile
spalte
feld typ=text weite=25% 
xsp:attribute
name=valuexsp:exprgewichte.get(merkmal)/xsp:expr/xsp:attribute
xsp:attribute
name=namexsp:exprmerkmal/xsp:expr/xsp:attribute 
xsp:attribute
name=beschreibungxsp:exprmerkmal/xsp:expr/xsp:attribute
/feld
/spalte
if (key_iter.hasNext()) {
String merkmal2 = (String) key_iter.next();
spalte
feld typ=text weite=25% 
xsp:attribute
name=valuexsp:exprgewichte.get(merkmal2)/xsp:expr/xsp:attribute
xsp:attribute
name=namexsp:exprmerkmal2/xsp:expr/xsp:attribute
xsp:attribute
name=beschreibungxsp:exprmerkmal2/xsp:expr/xsp:attribute
/feld
/spalte
}
/zeile  
}
/xsp:logic  


Greets, Barthi
 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



XML parsing and map:handle-errors

2006-01-13 Thread Alexander Nofftz
Hi!

I use the portal engine to aggregate some RSS feeds. If some newsfeed
returns invalid XML, the whole portal isn't running anymore.

Some newsfeed returned incorrectly some HTML 404 page containing a
PUBLIC DOCTYPE without DTD reference. This breaks up everything. I tried
to catch this via map:handle-errors but this doesn't work in this
case.

Regards,
  Alex

-- 
Alexander Nofftz, Leverkusen, Germany, EU, Terra, Solar System
[EMAIL PROTECTED] --- http://www.AlexNofftz.de/
Jabber: [EMAIL PROTECTED] (Jabber?! http://de.wikipedia.org/wiki/Jabber)


signature.asc
Description: Digital signature


Re: Coplet and generator question

2006-01-13 Thread Lars Huttar

Ard Schrijvers wrote:

Is it such a silly question? Or isn't it possible?



Probably not, but I do not really, and I suppose others as well, entirely grasp 
your problem. Lot's of people want to help at this list, but when a question is 
unclear, few answers are given. Probably silly of me, but I for example don't 
know what you mean with a coplet...If you explain a little more we can probably 
help you out

AS

  

Excuse my ignorance, but is a coplet the same as a portlet?
I see lots of information about characteristics and usage of coplets on 
the Cocoon site and elsewhere; e.g.

http://cocoon.apache.org/2.1/apidocs/org/apache/cocoon/webapps/portal/components/Coplet.html
and
http://www.devlib.org/apache/cocoon/events/acd2003/10_MatthewLangham_TheCocoonPortal.pdf
but I can't find a definition of *what a coplet is*.
From Christian's email and other context, it seems to be a lot like a 
portlet.
But p. 19 of the above-mentioned PDF seems to distinguish between coplet 
and portlet.
Maybe a coplet is like a portlet but its content is generated from data 
configured as part of the portal, whereas a portlet takes its content 
from an external source?


Where did you first hear about coplets? Seems like I missed the memo. 
And wikipedia.org doesn't even have a page on coplets!  :-o


Thanks,
Lars
  

I'm new to Cocoon and really don't know how to manage it.
Is there a hint in the docu I missed?

Thanks,
Barthi
 



-Ursprüngliche Nachricht-
Von: Christian Barth [mailto:[EMAIL PROTECTED] 
Gesendet: Donnerstag, 12. Januar 2006 17:40

An: users@cocoon.apache.org
Betreff: Coplet and generator question

Hi, it's me again!
 
I just wrote a new generator calculating some things in Java 
and returning the results in an XML. This works fine.
 
But...
 
I need two coplets, one showing a kind of overview of the 
result and the second one showing details of the result.


Both have to be displayed on the same page. It would also be 
nice if I could click something in the overview-coplet and 
the details-coplet is updated.


So how can I build two coplets from one data-source?

Thanks,
BArthi


  



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Content negiation / fallback if document not found

2006-01-13 Thread Alexander Nofftz
Hi!

I want to do something like Apache Webserver's content negotiation using
MultiViews with Cocoon.

For example, I have documents like this:

  doc.de.xml
  doc.fr.xml
  doc.xml(default language)

And want to do something like this:

  map:act type=locale
map:match pattern=doc
  try {
map:generate src=doc.{../language}.xml/
  } catch (FileNotFoundException e) {
map:generate src=doc.xml/
  }
  map:serialize/
/map:match
  /map:act

Is something like this possible?

Thanks in advance,
  Alex

-- 
Alexander Nofftz, Leverkusen, Germany, EU, Terra, Solar System
[EMAIL PROTECTED] --- http://www.AlexNofftz.de/
Jabber: [EMAIL PROTECTED] (Jabber?! http://de.wikipedia.org/wiki/Jabber)


signature.asc
Description: Digital signature


Re: Coplet and generator question

2006-01-13 Thread christian bindeballe

Lars Huttar schrieb:


Coplet = COcocon PortLET :)

it is a part of the portal based on cocoon and can basically get its 
information from anywhere, inside or outside the server cocoon is 
running on.


regards, christian


Probably not, but I do not really, and I suppose others as well, 
entirely grasp your problem. Lot's of people want to help at this 
list, but when a question is unclear, few answers are given. Probably 
silly of me, but I for example don't know what you mean with a 
coplet...If you explain a little more we can probably help you out




Excuse my ignorance, but is a coplet the same as a portlet?
I see lots of information about characteristics and usage of coplets on 
the Cocoon site and elsewhere; e.g.
http://cocoon.apache.org/2.1/apidocs/org/apache/cocoon/webapps/portal/components/Coplet.html 


and
http://www.devlib.org/apache/cocoon/events/acd2003/10_MatthewLangham_TheCocoonPortal.pdf 




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Cocoon and xsl:output

2006-01-13 Thread ian . d . stewart
Dear List,

I have the following code in stylesheets/panelset2html.xsl:

xsl:output method=html version=4.01
doctype-public=-//W3C//DTD HTML 4.01 Frameset//EN
doctype-system=http://www.w3.org/TR/html4/frameset.dtd/

and the following in sitemap.xmap:

map:match pattern=
  map:generate src=views/index.xml type=jx
map:parameter name=lenient-xpath value=true/
  /map:generate
  map:transform src=stylesheets/panelset2html.xsl/
  map:serialize type=html/
/map:match

Based on this, I would expect the resulting HTML to containing the
following DOCTYPE:

  !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 Frameset//EN
http://www.w3.org/TR/html4/frameset.dtd;

Instead, I am getting:

  !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN
http://www.w3.org/TR/html4/loose.dtd;

Which MSIE doesn't seem to like in conjunction with the frameset element.

As far as I can tell, Cocoon is ignoring the xsl:output, and using
whatever is specified within the HTML Serializer configuration.

Is there a setting I can change to get Cocoon to respect the xsl:output,
or should I just configure a seperate instance of HTMLSerializer with the
appropriate doctype-public  and doctype-system values and use that instead
of the default serializer for frameset documents?


Thanks,
Ian

It's better to be hated for who you are
than loved for who you are not

Ian D. Stewart
Appl Dev Analyst-Advisory, DCS Automation
JPMorganChase Global Technology Infrastructure
Phone: (614) 244-2564
Pager: (888) 260-0078


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Cocoon and xsl:output

2006-01-13 Thread Sylvain Wallez

[EMAIL PROTECTED] wrote:

Dear List,

I have the following code in stylesheets/panelset2html.xsl:

xsl:output method=html version=4.01
doctype-public=-//W3C//DTD HTML 4.01 Frameset//EN
doctype-system=http://www.w3.org/TR/html4/frameset.dtd/
  


snip/

As far as I can tell, Cocoon is ignoring the xsl:output, and using
whatever is specified within the HTML Serializer configuration.
  


That's right. To understand why, you have to consider the two parts of 
an XSL engine:

- the transformation part, defined by the xsl templates
- the serialization part, whose behavior is driven by xsl:output

The XSL transformer in Cocoon uses... the transformation part! As a 
consequence, the xsl:output instruction is ignored.


The HTML serializer uses the serialization part of the same XSL engine, 
using an identity transformation that converts SAX events to a byte 
stream. This is where the doctype settings are taken into account.


You therefore have to define a different frameset-html serializer to 
have the appropriate doctype.


Sylvain

--
Sylvain WallezAnyware Technologies
http://bluxte.net http://www.anyware-tech.com
Apache Software Foundation Member Research  Technology Director


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Content negiation / fallback if document not found

2006-01-13 Thread Sylvain Wallez

Alexander Nofftz wrote:

Hi!

I want to do something like Apache Webserver's content negotiation using
MultiViews with Cocoon.

For example, I have documents like this:

  doc.de.xml
  doc.fr.xml
  doc.xml(default language)

And want to do something like this:

  map:act type=locale
map:match pattern=doc
  try {
map:generate src=doc.{../language}.xml/
  } catch (FileNotFoundException e) {
map:generate src=doc.xml/
  }
  map:serialize/
/map:match
  /map:act

Is something like this possible?
  


Yep, using the resource-exists selector:

map:match pattern=doc
 map:select type=resource-exists
   map:when test=doc.{../language}.xml/
 map:generate src=doc.{../language}.xml/
   /map:when
   map:otherwise
 map:generate src=doc.xml/
   /map:otherwise
 /map:select
/map:match

Sylvain

--
Sylvain WallezAnyware Technologies
http://bluxte.net http://www.anyware-tech.com
Apache Software Foundation Member Research  Technology Director


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: No log targets configured for the root logger

2006-01-13 Thread Ellis Pritchard

Hi,

Mike Dickson wrote:

Any ideas on what is up given the following error and logkit.xconf? 

 


Error:

 

org.apache.avalon.framework.configuration.ConfigurationException: No 
log targets configured for the root logger.
at 
org.apache.avalon.excalibur.logger.LogKitLoggerManager.setupLoggers(LogKitLoggerManager.java:531)
at 
org.apache.avalon.excalibur.logger.LogKitLoggerManager.configure(LogKitLoggerManager.java:407)
at 
org.apache.avalon.framework.container.ContainerUtil.configure(ContainerUtil.java:240)
at 
org.apache.cocoon.servlet.CocoonServlet.initLogger(CocoonServlet.java:826)
at 
org.apache.cocoon.servlet.CocoonServlet.init(CocoonServlet.java:311)
 


You need to have a category with name=

   category log-level=INFO name=
 log-target id-ref=core/
 log-target id-ref=error/
   /category

This is the root logger category; it's in there in the shipping 
logkit.xconf, I suggest you restore it...


Ellis.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



AW: XSP - What wrong??

2006-01-13 Thread Christian Barth
It's already solved. Thank you.
It needed another xsp:logic-Tag surrounding the second if-Clause.

Barthi

 -Ursprüngliche Nachricht-
 Von: Lars Huttar [mailto:[EMAIL PROTECTED]
 Gesendet: Freitag, 13. Januar 2006 17:17
 An: users@cocoon.apache.org
 Betreff: Re: XSP - What wrong??
 
 Did you already figure out the fix to this problem?
 Looking at your code, it seems to me that merkmal2 is defined in every
 context where it's accessed. Maybe if you look at the full generated
 Java code for this XSP page, you can determine why it cannot be resolved.
 
 The generated Java code is usually in a place like
 C:\Program Files\Apache Group\Tomcat
 5.5\work\Catalina\localhost\_\cocoon-
 files\org\apache\cocoon\www\mount\gem\error_xsp.java
 (for an xsp page at cocoon\build\webapp\mount\gem\error.xsp).
 
 Regards,
 Lars
 
 Christian Barth wrote:
  Hi! I get an Error, that merkmal2 cannot be resolved. Why?
 
  xsp:logic
  Set keys = gewichte.keySet();
  Iterator key_iter = keys.iterator();
  int index = 0;
  while (key_iter.hasNext()) {
  String merkmal = (String) key_iter.next();
  index++;
  zeile
  spalte
  feld typ=text weite=25% 
  xsp:attribute
  name=valuexsp:exprgewichte.get(merkmal)/xsp:expr/xsp:attribute
  xsp:attribute
  name=namexsp:exprmerkmal/xsp:expr/xsp:attribute
  xsp:attribute
  name=beschreibungxsp:exprmerkmal/xsp:expr/xsp:attribute
  /feld
  /spalte
  if (key_iter.hasNext()) {
  String merkmal2 = (String) key_iter.next();
  spalte
  feld typ=text weite=25% 
  xsp:attribute
  name=valuexsp:exprgewichte.get(merkmal2)/xsp:expr/xsp:attribute
  xsp:attribute
  name=namexsp:exprmerkmal2/xsp:expr/xsp:attribute
  xsp:attribute
  name=beschreibungxsp:exprmerkmal2/xsp:expr/xsp:attribute
  /feld
  /spalte
  }
  /zeile
  }
  /xsp:logic
 
 
  Greets, Barthi
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Content negiation / fallback if document not found

2006-01-13 Thread Jason Johnston
 Hi!

 I want to do something like Apache Webserver's content negotiation using
 MultiViews with Cocoon.

 For example, I have documents like this:

   doc.de.xml
   doc.fr.xml
   doc.xml(default language)

 And want to do something like this:

   map:act type=locale
 map:match pattern=doc
   try {
 map:generate src=doc.{../language}.xml/
   } catch (FileNotFoundException e) {
 map:generate src=doc.xml/
   }
   map:serialize/
 /map:match
   /map:act

 Is something like this possible?


Does the ResourceExistsSelector meet your need?
http://cocoon.apache.org/2.1/userdocs/resourceexists-selector.html

map:act type=locale
   map:match pattern=doc
  map:select type=resource-exists
 map:when test=doc.{../language}.xml
map:generate src=doc.{../language}.xml/
 /map:when
 map:otherwise
map:generate src=doc.xml/
 /map:otherwise
  /map:select
  map:serialize/
   /map:match
/map:act


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Binding selection boxes to beans in cocoon forms?

2006-01-13 Thread Andre Cesta

Can anybody answer this?  Perhaps send me an email with
working selection box - bean binding classes/pipeline/forms 
example?

--- Andre Cesta [EMAIL PROTECTED] wrote:

 Hi,
 
 I wonder if you can help me bind selection boxes to beans.
 (other properties on this very same form are binding just fine)
 
 Code snippets and exception for my attempt are shown below.
 I've searched the list archives and web without luck for solutions.  The 
 cocoon samples (car,
 country selectors are for XML binding and did not help much on the bean 
 binding side).
 8-
 Software: a study project on the area of hotel rooms management,
 where room type is (luxe, standard, etc).
 8-
 Cocoon version: 2.1.7
 --Bean Room.java (also questions posed on comments-
 public class Room ...
 
 public Collection getRoomTypes() throws ... {
 //returns a LinkedList by the way.
 }
 
 public void setRoomType(RoomType roomType) {
 //Should I also provide a overriden version with Long argument
 //to set the room type for binding reasons?
 ...
 }
 
 public RoomType getRoomType() {
 ...
 }
 --room_model.xml8-
 ...
 /fd:field
 fd:field id=roomType required=true
   fd:datatype base=long/
   fd:selection-list type=flow-jxpath list-path=roomTypes 
 label-path=description
 value-path=id /
   fd:labelRoom type:/fd:label
 /fd:field
   /fd:widgets
 ...
 --Exception thrown by cocoon8-
 An Error Occurred
 Incorrect value type for data.roomType (expected class java.lang.Long, got 
 class
 br.com.hotelman.datatypes.RoomType).
 
 org.apache.avalon.framework.CascadingRuntimeException:
 resource://org/apache/cocoon/forms/flow/javascript/Form.js, line 184: 
 uncaught JavaScript
 exception: at room (file:/C:/cocoon-2.1.7/build/webapp/forms2/flow/room.js, 
 Line 28) at
 (resource://org/apache/cocoon/forms/flow/javascript/Form.js, Line 184):
 java.lang.RuntimeException: Incorrect value type for data.roomType 
 (expected class
 java.lang.Long, got class br.com.hotelman.datatypes.RoomType).
 
 cause: java.lang.RuntimeException: Incorrect value type for data.roomType 
 (expected class
 java.lang.Long, got class br.com.hotelman.datatypes.RoomType).
 ---Room.js (flow)---8-
 function room(form) {
 var id = cocoon.request.getParameter(id);
 var room = null;
 room = Packages.br.com.hotelman.datatypes.Room.findById(id);
 form.load(room);
 form.showForm(room-display-pipeline);
 form.save(room);
 cocoon.sendPage(room-success-pipeline, { room: room });
 }
 --Pipeline---8-
  map:match pattern=room.flow*
map:call function=handleForm
  map:parameter name=function value=room/
  map:parameter name=form-definition value=forms/room_model.xml/
  map:parameter name=bindingURI value=forms/room_bind_bean.xml/
/map:call
  /map:match
 --Template room_template.xml8-
 ...
   br/
   ft:widget-label id=roomType/
   ft:widget id=roomType/
   br/
 ...
   input type=submit/
 ...
 
 ---room_bind_bean.xml---8-
 
   fb:value id=roomType path=roomType/
   fb:value id=lastInspected path=lastInspected/
 /fb:context
 8-
 
 Feel free to package your working selection box form files and
 bean and send to [EMAIL PROTECTED] so I can use as example.
 
 Kind regards, Andre
 
 
   
 ___ 
 NEW Yahoo! Cars - sell your car and browse thousands of new and used cars 
 online!
 http://uk.cars.yahoo.com/
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 






___ 
Yahoo! Messenger - NEW crystal clear PC to PC calling worldwide with voicemail 
http://uk.messenger.yahoo.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]