Re: Cocoon use worldwide

2003-01-31 Thread Thor Heinrichs-Wolpert
I'm just North of you in BC and I'm using Cocoon on my project.

I'm sure there are others, but the 2 biggest things I've seen is the 
lack of diverse clients locally.  By that I mean the really poor 
telephony networks across NA compared to other areas means I rarely see 
or build stuff for local clients that isn't focused on IE as the 
primary client.  For customers that businesses abroad, you get more 
diversity in the devices used and a greater need to support them.
The other thing that I've seen is that many in the Java community focus 
only on JSP frameworks and extensions to them, as opposed to alternate 
standards such as XForms (for example).

Cheers,
Thor HW

On Thursday, January 30, 2003, at 09:48  PM, Jeff Ramsdale wrote:

Hi all,

I'm just curious about something. I've been reading the Cocoon-users 
list
for a couple of weeks or so and I see a lot of folks in Europe (and
Australia--Jeff T!) interested in Cocoon. I'm sure it's not a matter of
Americans ( Canadians?) not being interested, I'm sure. (Oh,  
Antonio, I
don't want to leave you out!) Right?

With the utmost respect for the Project I observe that Cocoon is a bit 
of a
fringe product as far as web development is concerned. I happen to 
believe
this fringe is the leading edge of something big, which is why I'm 
here.
So here's my question: If any of what I've said above has truth in it, 
is
there a particular reason why Cocoon might have special appeal to 
Europeans?
Is there something about the mindset of European programmers that 
leads them
to Cocoon? Is Open-Source Software viewed differently, on the whole, in
Europe than America? Does this have anything to do with Microsoft's
influence in America? I guess that's more than one question! 
Interested in
your observations...

Reason I ask... I live in Seattle (Microsoft-land), and I'd love to 
find
work using Cocoon and/or Java (but especially Cocoon!), but I don't 
see as
much mindshare here as I think it deserves.

Jeff



-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: name an output-file dynamically in cocoon?

2003-01-31 Thread Konstantin Piroumian
From: [EMAIL PROTECTED]

 Hi again,

 is it possible to name an output-file dynamically in cocoon.

 E.g. a pdf is created that has the name report_31_01_2003.pdf because its
 the 31 Jan 2003 (or report_GSM.pdf because I got a parameter with the
value
 GSM).

 Is this possible at runntime?

What do you mean by the output file name? Is it the Content-Disposition
header? For this you should use an action, otherwise you would need to
extend the serializer, but serializers cannot get runtime parameters (at
lease it was so in 2.0.3).


 To keep up an other question, about why map:serialize type doesn't like
 my {xxx}-returns:

I thought that I've already answered to this. See my previous post on your
question.
Generally, the 'type' attribute cannot be dynamic, because the pipeline is
constructed before processing.

--
  Konstantin


 In your particular case it'd be much better to return two values from
the
 action, just you different keys in the HashMap to do it:

 results.put(xsl-choice, style _16);
 results.put(format, fo2pdf);

 and then use it in your sitemap like this:

 map:match pattern=blabla
  map:act type=allSelect
 map:generate src=sampleoutput.xml/
 map:transform src=stylesheets/{xsl-choice}
 _{format}.xsl/
 map:serialize type={format}/
  /map:act
 /map:match


 The  map:transform src={xsl-choice}_{format}.xsl/  part works great.

 But the  map:serialize type={format}/  doesnt work. I always get a
 Resource not found error.
 If I type in the type manually (e.g.  map:serialize type=fo2pdf/ )
it
 works.

 What could cause this problem?
 I wonder especially because the {format} in  map:transform src
 =stylesheets/{xsl-choice}_{format}.xsl/  works.

 Cheers
 Jonny


 --
--

 This electronic message contains information from the mmo2 plc Group which
 may be
 privileged or confidential. The information is intended to be for the use
 of the
 individual(s) or entity named above. If you are not the intended recipient
 be aware
 that any disclosure, copying, distribution or use of the contents of this
 information
 is prohibited. If you have received this electronic message in error,
 please notify
 us by telephone or email (to the numbers or address above) immediately.




 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: convert text in xml wel form

2003-01-31 Thread jtacaoio

Hi Angelo, 

You can convert structured text to XML with Chaperon parser generator 
(a parser because it parses the text and generator because it creates 
an XML document) which is integrated in cocoon as a generator.

See for more details:
http://chaperon.sourceforge.net/
http://xml.apache.org/cocoon/howto/chaperon/howto-chaperon-intro.html

My sitemap example:
map:match pattern=MAST_TXT2MAST_XMLresponse
map:act type=myFileUpload !--action for getting the uploaded 
text file, returning fileName in {src} sitemap parameter--
map:parameter name=file-name value=mast/ !--file-name 
attribute in the HTML form--
map:generate type=textparser src={src} !--
text2chaperonXML--
map:parameter name=grammar value=cocoon:/mast-
out.grm/ !--the grammar describing my text file structure and 
vocabulary--
map:parameter name=includeignorabletokens value=true/
/map:generate
map:transform src=stylesheets/chaperon2mastXML.xsl/ !--
chaperonXML2myXML--
map:transform type=myAddDocDB !--save XML to eXist--
map:parameter name=dom-name value=DBresult/
map:parameter name=dom-root-element value=Mast_Result/
map:parameter name=collection value=/Ruben/
map:parameter name=id value=Robot_Teleoperado.xml/
/map:transform
map:transform type=xalan src=stylesheets/simple-
xml2html.xsl/ !--visualize XML in Mozilla--
map:serialize/
/map:act
/map:match

map:match pattern=*.grm !--convert txt grammar to xml grammar--
map:generate type=textparser src=grammars/{1}.rgrm
map:parameter name=grammar value=grammars/rgrm.grm/
/map:generate
map:transform src=stylesheets/rgrm2grm.xsl/
map:serialize type=xml/
/map:match

Oskar


 --- Reçu de   INFETUDE.G145193 02/250.96.71  30-01-03 
08.25
 
 Hi,
 
 I am beginner with cocoon.
 I want convert a file text in xml wel form.
 The string text is
   .SE NAME 'toto   '
   .SE ADRESS 'xxyy jj'
   .SE TEL '01236547'
 ...
 I want convert data in xml
   NAMEtoto/NAME
   ADRESSxxyy jj/ADRESS
   TEL01236547/TEL
 ...
 It's possible??
 Are you a sample of this use (sitemap and stylesheet)
 
 Thanks.
 Angelo
 
  30-01-03 08.25  Envoyé à  ---
-
   - [EMAIL PROTECTED]
 
 
 **
 This email and any files transmitted with it are confidential and
 intended solely for the use of the individual or entity to whom they
 are addressed. If you have received this email in error please notify
 the system manager.
 
 
 [EMAIL PROTECTED]
 ***
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
 
 





-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Problem with special character (JSP) éà

2003-01-31 Thread CARLETTA ANGELO
--- Reçu de   INFETUDE.G145193 02/250.96.71  31-01-03 09.39

From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Date: Tue, 28 Jan 2003 13:11:00 +0100
Subject: special character (JSP) éà

--- Reçu de   INFETUDE.G145193 02/250.96.71  28-01-03 13.11

Hi,

I have a problem with character encoding in Cocoon with character French
(éà..)
I have Tomcat 4.1.12, JDK 1.3 and Cocoon 2.0.3
My JSP is generate via VaGen (VisualAge generator of IBM)

Without Cocoon, the application run correctely. I have in my JSP
meta http-equiv=Content-Type content=text/html; charset=ISO-8859-1
The form and data entry are correct without cocoon

With cocoon, the form is correct (with charset=UTF-8 in JSP)
  meta http-equiv=Content-Type content=text/html; charset=UTF-8
but the data entry is not correct, e.g. enter data René give following
result : René

A part of Core.log after entry data in JSP
--
CONTEXT PATH: /VagenWebModule
SERVLET PATH: /JAH0001WUI.jsp
PATH INFO: null

REMOTE HOST: localhost
REMOTE ADDRESS: 127.0.0.1
REMOTE USER: null
REQUEST SESSION ID: 9C392441C5CCA3C8D565427BA033DE2F
REQUEST PREFERRED LOCALE: fr_BE
SERVER HOST: localhost
SERVER PORT: 8080

METHOD: POST
CONTENT LENGTH: 324
PROTOCOL: HTTP/1.1
SCHEME: http
AUTH TYPE: null

CURRENT ACTIVE REQUESTS: 1
REQUEST PARAMETERS:

PARAM: 'hptRecord' VALUES: '[JAH0001WUI]'
PARAM: 'hptExec' VALUES: '[Y]'
PARAM: 'XLOC002' VALUES: '[STREPY BRACQUEGNIES]'
PARAM: 'MESSAGE' VALUES: '[]'
PARAM: 'ENREGISTRER-BUTTOM' VALUES: '[Enregistrer]'
PARAM: 'NOAGENT' VALUES: '[06662]'
PARAM: 'EMAIL' VALUES: '[]'
PARAM: 'RL' VALUES: '[FR]'
PARAM: 'TEL' VALUES: '[078159090]'
PARAM: 'XNUM007' VALUES: '[715]'
PARAM: 'FIELDCURSOR' VALUES: '[NOAGENT]'
PARAM: 'ORB-RETURNCD' VALUES: '[]'
PARAM: 'XNUM017' VALUES: '[77]'
PARAM: 'XNOM002' VALUES: '[AGENCE DE LA LOUVIERE]'
PARAM: 'XCOD707' VALUES: '[CONSEILLER  ]'
PARAM: 'XNOM001' VALUES: '[BERTONI, René]'!-- result --
PARAM: 'XCOD013B' VALUES: '[7110]'
PARAM: 'XRUE001' VALUES: '[RUE DE LA CROIX ROUGE, 15]'
PARAM: 'XNUM040' VALUES: '[3568]'
PARAM: 'hptAppId' VALUES: '[JAH0001]'
PARAM: 'XCOD004' VALUES: '[FR ]'
HEADER PARAMETERS:

PARAM: 'accept' VALUES: '[application/vnd.ms-excel, application/msword,
application/vnd.ms-powerpoint, image/gif, image/x-xbitmap, image/jpeg,
image/pjpeg, */*]'
PARAM: 'referer' VALUES:
'[http://localhost:8080/VagenWebModule/vgnt?hptAppId=JAH0001hptExec=YhptR
ecord=JAH0001WUI]'
--

I have add in the Sitemap.xmap, but the result is same

map:serializer logger=sitemap.serializer.xml mime-type=text/xml
name=xml src=org.apache.cocoon.serialization.XMLSerializer
  encodingUTF-8/encoding
/map:serializer

map:serializer logger=sitemap.serializer.html mime-type=text/html
name=html pool-grow=4 pool-max=32 pool-min=4
src=org.apache.cocoon.serialization.HTMLSerializer
  encodingUTF-8/encoding
  omit-xml-declarationtrue/omit-xml-declaration
  buffer-size1024/buffer-size
/map:serializer
.
map:action name=set-encoding
src=org.apache.cocoon.acting.SetCharacterEncodingAction/
.
  map:act type=set-encoding
map:parameter name=form-encoding value=UTF-8/
  /map:act

With ISO-8859-1 in JSP, the form and data entry are not correct.

Thanks for your help
Angelo

 28-01-03 13.11  Envoyé à  
  - [EMAIL PROTECTED]


**
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.


[EMAIL PROTECTED]
***


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




This footnote confirms that this email message has been checked
for the presence of computer viruses.

 31-01-03 09.39  Envoyé à  -
  - [EMAIL PROTECTED]


**
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.


[EMAIL PROTECTED]
***


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

To unsubscribe, 

Re: name an output-file dynamically in cocoon?

2003-01-31 Thread Johannes . Becker

Hi Konstantin,

 I thought that I've already answered to this. See my previous post on
your question.
 Generally, the 'type' attribute cannot be dynamic, because the pipeline
is
 constructed before processing.

I asked because you posted this before:

***

This won't work, you should use nested actions in such cases. Actions work
like an if ... else ... statement: if an action returns a non-null value
then it's contents is processed, otherwise the following part is processed.

In your particular case it'd be much better to return two values from the
action, just you different keys in the HashMap to do it:

results.put(xsl-choice, style.xsl);
results.put(format, pdf);  //shouldn't it be fo2pdf

and then use it in your sitemap like this:

map:match pattern=blabla
 map:act type=allSelect
map:generate src=sampleoutput.xml/
map:transform src=stylesheets/{xsl-choice}.xsl/
map:serialize type={format}/
 /map:act
  /map:match

This one should work fine. But it'd be even better if you've used input
modules instead of an action. Something like this:

map:match pattern=blabla
  map:generate src=sampleoutput.xml/
  map:transform
src=stylesheets/{request-param:report_id}{request-param:service_id}
_{reques
t-param:output_id}.xsl/
  map:serialize type={request-param:output_id}/
  /map:match

--
  Konstantin



Ok. Now I know that its impossible.

Thanks
Jonny



This electronic message contains information from the mmo2 plc Group which
may be
privileged or confidential. The information is intended to be for the use
of the
individual(s) or entity named above. If you are not the intended recipient
be aware
that any disclosure, copying, distribution or use of the contents of this
information
is prohibited. If you have received this electronic message in error,
please notify
us by telephone or email (to the numbers or address above) immediately.



|-+
| |   Konstantin  |
| |   Piroumian   |
| |   kpiroumian@apach|
| |   e.org   |
| ||
| |   01/31/03 09:17 AM|
| |   Please respond to|
| |   cocoon-users |
| ||
|-+
  
--|
  |
  |
  |   To:   [EMAIL PROTECTED]  
  |
  |   cc:  
  |
  |   Subject:  Re: name an output-file dynamically in cocoon? 
  |
  
--|




From: [EMAIL PROTECTED]

 Hi again,

 is it possible to name an output-file dynamically in cocoon.

 E.g. a pdf is created that has the name report_31_01_2003.pdf because its
 the 31 Jan 2003 (or report_GSM.pdf because I got a parameter with the
value
 GSM).

 Is this possible at runntime?

What do you mean by the output file name? Is it the Content-Disposition
header? For this you should use an action, otherwise you would need to
extend the serializer, but serializers cannot get runtime parameters (at
lease it was so in 2.0.3).


 To keep up an other question, about why map:serialize type doesn't
like
 my {xxx}-returns:

I thought that I've already answered to this. See my previous post on your
question.
Generally, the 'type' attribute cannot be dynamic, because the pipeline is
constructed before processing.

--
  Konstantin


 In your particular case it'd be much better to return two values from
the
 action, just you different keys in the HashMap to do it:

 results.put(xsl-choice, style _16);
 results.put(format, fo2pdf);

 and then use it in your sitemap like this:

 map:match pattern=blabla
  map:act type=allSelect
 map:generate src=sampleoutput.xml/
 map:transform src=stylesheets/{xsl-choice}
 _{format}.xsl/
 map:serialize type={format}/
  /map:act
 /map:match


 The  map:transform src={xsl-choice}_{format}.xsl/  part works
great.

 But the  map:serialize type={format}/  doesnt work. I always get 

Re: substring-before()

2003-01-31 Thread Thorsten Scherler
Thanks!

Joerg Heinicke wrote:

Thorsten Scherler wrote:


Jupp, thanks!

What would be an appropriate XSLT forum?

Any recommendations?



http://www.mulberrytech.com/xsl/xsl-list/

Joerg


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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





-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: name an output-file dynamically in cocoon?

2003-01-31 Thread Andreas Bednarz
Ho Dorthe,

kannst Du uns zwei Resieanträge in Blanko ausdrucken?

Andreas

Am Fre, 2003-01-31 um 09.47 schrieb [EMAIL PROTECTED]:
 Hi Konstantin,
 
  I thought that I've already answered to this. See my previous post on
 your question.
  Generally, the 'type' attribute cannot be dynamic, because the pipeline
 is
  constructed before processing.
 
 I asked because you posted this before:
 
 ***
 
 This won't work, you should use nested actions in such cases. Actions work
 like an if ... else ... statement: if an action returns a non-null value
 then it's contents is processed, otherwise the following part is processed.
 
 In your particular case it'd be much better to return two values from the
 action, just you different keys in the HashMap to do it:
 
 results.put(xsl-choice, style.xsl);
 results.put(format, pdf);  //shouldn't it be fo2pdf
 
 and then use it in your sitemap like this:
 
 map:match pattern=blabla
  map:act type=allSelect
 map:generate src=sampleoutput.xml/
 map:transform src=stylesheets/{xsl-choice}.xsl/
 map:serialize type={format}/
  /map:act
   /map:match
 
 This one should work fine. But it'd be even better if you've used input
 modules instead of an action. Something like this:
 
 map:match pattern=blabla
   map:generate src=sampleoutput.xml/
   map:transform
 src=stylesheets/{request-param:report_id}{request-param:service_id}
 _{reques
 t-param:output_id}.xsl/
   map:serialize type={request-param:output_id}/
   /map:match
 
 --
   Konstantin
 
 

 
 Ok. Now I know that its impossible.
 
 Thanks
 Jonny
 
 

 
 This electronic message contains information from the mmo2 plc Group which
 may be
 privileged or confidential. The information is intended to be for the use
 of the
 individual(s) or entity named above. If you are not the intended recipient
 be aware
 that any disclosure, copying, distribution or use of the contents of this
 information
 is prohibited. If you have received this electronic message in error,
 please notify
 us by telephone or email (to the numbers or address above) immediately.
 
 
 
 |-+
 | |   Konstantin  |
 | |   Piroumian   |
 | |   kpiroumian@apach|
 | |   e.org   |
 | ||
 | |   01/31/03 09:17 AM|
 | |   Please respond to|
 | |   cocoon-users |
 | ||
 |-+
   
--|
   |  
|
   |   To:   [EMAIL PROTECTED]
|
   |   cc:
|
   |   Subject:  Re: name an output-file dynamically in cocoon?   
|
   
--|
 
 
 
 
 From: [EMAIL PROTECTED]
 
  Hi again,
 
  is it possible to name an output-file dynamically in cocoon.
 
  E.g. a pdf is created that has the name report_31_01_2003.pdf because its
  the 31 Jan 2003 (or report_GSM.pdf because I got a parameter with the
 value
  GSM).
 
  Is this possible at runntime?
 
 What do you mean by the output file name? Is it the Content-Disposition
 header? For this you should use an action, otherwise you would need to
 extend the serializer, but serializers cannot get runtime parameters (at
 lease it was so in 2.0.3).
 
 
  To keep up an other question, about why map:serialize type doesn't
 like
  my {xxx}-returns:
 
 I thought that I've already answered to this. See my previous post on your
 question.
 Generally, the 'type' attribute cannot be dynamic, because the pipeline is
 constructed before processing.
 
 --
   Konstantin
 
 
  In your particular case it'd be much better to return two values from
 the
  action, just you different keys in the HashMap to do it:
 
  results.put(xsl-choice, style _16);
  results.put(format, fo2pdf);
 
  and then use it in your sitemap like this:
 
  map:match pattern=blabla
   map:act type=allSelect
  map:generate src=sampleoutput.xml/
  map:transform 

Re: Cocoon use worldwide

2003-01-31 Thread Antonio Gallardo
Jeff Ramsdale dijo:
 Hi all,

 I'm just curious about something. I've been reading the Cocoon-users
 list for a couple of weeks or so and I see a lot of folks in Europe (and
 Australia--Jeff T!) interested in Cocoon. I'm sure it's not a matter of
 Americans ( Canadians?) not being interested, I'm sure. (Oh,  Antonio,
 I don't want to leave you out!) Right?

I know that, thanks to include me in this philosophical thread.! ;-)

When I started working with Cocoon, I noted that the almost people working
here is from Europe. But to be true I never asked my self about this
inetereting question.

First of all, I think I can speak a little about the 2 worlds. I am from
Nicaragua (from the ones that dont know where is it - my country is the
center of America. Check a map a you will see I am right) ;-)

As a Latinoamerican I had the opportunity to studies my university at
Technical University at Kosice, Slovakia (Please, this is not the old
Yugoslavia, there is Slovenia. Slovakia is from the old Czecholvoakia -
the land of the most beautiful women ;-).

In slovakia I spend 7 years of my life:

1- Learning slovak language
5- Univerity
1- Working for a company called Novitech.

After that my roots called me back to my country, where I am living now.

There in Slovakia, I have contact with the European Mind. Of course in my
country I have always contact with the American Mind.

I think there is really a diference of mind between Americans and
Europeans. You can note it inmediately. Of course I will not talk about
that because this is not the main topic of the thread. I just write it to
tell that there is a diference in many aspects.

I think that Matthew is right. When posted:

 * Cocoon is strong on multi-channel publishing - especially useful for
 application scenarios in the mobile market. There are a lot of differences
 between these markets in Europe and the US. However the US will eventually
 catch up - so watch for Cocoon to become stronger there.

- I can add that believe it or not GSM comes here at the end of 2002. Of
course we used mobile phones since 90-ties but that was CDMA - the
American technology. As a European formed professional I tasted the GSM in
Europe and I always thinked that GSM is better than CDMA. Then here was
not the market that Matthew pointed. Currently with the intro of GSM here
started to talk about lastest technology and WML, WAP, etc. I hope this
market will grow in the next years.

 * There are a lot of corporate mergers happening in Europe - and so an
 integration platform is needed. Another of Cocoon's strong points.

- I agree, here this is a unipolar world, even if there are merges or not.
Always is Microsoft. I think this is because of the strong marketing
campaigns that MS do in this part of the world. In my country there is
only a handfull people using technology out of MS. Here the missconception
about all MS is the best is very strong between people. But I fell that
this will change in the next because of the high Licences and the
currently economics problems around the world. Just remember that MS made
many contracs with people at Universities around the world to make sure
new IT professionals will be good trained in the MS way.

I selled my 1st Cocoon project and when customer asked me about the cost
of implementation (Licences of OS, Database, etc.) He does not believe
that the cost will be near zero. And asked me a second time because he was
concerned about legal issues. :-)

 * Cocoon is a European driven project. It was started by an Italian
 and most of the developers are European.

Sorry, I dont agree partially here. There are many other people working
here. Internet breaks the frontiers. Linux was a European driven project,
but now is worldwide. Maybe this reason is only circunstantial right now.
I hope Cocoon will become a worldwide driven project. Maybe here we can
rewrite it:

Cocoon is a European borned project.

 * The visibility of Cocoon is high in European publications and events
 (magazines, conferences). This again feeds back into the project.

-dont know. I have no acces to printed publications, since BYTE
(http://www.byte.com) stop sending magazines and I had payed a 2 years
subscription! I never pay a subscription again. And in Internet I dont see
from where is the website.

 * There is a strong movement on Open Source in European governments and
 related institutions

Yes, but remember that this movement is wordwide now. The movement on
every country is leaded by diferent people that has his own point of view.
For example: I was mailing with the Argentina's movement and there they
does not like Java because it is not open source in the correct sense.
Maybe they are too purist in this things. They prefer perl, python and
similars.

Please, I dont want to start a battle about what language is the best of
the best. I just pointed that because for this movement Cocoon is not part
of the most important things about the movement. They are most concerned

Multiple matches in a protected resource

2003-01-31 Thread Lionel Crine
Hello,
I use sunrise framework.
I'd like to protected multiple patterns but I don't know how.

Here is what I tried :

!-- the handle --

...
 map:action name=sunRise_auth 
src=org.apache.cocoon.sunshine.sunrise.acting.AuthAction
  handlers
handler name=foo_handler 
xmlns:map=http://apache.org/cocoon/sitemap/1.0; 
xmlns:sunshine=http://sunshine.sundn.de/sunshine/1.0;
	  redirect-to uri=cocoon://login_page/
	  authentication uri=cocoon:raw://authuser/
	/handler
  /handlers
/map:action
...

!-- the protected resources --

	map:match pattern=protected*
	map:act type=sunRise_auth
	map:parameter name=handler value=foo_handler/

		!-- welcome page --
		map:match pattern=display
	  map:generate type=serverpages src=demo/display.xsp/
	  map:transform type=xslt src=demo/display.xsl/
	  map:serialize type=html/
	/map:match

		!-- another page --
		map:match pattern=page1
	  map:generate type=serverpages src=demo/page1.xsp/
	  map:transform type=xslt src=demo/page1.xsl/
	  map:serialize type=html/
	map:match

	/map:act
	/map:match


!-- the login which call authuser via the handler --
	map:match pattern=login
	
	!-- check if the user is logged --
	map:act type=sunRise_loggedIn
	map:parameter name=handler value=foo_handler/


	map:redirect-to uri=protecteddisplay/ = this redirection 
doesn't work, the brower says resource not found
	/map:act
	
	!-- log the user --
	map:act type=sunRise_login
	  map:parameter name=handler value=foo_handler/
	  map:parameter name=parameter_name value=request:name/
	  map:parameter name=parameter_password value=request:password/
  !-- if the authentication is successfull then this redirect 
will be performed --
	  map:redirect-to uri=demo/
	/map:act
	
	!-- authentication failed --
	map:generate src=demo/login_failed.xml/
	map:transform src=demo/login_failed.xsl/
	map:serialize type=html/
	/map:match


Someone has an idea ?


Thanks in advance
Lionel


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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



RE: Cocoon use worldwide

2003-01-31 Thread Luca Morandini
 -Original Message-
 From: Antonio Gallardo [mailto:[EMAIL PROTECTED]]
 Sent: Friday, January 31, 2003 10:57 AM
 To: [EMAIL PROTECTED]
 Subject: Re: Cocoon use worldwide

 -dont know. I have no acces to printed publications, since BYTE
 (http://www.byte.com) stop sending magazines and I had payed a 2 years
 subscription! 

Antonio,

you should have asked for a full refund... after a couple of months they gave me my 
money back :)

Regards,

- 
   Luca Morandini 
   GIS Consultant 
  [EMAIL PROTECTED] 
http://utenti.tripod.it/lmorandini/index.html 
-
 


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




RE: Multiple matches in a protected resource

2003-01-31 Thread Carsten Ziegeler

Lionel Crine wrote:
 
 Hello,
 I use sunrise framework.
 I'd like to protected multiple patterns but I don't know how.
 
 Here is what I tried :
 
 snip/
 
   map:match pattern=protected*
   map:act type=sunRise_auth
   map:parameter name=handler value=foo_handler/
 
   !-- welcome page --
   map:match pattern=display
Here is your problem, you first match agains any name starting
with protected, so for example protected-page would match.
Inside you match against the simple name display, but if
display is requested, protected* does not match.

So, you have to find a common pattern, for example each page
starting with protected, then you can change your second
match to protecteddisplay.

HTH
Carsten 

Carsten Ziegeler 
Open Source Group, SN AG


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: date translation

2003-01-31 Thread Scherler, Thorsten
xsl:value-of select=translate($your-date, '/', '.') /

Would be if only I
need to change all the '/' into '.'

-Ursprüngliche Nachricht-
Von: Konstantin Piroumian [mailto:[EMAIL PROTECTED]]
Gesendet: Freitag, 31. Januar 2003 08:57
An: [EMAIL PROTECTED]
Betreff: Re: date translation


Yes, that's it.

Another option could be to use the XSLT translate() function if you only
need to change all the '/' into '.' in your date string:

xsl:value-of select=translate($your-date, '/', '.') /.

This way you can do it in XSLT.

--
  Konstantin

- Original Message -
From: Scherler, Thorsten [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, January 30, 2003 20:28
Subject: AW: date translation


Thanks!

I found:
http://xml.apache.org/cocoon1/xsp.html


-Ursprüngliche Nachricht-
Von: Joerg Heinicke [mailto:[EMAIL PROTECTED]]
Gesendet: Donnerstag, 30. Januar 2003 17:57
An: [EMAIL PROTECTED]
Betreff: Re: date translation


Only a comment:

Using

xsl:param name=any
 xsl:value-of select=anyExpression/
/xsl:param

is mostly not the optimum. It will create a Result Tree Fragment, where
it is not needed. Using

xsl:param name=any select=anyExpression/

is shorter and is of a normal data type like node set, string or
number. While working with strings it's only a question of conversions
the processor has to do. But when working with node sets it can be
really a problem:

xsl:param name=any
 xsl:copy-of select=anyExpressionThatReturnsANodeset/
/xsl:param

You can't operate on $any like on a node set. Only string operatrions
are allowed. So for example $any/path/to/a/node is not possible.

Another problem:

xsl:variable name=emptyString select=''/

xsl:variable name=emptyRTF
   xsl:value-of select=''/
/xsl:variable

xsl:if test=$emptyString/  == false
xsl:if test=$emptyRTF/ == true

You can't test that simply on the emptyness of a RTF, because it returns
always true. You must explicitely convert it into a string via
test=string($emptyRTF).

http://www.w3.org/TR/xslt#section-Result-Tree-Fragments

So in general it's better to avoid RTFs.

Regards,

Joerg

Scherler, Thorsten wrote:
 Hello group,

 if anybody need a date translation, here it is:

 e.g. test.html?date=29.1.2003 (like we write in Germany) will be
1/29/2003.

 xsl:param name=date/
 xsl:param name=GETdayxsl:value-of
select=substring-before($date,'.')/ /xsl:param
 xsl:param name=GETmonth_yearxsl:value-of
select=substring-after($date,'.')//xsl:param
 xsl:param name=GETmonthxsl:value-of
select=substring-before($GETmonth_year,'.')/ /xsl:param
 xsl:param name=GETyearxsl:value-of
select=substring-after($GETmonth_year,'.')/ /xsl:param
 ...
 xsl:value-of select=$GETmonth//xsl:value-of
select=$GETday//xsl:value-of select=$GETyear/

 King regards


Mit freundlichem Gruss,

Thorsten Scherler


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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



-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
Hello group,

is there an equivalent in xsp to the xsl: xsl:param name=date/?

e.g. guess my request is like that: ...?date=30%2F01%2F2003.

And 
esql:query
 select * from info_bericht  where Info_datum = #xsp-request:get-parameter 
name=date/#
 /esql:query
is working fine.

But xsp-request:get-parameter name=date/ can't be used in xsp:logic/ like that:
xsp:logic
String timeOfDay = (
  new SimpleDateFormat(MM/dd/)
).format(xsp-request:get-parameter name=date/);
  /xsp:logic

If I do that I get:
type fatal
message Language Exception
description org.apache.cocoon.ProcessingException: Language Exception: 
org.apache.cocoon.components.language.LanguageException: Error while instantiating 
org\apache\cocoon\www\logic\IDC2_info_int_xsp: java.lang.NullPointerException

King regards for any help!

 Mit freundlichem Gruss,
 
 Thorsten Scherler
 Marketing / Telefonmarketing
 
 Weidmüller GmbH  Co.
 P.O. Box 2807
 33058 Paderborn
 Tel.:+ 49 - 5252-960-350
 Fax:+ 49 - 5252-960-116
 eMail: [EMAIL PROTECTED]
 http://www.weidmueller.de
 
 

-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: Cocoon use worldwide

2003-01-31 Thread John Callahan
Jeff,

I live and work in Washington, D.C. USA and see the
need for Cocoon rising rapidly in government and industry.
The primary reason is the lack of content scalability from
other solutions (ASP,JSP,CFM).  These technologies suffer
from poor support for pipelining XML easily and their difficulty
in handling the myriad of device requirements, i18n, etc.  I do
believe that the European part of the Cocoon community has
pioneered these facets of Cocoon due to the need to solve
their immediate i18n and mobile device problems (see the
intro part of Carsten  Matthew's book for example).

We're using Cocoon on health care projects that need to
protect XML content at a fine-grain level based on a user's
role, context, and state of the data.  Rather than embedding
this logic completely in the persistence layer or code (a DB
or EJBs), we're doing it within transforms and actions.  This
allows us to audit various transactions to ensure they meet
HIPAA guidelines at a very detailed level and express those
data security policies as constraints on XPath expressions -
which non-programmers like physicians can actually read
and understand! :-)  We've also been able to more easily
cast their web applications as web services, VoiceXML
services, and as AvantGo sources (e.g., a directory of
regional physicians).

Finally, the development and deployment of Cocoon
solutions are very cost effective (TCD and TCO).  We've
seen several competitors go out-of-business while trying to
move to the .NET platform because the cost of retraining and
retooling was too much for them in the current economy.
Meanwhile, Java and XML savvy developers are more
available than ever in our area and most are enthusiastic
supporters of Open Source efforts.  The Linux/Java/Tomcat/Cocoon
combo is just right for small companies in the current economy.
AFAIK, Microsoft still dominates government and industry efforts,
but they are not nearly as dominant as 2 years ago.

I enjoy the multi-national flavor of Cocoon and see it as a
great strength.  I'm giving a tutorial on Cocoon next month
( http://www.eccnet.com/xmlug/ ) here in D.C.  I also noticed
that Ivelin Ivanov is giving a talk in Austin, TX USA next
month too ( http://www.xmlaustin.org/_html_out/main/events.html )

-- jack

John R. Callahan
Sphere Software Corporation - The Intelligence of XML
[EMAIL PROTECTED]


- Original Message -
From: Jeff Ramsdale [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, January 30, 2003 9:48 PM
Subject: Cocoon use worldwide


 Hi all,

 I'm just curious about something. I've been reading the Cocoon-users list
 for a couple of weeks or so and I see a lot of folks in Europe (and
 Australia--Jeff T!) interested in Cocoon. I'm sure it's not a matter of
 Americans ( Canadians?) not being interested, I'm sure. (Oh,  Antonio, I
 don't want to leave you out!) Right?

 With the utmost respect for the Project I observe that Cocoon is a bit of
a
 fringe product as far as web development is concerned. I happen to believe
 this fringe is the leading edge of something big, which is why I'm here.
 So here's my question: If any of what I've said above has truth in it, is
 there a particular reason why Cocoon might have special appeal to
Europeans?
 Is there something about the mindset of European programmers that leads
them
 to Cocoon? Is Open-Source Software viewed differently, on the whole, in
 Europe than America? Does this have anything to do with Microsoft's
 influence in America? I guess that's more than one question! Interested in
 your observations...

 Reason I ask... I live in Seattle (Microsoft-land), and I'd love to find
 work using Cocoon and/or Java (but especially Cocoon!), but I don't see as
 much mindshare here as I think it deserves.

 Jeff



 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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



-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: xsp-element equivalent to xsl:param?

2003-01-31 Thread Andrew Timberlake
On Fri, 2003-01-31 at 14:31, Scherler, Thorsten wrote:
 Hello group,
 
 is there an equivalent in xsp to the xsl: xsl:param name=date/?
Yes, see below

 
 e.g. guess my request is like that: ...?date=30%2F01%2F2003.
 
 And 
 esql:query
  select * from info_bericht  where Info_datum = #xsp-request:get-parameter 
name=date/#
  /esql:query
 is working fine.
 
 But xsp-request:get-parameter name=date/ can't be used in xsp:logic/ like that:
   xsp:logic
 String timeOfDay = (
   new SimpleDateFormat(MM/dd/)
 ).format(xsp-request:get-parameter name=date/);
   /xsp:logic

xsp:logic
try{
String timeOfDay = (new
SimpleDateFormat(MM/dd/)).format(parameters.getParameter(date);
}catch(Exception e){}
/xsp:logic

You will need to wrap the code in a try/catch block or alternatively use
the syntax: parameters.getParameter(date, default value of choice);

 
 If I do that I get:
 type fatal
 message Language Exception
 description org.apache.cocoon.ProcessingException: Language Exception: 
org.apache.cocoon.components.language.LanguageException: Error while instantiating 
org\apache\cocoon\www\logic\IDC2_info_int_xsp: java.lang.NullPointerException
 
 King regards for any help!
 
  Mit freundlichem Gruss,
  
  Thorsten Scherler
  Marketing / Telefonmarketing
  
  Weidmüller GmbH  Co.
  P.O. Box 2807
  33058 Paderborn
  Tel.:+ 49 - 5252-960-350
  Fax:+ 49 - 5252-960-116
  eMail: [EMAIL PROTECTED]
  http://www.weidmueller.de
  
  
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
-- 
Andrew Timberlake [EMAIL PROTECTED]


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
Hello Andrew,

with:
xsp:logic
try{
String timeOfDay = (new
SimpleDateFormat(MM/dd/)).format(parameters.getParameter(date);
}catch(Exception e){}
/xsp:logic

I get:

type fatal

message Language Exception

description org.apache.cocoon.ProcessingException: Language Exception: 
org.apache.cocoon.components.language.LanguageException: Error compiling 
IDC2_info_int_xsp: Line 251, column 0: illegal start of type Line 105, column 11: 
class org.apache.cocoon.www.logic.IDC2_info_int_xsp should be declared abstract; it 
does not define method generate() in class 
org.apache.cocoon.generation.AbstractGenerator Line 0, column 0: 2 errors 

sender org.apache.cocoon.servlet.CocoonServlet

source Cocoon servlet

stack-trace

org.apache.cocoon.ProcessingException: Language Exception: 
org.apache.cocoon.components.language.LanguageException: Error compiling 
IDC2_info_int_xsp:
Line 251, column 0:  illegal start of type
Line 105, column 11:  class org.apache.cocoon.www.logic.IDC2_info_int_xsp should be 
declared abstract; it does not define method generate() in class 
org.apache.cocoon.generation.AbstractGenerator
Line 0, column 0: 
2 errors

at 
org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.createResource(ProgramGeneratorImpl.java:340)
at 
org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.load(ProgramGeneratorImpl.java:292)
at 
org.apache.cocoon.generation.ServerPagesGenerator.setup(ServerPagesGenerator.java:198)
at 
org.apache.cocoon.components.pipeline.AbstractEventPipeline.setupPipeline(AbstractEventPipeline.java:202)
at 
org.apache.cocoon.components.pipeline.CachingEventPipeline.setup(CachingEventPipeline.java:278)
at 
org.apache.cocoon.components.pipeline.CachingEventPipeline.generateKey(CachingEventPipeline.java:141)
at 
org.apache.cocoon.components.pipeline.CachingStreamPipeline.process(CachingStreamPipeline.java:317)
at 
org.apache.cocoon.components.treeprocessor.sitemap.SerializeNode.invoke(SerializeNode.java:153)
at 
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:85)
at 
org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invoke(PreparableMatchNode.java:156)
at 
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:109)
at 
org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:140)
at 
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:109)
at 
org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:144)
at 
org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:328)
at 
org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:293)
at org.apache.cocoon.Cocoon.process(Cocoon.java:575)
at org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:999)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:260)
at 
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at 
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2415)
at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
at 
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
at 
org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170)
at 
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
at 
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172)
at 
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
at 

AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Jan Harms

Andrew Timberlake wrote:
 try{
 String timeOfDay = (new
 SimpleDateFormat(MM/dd/)).format(parameters.getParameter
 (date);
 }catch(Exception e){}
 /xsp:logic
 
 You will need to wrap the code in a try/catch block or 
 alternatively use
 the syntax: parameters.getParameter(date, default value of 
 choice);
 

Thorsten, do you need a sitemap-parameter or a request-parameter? From your previous 
posts I assume that you want a request Parameter. In that case you should use 

request.getParamter(date) 

instead of 

parameters.getParameter(date)


The variables request and parameters are predefined variables in every XSP. Have a 
look at http://wiki.cocoondev.org/Wiki.jsp?page=XSPEnvironment

Hope this helps

-Jan Harms

-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
Hello jan,

with the request I get a similar error like with the parameters.

But here are all the files:

my sitemap.xmap:
?xml version=1.0?
map:sitemap xmlns:map=http://apache.org/cocoon/sitemap/1.0;
!-- === Components  
--
map:components
map:generators default=file
map:generator label=content,data 
logger=sitemap.generator.file name=file pool-grow=4 pool-max=32 pool-min=8 
src=org.apache.cocoon.generation.FileGenerator/
map:generator label=content,data 
logger=sitemap.generator.serverpages name=xsp pool-grow=2 pool-max=32 
pool-min=4 src=org.apache.cocoon.generation.ServerPagesGenerator/
/map:generators
map:transformers default=xslt
map:transformer logger=sitemap.transformer.xslt name=xslt 
pool-grow=2 pool-max=32 pool-min=8 
src=org.apache.cocoon.transformation.TraxTransformer
use-request-parametersfalse/use-request-parameters

use-browser-capabilities-dbfalse/use-browser-capabilities-db
use-delifalse/use-deli
/map:transformer
/map:transformers
map:readers default=resource
map:reader logger=sitemap.reader.resource name=resource 
pool-max=32 src=org.apache.cocoon.reading.ResourceReader/
/map:readers
map:serializers default=html
map:serializer logger=sitemap.serializer.xml 
mime-type=text/xml name=xml src=org.apache.cocoon.serialization.XMLSerializer/
map:serializer logger=sitemap.serializer.html 
mime-type=text/html name=html pool-grow=4 pool-max=32 pool-min=4 
src=org.apache.cocoon.serialization.HTMLSerializer
buffer-size1024/buffer-size
/map:serializer
map:serializer name=fo2pdf 
src=org.apache.cocoon.serialization.FOPSerializer logger=sitemap.serializer.fo2pdf 
mime-type=application/pdf
!----
user-config src=/fonts/ci/config.xml/
/map:serializer
/map:serializers
map:matchers default=wildcard
map:matcher logger=sitemap.matcher.wildcard name=wildcard 
src=org.apache.cocoon.matching.WildcardURIMatcher/
/map:matchers
map:selectors/
map:actions
map:action name=form-validator 
src=org.apache.cocoon.acting.FormValidatorAction/
/map:actions
/map:components
map:views/
!-- === Components  
--
!-- === Pipelines  --
map:pipelines
map:pipeline
!-- === Weidmueller 
 --
!-- index --
map:match pattern=
map:redirect-to uri=start.html/
/map:match
!-- start --
map:match pattern=start.html
map:generate typ=xml src=docs/menu.xml/
map:transform src=stylesheets/html/menu2html.xsl
map:parameter name=use-request-parameters 
value=true/
/map:transform
map:serialize type=html/
/map:match
!-- test --
map:match pattern=test.html
map:generate typ=xml src=docs/test.xml/
map:transform src=stylesheets/html/test2html.xsl
map:parameter name=use-request-parameters 
value=true/
/map:transform
map:serialize type=html/
/map:match
snip/
!-- === 
IDC2 --
!-- WI_int200301IDC2  - Info_sofort--
map:match pattern=IDC2/info_int.xml
map:generate type=xsp 
src=logic/IDC2_info_int.xsp/
map:serialize type=xml/
/map:match
map:match pattern=IDC2/info_int.pdf
map:aggregate element=Container
map:part src=cocoon:/IDC2/info_int.xml/
/map:aggregate
map:transform 
src=stylesheets/pdf/IDC2/bericht_int.xsl/
  

AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Jan Harms
Are you sure these are the correct files? 

I don´t see the xsp:logic tag with the

SimpleDateFormat(MM/dd/)).format(...


The error message looks like you have forgotten to close some curly braces. That´s 
just a guess though...

-Jan



 -Ursprüngliche Nachricht-
 Von: Scherler, Thorsten [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 13:54
 An: [EMAIL PROTECTED]
 Betreff: AW: xsp-element equivalent to xsl:param?
 
 
 Hello jan,
 
 with the request I get a similar error like with the parameters.
 
 But here are all the files:
 
 my sitemap.xmap:
 ?xml version=1.0?
 map:sitemap xmlns:map=http://apache.org/cocoon/sitemap/1.0;
   !-- === Components 
  --
   map:components
   map:generators default=file
   map:generator label=content,data 
 logger=sitemap.generator.file name=file pool-grow=4 
 pool-max=32 pool-min=8 
 src=org.apache.cocoon.generation.FileGenerator/
   map:generator label=content,data 
 logger=sitemap.generator.serverpages name=xsp 
 pool-grow=2 pool-max=32 pool-min=4 
 src=org.apache.cocoon.generation.ServerPagesGenerator/
   /map:generators
   map:transformers default=xslt
   map:transformer 
 logger=sitemap.transformer.xslt name=xslt pool-grow=2 
 pool-max=32 pool-min=8 
 src=org.apache.cocoon.transformation.TraxTransformer
   
 use-request-parametersfalse/use-request-parameters
   
 use-browser-capabilities-dbfalse/use-browser-capabilities-db
   use-delifalse/use-deli
   /map:transformer
   /map:transformers
   map:readers default=resource
   map:reader 
 logger=sitemap.reader.resource name=resource 
 pool-max=32 src=org.apache.cocoon.reading.ResourceReader/
   /map:readers
   map:serializers default=html
   map:serializer 
 logger=sitemap.serializer.xml mime-type=text/xml 
 name=xml src=org.apache.cocoon.serialization.XMLSerializer/
   map:serializer 
 logger=sitemap.serializer.html mime-type=text/html 
 name=html pool-grow=4 pool-max=32 pool-min=4 
 src=org.apache.cocoon.serialization.HTMLSerializer
   buffer-size1024/buffer-size
   /map:serializer
   map:serializer name=fo2pdf 
 src=org.apache.cocoon.serialization.FOPSerializer 
 logger=sitemap.serializer.fo2pdf mime-type=application/pdf
   !----
   user-config 
 src=/fonts/ci/config.xml/
   /map:serializer
   /map:serializers
   map:matchers default=wildcard
   map:matcher 
 logger=sitemap.matcher.wildcard name=wildcard 
 src=org.apache.cocoon.matching.WildcardURIMatcher/
   /map:matchers
   map:selectors/
   map:actions
   map:action name=form-validator 
 src=org.apache.cocoon.acting.FormValidatorAction/
   /map:actions
   /map:components
   map:views/
   !-- === Components 
  --
   !-- === Pipelines 
  --
   map:pipelines
   map:pipeline
   !-- === 
 Weidmueller  --
   !-- index --
   map:match pattern=
   map:redirect-to uri=start.html/
   /map:match
   !-- start --
   map:match pattern=start.html
   map:generate typ=xml 
 src=docs/menu.xml/
   map:transform 
 src=stylesheets/html/menu2html.xsl
   map:parameter 
 name=use-request-parameters value=true/
   /map:transform
   map:serialize type=html/
   /map:match
   !-- test --
   map:match pattern=test.html
   map:generate typ=xml 
 src=docs/test.xml/
   map:transform 
 src=stylesheets/html/test2html.xsl
   map:parameter 
 name=use-request-parameters value=true/
   /map:transform
   map:serialize type=html/
   /map:match
 snip/
   !-- === 
 IDC2 --
   !-- WI_int200301IDC2  - Info_sofort--
   map:match pattern=IDC2/info_int.xml
   map:generate type=xsp 
 

AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
Sorry jan, ...and thabks a lot for your help!

I posted the working one! ;-)

The NOT working logic/IDC2_info_int.xsp:
xsp:page language=java xmlns:xsp=http://apache.org/xsp; 
xmlns:esql=http://apache.org/cocoon/SQL/v2; 
xmlns:xsp-request=http://apache.org/xsp/request/2.0;
xsp:logic
try{
String timeOfDay = (new
SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
}catch(Exception e){}
/xsp:logic
dataset
...

-Ursprüngliche Nachricht-
Von: Scherler, Thorsten 
Gesendet: Freitag, 31. Januar 2003 13:54
An: [EMAIL PROTECTED]
Betreff: AW: xsp-element equivalent to xsl:param?


Hello jan,

with the request I get a similar error like with the parameters.

But here are all the files:

my sitemap.xmap:
?xml version=1.0?
map:sitemap xmlns:map=http://apache.org/cocoon/sitemap/1.0;
!-- === Components  
--
map:components
map:generators default=file
map:generator label=content,data 
logger=sitemap.generator.file name=file pool-grow=4 pool-max=32 pool-min=8 
src=org.apache.cocoon.generation.FileGenerator/
map:generator label=content,data 
logger=sitemap.generator.serverpages name=xsp pool-grow=2 pool-max=32 
pool-min=4 src=org.apache.cocoon.generation.ServerPagesGenerator/
/map:generators
map:transformers default=xslt
map:transformer logger=sitemap.transformer.xslt name=xslt 
pool-grow=2 pool-max=32 pool-min=8 
src=org.apache.cocoon.transformation.TraxTransformer
use-request-parametersfalse/use-request-parameters

use-browser-capabilities-dbfalse/use-browser-capabilities-db
use-delifalse/use-deli
/map:transformer
/map:transformers
map:readers default=resource
map:reader logger=sitemap.reader.resource name=resource 
pool-max=32 src=org.apache.cocoon.reading.ResourceReader/
/map:readers
map:serializers default=html
map:serializer logger=sitemap.serializer.xml 
mime-type=text/xml name=xml src=org.apache.cocoon.serialization.XMLSerializer/
map:serializer logger=sitemap.serializer.html 
mime-type=text/html name=html pool-grow=4 pool-max=32 pool-min=4 
src=org.apache.cocoon.serialization.HTMLSerializer
buffer-size1024/buffer-size
/map:serializer
map:serializer name=fo2pdf 
src=org.apache.cocoon.serialization.FOPSerializer logger=sitemap.serializer.fo2pdf 
mime-type=application/pdf
!----
user-config src=/fonts/ci/config.xml/
/map:serializer
/map:serializers
map:matchers default=wildcard
map:matcher logger=sitemap.matcher.wildcard name=wildcard 
src=org.apache.cocoon.matching.WildcardURIMatcher/
/map:matchers
map:selectors/
map:actions
map:action name=form-validator 
src=org.apache.cocoon.acting.FormValidatorAction/
/map:actions
/map:components
map:views/
!-- === Components  
--
!-- === Pipelines  --
map:pipelines
map:pipeline
!-- === Weidmueller 
 --
!-- index --
map:match pattern=
map:redirect-to uri=start.html/
/map:match
!-- start --
map:match pattern=start.html
map:generate typ=xml src=docs/menu.xml/
map:transform src=stylesheets/html/menu2html.xsl
map:parameter name=use-request-parameters 
value=true/
/map:transform
map:serialize type=html/
/map:match
!-- test --
map:match pattern=test.html
map:generate typ=xml src=docs/test.xml/
map:transform src=stylesheets/html/test2html.xsl
map:parameter name=use-request-parameters 
value=true/
/map:transform
map:serialize type=html/
/map:match
snip/
!-- === 
IDC2 --
!-- 

RE: xsp-element equivalent to xsl:param?

2003-01-31 Thread Geoff Howard
Wast that cut and pasted?  It looks like you're missing an end ) - should
be:
  getParameter(date));

Geoff

 -Original Message-
 From: Scherler, Thorsten [mailto:[EMAIL PROTECTED]]
 Sent: Friday, January 31, 2003 7:48 AM
 To: [EMAIL PROTECTED]
 Subject: AW: xsp-element equivalent to xsl:param?


 Hello Andrew,

 with:
 xsp:logic
 try{
 String timeOfDay = (new
 SimpleDateFormat(MM/dd/)).format(parameters.getParameter(date);
 }catch(Exception e){}
 /xsp:logic

 I get:

 type fatal

 message Language Exception

 description org.apache.cocoon.ProcessingException: Language
 Exception:
 org.apache.cocoon.components.language.LanguageException: Error
 compiling IDC2_info_int_xsp: Line 251, column 0: illegal start of
 type Line 105, column 11: class
 org.apache.cocoon.www.logic.IDC2_info_int_xsp should be declared
 abstract; it does not define method generate() in class
 org.apache.cocoon.generation.AbstractGenerator Line 0, column 0: 2 errors

 sender org.apache.cocoon.servlet.CocoonServlet

 source Cocoon servlet

 stack-trace

 org.apache.cocoon.ProcessingException: Language Exception:
 org.apache.cocoon.components.language.LanguageException: Error
 compiling IDC2_info_int_xsp:
 Line 251, column 0:  illegal start of type
 Line 105, column 11:  class
 org.apache.cocoon.www.logic.IDC2_info_int_xsp should be declared
 abstract; it does not define method generate() in class
 org.apache.cocoon.generation.AbstractGenerator
 Line 0, column 0:
 2 errors

   at
 org.apache.cocoon.components.language.generator.ProgramGeneratorIm
 pl.createResource(ProgramGeneratorImpl.java:340)
   at
 org.apache.cocoon.components.language.generator.ProgramGeneratorIm
 pl.load(ProgramGeneratorImpl.java:292)
   at
 org.apache.cocoon.generation.ServerPagesGenerator.setup(ServerPage
 sGenerator.java:198)
   at
 org.apache.cocoon.components.pipeline.AbstractEventPipeline.setupP
 ipeline(AbstractEventPipeline.java:202)
   at
 org.apache.cocoon.components.pipeline.CachingEventPipeline.setup(C
achingEventPipeline.java:278)
   at
 org.apache.cocoon.components.pipeline.CachingEventPipeline.generat
 eKey(CachingEventPipeline.java:141)
   at
 org.apache.cocoon.components.pipeline.CachingStreamPipeline.proces
 s(CachingStreamPipeline.java:317)
   at
 org.apache.cocoon.components.treeprocessor.sitemap.SerializeNode.i
 nvoke(SerializeNode.java:153)
   at
 org.apache.cocoon.components.treeprocessor.AbstractParentProcessin
 gNode.invokeNodes(AbstractParentProcessingNode.java:85)
   at
 org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatch
 Node.invoke(PreparableMatchNode.java:156)
   at
 org.apache.cocoon.components.treeprocessor.AbstractParentProcessin
 gNode.invokeNodes(AbstractParentProcessingNode.java:109)
   at
 org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.in
 voke(PipelineNode.java:140)
   at
 org.apache.cocoon.components.treeprocessor.AbstractParentProcessin
 gNode.invokeNodes(AbstractParentProcessingNode.java:109)
   at
 org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.i
 nvoke(PipelinesNode.java:144)
   at
 org.apache.cocoon.components.treeprocessor.TreeProcessor.process(T
 reeProcessor.java:328)
   at
 org.apache.cocoon.components.treeprocessor.TreeProcessor.process(T
 reeProcessor.java:293)
   at org.apache.cocoon.Cocoon.process(Cocoon.java:575)
   at
 org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:999)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
   at
 org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(A
pplicationFilterChain.java:247)
   at
 org.apache.catalina.core.ApplicationFilterChain.doFilter(Applicati
 onFilterChain.java:193)
   at
 org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapp
 erValve.java:260)
   at
 org.apache.catalina.core.StandardPipeline$StandardPipelineValveCon
 text.invokeNext(StandardPipeline.java:643)
   at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.
 java:480)
   at
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
   at
 org.apache.catalina.core.StandardContextValve.invoke(StandardConte
 xtValve.java:191)
   at
 org.apache.catalina.core.StandardPipeline$StandardPipelineValveCon
 text.invokeNext(StandardPipeline.java:643)
   at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.
 java:480)
   at
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
   at
 org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2415)
   at
 org.apache.catalina.core.StandardHostValve.invoke(StandardHostValv
 e.java:180)
   at
 org.apache.catalina.core.StandardPipeline$StandardPipelineValveCon
 text.invokeNext(StandardPipeline.java:643)
   at
 org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispat
 cherValve.java:170)
   at
 

AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
Yes, I've noticed that as well but with
getParameter(date)); - same exception.

Thanks

-Ursprüngliche Nachricht-
Von: Geoff Howard [mailto:[EMAIL PROTECTED]]
Gesendet: Freitag, 31. Januar 2003 14:17
An: [EMAIL PROTECTED]
Betreff: RE: xsp-element equivalent to xsl:param?


Wast that cut and pasted?  It looks like you're missing an end ) - should
be:
  getParameter(date));

Geoff

 -Original Message-
 From: Scherler, Thorsten [mailto:[EMAIL PROTECTED]]
 Sent: Friday, January 31, 2003 7:48 AM
 To: [EMAIL PROTECTED]
 Subject: AW: xsp-element equivalent to xsl:param?


 Hello Andrew,

 with:
 xsp:logic
 try{
 String timeOfDay = (new
 SimpleDateFormat(MM/dd/)).format(parameters.getParameter(date);
 }catch(Exception e){}
 /xsp:logic

 I get:

 type fatal

 message Language Exception

 description org.apache.cocoon.ProcessingException: Language
 Exception:
 org.apache.cocoon.components.language.LanguageException: Error
 compiling IDC2_info_int_xsp: Line 251, column 0: illegal start of
 type Line 105, column 11: class
 org.apache.cocoon.www.logic.IDC2_info_int_xsp should be declared
 abstract; it does not define method generate() in class
 org.apache.cocoon.generation.AbstractGenerator Line 0, column 0: 2 errors

 sender org.apache.cocoon.servlet.CocoonServlet

 source Cocoon servlet

 stack-trace

 org.apache.cocoon.ProcessingException: Language Exception:
 org.apache.cocoon.components.language.LanguageException: Error
 compiling IDC2_info_int_xsp:
 Line 251, column 0:  illegal start of type
 Line 105, column 11:  class
 org.apache.cocoon.www.logic.IDC2_info_int_xsp should be declared
 abstract; it does not define method generate() in class
 org.apache.cocoon.generation.AbstractGenerator
 Line 0, column 0:
 2 errors

   at
 org.apache.cocoon.components.language.generator.ProgramGeneratorIm
 pl.createResource(ProgramGeneratorImpl.java:340)
   at
 org.apache.cocoon.components.language.generator.ProgramGeneratorIm
 pl.load(ProgramGeneratorImpl.java:292)
   at
 org.apache.cocoon.generation.ServerPagesGenerator.setup(ServerPage
 sGenerator.java:198)
   at
 org.apache.cocoon.components.pipeline.AbstractEventPipeline.setupP
 ipeline(AbstractEventPipeline.java:202)
   at
 org.apache.cocoon.components.pipeline.CachingEventPipeline.setup(C
achingEventPipeline.java:278)
   at
 org.apache.cocoon.components.pipeline.CachingEventPipeline.generat
 eKey(CachingEventPipeline.java:141)
   at
 org.apache.cocoon.components.pipeline.CachingStreamPipeline.proces
 s(CachingStreamPipeline.java:317)
   at
 org.apache.cocoon.components.treeprocessor.sitemap.SerializeNode.i
 nvoke(SerializeNode.java:153)
   at
 org.apache.cocoon.components.treeprocessor.AbstractParentProcessin
 gNode.invokeNodes(AbstractParentProcessingNode.java:85)
   at
 org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatch
 Node.invoke(PreparableMatchNode.java:156)
   at
 org.apache.cocoon.components.treeprocessor.AbstractParentProcessin
 gNode.invokeNodes(AbstractParentProcessingNode.java:109)
   at
 org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.in
 voke(PipelineNode.java:140)
   at
 org.apache.cocoon.components.treeprocessor.AbstractParentProcessin
 gNode.invokeNodes(AbstractParentProcessingNode.java:109)
   at
 org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.i
 nvoke(PipelinesNode.java:144)
   at
 org.apache.cocoon.components.treeprocessor.TreeProcessor.process(T
 reeProcessor.java:328)
   at
 org.apache.cocoon.components.treeprocessor.TreeProcessor.process(T
 reeProcessor.java:293)
   at org.apache.cocoon.Cocoon.process(Cocoon.java:575)
   at
 org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:999)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
   at
 org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(A
pplicationFilterChain.java:247)
   at
 org.apache.catalina.core.ApplicationFilterChain.doFilter(Applicati
 onFilterChain.java:193)
   at
 org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapp
 erValve.java:260)
   at
 org.apache.catalina.core.StandardPipeline$StandardPipelineValveCon
 text.invokeNext(StandardPipeline.java:643)
   at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.
 java:480)
   at
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
   at
 org.apache.catalina.core.StandardContextValve.invoke(StandardConte
 xtValve.java:191)
   at
 org.apache.catalina.core.StandardPipeline$StandardPipelineValveCon
 text.invokeNext(StandardPipeline.java:643)
   at
 org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.
 java:480)
   at
 org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
   at
 org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2415)
   at
 org.apache.catalina.core.StandardHostValve.invoke(StandardHostValv
 

AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Jan Harms
Thorsten,

here is a tip that might be useful: When you get a message Error compiling foo.xsp 
you should have a look at the generated java class.

Like JSPs, XSPs are transformed into a .java source file. Afterwards cocoon tries to 
compile this .java file into a .class file. These files can be found in Tomcats (or 
your servlet-engines) work-directory. Search for a subdirectory called 

cocoon-files/org/apache/cocoon/www/

There you can find a foo_xsp.java file. Open this file and search for syntax errors 
(the exception contains a line number!). Sure it´s generated code, but quite readable.

-Jan


 -Ursprüngliche Nachricht-
 Von: Scherler, Thorsten [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 14:09
 An: [EMAIL PROTECTED]
 Betreff: AW: xsp-element equivalent to xsl:param?
 
 
 Yes, I've noticed that as well but with
 getParameter(date)); - same exception.
 
 Thanks
 
 -Ursprüngliche Nachricht-
 Von: Geoff Howard [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 14:17
 An: [EMAIL PROTECTED]
 Betreff: RE: xsp-element equivalent to xsl:param?
 
 
 Wast that cut and pasted?  It looks like you're missing an 
 end ) - should
 be:
   getParameter(date));
 
 Geoff
 
  -Original Message-
  From: Scherler, Thorsten [mailto:[EMAIL PROTECTED]]
  Sent: Friday, January 31, 2003 7:48 AM
  To: [EMAIL PROTECTED]
  Subject: AW: xsp-element equivalent to xsl:param?
 
 
  Hello Andrew,
 
  with:
  xsp:logic
  try{
  String timeOfDay = (new
  
 SimpleDateFormat(MM/dd/)).format(parameters.getParameter
 (date);
  }catch(Exception e){}
  /xsp:logic
 
  I get:
 
  type fatal
 
  message Language Exception
 
  description org.apache.cocoon.ProcessingException: Language
  Exception:
  org.apache.cocoon.components.language.LanguageException: Error
  compiling IDC2_info_int_xsp: Line 251, column 0: illegal start of
  type Line 105, column 11: class
  org.apache.cocoon.www.logic.IDC2_info_int_xsp should be declared
  abstract; it does not define method generate() in class
  org.apache.cocoon.generation.AbstractGenerator Line 0, 
 column 0: 2 errors
 
  sender org.apache.cocoon.servlet.CocoonServlet
 
  source Cocoon servlet
 
  stack-trace
 
  org.apache.cocoon.ProcessingException: Language Exception:
  org.apache.cocoon.components.language.LanguageException: Error
  compiling IDC2_info_int_xsp:
  Line 251, column 0:  illegal start of type
  Line 105, column 11:  class
  org.apache.cocoon.www.logic.IDC2_info_int_xsp should be declared
  abstract; it does not define method generate() in class
  org.apache.cocoon.generation.AbstractGenerator
  Line 0, column 0:
  2 errors
 
  at
  org.apache.cocoon.components.language.generator.ProgramGeneratorIm
  pl.createResource(ProgramGeneratorImpl.java:340)
  at
  org.apache.cocoon.components.language.generator.ProgramGeneratorIm
  pl.load(ProgramGeneratorImpl.java:292)
  at
  org.apache.cocoon.generation.ServerPagesGenerator.setup(ServerPage
  sGenerator.java:198)
  at
  org.apache.cocoon.components.pipeline.AbstractEventPipeline.setupP
  ipeline(AbstractEventPipeline.java:202)
  at
  org.apache.cocoon.components.pipeline.CachingEventPipeline.setup(C
 achingEventPipeline.java:278)
  at
  org.apache.cocoon.components.pipeline.CachingEventPipeline.generat
  eKey(CachingEventPipeline.java:141)
  at
  org.apache.cocoon.components.pipeline.CachingStreamPipeline.proces
  s(CachingStreamPipeline.java:317)
  at
  org.apache.cocoon.components.treeprocessor.sitemap.SerializeNode.i
  nvoke(SerializeNode.java:153)
  at
  org.apache.cocoon.components.treeprocessor.AbstractParentProcessin
  gNode.invokeNodes(AbstractParentProcessingNode.java:85)
  at
  org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatch
  Node.invoke(PreparableMatchNode.java:156)
  at
  org.apache.cocoon.components.treeprocessor.AbstractParentProcessin
  gNode.invokeNodes(AbstractParentProcessingNode.java:109)
  at
  org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.in
  voke(PipelineNode.java:140)
  at
  org.apache.cocoon.components.treeprocessor.AbstractParentProcessin
  gNode.invokeNodes(AbstractParentProcessingNode.java:109)
  at
  org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.i
  nvoke(PipelinesNode.java:144)
  at
  org.apache.cocoon.components.treeprocessor.TreeProcessor.process(T
  reeProcessor.java:328)
  at
  org.apache.cocoon.components.treeprocessor.TreeProcessor.process(T
  reeProcessor.java:293)
  at org.apache.cocoon.Cocoon.process(Cocoon.java:575)
  at
  
 org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.
 java:999)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
  at
  org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(A
 pplicationFilterChain.java:247)
  at
  org.apache.catalina.core.ApplicationFilterChain.doFilter(Applicati
  onFilterChain.java:193)
  at
  

Get session variables for a generator

2003-01-31 Thread Lionel Crine
Hello,

I' d like to get two session variables and use them as parameter for my 
custom generator.

1/Should I get them in the sitemap and use map:parameter ? in the sitemap.
how do I write that ?

2/Or should I get them direclty in the generator ?
How do I do that ?


Lionel


 


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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



Passing User-Agent as a map:parameter

2003-01-31 Thread Lenya L. Khachaturov
Hello,

I'd like to know if it's possible. I would like to do the following:

map:transform src=blog/blog.xsl type=xslt
map:parameter name=browser value=USERAGENT/   
/map:transform

So that in my XSL I could write the following:

xsl:if test=$browser='ie'
link rel=stylesheet href=ie.css type=text/css/
/xsl:if

xsl:if test=another browser
link to another CSS
/xsl:if

The example in the Browser Selector docs is not what I really want - I
don't need different XSLs for different browser.

-- 
Lenya Khachaturov
mailto:[EMAIL PROTECTED]

-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




RE: Cocoon use worldwide

2003-01-31 Thread Geoff Howard
I've been working with Cocoon for a little over a year now (in the
US) and have certainly have had that feeling.  There have been some
really good points so far which I won't recapitulate.  I'll just
add a couple of tidbits:

- I have been looking for Cocoon related jobs in the US and haven't
found a single one (yet).
- There haven't been (yet) any big name companies adopting cocoon
publicly - this would help.
- I have made some wrong assumptions based on names, and other cues
(how well they seem to know the people who I _know_ live in Europe)
only to find they are in the States.
- I think the books have helped visibility here - I've
noticed more name recognition recently when I mention Cocoon.
- I think some here will take a wait and see attitude to see if Cocoon
will jump the pond.
- We need some Cocoon users groups in the US.  I'm in DC and know there's at
least 5-10 regulars on the list from here.  (maybe I'll meet them at John
Callahan's shpiel).

Anyone in DC up for a C.H.U.G.? (Cocoon Hackers  Users Group)

Geoff

 -Original Message-
 From: John Callahan [mailto:[EMAIL PROTECTED]]
 Sent: Friday, January 31, 2003 10:33 AM
 To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
 Subject: Re: Cocoon use worldwide


 Jeff,

 I live and work in Washington, D.C. USA and see the
 need for Cocoon rising rapidly in government and industry.
 The primary reason is the lack of content scalability from
 other solutions (ASP,JSP,CFM).  These technologies suffer
 from poor support for pipelining XML easily and their difficulty
 in handling the myriad of device requirements, i18n, etc.  I do
 believe that the European part of the Cocoon community has
 pioneered these facets of Cocoon due to the need to solve
 their immediate i18n and mobile device problems (see the
 intro part of Carsten  Matthew's book for example).

 We're using Cocoon on health care projects that need to
 protect XML content at a fine-grain level based on a user's
 role, context, and state of the data.  Rather than embedding
 this logic completely in the persistence layer or code (a DB
 or EJBs), we're doing it within transforms and actions.  This
 allows us to audit various transactions to ensure they meet
 HIPAA guidelines at a very detailed level and express those
 data security policies as constraints on XPath expressions -
 which non-programmers like physicians can actually read
 and understand! :-)  We've also been able to more easily
 cast their web applications as web services, VoiceXML
 services, and as AvantGo sources (e.g., a directory of
 regional physicians).

 Finally, the development and deployment of Cocoon
 solutions are very cost effective (TCD and TCO).  We've
 seen several competitors go out-of-business while trying to
 move to the .NET platform because the cost of retraining and
 retooling was too much for them in the current economy.
 Meanwhile, Java and XML savvy developers are more
 available than ever in our area and most are enthusiastic
 supporters of Open Source efforts.  The Linux/Java/Tomcat/Cocoon
 combo is just right for small companies in the current economy.
 AFAIK, Microsoft still dominates government and industry efforts,
 but they are not nearly as dominant as 2 years ago.

 I enjoy the multi-national flavor of Cocoon and see it as a
 great strength.  I'm giving a tutorial on Cocoon next month
 ( http://www.eccnet.com/xmlug/ ) here in D.C.  I also noticed
 that Ivelin Ivanov is giving a talk in Austin, TX USA next
 month too ( http://www.xmlaustin.org/_html_out/main/events.html )

 -- jack

 John R. Callahan
 Sphere Software Corporation - The Intelligence of XML
 [EMAIL PROTECTED]


 - Original Message -
 From: Jeff Ramsdale [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Thursday, January 30, 2003 9:48 PM
 Subject: Cocoon use worldwide


  Hi all,
 
  I'm just curious about something. I've been reading the
 Cocoon-users list
  for a couple of weeks or so and I see a lot of folks in Europe (and
  Australia--Jeff T!) interested in Cocoon. I'm sure it's not a matter of
  Americans ( Canadians?) not being interested, I'm sure. (Oh, 
 Antonio, I
  don't want to leave you out!) Right?
 
  With the utmost respect for the Project I observe that Cocoon
 is a bit of
 a
  fringe product as far as web development is concerned. I happen
 to believe
  this fringe is the leading edge of something big, which is
 why I'm here.
  So here's my question: If any of what I've said above has truth
 in it, is
  there a particular reason why Cocoon might have special appeal to
 Europeans?
  Is there something about the mindset of European programmers that leads
 them
  to Cocoon? Is Open-Source Software viewed differently, on the whole, in
  Europe than America? Does this have anything to do with Microsoft's
  influence in America? I guess that's more than one question!
 Interested in
  your observations...
 
  Reason I ask... I live in Seattle (Microsoft-land), and I'd love to find
  work using Cocoon and/or Java (but especially 

Re: Get session variables for a generator

2003-01-31 Thread Andrew Timberlake
On Fri, 2003-01-31 at 16:01, Lionel Crine wrote:
 Hello,
 
 I' d like to get two session variables and use them as parameter for my 
 custom generator.
 
 1/Should I get them in the sitemap and use map:parameter ? in the sitemap.
 how do I write that ?
map:generator ...
map:parameter name=var1 value={session-attr:var1}/
map:parameter name=var2 value={session-attr:var2}/
/map:generator

This will create parameters named var1  var2 respectively using the
session attributes var1  var2
The {session-attr:} is an input module.

 
 2/Or should I get them direclty in the generator ?
 How do I do that ?
I don't know if one is necessarily better than the other but to do this
would be done as follows, inside the act method.

Request request = ObjectModelHelper.getRequest(objectModel);
String var1 = (String) request.getSession().getAttribute(var1);

 
 
 Lionel
 
Hope this helps

 
   
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
-- 
Andrew Timberlake [EMAIL PROTECTED]


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
Hello Jan,

I couldn't find the error.

But I attached it.

-Ursprüngliche Nachricht-
Von: Jan Harms [mailto:[EMAIL PROTECTED]]
Gesendet: Freitag, 31. Januar 2003 14:31
An: [EMAIL PROTECTED]
Betreff: AW: xsp-element equivalent to xsl:param?


Thorsten,

here is a tip that might be useful: When you get a message Error compiling foo.xsp 
you should have a look at the generated java class.

Like JSPs, XSPs are transformed into a .java source file. Afterwards cocoon tries to 
compile this .java file into a .class file. These files can be found in Tomcats (or 
your servlet-engines) work-directory. Search for a subdirectory called 

cocoon-files/org/apache/cocoon/www/

There you can find a foo_xsp.java file. Open this file and search for syntax errors 
(the exception contains a line number!). Sure it´s generated code, but quite readable.

-Jan


 -Ursprüngliche Nachricht-
 Von: Scherler, Thorsten [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 14:09
 An: [EMAIL PROTECTED]
 Betreff: AW: xsp-element equivalent to xsl:param?
 
 
 Yes, I've noticed that as well but with
 getParameter(date)); - same exception.
 
 Thanks
 
 -Ursprüngliche Nachricht-
 Von: Geoff Howard [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 14:17
 An: [EMAIL PROTECTED]
 Betreff: RE: xsp-element equivalent to xsl:param?
 
 
 Wast that cut and pasted?  It looks like you're missing an 
 end ) - should
 be:
   getParameter(date));
 
 Geoff
 
  -Original Message-
  From: Scherler, Thorsten [mailto:[EMAIL PROTECTED]]
  Sent: Friday, January 31, 2003 7:48 AM
  To: [EMAIL PROTECTED]
  Subject: AW: xsp-element equivalent to xsl:param?
 
 
  Hello Andrew,
 
  with:
  xsp:logic
  try{
  String timeOfDay = (new
  
 SimpleDateFormat(MM/dd/)).format(parameters.getParameter
 (date);
  }catch(Exception e){}
  /xsp:logic
 
  I get:
 
  type fatal
 
  message Language Exception
 
  description org.apache.cocoon.ProcessingException: Language
  Exception:
  org.apache.cocoon.components.language.LanguageException: Error
  compiling IDC2_info_int_xsp: Line 251, column 0: illegal start of
  type Line 105, column 11: class
  org.apache.cocoon.www.logic.IDC2_info_int_xsp should be declared
  abstract; it does not define method generate() in class
  org.apache.cocoon.generation.AbstractGenerator Line 0, 
 column 0: 2 errors
 
  sender org.apache.cocoon.servlet.CocoonServlet
 
  source Cocoon servlet
 
  stack-trace
 
  org.apache.cocoon.ProcessingException: Language Exception:
  org.apache.cocoon.components.language.LanguageException: Error
  compiling IDC2_info_int_xsp:
  Line 251, column 0:  illegal start of type
  Line 105, column 11:  class
  org.apache.cocoon.www.logic.IDC2_info_int_xsp should be declared
  abstract; it does not define method generate() in class
  org.apache.cocoon.generation.AbstractGenerator
  Line 0, column 0:
  2 errors
 
  at
  org.apache.cocoon.components.language.generator.ProgramGeneratorIm
  pl.createResource(ProgramGeneratorImpl.java:340)
  at
  org.apache.cocoon.components.language.generator.ProgramGeneratorIm
  pl.load(ProgramGeneratorImpl.java:292)
  at
  org.apache.cocoon.generation.ServerPagesGenerator.setup(ServerPage
  sGenerator.java:198)
  at
  org.apache.cocoon.components.pipeline.AbstractEventPipeline.setupP
  ipeline(AbstractEventPipeline.java:202)
  at
  org.apache.cocoon.components.pipeline.CachingEventPipeline.setup(C
 achingEventPipeline.java:278)
  at
  org.apache.cocoon.components.pipeline.CachingEventPipeline.generat
  eKey(CachingEventPipeline.java:141)
  at
  org.apache.cocoon.components.pipeline.CachingStreamPipeline.proces
  s(CachingStreamPipeline.java:317)
  at
  org.apache.cocoon.components.treeprocessor.sitemap.SerializeNode.i
  nvoke(SerializeNode.java:153)
  at
  org.apache.cocoon.components.treeprocessor.AbstractParentProcessin
  gNode.invokeNodes(AbstractParentProcessingNode.java:85)
  at
  org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatch
  Node.invoke(PreparableMatchNode.java:156)
  at
  org.apache.cocoon.components.treeprocessor.AbstractParentProcessin
  gNode.invokeNodes(AbstractParentProcessingNode.java:109)
  at
  org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.in
  voke(PipelineNode.java:140)
  at
  org.apache.cocoon.components.treeprocessor.AbstractParentProcessin
  gNode.invokeNodes(AbstractParentProcessingNode.java:109)
  at
  org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.i
  nvoke(PipelinesNode.java:144)
  at
  org.apache.cocoon.components.treeprocessor.TreeProcessor.process(T
  reeProcessor.java:328)
  at
  org.apache.cocoon.components.treeprocessor.TreeProcessor.process(T
  reeProcessor.java:293)
  at org.apache.cocoon.Cocoon.process(Cocoon.java:575)
  at
  
 org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.
 java:999)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
   

AW: Get session variables for a generator

2003-01-31 Thread Sternath Elmar
I used WildcardSessionAttributeMatcher to get session attributes:
map:match type=sessionstate pattern=*
map:parameter name=attribute-name value=YourParam/
map:generate type=YourGenerator src=YourSource
map:parameter name=YourParam value={1} /

Here is YourGenerator's source code to get YourParam:
public void generate() throws IOException, SAXException, ProcessingException {
  // Get YourParam
String yourParam = parameters.getParameter(YourParam, );

Elmar


-Ursprüngliche Nachricht-
Von: Lionel Crine [mailto:[EMAIL PROTECTED]]
Gesendet: Freitag, 31. Januar 2003 15:02
An: [EMAIL PROTECTED]
Betreff: Get session variables for a generator


Hello,

I' d like to get two session variables and use them as parameter for my 
custom generator.

1/Should I get them in the sitemap and use map:parameter ? in the sitemap.
how do I write that ?

2/Or should I get them direclty in the generator ?
How do I do that ?


Lionel


  


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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

-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Andrew Timberlake
On Fri, 2003-01-31 at 16:09, Scherler, Thorsten wrote:
 Hello Jan,
 
 I couldn't find the error.
 
 But I attached it.
 

The following code looks VERY wrong as you seem to have java code that
resides outside of a method.

/*snip*/
try{ 
String timeOfDay = (new 
SimpleDateFormat(MM/dd/)).format(request.getParameter(date)); 
}catch(Exception e){} 


  /** 
   * Generate XML data. 
   */ 
  public void generate() throws SAXException, IOException,
ProcessingException { 
/*snip*/

Make sure that the request.getParameter ... code is placed after the
first xml element in the xsp page.

-- 
Andrew Timberlake [EMAIL PROTECTED]


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Andrew Timberlake
On Fri, 2003-01-31 at 16:09, Scherler, Thorsten wrote:
 Hello Jan,
 
 I couldn't find the error.
 
 But I attached it.
 
I was reading your previous post in which you posted your xsp source.
Instead of this:
esql:execute-query
esql:query
 select * from info_bericht  where country ='xsp-request:get-parameter
name=GETcountry/' AND  Info_datum = #xsp-request:get-parameter name=date/#
/esql:query

Try this:
esql:execute-query
esql:query
 select * from info_bericht  where country = 
esql:parameterxsp-request:get-parameter
name=GETcountry//esql:parameter AND  Info_datum = 
esql:parameterxsp-request:get-parameter name=date//esql:parameter
/esql:query

This will then use a PreparedStatement which is safer from possible SQL exploit.

Other than that, the XSP source didn't show where you were using the direct access to 
parameters.getParameter() or request.getParameter()

Andrew

Andrew


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: XMLForm Xindice howto at Wiki refactored and ready

2003-01-31 Thread Ivelin Ivanov
Josema,

The new revision is excelent.

Please follow the instructions to submit an official HOWTO
http://xml.apache.org/cocoon/howto/howto-author-howto.html

Diana will take it from there.


I would recommend the following minor corrections to the code:

In the fragment below, why use //. Is it a typo?
/info and /@id are probably more appropriate.
The ref in the textbox case should always resolve to a single node. // may
return a nodeset.

 xf:textbox ref=//@id
  xf:captionArtist identifier:/xf:caption
/xf:textbox
xf:textbox ref=//Name

same applies for

String artistName = (String)getForm().getValue(//@id);
...
v.setPath(//@id);


Do you even need // for
Node result = xi.find(xindiceSubCol, //Artist[@id='+ artistName +'],
Artist);

this looks like stale code

  //v.setPath(/artistName);



You can remove the reset() method.
Checkboxes are automatically handled for session scope beans.
My experience shows that when representing plain value objects, session
beans are never a memory concern
with the modern app servers.
I would prefer them almost always over request scope.
Much easier to code, which results in less code and less maintanance.




On a different note, I thinkg that your code can be used in the
AbstractXMLFormAction.

For example when the map parameter is prefixed with java:, like in
java:org.my.TestBean,
then the existing JavaBean instantiation logic can be used.
In all other cases, the model can be resolved via the SourceResolver.
This will allow benefiting from the InputModules to access xml files from
different sources: file system, xindice, remote URL, etc.
 map:parameter name=xmlform-model value=artist/artist-model.xml/

If you think this makes sense, please consider submitting a patch to that
effect.



Congratulations for the great job once again.


-=Ivelin=-
- Original Message -
From: Josema Alonso [EMAIL PROTECTED]
To: Cocoon-Users [EMAIL PROTECTED]
Sent: Tuesday, January 28, 2003 1:06 PM
Subject: XMLForm Xindice howto at Wiki refactored and ready


 Ivelin and all,

 I finally had the time to refactor the example. Following the ideas we
 exchanged these past days, I put it altogether at Wiki and I think we have
 now a much better sample :-)
 http://wiki.cocoondev.org/Wiki.jsp?page=XMLFormXindice

 Please, review it if you want to and inform me of any faults you can find
so
 i could fix them. I hope i wrote a clear explanation.

 If you feel this can be a good addittion to the official how-tos feel free
 of adding it yourself of let me know who I should contact (Diana, maybe?)
or
 where I should start. I still have not contributed anything to the
official
 docs and I'm somewhat lost...

 Thanks.



 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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



-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: Cocoon use worldwide

2003-01-31 Thread jcallahan
Geoff,

I'm game for a DC CHUG.  I already partipate in the DC SGML/XML UG and
the Baltimore HJUG, but my S.O. won't mind another night per month.
Right? :-)

Let's talk on Wed. Feb 19th at the DC SGML/XML UG meeting (at the AGU
Bldg. on Florida and Connecticut Aves. NW north of Dupont Circle).
February's meeting is also a joint meeting with the DC Linux UG.

-- jack

John R. Callahan
Sphere Software Corporation - The Intelligence of XML
[EMAIL PROTECTED]

 
 Anyone in DC up for a C.H.U.G.? (Cocoon Hackers  Users Group)
 
 Geoff
 

-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
Hello Andrew,

my final xsp should look like this:
...
dataset
  xsp:logic
 try{
 String timeOfDay = (new
SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
}catch(Exception e){}
 /xsp:logic
esql:connection
esql:poolIDC2_int/esql:pool
esql:execute-query
esql:query
 select * from info_bericht  where country ='xsp-request:get-parameter 
name=GETcountry/'   AND  Info_datum = #xsp:exprtimeOfDay/xsp:expr#
 /esql:query
...

like I stated before, as soon I get rid off the logic my query is successful.

Like you told me before my method now starts after the first xml element:

snip from IDC2_info_int_xsp.java
  /**
* Generate XML data.
*/
  public void generate() throws SAXException, IOException, ProcessingException {
  this.contentHandler.startDocument();
 AttributesImpl xspAttr = new AttributesImpl();

...

this.contentHandler.startElement(
  ,
  dataset,
  dataset,
  xspAttr
);
xspAttr.clear();


 this.characters(\n  );
  
 try{
 String timeOfDay = (new
SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
}catch(Exception e){}
 
 this.characters(\n\t\t);
  ... 


-Ursprüngliche Nachricht-
Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
Gesendet: Freitag, 31. Januar 2003 15:30
An: [EMAIL PROTECTED]
Betreff: Re: AW: xsp-element equivalent to xsl:param?


On Fri, 2003-01-31 at 16:09, Scherler, Thorsten wrote:
 Hello Jan,
 
 I couldn't find the error.
 
 But I attached it.
 
I was reading your previous post in which you posted your xsp source.
Instead of this:
esql:execute-query
esql:query
 select * from info_bericht  where country ='xsp-request:get-parameter
name=GETcountry/' AND  Info_datum = #xsp-request:get-parameter name=date/#
/esql:query

Try this:
esql:execute-query
esql:query
 select * from info_bericht  where country = 
esql:parameterxsp-request:get-parameter
name=GETcountry//esql:parameter AND  Info_datum = 
esql:parameterxsp-request:get-parameter name=date//esql:parameter
/esql:query

This will then use a PreparedStatement which is safer from possible SQL exploit.

Other than that, the XSP source didn't show where you were using the direct access to 
parameters.getParameter() or request.getParameter()

Andrew

Andrew


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
I found out that (1):
...
  xsp:logic
 String timeOfDay = (new
SimpleDateFormat(MM/dd/)).format(new Date());
 /xsp:logic
...
esql:query
 select * from info_bericht  where country ='xsp-request:get-parameter 
name=GETcountry/'   AND  Info_datum = #xsp:exprtimeOfDay/xsp:expr#
 /esql:query
...

works fine!

BUT this (2/3/4) one is not working at all:
...
xsp:logic
 try{
String timeOfDay = (new
 SimpleDateFormat(MM/dd/)).format(new Date());
 }catch(Exception e){}
 /xsp:logic
...
esql:query
 select * from info_bericht  where country ='xsp-request:get-parameter 
name=GETcountry/'   AND  Info_datum = #xsp:exprtimeOfDay/xsp:expr#
 /esql:query
...

error:
description org.apache.cocoon.ProcessingException: Language Exception: 
org.apache.cocoon.components.language.LanguageException: Error compiling 
IDC2_info_int_xsp: Line 371, column 9: variable timeOfDay not found in class 
org.apache.cocoon.www.logic.IDC2_info_int_xsp Line 0, column 0: 1 error 

AND (3) neither working:
...
  xsp:logic
 String timeOfDay = (new
SimpleDateFormat(MM/dd/)).format(parameters.getParameter(date));
 /xsp:logic
...

error:
description org.apache.cocoon.ProcessingException: Language Exception: 
org.apache.cocoon.components.language.LanguageException: Error compiling 
IDC2_info_int_xsp: Line 302, column 62: unreported exception: 
org.apache.avalon.framework.parameters.ParameterException; must be caught or declared 
to be thrown Line 0, column 0: 1 error 

Nor (4):
...
  xsp:logic
 String timeOfDay = (new
SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
 /xsp:logic
...

error:
escription org.apache.cocoon.ProcessingException: Exception in 
ServerPagesGenerator.generate(): java.lang.IllegalArgumentException: Cannot format 
given Object as a Date

I don't have a clue!

Is there another way?

King regards

-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Andrew Timberlake
Try this

...
dataset
   xsp:logic
  String timeOfDay = ;
  try{
 timeOfDay = (new
SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
  }catch(Exception e){}
   /xsp:logic
   
esql:connection
esql:poolIDC2_int/esql:pool
esql:execute-query
esql:query
select * from info_bericht  where country ='xsp-request:get-parameter
name=GETcountry/'   AND  Info_datum =
#xsp:exprtimeOfDay/xsp:expr#
/esql:query

I will mention again that you should look into using esql:parameter
tags.

Andrew

On Fri, 2003-01-31 at 16:46, Scherler, Thorsten wrote:
 Hello Andrew,
 
 my final xsp should look like this:
 ...
 dataset
   xsp:logic
  try{
  String timeOfDay = (new
 SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
 }catch(Exception e){}
  /xsp:logic
 esql:connection
 esql:poolIDC2_int/esql:pool
 esql:execute-query
 esql:query
  select * from info_bericht  where country ='xsp-request:get-parameter 
name=GETcountry/'   AND  Info_datum = #xsp:exprtimeOfDay/xsp:expr#
  /esql:query
 ...
 
 like I stated before, as soon I get rid off the logic my query is successful.
 
 Like you told me before my method now starts after the first xml element:
 
 snip from IDC2_info_int_xsp.java
   /**
 * Generate XML data.
 */
   public void generate() throws SAXException, IOException, ProcessingException {
   this.contentHandler.startDocument();
  AttributesImpl xspAttr = new AttributesImpl();
 
 ...
 
 this.contentHandler.startElement(
   ,
   dataset,
   dataset,
   xspAttr
 );
 xspAttr.clear();
 
 
  this.characters(\n  );
   
  try{
  String timeOfDay = (new
 SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
 }catch(Exception e){}
  
  this.characters(\n\t\t);
   ... 
 
 
 -Ursprüngliche Nachricht-
 Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 15:30
 An: [EMAIL PROTECTED]
 Betreff: Re: AW: xsp-element equivalent to xsl:param?
 
 
 On Fri, 2003-01-31 at 16:09, Scherler, Thorsten wrote:
  Hello Jan,
  
  I couldn't find the error.
  
  But I attached it.
  
 I was reading your previous post in which you posted your xsp source.
 Instead of this:
 esql:execute-query
 esql:query
  select * from info_bericht  where country ='xsp-request:get-parameter
 name=GETcountry/' AND  Info_datum = #xsp-request:get-parameter name=date/#
 /esql:query
 
 Try this:
 esql:execute-query
 esql:query
  select * from info_bericht  where country = 
esql:parameterxsp-request:get-parameter
 name=GETcountry//esql:parameter AND  Info_datum = 
esql:parameterxsp-request:get-parameter name=date//esql:parameter
 /esql:query
 
 This will then use a PreparedStatement which is safer from possible SQL exploit.
 
 Other than that, the XSP source didn't show where you were using the direct access 
to parameters.getParameter() or request.getParameter()
 
 Andrew
 
 Andrew
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
-- 
Andrew Timberlake [EMAIL PROTECTED]


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




How can the result of a pipeline be a parameter for a transformation in another pipeline?

2003-01-31 Thread Cyril Vidal
Hello,

I would like to retrieve the language of the user's browser, so that I could
call the I18n Trasnformer in the right way (by passing the locales's value
equal to the browser's language).

To retrieve the language set up in the browser, I've used the Request
Generator, and applied the following simple stylesheet to it:

xsl:stylesheet version=1.0

xmlns:xsl=http://www.w3.org/1999/XSL/Transform;

xmlns:req=http://xml.apache.org/cocoon/requestgenerator/2.0;



xsl:template match=/

xsl:value-of
select=//req:requestHeaders/req:header[@name='accept-language']/

/xsl:template

/xsl:stylesheet



And this is working fine. By example, for my browser, the result is 'fr'.

But now, I don't know what really to do with this value: I would like to use
it as a parameter for a I18nTransformation in another pipeline.

Do you know how this can be achieved?



Thanks for your help,

Cyril.



-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




RE: proposal: The Newbies Competence Center (XSP?)

2003-01-31 Thread Hunsberger, Peter
 I think we are agreeing (?) on the issue of proprietary : in essence, any
code that
 you do not write yourself is 'proprietary' in some way - it belongs to
someone.

Uh, no, but it's not worth worrying about...

-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: How can the result of a pipeline be a parameter for a transformation in another pipeline?

2003-01-31 Thread Konstantin Piroumian
From: Cyril Vidal [EMAIL PROTECTED]

 Hello,

 I would like to retrieve the language of the user's browser, so that I
could
 call the I18n Trasnformer in the right way (by passing the locales's value
 equal to the browser's language).

Simply use the LocaleAction as it is done in i18n samples.
AFAIK, you can setup it to use only the browser's locale and not take into
account request params, session attributes or cookies. But I'm sure you'll
need to allow users to change to language on fly or retain it in a cookie on
the client side to serve the last preferred language of the user. In all
this cases LocaleAction will help you a lot.

-- Konstantin


 To retrieve the language set up in the browser, I've used the Request
 Generator, and applied the following simple stylesheet to it:

 xsl:stylesheet version=1.0

 xmlns:xsl=http://www.w3.org/1999/XSL/Transform;

 xmlns:req=http://xml.apache.org/cocoon/requestgenerator/2.0;

 

 xsl:template match=/

 xsl:value-of
 select=//req:requestHeaders/req:header[@name='accept-language']/

 /xsl:template

 /xsl:stylesheet



 And this is working fine. By example, for my browser, the result is 'fr'.

 But now, I don't know what really to do with this value: I would like to
use
 it as a parameter for a I18nTransformation in another pipeline.

 Do you know how this can be achieved?



 Thanks for your help,

 Cyril.



 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
Thanks,

but now I am not getting any results because is always timeOfDay = .

I will look into using esql:parameter tags.

Thanks for your patience.

-Ursprüngliche Nachricht-
Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
Gesendet: Freitag, 31. Januar 2003 16:07
An: [EMAIL PROTECTED]
Betreff: Re: AW: AW: xsp-element equivalent to xsl:param?


Try this

...
dataset
   xsp:logic
  String timeOfDay = ;
  try{
 timeOfDay = (new
SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
  }catch(Exception e){}
   /xsp:logic
   
esql:connection
esql:poolIDC2_int/esql:pool
esql:execute-query
esql:query
select * from info_bericht  where country ='xsp-request:get-parameter
name=GETcountry/'   AND  Info_datum =
#xsp:exprtimeOfDay/xsp:expr#
/esql:query

I will mention again that you should look into using esql:parameter
tags.

Andrew

On Fri, 2003-01-31 at 16:46, Scherler, Thorsten wrote:
 Hello Andrew,
 
 my final xsp should look like this:
 ...
 dataset
   xsp:logic
  try{
  String timeOfDay = (new
 SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
 }catch(Exception e){}
  /xsp:logic
 esql:connection
 esql:poolIDC2_int/esql:pool
 esql:execute-query
 esql:query
  select * from info_bericht  where country ='xsp-request:get-parameter 
name=GETcountry/'   AND  Info_datum = #xsp:exprtimeOfDay/xsp:expr#
  /esql:query
 ...
 
 like I stated before, as soon I get rid off the logic my query is successful.
 
 Like you told me before my method now starts after the first xml element:
 
 snip from IDC2_info_int_xsp.java
   /**
 * Generate XML data.
 */
   public void generate() throws SAXException, IOException, ProcessingException {
   this.contentHandler.startDocument();
  AttributesImpl xspAttr = new AttributesImpl();
 
 ...
 
 this.contentHandler.startElement(
   ,
   dataset,
   dataset,
   xspAttr
 );
 xspAttr.clear();
 
 
  this.characters(\n  );
   
  try{
  String timeOfDay = (new
 SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
 }catch(Exception e){}
  
  this.characters(\n\t\t);
   ... 
 
 
 -Ursprüngliche Nachricht-
 Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 15:30
 An: [EMAIL PROTECTED]
 Betreff: Re: AW: xsp-element equivalent to xsl:param?
 
 
 On Fri, 2003-01-31 at 16:09, Scherler, Thorsten wrote:
  Hello Jan,
  
  I couldn't find the error.
  
  But I attached it.
  
 I was reading your previous post in which you posted your xsp source.
 Instead of this:
 esql:execute-query
 esql:query
  select * from info_bericht  where country ='xsp-request:get-parameter
 name=GETcountry/' AND  Info_datum = #xsp-request:get-parameter name=date/#
 /esql:query
 
 Try this:
 esql:execute-query
 esql:query
  select * from info_bericht  where country = 
esql:parameterxsp-request:get-parameter
 name=GETcountry//esql:parameter AND  Info_datum = 
esql:parameterxsp-request:get-parameter name=date//esql:parameter
 /esql:query
 
 This will then use a PreparedStatement which is safer from possible SQL exploit.
 
 Other than that, the XSP source didn't show where you were using the direct access 
to parameters.getParameter() or request.getParameter()
 
 Andrew
 
 Andrew
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
-- 
Andrew Timberlake [EMAIL PROTECTED]


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Question on generators...

2003-01-31 Thread SriKumar Kareti

Thanks for you help in advance...

I am a new user to Cocoon. I have searched the site pretty well and
could
not answer this question. Could someone help...

My goal is to move from current servlet based solution to Cocoon. The
general
flow of my current program is 

1) Take the request, 
2) Generate the XML by making calls to Database based on the parameters 
   passed...
3) Use XSLT to generate html which is returned...

Now I'd like to move to cocoon. I want to use my existing Java class
as the generator in Cocoon.

Can I do that?

SriKumar.

-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




session variables from sunshine framework

2003-01-31 Thread Lionel Crine
I have a smal portal with a login page.
I get them with :

map:parameter name=parameter_name value=request:name/
map:parameter name=parameter_password value=request:password/

to check them with an xsl page.

I presume this two variable are stored in a sunshine context.

If yes :
how can i get them to put them in my generator ?


If not :
how can I store my two variables a sunshine session context and then to 
get them to my generator ?


Lionel


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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



Re: AW: AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Andrew Timberlake
I think that the request parameter is returning a string and the format
object is expecting a Date object. (I should have recognised this
earlier).
I think the XSP page is throwing an exception which we have been
ignoring. Try the following code and then check the sitemap.log and
errors.log (can't remember which one) file in /WEB-INF/logs/ for the
exception. You can do a find in the log file for XSP date error to
locate the error.
If there is an error being thrown, then you are going to have to change
the request parameter value into a valid java.util.Date object.

...
dataset
   xsp:logic
  String timeOfDay = ;
  try{
 timeOfDay = (new
SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
  }catch(Exception e){
getLogger().error(XSP date error: , e);
}
   /xsp:logic
   

On Fri, 2003-01-31 at 17:13, Scherler, Thorsten wrote:
 Thanks,
 
 but now I am not getting any results because is always timeOfDay = .
 
 I will look into using esql:parameter tags.
 
 Thanks for your patience.
 
 -Ursprüngliche Nachricht-
 Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 16:07
 An: [EMAIL PROTECTED]
 Betreff: Re: AW: AW: xsp-element equivalent to xsl:param?
 
 
 Try this
 
 ...
 dataset
xsp:logic
   String timeOfDay = ;
   try{
  timeOfDay = (new
 SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
   }catch(Exception e){}
/xsp:logic

 esql:connection
 esql:poolIDC2_int/esql:pool
 esql:execute-query
 esql:query
 select * from info_bericht  where country ='xsp-request:get-parameter
 name=GETcountry/'   AND  Info_datum =
 #xsp:exprtimeOfDay/xsp:expr#
 /esql:query
 
 I will mention again that you should look into using esql:parameter
 tags.
 
 Andrew
 
 On Fri, 2003-01-31 at 16:46, Scherler, Thorsten wrote:
  Hello Andrew,
  
  my final xsp should look like this:
  ...
  dataset
xsp:logic
   try{
   String timeOfDay = (new
  SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
  }catch(Exception e){}
   /xsp:logic
  esql:connection
  esql:poolIDC2_int/esql:pool
  esql:execute-query
  esql:query
   select * from info_bericht  where country ='xsp-request:get-parameter 
name=GETcountry/'   AND  Info_datum = #xsp:exprtimeOfDay/xsp:expr#
   /esql:query
  ...
  
  like I stated before, as soon I get rid off the logic my query is successful.
  
  Like you told me before my method now starts after the first xml element:
  
  snip from IDC2_info_int_xsp.java
/**
  * Generate XML data.
  */
public void generate() throws SAXException, IOException, ProcessingException {
this.contentHandler.startDocument();
   AttributesImpl xspAttr = new AttributesImpl();
  
  ...
  
  this.contentHandler.startElement(
,
dataset,
dataset,
xspAttr
  );
  xspAttr.clear();
  
  
   this.characters(\n  );

   try{
   String timeOfDay = (new
  SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
  }catch(Exception e){}
   
   this.characters(\n\t\t);
... 
  
  
  -Ursprüngliche Nachricht-
  Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
  Gesendet: Freitag, 31. Januar 2003 15:30
  An: [EMAIL PROTECTED]
  Betreff: Re: AW: xsp-element equivalent to xsl:param?
  
  
  On Fri, 2003-01-31 at 16:09, Scherler, Thorsten wrote:
   Hello Jan,
   
   I couldn't find the error.
   
   But I attached it.
   
  I was reading your previous post in which you posted your xsp source.
  Instead of this:
  esql:execute-query
  esql:query
   select * from info_bericht  where country ='xsp-request:get-parameter
  name=GETcountry/' AND  Info_datum = #xsp-request:get-parameter name=date/#
  /esql:query
  
  Try this:
  esql:execute-query
  esql:query
   select * from info_bericht  where country = 
esql:parameterxsp-request:get-parameter
  name=GETcountry//esql:parameter AND  Info_datum = 
esql:parameterxsp-request:get-parameter name=date//esql:parameter
  /esql:query
  
  This will then use a PreparedStatement which is safer from possible SQL exploit.
  
  Other than that, the XSP source didn't show where you were using the direct access 
to parameters.getParameter() or request.getParameter()
  
  Andrew
  
  Andrew
  
  
  -
  Please check that your question  has not already been answered in the
  FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
  
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail:   [EMAIL PROTECTED]
  
  
  -
  Please check that your question  has not already been answered in the
  FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
  
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail:   [EMAIL PROTECTED]
-- 
Andrew Timberlake [EMAIL PROTECTED]



Re: Question on generators...

2003-01-31 Thread Lionel Crine
Yes you can do a generator :

Here is what I did, this is a main structure :



import your_package;


public class your_class extends ComposerGenerator (or absctractGenerator)
{
...

public void setup(SourceResolver resolver, Map objectModel, String 
src, Parameters par)
throws ProcessingException, SAXException, IOException
{
super.setup(resolver, objectModel, src, par);
}

public void recycle()
{
}

public void generate() throws SAXException, IOException, 
ProcessingException
{
/*	to generate sax events  */
}

for exemple:
public void your_method throws IOException, SAXException, 
ProcessingException
{
}


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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



AW: AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
Hello everyone,

I hope I don't bother you.

At the moment only if I use xsp-request:get-parameter name=date/ I get the 
parameter.

Otherwise I get s**t (sorry for being rude, I spent now more than 12h)- nothing.

So is that a bug?

should I post to the dev-list?

-Ursprüngliche Nachricht-
Von: Scherler, Thorsten 
Gesendet: Freitag, 31. Januar 2003 16:14
An: [EMAIL PROTECTED]
Betreff: AW: AW: AW: xsp-element equivalent to xsl:param?


Thanks,

but now I am not getting any results because is always timeOfDay = .

I will look into using esql:parameter tags.

Thanks for your patience.

-Ursprüngliche Nachricht-
Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
Gesendet: Freitag, 31. Januar 2003 16:07
An: [EMAIL PROTECTED]
Betreff: Re: AW: AW: xsp-element equivalent to xsl:param?


Try this

...
dataset
   xsp:logic
  String timeOfDay = ;
  try{
 timeOfDay = (new
SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
  }catch(Exception e){}
   /xsp:logic
   
esql:connection
esql:poolIDC2_int/esql:pool
esql:execute-query
esql:query
select * from info_bericht  where country ='xsp-request:get-parameter
name=GETcountry/'   AND  Info_datum =
#xsp:exprtimeOfDay/xsp:expr#
/esql:query

I will mention again that you should look into using esql:parameter
tags.

Andrew

On Fri, 2003-01-31 at 16:46, Scherler, Thorsten wrote:
 Hello Andrew,
 
 my final xsp should look like this:
 ...
 dataset
   xsp:logic
  try{
  String timeOfDay = (new
 SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
 }catch(Exception e){}
  /xsp:logic
 esql:connection
 esql:poolIDC2_int/esql:pool
 esql:execute-query
 esql:query
  select * from info_bericht  where country ='xsp-request:get-parameter 
name=GETcountry/'   AND  Info_datum = #xsp:exprtimeOfDay/xsp:expr#
  /esql:query
 ...
 
 like I stated before, as soon I get rid off the logic my query is successful.
 
 Like you told me before my method now starts after the first xml element:
 
 snip from IDC2_info_int_xsp.java
   /**
 * Generate XML data.
 */
   public void generate() throws SAXException, IOException, ProcessingException {
   this.contentHandler.startDocument();
  AttributesImpl xspAttr = new AttributesImpl();
 
 ...
 
 this.contentHandler.startElement(
   ,
   dataset,
   dataset,
   xspAttr
 );
 xspAttr.clear();
 
 
  this.characters(\n  );
   
  try{
  String timeOfDay = (new
 SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
 }catch(Exception e){}
  
  this.characters(\n\t\t);
   ... 
 
 
 -Ursprüngliche Nachricht-
 Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 15:30
 An: [EMAIL PROTECTED]
 Betreff: Re: AW: xsp-element equivalent to xsl:param?
 
 
 On Fri, 2003-01-31 at 16:09, Scherler, Thorsten wrote:
  Hello Jan,
  
  I couldn't find the error.
  
  But I attached it.
  
 I was reading your previous post in which you posted your xsp source.
 Instead of this:
 esql:execute-query
 esql:query
  select * from info_bericht  where country ='xsp-request:get-parameter
 name=GETcountry/' AND  Info_datum = #xsp-request:get-parameter name=date/#
 /esql:query
 
 Try this:
 esql:execute-query
 esql:query
  select * from info_bericht  where country = 
esql:parameterxsp-request:get-parameter
 name=GETcountry//esql:parameter AND  Info_datum = 
esql:parameterxsp-request:get-parameter name=date//esql:parameter
 /esql:query
 
 This will then use a PreparedStatement which is safer from possible SQL exploit.
 
 Other than that, the XSP source didn't show where you were using the direct access 
to parameters.getParameter() or request.getParameter()
 
 Andrew
 
 Andrew
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
-- 
Andrew Timberlake [EMAIL PROTECTED]


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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



AW: AW: AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
You're patience and so brilliant:
sitemap.log:
ERROR   (2003-01-31) 16:36.32:707   [sitemap.generator.serverpages] 
(/weidmueller-dev/IDC2/info_int.xml) Thread-9/IDC2_info_int_xsp: XSP date error: 
java.lang.IllegalArgumentException: Cannot format given Object as a Date
at java.text.DateFormat.format(DateFormat.java:265)
at java.text.Format.format(Format.java:116)

now you wrote:
If there is an error being thrown, then you are going to have to change
the request parameter value into a valid java.util.Date object.

my question: How? - I am so stupid when it comes to Java (or maybe in general ;-))

-Ursprüngliche Nachricht-
Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
Gesendet: Freitag, 31. Januar 2003 16:27
An: [EMAIL PROTECTED]
Betreff: Re: AW: AW: AW: xsp-element equivalent to xsl:param?


I think that the request parameter is returning a string and the format
object is expecting a Date object. (I should have recognised this
earlier).
I think the XSP page is throwing an exception which we have been
ignoring. Try the following code and then check the sitemap.log and
errors.log (can't remember which one) file in /WEB-INF/logs/ for the
exception. You can do a find in the log file for XSP date error to
locate the error.
If there is an error being thrown, then you are going to have to change
the request parameter value into a valid java.util.Date object.

...
dataset
   xsp:logic
  String timeOfDay = ;
  try{
 timeOfDay = (new
SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
  }catch(Exception e){
getLogger().error(XSP date error: , e);
}
   /xsp:logic
   

On Fri, 2003-01-31 at 17:13, Scherler, Thorsten wrote:
 Thanks,
 
 but now I am not getting any results because is always timeOfDay = .
 
 I will look into using esql:parameter tags.
 
 Thanks for your patience.
 
 -Ursprüngliche Nachricht-
 Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 16:07
 An: [EMAIL PROTECTED]
 Betreff: Re: AW: AW: xsp-element equivalent to xsl:param?
 
 
 Try this
 
 ...
 dataset
xsp:logic
   String timeOfDay = ;
   try{
  timeOfDay = (new
 SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
   }catch(Exception e){}
/xsp:logic

 esql:connection
 esql:poolIDC2_int/esql:pool
 esql:execute-query
 esql:query
 select * from info_bericht  where country ='xsp-request:get-parameter
 name=GETcountry/'   AND  Info_datum =
 #xsp:exprtimeOfDay/xsp:expr#
 /esql:query
 
 I will mention again that you should look into using esql:parameter
 tags.
 
 Andrew
 
 On Fri, 2003-01-31 at 16:46, Scherler, Thorsten wrote:
  Hello Andrew,
  
  my final xsp should look like this:
  ...
  dataset
xsp:logic
   try{
   String timeOfDay = (new
  SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
  }catch(Exception e){}
   /xsp:logic
  esql:connection
  esql:poolIDC2_int/esql:pool
  esql:execute-query
  esql:query
   select * from info_bericht  where country ='xsp-request:get-parameter 
name=GETcountry/'   AND  Info_datum = #xsp:exprtimeOfDay/xsp:expr#
   /esql:query
  ...
  
  like I stated before, as soon I get rid off the logic my query is successful.
  
  Like you told me before my method now starts after the first xml element:
  
  snip from IDC2_info_int_xsp.java
/**
  * Generate XML data.
  */
public void generate() throws SAXException, IOException, ProcessingException {
this.contentHandler.startDocument();
   AttributesImpl xspAttr = new AttributesImpl();
  
  ...
  
  this.contentHandler.startElement(
,
dataset,
dataset,
xspAttr
  );
  xspAttr.clear();
  
  
   this.characters(\n  );

   try{
   String timeOfDay = (new
  SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
  }catch(Exception e){}
   
   this.characters(\n\t\t);
... 
  
  
  -Ursprüngliche Nachricht-
  Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
  Gesendet: Freitag, 31. Januar 2003 15:30
  An: [EMAIL PROTECTED]
  Betreff: Re: AW: xsp-element equivalent to xsl:param?
  
  
  On Fri, 2003-01-31 at 16:09, Scherler, Thorsten wrote:
   Hello Jan,
   
   I couldn't find the error.
   
   But I attached it.
   
  I was reading your previous post in which you posted your xsp source.
  Instead of this:
  esql:execute-query
  esql:query
   select * from info_bericht  where country ='xsp-request:get-parameter
  name=GETcountry/' AND  Info_datum = #xsp-request:get-parameter name=date/#
  /esql:query
  
  Try this:
  esql:execute-query
  esql:query
   select * from info_bericht  where country = 
esql:parameterxsp-request:get-parameter
  name=GETcountry//esql:parameter AND  Info_datum = 
esql:parameterxsp-request:get-parameter name=date//esql:parameter
  /esql:query
  
  This will then use a PreparedStatement which is safer from possible SQL exploit.
  
  Other than that, the XSP source didn't show where you were using the direct 

RE: Cocoon use worldwide

2003-01-31 Thread Matthew Langham
 1) Open Source projects seem to grow virally, infecting those
 closest to the
 source first.  Sooner or later a carrier makes their way to some place new
 and a new source of infection grows up.  With Cocoon I think there are now
 enough sources of infection that it will propagate at a pretty rapid rate
 across the entire world in the future.

This is very true. For the last weeks of 2002 and now in 2003 we are
noticing a strong growth in the number of Cocoon related inquiries we
receive.

The problem of large companies using Cocoon and not (yet) talking about it
publicly has been touched on in this thread. I can say that there are really
really large companies either already using Cocoon in production
environments or evaluating Cocoon for their requirements. Hopefully we will
see more of this become public this year.

Anyone know any VCs with money left? :-).

Matthew

--
Open Source Group   Cocoon { Consulting, Training, Projects }
=
Matthew Langham, SN AG, Klingenderstrasse 5, D-33100 Paderborn
Tel:+49-5251-1581-30  [EMAIL PROTECTED] - http://www.s-und-n.de
-
Cocoon book:
  http://www.amazon.com/exec/obidos/ASIN/0735712352/needacake-20
Weblogs:
  http://radio.weblogs.com/0103021/
  http://www.oreillynet.com/weblogs/author/1014
=



-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




RE: Cocoon use worldwide

2003-01-31 Thread Hunsberger, Peter
 We're using Cocoon on health care projects that need to
 protect XML content at a fine-grain level based on a user's role, context,
and state  of the data.  Rather than embedding this logic completely in the
persistence layer 
 or code (a DB or EJBs), we're doing it within transforms and actions.  

Hi Jack (John?),

This sounds an awful lot like what we are working on here at St. Jude
Children's Research Hospital...  I've posted about it some here on users and
some on dev.  Mostly architectural concerns: one area I'd like to see Cocoon
go is to make it possible to write all business and presentation logic as
XSLT rules triggered from XML templates.

 This allows us to audit various transactions to ensure they meet HIPAA
guidelines at 
 a very detailed level and express those data security policies as
constraints on
 XPath expressions - which non-programmers like physicians can actually
read and
 understand! :-)  

That's a bit different than our approach.  The security and audit rules are
written in  XSLT/Xpath, but they aren't implemented in such a way that I'd
expect anyone but a programmer to understand (though they are not to
opaque).  Eg:

  xsl:if test=$auth != 'None' and $auth != ''  !-- can user see
object at all? --

Or:
  xsl:if test=contains(@authorization,'Update')

 We've also been able to more easily cast their web applications as web
services, 
 VoiceXML services, and as AvantGo sources (e.g., a directory of regional
 physicians).

Haven't had to go their yet...

 Finally, the development and deployment of Cocoon
 solutions are very cost effective (TCD and TCO). 

Very important for a non-profit like us...

snip/

 I'm giving a tutorial on Cocoon next month ( http://www.eccnet.com/xmlug/
) here 
 in D.C.  I also noticed that Ivelin Ivanov is giving a talk in Austin, TX
USA next
 month too ( http://www.xmlaustin.org/_html_out/main/events.html )

If you ever make it near Memphis I think it would be worth getting together.
I used to get to the DC area every spring for the HCFA conferences but don't
have time for those these days...


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: How can the result of a pipeline be a parameter for a transformation in another pipeline?

2003-01-31 Thread Cyril Vidal
Thanks for your help Konstantin!
It's OK with LocaleAction.

Regards,
Cyril.
- Original Message -
From: Konstantin Piroumian [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, January 31, 2003 4:12 PM
Subject: Re: How can the result of a pipeline be a parameter for a
transformation in another pipeline?


 From: Cyril Vidal [EMAIL PROTECTED]

  Hello,
 
  I would like to retrieve the language of the user's browser, so that I
 could
  call the I18n Trasnformer in the right way (by passing the locales's
value
  equal to the browser's language).

 Simply use the LocaleAction as it is done in i18n samples.
 AFAIK, you can setup it to use only the browser's locale and not take into
 account request params, session attributes or cookies. But I'm sure you'll
 need to allow users to change to language on fly or retain it in a cookie
on
 the client side to serve the last preferred language of the user. In all
 this cases LocaleAction will help you a lot.

 -- Konstantin

 
  To retrieve the language set up in the browser, I've used the Request
  Generator, and applied the following simple stylesheet to it:
 
  xsl:stylesheet version=1.0
 
  xmlns:xsl=http://www.w3.org/1999/XSL/Transform;
 
  xmlns:req=http://xml.apache.org/cocoon/requestgenerator/2.0;
 
  
 
  xsl:template match=/
 
  xsl:value-of
  select=//req:requestHeaders/req:header[@name='accept-language']/
 
  /xsl:template
 
  /xsl:stylesheet
 
 
 
  And this is working fine. By example, for my browser, the result is
'fr'.
 
  But now, I don't know what really to do with this value: I would like to
 use
  it as a parameter for a I18nTransformation in another pipeline.
 
  Do you know how this can be achieved?
 
 
 
  Thanks for your help,
 
  Cyril.
 
 
 
  -
  Please check that your question  has not already been answered in the
  FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail:   [EMAIL PROTECTED]
 
 


 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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





-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: AW: AW: AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Andrew Timberlake
Thank you for the compliment but it was only through bumping my head
against many a brick wall that I learned anything.

To convert your string into a Date object, you simply invert the process
on the SimpleDateFormat object

Date myDate = (new
SimpleDateFormat(MM/dd/)).parse(request.getParameter(date));
This method needs the request parameter to arrive in the correct format
though and therefore invalidates the need to format the date in the way
you been up until now.

Now this is where the esql:parameter tag comes in handy. Instead of
using the #Formated dat string# format you can pass the date object
directly to the esql parameter:

esql:parameterxsp:exprmyDate/xsp:expr/esql:parameter

Andrew

On Fri, 2003-01-31 at 17:40, Scherler, Thorsten wrote:
 You're patience and so brilliant:
 sitemap.log:
 ERROR   (2003-01-31) 16:36.32:707   [sitemap.generator.serverpages] 
(/weidmueller-dev/IDC2/info_int.xml) Thread-9/IDC2_info_int_xsp: XSP date error: 
 java.lang.IllegalArgumentException: Cannot format given Object as a Date
   at java.text.DateFormat.format(DateFormat.java:265)
   at java.text.Format.format(Format.java:116)
 
 now you wrote:
 If there is an error being thrown, then you are going to have to change
 the request parameter value into a valid java.util.Date object.
 
 my question: How? - I am so stupid when it comes to Java (or maybe in general ;-))
 
 -Ursprüngliche Nachricht-
 Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 16:27
 An: [EMAIL PROTECTED]
 Betreff: Re: AW: AW: AW: xsp-element equivalent to xsl:param?
 
 
 I think that the request parameter is returning a string and the format
 object is expecting a Date object. (I should have recognised this
 earlier).
 I think the XSP page is throwing an exception which we have been
 ignoring. Try the following code and then check the sitemap.log and
 errors.log (can't remember which one) file in /WEB-INF/logs/ for the
 exception. You can do a find in the log file for XSP date error to
 locate the error.
 If there is an error being thrown, then you are going to have to change
 the request parameter value into a valid java.util.Date object.
 
 ...
 dataset
xsp:logic
   String timeOfDay = ;
   try{
  timeOfDay = (new
 SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
   }catch(Exception e){
 getLogger().error(XSP date error: , e);
 }
/xsp:logic

 
 On Fri, 2003-01-31 at 17:13, Scherler, Thorsten wrote:
  Thanks,
  
  but now I am not getting any results because is always timeOfDay = .
  
  I will look into using esql:parameter tags.
  
  Thanks for your patience.
  
  -Ursprüngliche Nachricht-
  Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
  Gesendet: Freitag, 31. Januar 2003 16:07
  An: [EMAIL PROTECTED]
  Betreff: Re: AW: AW: xsp-element equivalent to xsl:param?
  
  
  Try this
  
  ...
  dataset
 xsp:logic
String timeOfDay = ;
try{
   timeOfDay = (new
  SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
}catch(Exception e){}
 /xsp:logic
 
  esql:connection
  esql:poolIDC2_int/esql:pool
  esql:execute-query
  esql:query
  select * from info_bericht  where country ='xsp-request:get-parameter
  name=GETcountry/'   AND  Info_datum =
  #xsp:exprtimeOfDay/xsp:expr#
  /esql:query
  
  I will mention again that you should look into using esql:parameter
  tags.
  
  Andrew
  
  On Fri, 2003-01-31 at 16:46, Scherler, Thorsten wrote:
   Hello Andrew,
   
   my final xsp should look like this:
   ...
   dataset
 xsp:logic
try{
String timeOfDay = (new
   SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
   }catch(Exception e){}
/xsp:logic
   esql:connection
   esql:poolIDC2_int/esql:pool
   esql:execute-query
   esql:query
select * from info_bericht  where country ='xsp-request:get-parameter 
name=GETcountry/'   AND  Info_datum = #xsp:exprtimeOfDay/xsp:expr#
/esql:query
   ...
   
   like I stated before, as soon I get rid off the logic my query is successful.
   
   Like you told me before my method now starts after the first xml element:
   
   snip from IDC2_info_int_xsp.java
 /**
   * Generate XML data.
   */
 public void generate() throws SAXException, IOException, ProcessingException {
 this.contentHandler.startDocument();
AttributesImpl xspAttr = new AttributesImpl();
   
   ...
   
   this.contentHandler.startElement(
 ,
 dataset,
 dataset,
 xspAttr
   );
   xspAttr.clear();
   
   
this.characters(\n  );
 
try{
String timeOfDay = (new
   SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
   }catch(Exception e){}

this.characters(\n\t\t);
 ... 
   
   
   -Ursprüngliche Nachricht-
   Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
   Gesendet: Freitag, 31. Januar 2003 15:30
   An: [EMAIL PROTECTED]
   Betreff: Re: AW: xsp-element equivalent to 

Re: How can the result of a pipeline be a parameter for a transformation in another pipeline?

2003-01-31 Thread Christian Haul
On 31.Jan.2003 -- 04:07 PM, Cyril Vidal wrote:
 Hello,
 
 I would like to retrieve the language of the user's browser, so that I could
 call the I18n Trasnformer in the right way (by passing the locales's value
 equal to the browser's language).
 
 To retrieve the language set up in the browser, I've used the Request
 Generator, and applied the following simple stylesheet to it:

Starting with version 2.0.4 you could try
{request-header:accept-language} for that. See input modules in
concepts and javadocs.

Chris.
-- 
C h r i s t i a n   H a u l
[EMAIL PROTECTED]
fingerprint: 99B0 1D9D 7919 644A 4837  7D73 FEF9 6856 335A 9E08

-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: AW: AW: AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
Yes, I am doing that right now.

But the people using the app that I am writing don't want type 01/30/2003 to get the 
reports.
The main reason is that the company that I am working for is in Germany. So the user 
wants to put 30.01.2003 in the form.

If I parse that into the esql I can't get any data out of db.

I thought about client-side JavaScript to transform the date and then parse it, but I 
hoped that I could transform it on the server side with xsp.

You said something about: simply invert the process on the SimpleDateFormat object. 

How would I do that?

-Ursprüngliche Nachricht-
Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
Gesendet: Freitag, 31. Januar 2003 16:50
An: [EMAIL PROTECTED]
Betreff: Re: AW: AW: AW: AW: xsp-element equivalent to xsl:param?


Thank you for the compliment but it was only through bumping my head
against many a brick wall that I learned anything.

To convert your string into a Date object, you simply invert the process
on the SimpleDateFormat object

Date myDate = (new
SimpleDateFormat(MM/dd/)).parse(request.getParameter(date));
This method needs the request parameter to arrive in the correct format
though and therefore invalidates the need to format the date in the way
you been up until now.

Now this is where the esql:parameter tag comes in handy. Instead of
using the #Formated dat string# format you can pass the date object
directly to the esql parameter:

esql:parameterxsp:exprmyDate/xsp:expr/esql:parameter

Andrew

On Fri, 2003-01-31 at 17:40, Scherler, Thorsten wrote:
 You're patience and so brilliant:
 sitemap.log:
 ERROR   (2003-01-31) 16:36.32:707   [sitemap.generator.serverpages] 
(/weidmueller-dev/IDC2/info_int.xml) Thread-9/IDC2_info_int_xsp: XSP date error: 
 java.lang.IllegalArgumentException: Cannot format given Object as a Date
   at java.text.DateFormat.format(DateFormat.java:265)
   at java.text.Format.format(Format.java:116)
 
 now you wrote:
 If there is an error being thrown, then you are going to have to change
 the request parameter value into a valid java.util.Date object.
 
 my question: How? - I am so stupid when it comes to Java (or maybe in general ;-))
 
 -Ursprüngliche Nachricht-
 Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 16:27
 An: [EMAIL PROTECTED]
 Betreff: Re: AW: AW: AW: xsp-element equivalent to xsl:param?
 
 
 I think that the request parameter is returning a string and the format
 object is expecting a Date object. (I should have recognised this
 earlier).
 I think the XSP page is throwing an exception which we have been
 ignoring. Try the following code and then check the sitemap.log and
 errors.log (can't remember which one) file in /WEB-INF/logs/ for the
 exception. You can do a find in the log file for XSP date error to
 locate the error.
 If there is an error being thrown, then you are going to have to change
 the request parameter value into a valid java.util.Date object.
 
 ...
 dataset
xsp:logic
   String timeOfDay = ;
   try{
  timeOfDay = (new
 SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
   }catch(Exception e){
 getLogger().error(XSP date error: , e);
 }
/xsp:logic

 
 On Fri, 2003-01-31 at 17:13, Scherler, Thorsten wrote:
  Thanks,
  
  but now I am not getting any results because is always timeOfDay = .
  
  I will look into using esql:parameter tags.
  
  Thanks for your patience.
  
  -Ursprüngliche Nachricht-
  Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
  Gesendet: Freitag, 31. Januar 2003 16:07
  An: [EMAIL PROTECTED]
  Betreff: Re: AW: AW: xsp-element equivalent to xsl:param?
  
  
  Try this
  
  ...
  dataset
 xsp:logic
String timeOfDay = ;
try{
   timeOfDay = (new
  SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
}catch(Exception e){}
 /xsp:logic
 
  esql:connection
  esql:poolIDC2_int/esql:pool
  esql:execute-query
  esql:query
  select * from info_bericht  where country ='xsp-request:get-parameter
  name=GETcountry/'   AND  Info_datum =
  #xsp:exprtimeOfDay/xsp:expr#
  /esql:query
  
  I will mention again that you should look into using esql:parameter
  tags.
  
  Andrew
  
  On Fri, 2003-01-31 at 16:46, Scherler, Thorsten wrote:
   Hello Andrew,
   
   my final xsp should look like this:
   ...
   dataset
 xsp:logic
try{
String timeOfDay = (new
   SimpleDateFormat(MM/dd/)).format(request.getParameter(date));
   }catch(Exception e){}
/xsp:logic
   esql:connection
   esql:poolIDC2_int/esql:pool
   esql:execute-query
   esql:query
select * from info_bericht  where country ='xsp-request:get-parameter 
name=GETcountry/'   AND  Info_datum = #xsp:exprtimeOfDay/xsp:expr#
/esql:query
   ...
   
   like I stated before, as soon I get rid off the logic my query is successful.
   
   Like you told me before my method now starts after the first xml element:
   
   snip from 

Re: AW: AW: AW: AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Andrew Timberlake
On Fri, 2003-01-31 at 17:59, Scherler, Thorsten wrote:
 Yes, I am doing that right now.
 
 But the people using the app that I am writing don't want type 01/30/2003 to get the 
reports.
 The main reason is that the company that I am working for is in Germany. So the user 
wants to put 30.01.2003 in the form.
 
 If I parse that into the esql I can't get any data out of db.
 
 I thought about client-side JavaScript to transform the date and then parse it, but 
I hoped that I could transform it on the server side with xsp.
 
 You said something about: simply invert the process on the SimpleDateFormat object. 
 
 How would I do that?
I think what you are trying to do is the following:
Date myDate = (new
SimpleDateFormat(dd.MM.).parse(request.getParameter(date));
String dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
That will receive the date in format 30.01.2003 and convert it to
01/30/2003

I'm not sure if you've understood the esql:parameter concept fully.
Using the esql parameter will result in java code that looks something
like the following:

...
PreparedStatement statement = conn.prepareStatement(select * from table
where datecolumn = ?);
statement.setDate(1, myDate);
...

When using code like this, you don't have to worry about the format the
database engine uses, you only have to worry about the format the user
uses and parse that into a Date object.

I do realise that I may not always understand exactly what you are
asking so please keep asking until we fully understand each other.

-- 
Andrew Timberlake [EMAIL PROTECTED]


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




mapping to basepath in static content

2003-01-31 Thread Robert Sösemann
Hello,

what I need is a centralized mechanism to change the paths in all my
site-elements. (that means: Later when I switsch from development to
production I just want to change pathname at one single point, not every
single href, src ...)

Inside elements handled by cocoon (XSP, Generators, Action) thats no
problem, because they know their own context. Things I later add in my
Transformers are also no problem. I use xsl:include to set a variable in
very other xsl.

BUT: I also use static html or xhtml pages. How can change path attributes
an even javascript command in a similar centralized way?

Who can help? Maybe I am on a totally wrong way.

Rob



-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: How can the result of a pipeline be a parameter for a transformation in another pipeline?

2003-01-31 Thread Cyril Vidal
Hello Christian,

First, thanks for your help!
I think I've done what you told me concerning the input module. And in fact,
I've just changed the  value of the parameter 'locale', given the
successfull pattern using localeAction:

 localeAction ***
map:pipeline

map:act type=locale

map:match pattern=localeAction

map:generate src=documents/participants.xml/

map:transform src=stylesheets/participantsINT.xsl

map:parameter name=use-request-parameters value=true/

/map:transform

map:transform type=i18n

map:parameter name=locale value={../locale}/

/map:transform

map:serialize type=html/

/map:match

/map:act



*input module *


map:match pattern=inputModule

map:generate src=documents/participants.xml/

map:transform src=stylesheets/participantsINT.xsl

map:parameter name=use-request-parameters value=true/

/map:transform

map:transform type=i18n

map:parameter name=locale value={request-header:accept-language}/

/map:transform

map:serialize type=html/

/map:match

/map:pipeline

but unfortunately, I receive the following error message, that I didn't have
with the preceding localAction:

type fatal

message Unable to locate resource: messages

description org.apache.cocoon.ProcessingException: Unable to locate
resource: messages:
org.apache.avalon.framework.component.ComponentException: Unable to locate
resource: messages

sender org.apache.cocoon.servlet.CocoonServlet

source Cocoon servlet

stack-trace

Is it normal?

Thanks again for your help,

Regards,

Cyril.

- Original Message -
From: Christian Haul [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, January 31, 2003 4:23 PM
Subject: Re: How can the result of a pipeline be a parameter for a
transformation in another pipeline?


 On 31.Jan.2003 -- 04:07 PM, Cyril Vidal wrote:
  Hello,
 
  I would like to retrieve the language of the user's browser, so that I
could
  call the I18n Trasnformer in the right way (by passing the locales's
value
  equal to the browser's language).
 
  To retrieve the language set up in the browser, I've used the Request
  Generator, and applied the following simple stylesheet to it:

 Starting with version 2.0.4 you could try
 {request-header:accept-language} for that. See input modules in
 concepts and javadocs.

 Chris.
 --
 C h r i s t i a n   H a u l
 [EMAIL PROTECTED]
 fingerprint: 99B0 1D9D 7919 644A 4837  7D73 FEF9 6856 335A 9E08

 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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





-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




cocoon portability

2003-01-31 Thread Tellis George
Hi,

How easy is it to configure cocoon to work with other app servers such as 
weblogic, jetty, sun one etc...?

Basically after I gave them a presentation, my management is keen on cocoon 
but they insist that I show them that there is a way to transition smoothly 
to  alternatives to tomcat if required.

Also they want to know how much of the effort of setting up a cocoon can be 
reused if we decide not to go with cocoon. I suppose the business logic can 
be reused and possible the stylesheets but I am not sure.

Any advise will be great !!

Regards
Tellis




_
It's fast, it's easy and it's free. Get MSN Messenger today! 
http://messenger.msn.co.uk


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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



AW: AW: AW: AW: AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
Hello again,

I have shorten the xsp:
xsp:page language=java xmlns:xsp=http://apache.org/xsp; 
xmlns:esql=http://apache.org/cocoon/SQL/v2; 
xmlns:xsp-request=http://apache.org/xsp/request/2.0;
dataset
xsp:logic
Date myDate = ;
try{
myDate = (new
SimpleDateFormat(dd.MM.).parse(request.getParameter(date));
String dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
  }catch(Exception e){
getLogger().error(XSP date error: , e);
}
/xsp:logic
test
xsp:exprmyDate /xsp:expr
/test
/dataset
/xsp:page

error (cocoon):
description org.apache.cocoon.ProcessingException: Language Exception: 
org.apache.cocoon.components.language.LanguageException: Error compiling 
IDC2_info_int_xsp: Line 289, column 66: ')' expected Line 286, column -1: incompatible 
types Line 0, column 0: 2 errors 

IDC2_info_int_xsp.java:
snip/
this.characters(\n\t\t);
string myDate = ;
try{
myDate = (new
SimpleDateFormat(dd.MM.).parse(request.getParameter(date));
  }catch(Exception e){
getLogger().error(XSP date error: , e);
}

The Line 289, column 66 is (*): parse(request.getParameter(date)(*))

The sitemap.log and error.log don't have the XSP date error.


-Ursprüngliche Nachricht-
Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
Gesendet: Freitag, 31. Januar 2003 17:08
An: [EMAIL PROTECTED]
Betreff: Re: AW: AW: AW: AW: AW: xsp-element equivalent to xsl:param?


On Fri, 2003-01-31 at 17:59, Scherler, Thorsten wrote:
 Yes, I am doing that right now.
 
 But the people using the app that I am writing don't want type 01/30/2003 to get the 
reports.
 The main reason is that the company that I am working for is in Germany. So the user 
wants to put 30.01.2003 in the form.
 
 If I parse that into the esql I can't get any data out of db.
 
 I thought about client-side JavaScript to transform the date and then parse it, but 
I hoped that I could transform it on the server side with xsp.
 
 You said something about: simply invert the process on the SimpleDateFormat object. 
 
 How would I do that?
I think what you are trying to do is the following:
Date myDate = (new
SimpleDateFormat(dd.MM.).parse(request.getParameter(date));
String dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
That will receive the date in format 30.01.2003 and convert it to
01/30/2003

I'm not sure if you've understood the esql:parameter concept fully.
Using the esql parameter will result in java code that looks something
like the following:

...
PreparedStatement statement = conn.prepareStatement(select * from table
where datecolumn = ?);
statement.setDate(1, myDate);
...

When using code like this, you don't have to worry about the format the
database engine uses, you only have to worry about the format the user
uses and parse that into a Date object.

I do realise that I may not always understand exactly what you are
asking so please keep asking until we fully understand each other.

-- 
Andrew Timberlake [EMAIL PROTECTED]


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




RE: Question on generators...

2003-01-31 Thread SriKumar Kareti

Thank you Lionel, I will try it out.

-Original Message-
From: Lionel Crine [mailto:[EMAIL PROTECTED]]
Sent: Friday, January 31, 2003 9:42 AM
To: [EMAIL PROTECTED]
Subject: Re: Question on generators...


Yes you can do a generator :

Here is what I did, this is a main structure :



import your_package;


public class your_class extends ComposerGenerator (or
absctractGenerator)
{
...

 public void setup(SourceResolver resolver, Map objectModel, String 
src, Parameters par)
 throws ProcessingException, SAXException, IOException
 {
 super.setup(resolver, objectModel, src, par);
}

 public void recycle()
 {
}

 public void generate() throws SAXException, IOException, 
ProcessingException
 {
/*  to generate sax events  */
}

for exemple:
 public void your_method throws IOException, SAXException, 
ProcessingException
 {
}


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




RE: cocoon portability

2003-01-31 Thread Hunsberger, Peter
 Also they want to know how much of the effort of setting up a cocoon can
be 
 reused if we decide not to go with cocoon. I suppose the business logic
can 
 be reused and possible the stylesheets but I am not sure.

If you stay away from XSP then much of what you do can be reused.  If you're
careful all your XSLT are portable.  Similarly, Cocoon is a big servlet: if
you're careful (extend a common base class that of your own) actions and
generators can be maybe 80% reusable, though you'll have to write a lot of
code to move them anywhere:  Basically, you'd have to implement your own
servlet that probably made hard coded assumptions about resource names. It
would call your generators to pass the output on to an XML transform.  From
there you'd call your actions, again with a bunch of stuff hard coded. I
can't imagine actually wanting to ever do this, but much of our code has
been written with this possibility in mind.  Now that Cocoon is more
accepted here this requirement may go away for us in the future :-)


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: AW: AW: AW: AW: AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Andrew Timberlake
On Fri, 2003-01-31 at 18:37, Scherler, Thorsten wrote:
 Hello again,
 
 I have shorten the xsp:
 xsp:page language=java xmlns:xsp=http://apache.org/xsp; 
xmlns:esql=http://apache.org/cocoon/SQL/v2; 
xmlns:xsp-request=http://apache.org/xsp/request/2.0;
 dataset
 xsp:logic
 Date myDate = ;
 try{
 myDate = (new
 SimpleDateFormat(dd.MM.)).parse(request.getParameter(date));
 ---^
You had a missing ')'

 String dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
   }catch(Exception e){
 getLogger().error(XSP date error: , e);
 }
 /xsp:logic
 test
 xsp:exprmyDate /xsp:expr
 /test
 /dataset
 /xsp:page
 

-- 
Andrew Timberlake [EMAIL PROTECTED]


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




RE: Cocoon use worldwide

2003-01-31 Thread Jeff Ramsdale
Well, Seattle is a LONG way from D.C.--about 4-5 days' drive each way, for
those who aren't familiar with the scale of the North American continent. I
was in D.C. over Christmas, though--too bad I hadn't asked my question yet!
Would love to see a CHUG if only to raise the prominence of Cocoon on this
side of the pond.

I participate in the Seattle Java Users Group (SeaJUG--www.seajug.org), and
Cocoon has come up in discussion a number of times lately--there's
definately awareness of it. The XML-SIG for the group is especially
interested, of course.

Jeff

 -Original Message-
 From: Geoff Howard [mailto:[EMAIL PROTECTED]]
 Sent: Friday, January 31, 2003 6:17 AM
 To: [EMAIL PROTECTED]
 Subject: RE: Cocoon use worldwide


 I've been working with Cocoon for a little over a year now (in the
 US) and have certainly have had that feeling.  There have been some
 really good points so far which I won't recapitulate.  I'll just
 add a couple of tidbits:

 - I have been looking for Cocoon related jobs in the US and haven't
 found a single one (yet).
 - There haven't been (yet) any big name companies adopting cocoon
 publicly - this would help.
 - I have made some wrong assumptions based on names, and other cues
 (how well they seem to know the people who I _know_ live in Europe)
 only to find they are in the States.
 - I think the books have helped visibility here - I've
 noticed more name recognition recently when I mention Cocoon.
 - I think some here will take a wait and see attitude to see if Cocoon
 will jump the pond.
 - We need some Cocoon users groups in the US.  I'm in DC and know
 there's at
 least 5-10 regulars on the list from here.  (maybe I'll meet them at John
 Callahan's shpiel).

 Anyone in DC up for a C.H.U.G.? (Cocoon Hackers  Users Group)

 Geoff

snip



-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




RE: cocoon portability

2003-01-31 Thread Schaper, Christoph
About the app servers.
Have experience with two different ones:
1) JBoss: No problem, runs out of the box.
2) Weblogic: Quite straightforward in general (it becomes a lot easier if
you deploy exploded), but there are some issues with some specific
features (eg the JSPGenerator)

Christoph

-Original Message-
From: Tellis George [mailto:[EMAIL PROTECTED]]
Sent: 31 January 2003 17:30
To: [EMAIL PROTECTED]
Subject: cocoon portability


Hi,

How easy is it to configure cocoon to work with other app servers such as 
weblogic, jetty, sun one etc...?

Basically after I gave them a presentation, my management is keen on cocoon 
but they insist that I show them that there is a way to transition smoothly 
to  alternatives to tomcat if required.

Also they want to know how much of the effort of setting up a cocoon can be 
reused if we decide not to go with cocoon. I suppose the business logic can 
be reused and possible the stylesheets but I am not sure.

Any advise will be great !!

Regards
Tellis




_
It's fast, it's easy and it's free. Get MSN Messenger today! 
http://messenger.msn.co.uk


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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

Any e-mail message from the European Central Bank (ECB) is sent in good faith but 
shall neither be binding nor construed as constituting a commitment by the ECB except 
where provided for in a written agreement.
This e-mail is intended only for the use of the recipient(s) named above. Any 
unauthorised disclosure, use or dissemination, either in whole or in part, is 
prohibited.
If you have received this e-mail in error, please notify the sender immediately via 
e-mail and delete this e-mail from your system.


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: AW: AW: AW: AW: AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
I correct it and now:

description org.apache.cocoon.ProcessingException: Language Exception: 
org.apache.cocoon.components.language.LanguageException: Error compiling 
IDC2_info_int_xsp: Line 286, column -1: incompatible types Line 309, column 48: 
variable dateParam not found in class org.apache.cocoon.www.logic.IDC2_info_int_xsp 
Line 0, column 0: 2 errors 

the xsp:
xsp:page language=java xmlns:xsp=http://apache.org/xsp; 
xmlns:esql=http://apache.org/cocoon/SQL/v2; 
xmlns:xsp-request=http://apache.org/xsp/request/2.0;
dataset
xsp:logic
  Date myDate = ;
  try{
myDate = (new SimpleDateFormat(dd.MM.)).parse(request.getParameter(date));
String dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
  }catch(Exception e){
getLogger().error(XSP date error: , e);
}
   /xsp:logic
test
xsp:exprdateParam/xsp:expr
/test
/dataset
/xsp:page

the request: ?date=31.01.2003

-Ursprüngliche Nachricht-
Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
Gesendet: Freitag, 31. Januar 2003 17:49
An: [EMAIL PROTECTED]
Betreff: Re: AW: AW: AW: AW: AW: AW: xsp-element equivalent to
xsl:param?


On Fri, 2003-01-31 at 18:37, Scherler, Thorsten wrote:
 Hello again,
 
 I have shorten the xsp:
 xsp:page language=java xmlns:xsp=http://apache.org/xsp; 
xmlns:esql=http://apache.org/cocoon/SQL/v2; 
xmlns:xsp-request=http://apache.org/xsp/request/2.0;
 dataset
 xsp:logic
 Date myDate = ;
 try{
 myDate = (new
 SimpleDateFormat(dd.MM.)).parse(request.getParameter(date));
 ---^
You had a missing ')'

 String dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
   }catch(Exception e){
 getLogger().error(XSP date error: , e);
 }
 /xsp:logic
 test
 xsp:exprmyDate /xsp:expr
 /test
 /dataset
 /xsp:page
 

-- 
Andrew Timberlake [EMAIL PROTECTED]


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: AW: AW: AW: AW: AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Andres, Judith
Hi Thorsten,

you define the variable dateParam inside a try/catch-block. When you reference to it 
outside of this block you're out of scope.

try:
xsp:page language=java xmlns:xsp=http://apache.org/xsp; 
xmlns:esql=http://apache.org/cocoon/SQL/v2; 
xmlns:xsp-request=http://apache.org/xsp/request/2.0;
dataset
xsp:logic
  Date myDate = ;
  String dateParam = null;

  try{
myDate = (new 
SimpleDateFormat(dd.MM.)).parse(request.getParameter(date));
   dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
  } catch(Exception e){
getLogger().error(XSP date error: , e);
  }
   /xsp:logic
test
xsp:exprdateParam/xsp:expr
/test
/dataset
/xsp:page

Bye
Judith

 -Ursprüngliche Nachricht-
 Von:  Scherler, Thorsten [SMTP:[EMAIL PROTECTED]]
 Gesendet am:  Freitag, 31. Januar 2003 18:01
 An:   [EMAIL PROTECTED]
 Betreff:  AW: AW: AW: AW: AW: AW: AW: xsp-element equivalent to xsl:param?
 
 I correct it and now:
 
 description org.apache.cocoon.ProcessingException: Language Exception: 
org.apache.cocoon.components.language.LanguageException: Error compiling 
IDC2_info_int_xsp: Line 286, column -1: incompatible types Line 309, column 48: 
variable dateParam not found in class org.apache.cocoon.www.logic.IDC2_info_int_xsp 
Line 0, column 0: 2 errors 
 
 the xsp:
 xsp:page language=java xmlns:xsp=http://apache.org/xsp; 
xmlns:esql=http://apache.org/cocoon/SQL/v2; 
xmlns:xsp-request=http://apache.org/xsp/request/2.0;
   dataset
   xsp:logic
   Date myDate = ;
   try{
 myDate = (new SimpleDateFormat(dd.MM.)).parse(request.getParameter(date));
 String dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
   }catch(Exception e){
 getLogger().error(XSP date error: , e);
 }
/xsp:logic
   test
   xsp:exprdateParam/xsp:expr
   /test
   /dataset
 /xsp:page
 
 the request: ?date=31.01.2003
 
 -Ursprüngliche Nachricht-
 Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 17:49
 An: [EMAIL PROTECTED]
 Betreff: Re: AW: AW: AW: AW: AW: AW: xsp-element equivalent to
 xsl:param?
 
 
 On Fri, 2003-01-31 at 18:37, Scherler, Thorsten wrote:
  Hello again,
  
  I have shorten the xsp:
  xsp:page language=java xmlns:xsp=http://apache.org/xsp; 
xmlns:esql=http://apache.org/cocoon/SQL/v2; 
xmlns:xsp-request=http://apache.org/xsp/request/2.0;
  dataset
  xsp:logic
  Date myDate = ;
  try{
  myDate = (new
  SimpleDateFormat(dd.MM.)).parse(request.getParameter(date));
  ---^
 You had a missing ')'
 
  String dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
}catch(Exception e){
  getLogger().error(XSP date error: , e);
  }
  /xsp:logic
  test
  xsp:exprmyDate /xsp:expr
  /test
  /dataset
  /xsp:page
  
 
 -- 
 Andrew Timberlake [EMAIL PROTECTED]
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
 

-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: AW: AW: AW: AW: AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
I tried:
xsp:page language=java xmlns:xsp=http://apache.org/xsp; 
xmlns:esql=http://apache.org/cocoon/SQL/v2; 
xmlns:xsp-request=http://apache.org/xsp/request/2.0;
dataset
xsp:logic
  Date myDate = ;
  String dateParam = null;

  try{
myDate = (new 
SimpleDateFormat(dd.MM.)).parse(request.getParameter(date));
   dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
  } catch(Exception e){
getLogger().error(XSP date error: , e);
  }
   /xsp:logic
test
xsp:exprdateParam/xsp:expr
/test
/dataset
/xsp:page

error:
description org.apache.cocoon.ProcessingException: Language Exception: 
org.apache.cocoon.components.language.LanguageException: Error compiling 
IDC2_info_int_xsp: Line 286, column -1: incompatible types Line 0, column 0: 1 error 


  IDC2_info_int_xsp.java: 
this.characters(\n\t\t\t);
  
  Date myDate = ;
  String dateParam = null;
  try{
myDate = (new 
SimpleDateFormat(dd.MM.)).parse(request.getParameter(date));
   dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
  } catch(Exception e){
getLogger().error(XSP date error: , e);
  }
   
this.characters(\n\t\t\t);
  



Bye
Judith

 -Ursprüngliche Nachricht-
 Von:  Scherler, Thorsten [SMTP:[EMAIL PROTECTED]]
 Gesendet am:  Freitag, 31. Januar 2003 18:01
 An:   [EMAIL PROTECTED]
 Betreff:  AW: AW: AW: AW: AW: AW: AW: xsp-element equivalent to xsl:param?
 
 I correct it and now:
 
 description org.apache.cocoon.ProcessingException: Language Exception: 
org.apache.cocoon.components.language.LanguageException: Error compiling 
IDC2_info_int_xsp: Line 286, column -1: incompatible types Line 309, column 48: 
variable dateParam not found in class org.apache.cocoon.www.logic.IDC2_info_int_xsp 
Line 0, column 0: 2 errors 
 
 the xsp:
 xsp:page language=java xmlns:xsp=http://apache.org/xsp; 
xmlns:esql=http://apache.org/cocoon/SQL/v2; 
xmlns:xsp-request=http://apache.org/xsp/request/2.0;
   dataset
   xsp:logic
   Date myDate = ;
   try{
 myDate = (new SimpleDateFormat(dd.MM.)).parse(request.getParameter(date));
 String dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
   }catch(Exception e){
 getLogger().error(XSP date error: , e);
 }
/xsp:logic
   test
   xsp:exprdateParam/xsp:expr
   /test
   /dataset
 /xsp:page
 
 the request: ?date=31.01.2003
 
 -Ursprüngliche Nachricht-
 Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 17:49
 An: [EMAIL PROTECTED]
 Betreff: Re: AW: AW: AW: AW: AW: AW: xsp-element equivalent to
 xsl:param?
 
 
 On Fri, 2003-01-31 at 18:37, Scherler, Thorsten wrote:
  Hello again,
  
  I have shorten the xsp:
  xsp:page language=java xmlns:xsp=http://apache.org/xsp; 
xmlns:esql=http://apache.org/cocoon/SQL/v2; 
xmlns:xsp-request=http://apache.org/xsp/request/2.0;
  dataset
  xsp:logic
  Date myDate = ;
  try{
  myDate = (new
  SimpleDateFormat(dd.MM.)).parse(request.getParameter(date));
  ---^
 You had a missing ')'
 
  String dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
}catch(Exception e){
  getLogger().error(XSP date error: , e);
  }
  /xsp:logic
  test
  xsp:exprmyDate /xsp:expr
  /test
  /dataset
  /xsp:page
  
 
 -- 
 Andrew Timberlake [EMAIL PROTECTED]
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
 

-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: AW: AW: AW: AW: AW: AW: xsp-element equivalent to xsl:param?

2003-01-31 Thread Scherler, Thorsten
Last Mail before I stop work:

If I modify the code of Judith like that:
...
 Date myDate = null;
...

instead of Date myDate = ;

I do not get an error now, but neither the date.

So thanks everybody for your help.

I will finish up after 14hours without solving the problem.

King regards
-Ursprüngliche Nachricht-
Von: Scherler, Thorsten 
Gesendet: Freitag, 31. Januar 2003 18:11
An: [EMAIL PROTECTED]
Betreff: AW: AW: AW: AW: AW: AW: AW: xsp-element equivalent to
xsl:param?


I tried:
xsp:page language=java xmlns:xsp=http://apache.org/xsp; 
xmlns:esql=http://apache.org/cocoon/SQL/v2; 
xmlns:xsp-request=http://apache.org/xsp/request/2.0;
dataset
xsp:logic
  Date myDate = ;
  String dateParam = null;

  try{
myDate = (new 
SimpleDateFormat(dd.MM.)).parse(request.getParameter(date));
   dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
  } catch(Exception e){
getLogger().error(XSP date error: , e);
  }
   /xsp:logic
test
xsp:exprdateParam/xsp:expr
/test
/dataset
/xsp:page

error:
description org.apache.cocoon.ProcessingException: Language Exception: 
org.apache.cocoon.components.language.LanguageException: Error compiling 
IDC2_info_int_xsp: Line 286, column -1: incompatible types Line 0, column 0: 1 error 


  IDC2_info_int_xsp.java: 
this.characters(\n\t\t\t);
  
  Date myDate = ;
  String dateParam = null;
  try{
myDate = (new 
SimpleDateFormat(dd.MM.)).parse(request.getParameter(date));
   dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
  } catch(Exception e){
getLogger().error(XSP date error: , e);
  }
   
this.characters(\n\t\t\t);
  



Bye
Judith

 -Ursprüngliche Nachricht-
 Von:  Scherler, Thorsten [SMTP:[EMAIL PROTECTED]]
 Gesendet am:  Freitag, 31. Januar 2003 18:01
 An:   [EMAIL PROTECTED]
 Betreff:  AW: AW: AW: AW: AW: AW: AW: xsp-element equivalent to xsl:param?
 
 I correct it and now:
 
 description org.apache.cocoon.ProcessingException: Language Exception: 
org.apache.cocoon.components.language.LanguageException: Error compiling 
IDC2_info_int_xsp: Line 286, column -1: incompatible types Line 309, column 48: 
variable dateParam not found in class org.apache.cocoon.www.logic.IDC2_info_int_xsp 
Line 0, column 0: 2 errors 
 
 the xsp:
 xsp:page language=java xmlns:xsp=http://apache.org/xsp; 
xmlns:esql=http://apache.org/cocoon/SQL/v2; 
xmlns:xsp-request=http://apache.org/xsp/request/2.0;
   dataset
   xsp:logic
   Date myDate = ;
   try{
 myDate = (new SimpleDateFormat(dd.MM.)).parse(request.getParameter(date));
 String dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
   }catch(Exception e){
 getLogger().error(XSP date error: , e);
 }
/xsp:logic
   test
   xsp:exprdateParam/xsp:expr
   /test
   /dataset
 /xsp:page
 
 the request: ?date=31.01.2003
 
 -Ursprüngliche Nachricht-
 Von: Andrew Timberlake [mailto:[EMAIL PROTECTED]]
 Gesendet: Freitag, 31. Januar 2003 17:49
 An: [EMAIL PROTECTED]
 Betreff: Re: AW: AW: AW: AW: AW: AW: xsp-element equivalent to
 xsl:param?
 
 
 On Fri, 2003-01-31 at 18:37, Scherler, Thorsten wrote:
  Hello again,
  
  I have shorten the xsp:
  xsp:page language=java xmlns:xsp=http://apache.org/xsp; 
xmlns:esql=http://apache.org/cocoon/SQL/v2; 
xmlns:xsp-request=http://apache.org/xsp/request/2.0;
  dataset
  xsp:logic
  Date myDate = ;
  try{
  myDate = (new
  SimpleDateFormat(dd.MM.)).parse(request.getParameter(date));
  ---^
 You had a missing ')'
 
  String dateParam = (new SimpleDateFormat(MM/dd/)).format(myDate);
}catch(Exception e){
  getLogger().error(XSP date error: , e);
  }
  /xsp:logic
  test
  xsp:exprmyDate /xsp:expr
  /test
  /dataset
  /xsp:page
  
 
 -- 
 Andrew Timberlake [EMAIL PROTECTED]
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
 

-
Please check that your question  has not already been 

AW: Apache error on startup

2003-01-31 Thread Marco Rolappe
hi richard,

I think this is a path issue. see below:

 -Ursprüngliche Nachricht-
 Von: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]]Im
 Auftrag von Richard Cunliffe
 Gesendet: Donnerstag, 30. Januar 2003 11:34
 An: [EMAIL PROTECTED]
 Betreff: RE: Apache error on startup


 Hussayn,

 I have read that the mod_jk.so is for Unix and mod_jk.dll is for
 windows. I am running windows, and I have the following line already in
 my auto mod_jk:

 IfModule !mod_jk.c

   LoadModule jk_module c:/Program Files/Apache
Group/Apache2/modules/mod_jk.dll
^^^

I guess this line makes it 3 arguments because of the space. maybe try
quoting it:

   LoadModule jk_module c:/Program Files/Apache
Group/Apache2/modules/mod_jk.dll

or maybe use a relative path:

   LoadModule jk_module modules/mod_jk.dll


 /IfModule


 Is there anything that could wrong?

 Richard.




 -Original Message-
 From: SAXESS - Hussayn Dabbous [mailto:[EMAIL PROTECTED]]
 Sent: 30 January 2003 10:12
 To: [EMAIL PROTECTED]
 Subject: Re: Apache error on startup

 The error message says, you are missing one parameter.
 Check, that on your line 4 you have the following
 content. If you have, check that you are looking at
 the right file ;-)


 LoadModule jk_module  modules/mod_jk.so




 regards, hussayn


 Richard Cunliffe wrote:
  Hi,
 
  I have installed Apache 2.0.43 and tomcat 4.0.6, using mod_jk 2.0.43.
 I
  am following the flash guide produced by Lajos.
 
  I am getting the following error after I have started tomcat and then
  try and start Apache:
 
 
  Sntax error on line 4 of c:/tomcat/conf/auto/mod_jk.conf:
  LoadModule takes two arguments, a module name and the name of a shared
  object file to load it from
 
 
  How should I go about fixing this?
 
 
  Thanks,
 
 
  Richard.
 
 
 
 
 
 
 
  -Original Message-
  From: SAXESS - Hussayn Dabbous [mailto:[EMAIL PROTECTED]]
  Sent: 29 January 2003 21:53
  To: [EMAIL PROTECTED]
  Subject: Re: WARP, Jserv or mod_jk?
 
  just one tip.
 
  As far as i see, you dont need to build the java components for mod_jk
  if
  you are planning to run a binary distribution of tomcat-4.*.*.
  The java components are already included in these tomcat
 distributions.
  You would only have to build the apache mod_jk module ...
  Therefor you may simply skip all the java and ant related topics...
 
  maybe that helps you getting faster to your goal.
 
  regards, hussayn
 
  Richard Cunliffe wrote:
 
 
 Lajos,
 
 I have reached point 6, where you build ant, but it is coming up with
 the following error:
 
 Warning: JAVA_HOME environment variable not set.
 If build fails because sun.* classes could not not be
 found
 You will need to set the JAVA_HOME environment
 
  variable
 
 To the installation directory of java.
 
 Bulidfile: build.xml does not exist!
 Build failed
 
 So,
 1. How do you set the JAVA_HOME?
 (I have java 1.3 installed)
 
 2. I checked if build.xml exsits and it does. Is it not
 
  finding
 
 it
 because it cant find the JAVA_HOME?
 
 Thanks,
 
 Richard
 
 -Original Message-
 From: Lajos [mailto:[EMAIL PROTECTED]]
 Sent: 29 January 2003 15:17
 To: [EMAIL PROTECTED]
 Subject: Re: WARP, Jserv or mod_jk?
 
 Is that a link off my guide? Sorry, if it is - I have to update the
 
  damn
 
 things every couple of weeks 'cause they change so often. Anyhow, if
 
  you
 
 are using 4.0.6, you need the attached zip file. But you can also
 
  check
 
 for binaries at
 
 
 
 http://jakarta.apache.org/builds/jakarta-tomcat-connectors/jk/release/v1
 
 .2.2/bin/
 and save yourself some time.
 
 Regards,
 
 Lajos
 
 Richard Cunliffe wrote:
 
 Lajos,
 
 The following link is not working
 
 
 
 http://jakarta.apache.org/builds/jakarta-tomcat-4.0/release/v4.0.3/src/j
 
 akarta-tomcat-connectors-4.0.2-01-src.zip.
 
 If you have the zip file could you e-mail it to me at
 [EMAIL PROTECTED]
 
 Thanks for the advice
 
 Richard.
 
 
 
 
 -Original Message-
 From: Lajos [mailto:[EMAIL PROTECTED]]
 Sent: 29 January 2003 14:46
 To: [EMAIL PROTECTED]
 Subject: Re: WARP, Jserv or mod_jk?
 
 Hi Richard -
 
 mod_jk by far is the best. WARP is buggy and is may not even be
 
 actively
 
 developed any more. mod_jk is stable, widely used, and generally has
 
 few
 
 bugs reported. If you need help with the integration, my FlashGuides
 (www.galatea.com/flashguides) have instructions on connecting Apache
 
 2.x
 
 with Tomcat 4.x using Jk.
 
 Regards,
 
 Lajos
 
 
 Richard Cunliffe wrote:
 
 
 Hi,
 
 
 
 I?m upgrading! Can anyone suggest the best way to connect Apache
 
 2.0.42
 
 
 and Tomcat 4.0.6. I will be using Cocoon 2.0.4. I have read that the
 WARP connecter is the best, but I used Jserv on my older version.
 
 There
 
 
 is also the mod_jk. Which is the most reliable etc.
 
 
 
 
 
 Thanks
 
 
 
 Richard.
 
 
 --
 This message has 

AW: How can the result of a pipeline be a parameter for a transformation in another pipeline?

2003-01-31 Thread Marco Rolappe
maybe your user agent has several languages set in Accept-Language and maybe
the input module uses these (LocalAction using first encountered).

 -Ursprüngliche Nachricht-
 Von: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]]Im
 Auftrag von Cyril Vidal
 Gesendet: Freitag, 31. Januar 2003 17:27
 An: [EMAIL PROTECTED]; [EMAIL PROTECTED]
 Betreff: Re: How can the result of a pipeline be a parameter for a
 transformation in another pipeline?


 Hello Christian,

 First, thanks for your help!
 I think I've done what you told me concerning the input module.
 And in fact,
 I've just changed the  value of the parameter 'locale', given the
 successfull pattern using localeAction:

  localeAction ***
 map:pipeline

 map:act type=locale

 map:match pattern=localeAction

 map:generate src=documents/participants.xml/

 map:transform src=stylesheets/participantsINT.xsl

 map:parameter name=use-request-parameters value=true/

 /map:transform

 map:transform type=i18n

 map:parameter name=locale value={../locale}/

 /map:transform

 map:serialize type=html/

 /map:match

 /map:act



 *input module *


 map:match pattern=inputModule

 map:generate src=documents/participants.xml/

 map:transform src=stylesheets/participantsINT.xsl

 map:parameter name=use-request-parameters value=true/

 /map:transform

 map:transform type=i18n

 map:parameter name=locale value={request-header:accept-language}/

 /map:transform

 map:serialize type=html/

 /map:match

 /map:pipeline

 but unfortunately, I receive the following error message, that I
 didn't have
 with the preceding localAction:

 type fatal

 message Unable to locate resource: messages

 description org.apache.cocoon.ProcessingException: Unable to locate
 resource: messages:
 org.apache.avalon.framework.component.ComponentException: Unable to locate
 resource: messages

 sender org.apache.cocoon.servlet.CocoonServlet

 source Cocoon servlet

 stack-trace

 Is it normal?

 Thanks again for your help,

 Regards,

 Cyril.

 - Original Message -
 From: Christian Haul [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Friday, January 31, 2003 4:23 PM
 Subject: Re: How can the result of a pipeline be a parameter for a
 transformation in another pipeline?


  On 31.Jan.2003 -- 04:07 PM, Cyril Vidal wrote:
   Hello,
  
   I would like to retrieve the language of the user's browser, so that I
 could
   call the I18n Trasnformer in the right way (by passing the locales's
 value
   equal to the browser's language).
  
   To retrieve the language set up in the browser, I've used the Request
   Generator, and applied the following simple stylesheet to it:
 
  Starting with version 2.0.4 you could try
  {request-header:accept-language} for that. See input modules in
  concepts and javadocs.
 
  Chris.
  --
  C h r i s t i a n   H a u l
  [EMAIL PROTECTED]
  fingerprint: 99B0 1D9D 7919 644A 4837  7D73 FEF9 6856 335A 9E08
 
  -
  Please check that your question  has not already been answered in the
  FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail:   [EMAIL PROTECTED]
 
 



 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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



-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




DC CHUG (WAS RE: Cocoon use worldwide)

2003-01-31 Thread Geoff Howard
I'll be there with bells on (unless it's cold - then I'll dress warmer).

I've had a few others write off list with some interest, and an idea to
arrange a presentation at the NOVA JUG in Reston at some point.  If you're
interested, let me know on/off list.  No schedule yet - we'll just consider
the presentation on Feb. 19th our kick-off.

Geoff

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
 Sent: Friday, January 31, 2003 12:20 PM
 To: [EMAIL PROTECTED]
 Subject: Re: Cocoon use worldwide


 Geoff,

 I'm game for a DC CHUG.  I already partipate in the DC SGML/XML UG and
 the Baltimore HJUG, but my S.O. won't mind another night per month.
 Right? :-)

 Let's talk on Wed. Feb 19th at the DC SGML/XML UG meeting (at the AGU
 Bldg. on Florida and Connecticut Aves. NW north of Dupont Circle).
 February's meeting is also a joint meeting with the DC Linux UG.

 -- jack

 John R. Callahan
 Sphere Software Corporation - The Intelligence of XML
 [EMAIL PROTECTED]

 
  Anyone in DC up for a C.H.U.G.? (Cocoon Hackers  Users Group)
 
  Geoff
 

 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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





-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




RE: cocoon portability

2003-01-31 Thread Geoff Howard
Jetty now ships with 2.1, so it works there.  Cocoon is just a webapp, so if
you
mean portability to other containers, there should only be isolated issues.
If you
mean ripping your code out of cocoon, then Peter's advice is what you need.
Of course,
if you use helper classes with your xsp's you could also reuse some logic
there.

The other issue to consider is SAX.  A lot of your code is going to be
centered around
SAX.  At the moment, I'm not aware of many other SAX pipeline webapps
involving java.
And when I say many, it's only there to keep me from being called an idiot
if I say
any.

Geoff

 -Original Message-
 From: Tellis George [mailto:[EMAIL PROTECTED]]
 Sent: Friday, January 31, 2003 11:30 AM
 To: [EMAIL PROTECTED]
 Subject: cocoon portability


 Hi,

 How easy is it to configure cocoon to work with other app servers such as
 weblogic, jetty, sun one etc...?

 Basically after I gave them a presentation, my management is keen
 on cocoon
 but they insist that I show them that there is a way to
 transition smoothly
 to  alternatives to tomcat if required.

 Also they want to know how much of the effort of setting up a
 cocoon can be
 reused if we decide not to go with cocoon. I suppose the business
 logic can
 be reused and possible the stylesheets but I am not sure.

 Any advise will be great !!

 Regards
 Tellis




 _
 It's fast, it's easy and it's free. Get MSN Messenger today!
 http://messenger.msn.co.uk


 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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





-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




RE: Question on generators...

2003-01-31 Thread Geoff Howard
This all depends on what you were doing in your class.  Were you creating
xml?  If so, DOM, SAX or String?

Geoff

 -Original Message-
 From: SriKumar Kareti [mailto:[EMAIL PROTECTED]]
 Sent: Friday, January 31, 2003 10:21 AM
 To: [EMAIL PROTECTED]
 Subject: Question on generators...



 Thanks for you help in advance...

 I am a new user to Cocoon. I have searched the site pretty well and
 could
 not answer this question. Could someone help...

 My goal is to move from current servlet based solution to Cocoon. The
 general
 flow of my current program is

 1) Take the request,
 2) Generate the XML by making calls to Database based on the parameters
passed...
 3) Use XSLT to generate html which is returned...

 Now I'd like to move to cocoon. I want to use my existing Java class
 as the generator in Cocoon.

 Can I do that?

 SriKumar.

 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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





-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: Accessing session variables in the sitemap.xmap

2003-01-31 Thread Marco Rolappe
hi heiko,

please have a look at:

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16246

this explains why the session created in an XSP is not visible later in the
pipeline (being created after pipeline setup).

you could create your session within your XSP if you override the
generator's setup() method within your XSP, creatint your session at that
point, so the session will be created at pipeline setup time.

but maybe it's easier to create the session via an action, as already
suggested.


 -Ursprüngliche Nachricht-
 Von: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]]Im
 Auftrag von Heiko Milke
 Gesendet: Donnerstag, 30. Januar 2003 16:44
 An: [EMAIL PROTECTED]
 Betreff: Re: Accessing session variables in the sitemap.xmap


 Hey Andrew,

 Thanks for all your help! But well, it still aint working :(

 I tried on several browsers. I tried in the mount directory and i
 tried from
 the main sitemap. None if it works.

 Im using cocoon version 2.0.4 (on Windows 2000).


 Heiko


 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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



-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




RE: Question on generators...

2003-01-31 Thread SriKumar Kareti

Geoff,

I was creating String...

thx...

-Original Message-
From: Geoff Howard [mailto:[EMAIL PROTECTED]]
Sent: Friday, January 31, 2003 12:28 PM
To: [EMAIL PROTECTED]
Subject: RE: Question on generators...


This all depends on what you were doing in your class.  Were you
creating
xml?  If so, DOM, SAX or String?

Geoff

 -Original Message-
 From: SriKumar Kareti [mailto:[EMAIL PROTECTED]]
 Sent: Friday, January 31, 2003 10:21 AM
 To: [EMAIL PROTECTED]
 Subject: Question on generators...



 Thanks for you help in advance...

 I am a new user to Cocoon. I have searched the site pretty well and
 could
 not answer this question. Could someone help...

 My goal is to move from current servlet based solution to Cocoon. The
 general
 flow of my current program is

 1) Take the request,
 2) Generate the XML by making calls to Database based on the
parameters
passed...
 3) Use XSLT to generate html which is returned...

 Now I'd like to move to cocoon. I want to use my existing Java class
 as the generator in Cocoon.

 Can I do that?

 SriKumar.

 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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





-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




company packaging Cocoon as part of a product

2003-01-31 Thread dfeather

Hey,
  I saw someone mention that they wondered if there were any companies
packaging cocoon as a polished product. I noticed on the cocoon wiki that
there were some guys listed as working for a place called Hippo Webworks
(http://www.hippo.nl/EN/index.html). It looks like they have built a
succesful content management system based on cocoon. I thought that was
interesting, and encouraging. After reading some of the discouraging things
that were posted this week right after my boss and his boss gave me the go
ahead to do a redesign of our production site using cocoon, this was good
to see. Thought that was interesting and thought maybe others would think
so too. Take care.

Dan Feather






-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: company packaging Cocoon as part of a product

2003-01-31 Thread dfeather

Actually... if you just go to
http://wiki.cocoondev.org/Wiki.jsp?page=People and look through that list,
there are several people that work for companies using cocoon in this same
manner and/or in production environments. Very encouraging... very cool.

Dan Feather






-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




handing an XML doc (in memory) to the sitemap

2003-01-31 Thread Ray Martin
Using the SunRise instructions found at
http://radio.weblogs.com/0103021/stories/2002/02/28/usingTheSunriseComponent
s.html

The example has a pipeline named foo-authuser
In this pipeline, i call an action named checkCredentials.  This action
accesses several tables in a database.  If a match is found, for username
and password, a vector of roles available to that user is created.  Then an
XML document is produced in the action that conforms to the Sunrise
example's authentication XML.

Now i want to hand that XML to the sitemap in place of foo-user.xml and
foo-user.xsl

Please help me.

I will be glad to share how this entire process works after i bridge this
final gap.  I will provide the action and all info how to set the database.
You would be able to modify this process to meet your data store needs.

Would anyone be so kind as to give me some assistance? please.



-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Browser Selector

2003-01-31 Thread Richard Cunliffe








Hi,



I am getting a strange result from my browser
selector. I have specified two xsl stylesheets, one for a PDA to run on AvantGo,
and another for a PC to run on Explorer. Now the expected result would be:





 PC = Welcome to soundpool. Your
are viewing this site from personal computer



 PDA = Welcome to soundpool. You
are viewing this site from a PDA







But the result I get when loading the site for both
devices is:





 Welcome to soundpool. Your are viewing this
site from personal computer Welcome to soundpool.
You are viewing this site from a PDA







Why should it want to do this?





I have configured my browser selector as follows:



map:selectors
default=browser

 map:selector
logger=sitemap.selector.browser name=browser src="">

 !-- #
NOTE: The appearance indicates the search order. This is very important since


# some words may be found in more than one
browser description. (MSIE is


# presented as Mozilla/4.0
(Compatible; MSIE 4.01; ...)

 --


browser name=explorer useragent=MSIE/


browser name=pocketexplorer useragent=MSPIE/


browser name=handweb useragent=HandHTTP/


browser name=avantgo useragent=AvantGo/


browser name=imode useragent=DoCoMo/


browser name=opera useragent=Opera/


browser name=lynx useragent=Lynx/


browser name=java useragent=Java/


browser name=wap useragent=Nokia/


browser name=wap useragent=UP/


browser name=wap useragent=Wapalizer/


browser name=mozilla5 useragent=Mozilla/5/


browser name=mozilla5 useragent=Netscape6//


browser name=netscape useragent=Mozilla/

 /map:selector



 map:select

 map:when
test=avantgo

 map:transform
src="">

 map:seralize/

 /map:when

 map:otherwise

 map:transform
src="">

 map:seralize/

 /map:otherwise

 /map:select













and my pipeline looks like this:



!--
soundpool --



map:pipeline

  map:match
pattern=soundpool/soundpool

   map:generate
src="">

  map:serialize/

  /map:match

/map:pipeline







What can you suggest?



Thanks



Richard.








Re: AW: Accessing session variables in the sitemap.xmap

2003-01-31 Thread Heiko Milke
Hello Marco,

thank you very much for your reply. It is a bit irretating that you
can't read something from the session that was set to it earlier in a
serverpage (while working on the same request) but i'll have to live
with it.

Now I wrote an action that does the talking to the session and it works
fine. The serverpages just lost some of their value for me. I was so
happy with the XMLFragment implementation of mine working out so well
but if session modifications are delayed to the next page request 

Gn8 Heiko!


Am Fre, 2003-01-31 um 20.07 schrieb Marco Rolappe:
 hi heiko,
 
 please have a look at:
 
 http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16246
 
 this explains why the session created in an XSP is not visible later in the
 pipeline (being created after pipeline setup).
 
 you could create your session within your XSP if you override the
 generator's setup() method within your XSP, creatint your session at that
 point, so the session will be created at pipeline setup time.
 
 but maybe it's easier to create the session via an action, as already
 suggested.
 
 
  -Ursprüngliche Nachricht-
  Von: [EMAIL PROTECTED]
  [mailto:[EMAIL PROTECTED]]Im
  Auftrag von Heiko Milke
  Gesendet: Donnerstag, 30. Januar 2003 16:44
  An: [EMAIL PROTECTED]
  Betreff: Re: Accessing session variables in the sitemap.xmap
 
 
  Hey Andrew,
 
  Thanks for all your help! But well, it still aint working :(
 
  I tried on several browsers. I tried in the mount directory and i
  tried from
  the main sitemap. None if it works.
 
  Im using cocoon version 2.0.4 (on Windows 2000).
 
 
  Heiko
 
 
  -
  Please check that your question  has not already been answered in the
  FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail:   [EMAIL PROTECTED]
 
 
 
 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail:   [EMAIL PROTECTED]
 


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: Browser Selector

2003-01-31 Thread Marco Rolappe
hi richard,

from what you wrote in your mail it seems you have misplaced the
map:select. those go into the pipeline definitions.

maybe it would be best if you read some introductory material on the sitemap
or have a look at samples sitemaps.

your sitemap should look something like this:

!-- soundpool --

map:pipeline
map:match pattern=soundpool/soundpool
  map:generate src=soundpool.xml/

  map:select
  map:when test=avantgo
  map:transform src=stylesheets/soundpoolpda.xsl/
  /map:when
  map:otherwise
  map:transform src=stylesheets/soundpoolpc.xsl/
  /map:otherwise
  /map:select

  map:serialize/
/map:match
/map:pipeline


-Ursprungliche Nachricht-
Von: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]Im Auftrag
von Richard Cunliffe
Gesendet: Samstag, 1. Februar 2003 01:21
An: [EMAIL PROTECTED]
Betreff: Browser Selector


Hi,

I am getting a strange result from my browser selector. I have specified two
xsl stylesheets, one for a PDA to run on AvantGo, and another for a PC to
run on Explorer. Now the expected result would be:


  PC= Welcome to soundpool. Your are viewing this site from personal
computer
  PDA   = Welcome to soundpool. You are viewing this site from a PDA


But the result I get when loading the site for both devices is:


  Welcome to soundpool. Your are viewing this site from personal computer
Welcome to soundpool. You are viewing this site from a PDA


Why should it want to do this?


I have configured my browser selector as follows:

map:selectors default=browser
   map:selector logger=sitemap.selector.browser name=browser
src=org.apache.cocoon.selection.BrowserSelector
!-- # NOTE: The appearance indicates the search order. This is very
important since
 #   some words may be found in more than one browser
description. (MSIE is
 #   presented as Mozilla/4.0 (Compatible; MSIE 4.01; ...)
--
browser name=explorer useragent=MSIE/
browser name=pocketexplorer useragent=MSPIE/
browser name=handweb useragent=HandHTTP/
browser name=avantgo useragent=AvantGo/
browser name=imode useragent=DoCoMo/
browser name=opera useragent=Opera/
browser name=lynx useragent=Lynx/
browser name=java useragent=Java/
browser name=wap useragent=Nokia/
browser name=wap useragent=UP/
browser name=wap useragent=Wapalizer/
browser name=mozilla5 useragent=Mozilla/5/
browser name=mozilla5 useragent=Netscape6//
browser name=netscape useragent=Mozilla/
   /map:selector

  map:select
map:when test=avantgo
  map:transform src=stylesheets/soundpoolpda.xsl/
  map:seralize/
/map:when
map:otherwise
  map:transform src=stylesheets/soundpoolpc.xsl/
  map:seralize/
/map:otherwise
  /map:select






and my pipeline looks like this:

!-- soundpool --

map:pipeline
map:match pattern=soundpool/soundpool
  map:generate src=soundpool.xml/
  map:serialize/
/map:match
/map:pipeline



What can you suggest?

Thanks

Richard.


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




AW: AW: Accessing session variables in the sitemap.xmap

2003-01-31 Thread Marco Rolappe
hey heiko,

see comments inline

 -Ursprüngliche Nachricht-
 Von: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]]Im
 Auftrag von Heiko Milke
 Gesendet: Samstag, 1. Februar 2003 01:32
 An: [EMAIL PROTECTED]
 Betreff: Re: AW: Accessing session variables in the sitemap.xmap


 Hello Marco,

 thank you very much for your reply. It is a bit irretating that you
 can't read something from the session that was set to it earlier in a

the thing is that it was not set *earlier*. this has to do with how
pipelines work. the xsp attribute
create-session=true leads to code in the serverpage's generate() method.
but this method is not called before pipeline setup. so at pipeline
setup/assembly time the session will not yet have been created.

 serverpage (while working on the same request) but i'll have to live
 with it.

 Now I wrote an action that does the talking to the session and it works
 fine. The serverpages just lost some of their value for me. I was so

it's not really the serverpages' fault. you can have create-session=true
get to work. the xsp logicsheet just has to be modified accordingly (create
the session in the XSP's setup() method.

 happy with the XMLFragment implementation of mine working out so well
 but if session modifications are delayed to the next page request 

 Gn8 Heiko!


jo, schlaf ma gut!


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: XMLForm Xindice howto at Wiki refactored and ready

2003-01-31 Thread Josema Alonso
Hello again, Ivelin.

 The new revision is excelent.
Thank you very much.

 Please follow the instructions to submit an official HOWTO
 http://xml.apache.org/cocoon/howto/howto-author-howto.html

 Diana will take it from there.
I'll do once solved the doubts below. Thanks.

 In the fragment below, why use //. Is it a typo?
 /info and /@id are probably more appropriate.
 The ref in the textbox case should always resolve to a single node. //
may
 return a nodeset.

  xf:textbox ref=//@id
   xf:captionArtist identifier:/xf:caption
 /xf:textbox
 xf:textbox ref=//Name
I see, but let me explain it.
I should not use //, that's ok, but I think /@id for example is not
enough.
If I'm right, using / gives the Document Root but not the Root Element and
I can't access from there the id attribute. Also, making it that way I get
the exception at the end of this message, which seems to confirm my theory.

So, what I think it could be a good solution is to use '/Artist/@id' and
'Artist/Name'. What do you think? Am I wrong?

 same applies for

 String artistName = (String)getForm().getValue(//@id);
 ...
 v.setPath(//@id);
Same observations as above can be applied here.

 Do you even need // for
 Node result = xi.find(xindiceSubCol, //Artist[@id='+ artistName +'],
 Artist);
Nope, don't need it here. I'm changing this asap.

 this looks like stale code

   //v.setPath(/artistName);
It is. Thank you.

 You can remove the reset() method.
 Checkboxes are automatically handled for session scope beans.
I see. Thank you.

 My experience shows that when representing plain value objects, session
 beans are never a memory concern
 with the modern app servers.
 I would prefer them almost always over request scope.
 Much easier to code, which results in less code and less maintanance.
I'm with you on this. I'm using session beans in my web apps. I always try
not to heavy load the session but some data in there doesn't hurt at all and
makes life much easier.

 On a different note, I thinkg that your code can be used in the
 AbstractXMLFormAction.

 For example when the map parameter is prefixed with java:, like in
 java:org.my.TestBean,
 then the existing JavaBean instantiation logic can be used.
 In all other cases, the model can be resolved via the SourceResolver.
 This will allow benefiting from the InputModules to access xml files from
 different sources: file system, xindice, remote URL, etc.
  map:parameter name=xmlform-model value=artist/artist-model.xml/

 If you think this makes sense, please consider submitting a patch to that
 effect.
I like very much this approach. Unfortunately I do not think I'm expert
enough to accomplish this yet and I do not want to touch things that are
working. I'm afraid I could make some mistakes.
I also should learn more about Input Modules, I still haven't used them at
all.
Anyway, if nobody's doing it, I should try it sooner or later...it would be
a good addition.

 Congratulations for the great job once again.
Thank you very much again, too :-)

--
ERROR TRACE WHEN USING '/@id':
type fatal

message Cannot setValue of an object that is not some other object's
property/child

description java.lang.UnsupportedOperationException: Cannot setValue of an
object that is not some other object's property/child

sender org.apache.cocoon.servlet.CocoonServlet

source Cocoon servlet

request-uri

/cocoon/xmtrader/xmldb/xforms/Artist.xform

path-info

xmtrader/xmldb/xforms/Artist.xform

stack-trace

java.lang.UnsupportedOperationException: Cannot setValue of an object that
is not some other object's property/child
at
org.apache.commons.jxpath.ri.model.beans.NullPointer.setValue(NullPointer.ja
va:110)
at org.apache.cocoon.components.xmlform.Form.setValue(Form.java:273)
at org.apache.cocoon.components.xmlform.Form.populate(Form.java:436)
at
org.apache.cocoon.acting.AbstractXMLFormAction.act(AbstractXMLFormAction.jav
a:287)
at
org.apache.cocoon.components.treeprocessor.sitemap.ActTypeNode.invoke(ActTyp
eNode.java:139)
at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo
keNodes(AbstractParentProcessingNode.java:85)
at
org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invok
e(PreparableMatchNode.java:166)
at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo
keNodes(AbstractParentProcessingNode.java:109)
at
org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(Pipel
ineNode.java:153)
at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invo
keNodes(AbstractParentProcessingNode.java:109)
at
org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(Pipe
linesNode.java:143)
at
org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcess
or.java:326)
at

RE: handing an XML doc (in memory) to the sitemap

2003-01-31 Thread Geoff Howard
I have zero knowledge (well, very little) of the Sunrise process you're
trying to use, but it sounds like you should be able to place the
xmldocument into the session as a session attribute, and call the
SessionAttributeGenerator on it.  The javadocs are pretty good for that one.
For the xsl you may need to call it via cocoon:/ pseudo protocol from
another pipeline set up to use the same generator.  pretty sure that
protocol preserves all session info and attributes.

Be sure to let me know what happens.

By the way, I seem to recall that you are local to DC - did you notice the
DC CHUG information brewing earlier today?  Would you be interested in that
if it gets off the ground?

Geoff

 -Original Message-
 From: Ray Martin [mailto:[EMAIL PROTECTED]]
 Sent: Friday, January 31, 2003 7:02 PM
 To: [EMAIL PROTECTED]
 Subject: handing an XML doc (in memory) to the sitemap


 Using the SunRise instructions found at
 http://radio.weblogs.com/0103021/stories/2002/02/28/usingTheSunris
 eComponent
 s.html

 The example has a pipeline named foo-authuser
 In this pipeline, i call an action named checkCredentials.  This action
 accesses several tables in a database.  If a match is found, for username
 and password, a vector of roles available to that user is
 created.  Then an
 XML document is produced in the action that conforms to the Sunrise
 example's authentication XML.

 Now i want to hand that XML to the sitemap in place of foo-user.xml and
 foo-user.xsl

 Please help me.

 I will be glad to share how this entire process works after i bridge this
 final gap.  I will provide the action and all info how to set the
 database.
 You would be able to modify this process to meet your data store needs.

 Would anyone be so kind as to give me some assistance? please.



 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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





-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




RE: Question on generators...

2003-01-31 Thread Geoff Howard
Then yes, you can reuse it - but you should be aware that it's not very
optimized doing xml generation through string.  If you're doing short
documents, you may not notice any issue.  But if you have a larger document
you may wish to reimplement in SAX.  Try it first as is - you may be
perfectly satisfied.

The short answer about how is basically:
1) Make sure you read up on Generators, including the tutorial on
CustomGenerators if you haven't already.  Also read up on Avalon (the stuff
at in the Cocoon docs should be enough).
2) Create a generator that imports your original class, and populate a
String in your Generator by calling appropriate methods in your class.
Exactly how is 100% determined by the specifics of how it works now, but I
trust you can figure that part out.

I have to gloss over the next details I think until I know what version
you're using:
3) Lookup the parser from Cocoon's ComponentManager (which means your
Generator needs to extend ComposerGenerator, or implement Composable
itself).
4) Do InputSource inputSource = new InputSource(new StringReader(
yourXMLString ));
5) Pass that inputSource to parse();

What version of Cocoon are you using? 2.0.3, 2.0.4, or 2.1dev?

If you're using 2.1dev, check out WebServiceProxyGenerator (quick before
someone refactors it to not use String anymore).  It does almost exactly
what you want, except it gets the String over HTTP from any arbitrary url.
In fact, you may look into that as a quick option.  Don't know your current
setup, but if you can call the servlet and get xml string back via HTTP you
could be finished quite quickly.

HTH,
Geoff Howard

 -Original Message-
 From: SriKumar Kareti [mailto:[EMAIL PROTECTED]]
 Sent: Friday, January 31, 2003 2:08 PM
 To: [EMAIL PROTECTED]
 Subject: RE: Question on generators...



 Geoff,

 I was creating String...

 thx...

 -Original Message-
 From: Geoff Howard [mailto:[EMAIL PROTECTED]]
 Sent: Friday, January 31, 2003 12:28 PM
 To: [EMAIL PROTECTED]
 Subject: RE: Question on generators...


 This all depends on what you were doing in your class.  Were you
 creating
 xml?  If so, DOM, SAX or String?

 Geoff

  -Original Message-
  From: SriKumar Kareti [mailto:[EMAIL PROTECTED]]
  Sent: Friday, January 31, 2003 10:21 AM
  To: [EMAIL PROTECTED]
  Subject: Question on generators...
 
 
 
  Thanks for you help in advance...
 
  I am a new user to Cocoon. I have searched the site pretty well and
  could
  not answer this question. Could someone help...
 
  My goal is to move from current servlet based solution to Cocoon. The
  general
  flow of my current program is
 
  1) Take the request,
  2) Generate the XML by making calls to Database based on the
 parameters
 passed...
  3) Use XSLT to generate html which is returned...
 
  Now I'd like to move to cocoon. I want to use my existing Java class
  as the generator in Cocoon.
 
  Can I do that?
 
  SriKumar.
 
  -
  Please check that your question  has not already been answered in the
  FAQ before posting. http://xml.apache.org/cocoon/faq/index.html
 
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail:   [EMAIL PROTECTED]
 
 
 


 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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


 -
 Please check that your question  has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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





-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




Re: XMLForm Xindice howto at Wiki refactored and ready

2003-01-31 Thread Ivelin Ivanov

 I see, but let me explain it.
 I should not use //, that's ok, but I think /@id for example is not
 enough.
 If I'm right, using / gives the Document Root but not the Root Element
and
 I can't access from there the id attribute. Also, making it that way I get
 the exception at the end of this message, which seems to confirm my
theory.

 So, what I think it could be a good solution is to use '/Artist/@id' and
 'Artist/Name'. What do you think? Am I wrong?

I think you are correct.
The point is to identify the exact xpath to the @id attribute.

  This will allow benefiting from the InputModules to access xml files
from
  different sources: file system, xindice, remote URL, etc.
   map:parameter name=xmlform-model value=artist/artist-model.xml/
 
  If you think this makes sense, please consider submitting a patch to
that
  effect.
 I like very much this approach. Unfortunately I do not think I'm expert
 enough to accomplish this yet and I do not want to touch things that are
 working. I'm afraid I could make some mistakes.
 I also should learn more about Input Modules, I still haven't used them at
 all.
 Anyway, if nobody's doing it, I should try it sooner or later...it would
be
 a good addition.

If you get it started, I can review the changes and we should be able to
wrap it up in a few iterations.




Ivelin




-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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




DO NOT REPLY [PATCH QUEUE] Summary February 1 2003

2003-01-31 Thread nicolaken
---
 This mail is generated automatically using
 Jakarta Ant. Contents are automatically
 downloaded from Apache's Bugzilla.
---
 Please do not reply to this mail.
---

***
COCOON PATCH QUEUE UPDATE
 
patches in queue:  31 
***


---
9728:[PATCH] CocoonServlet getClassPath() enhancements Tomcat4
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=9728

REVIEWER:[EMAIL PROTECTED]
RESOLUTION:  
STATUS:  NEW
---
11533:[PATCH] Replacement for AvalonToCocoonSource
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=11533

REVIEWER:[EMAIL PROTECTED]
RESOLUTION:  
STATUS:  NEW
---
11549:[PATCH] Replace LogKitManageable through LoggerManageable
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=11549

REVIEWER:[EMAIL PROTECTED]
RESOLUTION:  
STATUS:  NEW
---
11861:[PATCH] extend castortransformer to handle collections
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=11861

REVIEWER:[EMAIL PROTECTED]
RESOLUTION:  
STATUS:  NEW
---
12173:[PATCH] SQLTransformer Query object prematurely closes conne
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12173

REVIEWER:[EMAIL PROTECTED]
RESOLUTION:  
STATUS:  NEW
---
12235:[PATCH] XPathTransformer
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12235

REVIEWER:[EMAIL PROTECTED]
RESOLUTION:  
STATUS:  NEW
---
12993:[PATCH] New version of CastorTransformer (includes marshalli
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12993

REVIEWER:[EMAIL PROTECTED]
RESOLUTION:  
STATUS:  NEW
---
14117:[PATCH] AuthAction fails in sub-requests
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=14117

REVIEWER:[EMAIL PROTECTED]
RESOLUTION:  
STATUS:  NEW
---
14144:[Patch] add CompressionFilter declaration to web.xml
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=14144

REVIEWER:[EMAIL PROTECTED]
RESOLUTION:  
STATUS:  NEW
---
14327:[PATCH] JSPEngineImpl response charset should be specified w
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=14327

REVIEWER:[EMAIL PROTECTED]
RESOLUTION:  
STATUS:  NEW
---
14803:[PATCH] cacheable.xsp for new AbstractServerPages
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=14803

REVIEWER:[EMAIL PROTECTED]
RESOLUTION:  
STATUS:  NEW
---
14845:[PATCH] Patch to generate a key with new resources in XMLDBT
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=14845

REVIEWER:[EMAIL PROTECTED]
RESOLUTION:  
STATUS:  NEW
---
14986:[PATCH] Enables velocitygenerator to get objects from reques
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=14986

REVIEWER:[EMAIL PROTECTED]
RESOLUTION:  
STATUS:  NEW
---
15100:[patch]/[donation] Sample app xml form popup with sourcewrit
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=15100

REVIEWER:[EMAIL PROTECTED]
RESOLUTION:  
STATUS:  NEW
---
15150:[PATCH]: HSSFSerializer Support for Gnumeric MergedRegions
---
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=15150


Re: XMLForm Xindice howto at Wiki refactored and ready

2003-01-31 Thread Josema Alonso
 I think you are correct.
 The point is to identify the exact xpath to the @id attribute.
Ok, so I let it that way then.

 If you get it started, I can review the changes and we should be able to
 wrap it up in a few iterations.
Well, first I'll see what to do regarding the howto. I mean, I'll read the
howto submit a howto and all and get it touch with Dianna and make it
available in the docs...
After that I'll try to learn something about Input Modules. And then maybe
I'll take the challenge and try to make it. I'll drop you a line then.

Best.



-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

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