Re: moving from cocoon 2.1 dev to cocoon 2.1.3 dev
Hi: Try to switch from xalan to xsltc or inverse. Best Regards, Antonio Gallardo - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: how to override locale date format?
Date formats used by i18n transformer come from the JDK resource bundles. Check the i18n samples in Cocoon and switch to Polish translation, there is a date somewhere at the last line and it should be formatted according to the selected locale. In any case, if you want another format then you can use i18n:date format=dd.MM. .../ to specify the desired date format. But note that this format will be fixed for all the locales. Regards, Konstantin From: Marcin Okraszewski [EMAIL PROTECTED] Hi, I'm using i18n for localizing date format. It works fine, but I don't agree with format for Polish date (-MM-dd and should rather be dd.MM.). How can I change it? Regards, Marcin Okraszewski - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE : [auth-fw] NPE in Application Manager
But if, in the application, the pipeline associated to the load is started automatically at login, at logout the pipeline associated to the save isn't triggered. Yes, currently. I'm +1 for adding this feature, but there is of course the potential that the user never logs out and simply leaves the site (by closing the browser). I think - not only to be compatible - we should make this configurable, which means, like the loadOnDemand you can specify a saveOnLogout attribute and then the application is saved on logout. What do you think? Yes of course I'm +1. It's much much better, but ... I'm not sure to be able to do it by myself, because I'm still fighting with the auth-fw that isn't a piece of cake for me. And I guess that I found another bug: applications declare in an handler can generate multiple xml roots. To reproduce this issue, go inside the authentication-fw example add an application ... authentication-manager ... handler name=demohandler redirect-to ... authentication ... applications application name=MyApp load uri=cocoon:raw:load-myApp/ /application applications /handler ... /authentication-mabager The protected page that came after the login shows 2 roots authentication and application instead of /authentication/applications I run it under the debugger but I haven't found what is wrong! Laurent Trillaud - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
status of Apple block
What is the status of the Apple block? Is there a Beta version? Thanks Sylvain - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: moving from cocoon 2.1 dev to cocoon 2.1.3 dev
On 04.11.2003 06:34, iyy wrote: We are moving our application from Cocoon 2.1 Dev to Cocoon 2.1.3 Dev. One xsl statement that worked in Cocoon 2.1 dev causes error in Cocoon 2.1.3 Dev. xsl:if test=normalize-space(element_name) = normalize-space($variable_name) /xsl:if Seems to be correct indeed. $variable_name is declared I guess? In the xsl-if , if I used normalize-space then the page fails with the following error: The XML page cannot be displayed Cannot view XML input using style sheet. Please correct the error and then click the Refresh button, or try again later. XML document must have a top level element. Error processing resource This is an Internet Explorer error message. Try to find the error messages server side, i.e. the Cocoon ones. View source on browser displays empty page. If I removed the normalize-space, then the page works ok ie. xsl:if test=element_name = $variable_name /xsl:if Really strange, didn't came across such an error. As far as I know, xsl syntax is ok. Any tips are welcome. The only difference between 2.1 and the current CVS are the versions of Xalan and Xerces. I don't know how old your 2.1 dev is, but 2.1 was released with Xalan 2.5.1, now we have 2.5.2, Xerces from 2.4 to 2.5. Could be that there are any regression bugs in one of the versions, maybe you can switch back. Or do you have updated endorsed dirs? I suggest to search for an server side error message first and afterwards (if this doesn't help) switch to an older version of both Xerces and Xalan. Joerg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Why do I get a java.net.MalformedURLException?
On 04.11.2003 06:48, Jon Bedworth wrote: Hello, Please can someone help ... I have been developing an application on my own server using Cocoon 2.1 and Tomcat. Things work fine. Yet when I transfer this to a server that is also using Tomcat but a newer version of Cocoon (version 2.1.2), I get the following error when I try to access certain pages: org.apache.cocoon.ProcessingException: Failed to execute pipeline.: org.apache.cocoon.ProcessingException: Failed to execute pipeline.: java.net.MalformedURLException: no protocol: XML_entities\ISOnum.ent which seems to relate to a problem with an entity definition file I have in a sub-directory (XML_entities). Has something happened in the newer release to cause this? This entity file is a standard file, and there is nothing 'malformed' about it that i can see. As far as I know only the Xerces version has changed related to this problem. Maybe you can try to switch back. (cc-ing David Crossley, who seems not to be on this list) Joerg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Two-pass transformation tutorial needed
It's a sitemap thing: map:match pattern=** map:generate src=doc.xml/ map:transform src=step1.xsl/ map:transform src=step2.xsl/ map:serialize/ /map:match If you now do in step1 the output independent transformations and in step2 the dependent ones (the main template), you should have less stylesheets than before. Joerg On 04.11.2003 08:21, Johannes Becker wrote: Hi, I' looking for a two-pass transformation tutorial for cocoon. Why? My post on xsl-list: ___ My problem is that I have lots of different stylesheets for the main-template (xsl:call-template name=main/), and I don't want to write millions of different xsl's that differ just in one entry (xsl:include href=X/). Is there an other way to solve this problem? my xsl: ?xml version=1.0 encoding=UTF-8? xsl:stylesheet version=1.0 xmlns:xsl=http://www.w3.org/1999/XSL/Transform; xsl:variable name=mainxsl:value-of select=/document/style//xsl:variable xsl:template match=/document ... xsl:call-template name=main/ ... /xsl:template !-- wrong usage of include -- xsl:include href={$main}/ !-- end wrong usage -- !-- needed to code around it -- /xsl:stylesheet __ They told me to use two pass transformation. Are there some documented examples for this in cocoon? Regards Jonny - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: status of Apple block
On 04.11.2003 09:40, [EMAIL PROTECTED] wrote: What is the status of the Apple block? Is there a Beta version? In Cocoon we don't have alpha or beta status, they are marked as stable or unstable, what refers to interfaces at first. Quote from blocks.properties: # unstable blocks are currently under development and do not guarantee that the # contracts they expose (API, xml schema, properties, behavior) will remain # constant in time. Developers are not committed to back-compatibility just yet. # This doesn't necessarily mean the blocks implementation is unstable or # the code can't be trusted for production, but use with care and watch # its development as things might change over time before they are marked # stable. What's the status of the apple block can tell you only one person I guess, so I will cc him. Can you give any status information, Marc? Joerg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
createSecurityManager
Hello all, my new hosting provider has just said that they cannot grant us the createSecurityManager permission, for the environment is shared and this would compromise the security. Is there any way to use Cocoon without this permission? Is this permission really a hazard in a shared environment? Thanks in advance, Flavio Costa - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
JXForms and Java Action class like in XMLForm
Hi, I have got a question concerning JXForms. My problem as a XMLForm user is that I would not like to use js(_javascript_) files for the flow control, I would rather prefer the way it was or is in XMLForm. There you create a java class *Action (and a JavaBean Model) as a class. Is there a way of doing creating java classes instead of _javascript_ in JXForm.No, hasn't been implemented yet. But it shouldn't be too difficult.Cheers,Reinhard Hello, I have the same problem. I have to get my old xmlforms working with jxforms. When will actions be implemented? thnx Twan
store file after transformation
Hi Everybody I'new to cocoon but I've got a difficult question, and I would be really thankful if somebody can help me out. what I'm trying to do is: 1. submit a form which tells cocoon which files to include in final document 2. transform this files into another document (xml-pdf) 3. write to a file (SourceWritingTransformer) 4. display a page like task complete how can I configure the sitemap? this is an example of my sitemap, I'm not sure, can I use two transformers? map:pipeline map:match pattern=file1.pdf map:generate src=file1.xml/ !--here should the document be transformed to pdf andafter that given to the sourcewriter-- map:transform type=sourcewriter/ map:serialize type=xml/ /map:match /map:pipeline sourcewriter map:transformer name=sourcewriter logger=sitemap.transformer.filewriter src=org.apache.cocoon.transformation.SourceWritingTransformer map:parameter name=serializer value=xml/ /map:transformer everytime i use this, I'm getting the documt in the browser window and not on disk can anybody help me with this? I'using cocoon 2.1.2 thanks! ciao dominik - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
access session context from flowscript
Hi everybody, I need to access the session authentication context created by the authentication framework using javascript within flowscript. Can anybody give some javascript code that does it for me? Or how can I use the class XSPSessionHelperFw to do it for me (see below)? public class XSPSessionFwHelper { /** GetXML Fragment from the given session context and path * * * @param session The Session object * @param context The Session context tha define where to search * @param path The parameter path * @param defaultValue Value to substitute in absence of the required Fragment **/ public static DocumentFragment getXML(ComponentManager cm, String context, String path) throws ProcessingException { SessionManager sm = null; DocumentFragment df = null; try { // Start looking up the manager sm = (SessionManager)cm.lookup(SessionManager.ROLE); // Make our work df = sm.getContextFragment(context, path); if (sm != null) { cm.release((Component)sm); } } catch (ComponentException ce) { throw new ProcessingException(Error during lookup of SessionManager component., ce); } finally { // End releasing the sessionmanager cm.release((Component)sm); } return df; } } Many thanks, Markus - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
+ The Use of JSPGenerator +
Hi all, I' am a newbie with cocoon 2.0 and this is my problem : I have a jsp file and with the JSPGenerator I can generate the correspondant xml file and then now come the problem ( I would to use the generated xml file to have a pdf file) but I don't how Can I do to have this xml file and then use it with the fo2pdf to have a pdf file. please when someone an ideal hat reply me as email - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: access session context from flowscript
Check in the samples of authentication framework fro Cocoon CVS. I thought there are example using flow. Best Regards, Antonio Gallardo Markus Heussen dijo: Hi everybody, I need to access the session authentication context created by the authentication framework using javascript within flowscript. Can anybody give some javascript code that does it for me? Or how can I use the class XSPSessionHelperFw to do it for me (see below)? public class XSPSessionFwHelper { /** GetXML Fragment from the given session context and path * * * @param session The Session object * @param context The Session context tha define where to search * @param path The parameter path * @param defaultValue Value to substitute in absence of the required Fragment **/ public static DocumentFragment getXML(ComponentManager cm, String context, String path) throws ProcessingException { SessionManager sm = null; DocumentFragment df = null; try { // Start looking up the manager sm = (SessionManager)cm.lookup(SessionManager.ROLE); // Make our work df = sm.getContextFragment(context, path); if (sm != null) { cm.release((Component)sm); } } catch (ComponentException ce) { throw new ProcessingException(Error during lookup of SessionManager component., ce); } finally { // End releasing the sessionmanager cm.release((Component)sm); } return df; } } Many thanks, Markus - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: JXForms and Java Action class like in XMLForm
I'm sorry to say this but I think none of the Cocoon committer will do it because we concentrate our efforts on Cocoon Forms (aka Woody) which overcomes many limitations of JXForms/XMLForms. Of course if somebody provides a patch it will be added to the JXForms block. After releasing Cocoon Forms we will deprecate JXForms as well - so if it is possible for you the best way would be switching to Cocoon Forms (but be aware that a contract stable release will take another few months from now). HTH -- Reinhard -Original Message- From: Twan Munster [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 04, 2003 12:50 PM To: [EMAIL PROTECTED] Subject: JXForms and Java Action class like in XMLForm Hi, I have got a question concerning JXForms. My problem as a XMLForm user is that I would not like to use js(javascript) files for the flow control, I would rather prefer the way it was or is in XMLForm. There you create a java class *Action (and a JavaBean Model) as a class. Is there a way of doing creating java classes instead of javascript in JXForm. No, hasn't been implemented yet. But it shouldn't be too difficult. Cheers, Reinhard Hello, I have the same problem. I have to get my old xmlforms working with jxforms. When will actions be implemented? thnx Twan - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: store file after transformation
You can use two or more transformers in a pipeline. Are you inserting necessary tags needed for sourcewriter transformer in your first step transformation. The result of first step transformation should be something like: page ... source:write xmlns:source=http://apache.org/cocoon/source/1.0; source:sourcecontext://doc/editable/my.xml/source:source source:fragment page titleHello World/title content pThis is my first paragraph./p /content /page /source:fragment /source:write ... /page Inside the source:fragment you can have any xml content like xsl:fo contents. ( Detailed explanation: http://cocoon.apache.org/2.1/userdocs/transformers/sourcewriting-transformer.html ) Anyway please note that pdf files are created in the serialization step, if you use fop serializer. So in this case, you don't have the pdf content after first transformation. You can have xsl:fo content instead and write it to a file using sourcewriter transformation. If you can explain your use case more clearly, maybe better help can be provided. Regards, Hassan - Original Message - From: Ulrich, Dominik [EMAIL PROTECTED] To: Cocoon Mailing Liste (E-Mail) [EMAIL PROTECTED] Sent: Tuesday, November 04, 2003 8:58 PM Subject: store file after transformation Hi Everybody I'new to cocoon but I've got a difficult question, and I would be really thankful if somebody can help me out. what I'm trying to do is: 1. submit a form which tells cocoon which files to include in final document 2. transform this files into another document (xml-pdf) 3. write to a file (SourceWritingTransformer) 4. display a page like task complete how can I configure the sitemap? this is an example of my sitemap, I'm not sure, can I use two transformers? map:pipeline map:match pattern=file1.pdf map:generate src=file1.xml/ !--here should the document be transformed to pdf andafter that given to the sourcewriter-- map:transform type=sourcewriter/ map:serialize type=xml/ /map:match /map:pipeline sourcewriter map:transformer name=sourcewriter logger=sitemap.transformer.filewriter src=org.apache.cocoon.transformation.SourceWritingTransformer map:parameter name=serializer value=xml/ /map:transformer everytime i use this, I'm getting the documt in the browser window and not on disk can anybody help me with this? I'using cocoon 2.1.2 thanks! ciao dominik - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: + The Use of JSPGenerator +
Hi, To be able to use fo2pdf you need to transform your xml to XSL-FO (http://www.w3.org/TR/xsl/slice6.html#fo-section). You can of course do this by a xslt tranformation step between you jsp generator and fo2pdf serialization. Cocoon has a hello world pdf sample that may help you understand the steps. Regards, Hassan - Original Message - From: pagop Serge [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, November 04, 2003 10:42 PM Subject: + The Use of JSPGenerator + Hi all, I' am a newbie with cocoon 2.0 and this is my problem : I have a jsp file and with the JSPGenerator I can generate the correspondant xml file and then now come the problem ( I would to use the generated xml file to have a pdf file) but I don't how Can I do to have this xml file and then use it with the fo2pdf to have a pdf file. please when someone an ideal hat reply me as email - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Useful Transfomers? - wsinclude, htmlinclude
Tony Culshaw wrote: ... These have been running for a while in a stable environment (currently 2.1.1) and have been well used. FYI, I have uploaded your submission to bugzilla so that we don't forget about it: http://nagoya.apache.org/bugzilla/show_bug.cgi?id=24391 -Bertrand - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
xsp visual edtior
Hi all, I'm currently working on web interfaces built with and i like to know if one of you know a XSP graphical editor... By this way, I mean that it's boring a lot to code every line of your XSP page, so i like to know if you know a tool that generates XSP code... Thanks a lot for answering and best regards Jerome - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
new Sitemap Viewer
I put a new version of the Sitemap Viewer in bugzilla: http://nagoya.apache.org/bugzilla/showattachment.cgi?attach_id=8918 I think it is getting better. Let me know what you think. Greetings, Jelle - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Two-pass transformation tutorial needed
If your stylesheet stays the same but different documents needed to be dynamically included you can write a source resolver and then reference it as xsl:include href=mysource://mydocument.xsl. Your source resolver can then include different versions of mydocument.xsl based upon whatever criteria you need. I am doing exactly this to dynamically choose documents based upon the website name. Ralph -Original Message- From: Johannes Becker [mailto:[EMAIL PROTECTED] Sent: Monday, November 03, 2003 11:21 PM To: [EMAIL PROTECTED] Subject: Two-pass transformation tutorial needed Hi, I' looking for a two-pass transformation tutorial for cocoon. Why? My post on xsl-list: __ _ My problem is that I have lots of different stylesheets for the main-template (xsl:call-template name=main/), and I don't want to write millions of different xsl's that differ just in one entry (xsl:include href=X/). Is there an other way to solve this problem? my xsl: ?xml version=1.0 encoding=UTF-8? xsl:stylesheet version=1.0 xmlns:xsl=http://www.w3.org/1999/XSL/Transform; xsl:variable name=mainxsl:value-of select=/document/style//xsl:variable xsl:template match=/document ... xsl:call-template name=main/ ... /xsl:template !-- wrong usage of include -- xsl:include href={$main}/ !-- end wrong usage -- !-- needed to code around it -- /xsl:stylesheet __ They told me to use two pass transformation. Are there some documented examples for this in cocoon? Regards Jonny _ FreeSMS abräumen mit dem MSN Messenger - der Countdown läuft! http://messenger-mania.msn.de Jetzt mitmachen und gewinnen! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Using the context:// protocol in ExcaliburTest
Hi Cocoon community, I want to test some components with an ExcaliburTest subclass. Resolving a source using the context:// protocol does not work - the returned source is not valid. What can I do to solve this problem? Thanks in advance! -- Andreas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
passing session context data
Hi all, I have an application in which a non-authenticated user collects a set of items from a catalog (shopping-cart like), and stores the item list in the context of the session. I use the session taglib and the session transformer to do so. To proceed to the cart command, the user logs in. I use the the DatabaseAuthenticatorAction to do so. This creates a new session for the user. I'm trying to figure out how to pass the shopping-cart context from the unauthenticated session to the authenticated one. But I have trouble seeing how it can be done : is the previous session terminated as soon the user authenticates? How can I track info from another session? Many thanks for your thoughts!! These are the concerned parts of my sitemap : !-- __ Add items to cart ___ -- map:pipeline map:match pattern=ajout/* map:generate src=panier/panier.xml/ map:transform src=xsl/create_context.xsl map:parameter name=item_id value={1}/ /map:transform map:transform type=session/ map:serialize type=xml/ /map:match /map:pipeline !-- __ See cart content ___ -- map:pipeline map:match pattern=consult map:generate type=serverpages src=panier/consult.xsp/ map:transform type=session/ map:serialize type=xml/ /map:match /map:pipeline !-- __ Authentication ___ -- map:pipeline map:match pattern=login map:act type=authenticator map:parameter name=descriptor value=context://dvdcarte/defs/auth-def.xml/ map:redirect-to uri=perso_accueil/ /map:act map:redirect-to uri=login.html/ /map:match /map:pipeline !-- __ Protected area ___ -- map:pipeline map:match type=sessionstate pattern=* map:parameter name=attribute-name value=userId/ map:match pattern=perso_accueil map:generate type=serverpages src=xsp/perso_accueil.xsp/ map:serialize type=html/ /map:match /map:match /map:pipeline - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Dynamic transformer chains in sitemap?
Hello, I have a situation where I want to assemble a chain of XSL style sheets dynamically. An action in my pipeline knows which stylesheets to chain, but I can't figure out how to assemble the chain, short of trying to write something like the CocoonTransformerChainBuilderFilter. All I really need is to chain XSL stylesheets, but I guess it'd be nice and more general to Cocoon if I could build a chain of any type of transformers. --Justin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Cocoon 2.1.2 on Jboss 4.0.0.DR2
I am trying to deploy the latest release of Cocoon i.e. 2.1.2 as webapp on JBoss 4.0.0.DR2 (built in Tomcat 4.1.24). I get following exception: 10:10:35,083 ERROR [STDERR] Caused by: com.hp.hpl.jena.rdf.arp.ParseException: {E201} Syntax error when processing EOF. Input to RDF parser ended prematurely. This is often related to an XML parser abort. Encountered EOF Was expecting one of: XML ELEMENT CONTENT start element rdf:RDF start element rdf:Description general start element tag 10:10:35,085 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.RDFParser.generateParseException(RDFParser.java:2208) 10:10:35,085 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.RDFParser.jj_consume_token(RDFParser.java:2095) 10:10:35,085 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.RDFParser.root(RDFParser.java:1325) 10:10:35,086 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.RDFParser.embeddedFile(RDFParser.java:1308) 10:10:35,086 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.ARPFilter.parse(ARPFilter.java:293) 10:10:35,087 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.JenaReader.read(JenaReader.java:227) 10:10:35,087 ERROR [STDERR] ... 129 more Can anybody help me figuring out what's wrong ? FYI: I was able to deploy Cocoon 2.1 webapp on same JBoss installation successfully. -YKP - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[WOODY] convert xsd to form model
Is iT theorically possible to convert xsd to woody form (with for example a xsl ) ?
How to update one table while mod-db add to another in same request?
I have a form from which I can perform several options each having it's own submit button that passes the value of the option selected to a sitemap pattern like the one below. The behavior that I want from option 3 is to update a flag in one database table and also perform a modular db add to another table. Since my cocoon actions are different (update and mod-db add), I used an xsl for the table update and an action for the mod-db add. The db update in the xsl file is not performed but the mod-db add is performed as desired. In order for the db update to be performed, I had to remove the redirects and serialize the output to xml or html. The xsl file does a simple update table where key field = value. What prohibits the update in the xsl file in combination with the mod-db add and redirects as coded? Is there a better way to do this? Can the desired behavior be achieved without writing my own action? In my sitemap is the following: map:match pattern=perf_sev_opts map:generate type=request/ map:select type=request-parameter map:parameter name=parameter-name value=opt/ map:when test=opt1 map:redirect-to uri=option1/ /map:when map:when test=opt2 map:redirect-to uri=option2/ /map:when map:otherwise map:transform src=do_updateflag.xsl map:parameter name=use-request-parameters value=true/ /map:transform map:transform type=sql map:parameter name=use-connection value=DBNAME/ /map:transform map:act set=moddbinsert map:parameter name=descriptor value=descriptor.xml/ /map:act map:transform type=sql map:parameter name=use-connection value=DBNAME/ /map:transform map:select type=request-parameter map:parameter name=parameter-name value=redirectflag/ map:when test=opt3 map:redirect-to uri=select_option_to_perform/ /map:test map:otherwise map:redirect-to uri=home/ /map:otherwise /map:select /map:otherwise /map:select /map:match __ Do you Yahoo!? Protect your identity with Yahoo! Mail AddressGuard http://antispam.yahoo.com/whatsnewfree - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Desing patterns used by Cocoon
i would like to know the list of all the design patterns used by cocoon (and avalon) i know cocoon use : - MVC - Separation of concern and ?
xhtml character encoding
Hi, I am using cocoon 2.1.2 and I need some help getting the xml serializer to behave like the html serializer. I can demostrate the problem using the hello-world sample. If I modify samples/hello-world/content/hello.xml and insert the code #189; as follows: ?xml version=1.0? !-- CVS $Id: hello.xml,v 1.3 2003/05/07 04:57:13 vgritsenko Exp $ -- page titleHello/title content paraThis is my #189; first Cocoon page!/para /content /page When I access it as hello.html I get pThis is my frac12; first Cocoon page!/p as hello.xhtml I get pThis is my ½ first Cocoon page!/p I'm not sure the extra char will appear in this email, however viewing the page in a browser displays an additional A with a caret in front of the half symbol. I would like to output as xhtml but would prefer the output using the text encoding as in the html example. Is this possible? Many thanks, John. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: status of Apple block
Joerg Heinicke wrote: On 04.11.2003 09:40, [EMAIL PROTECTED] wrote: What is the status of the Apple block? Is there a Beta version? In Cocoon we don't have alpha or beta status, they are marked as stable or unstable, what refers to interfaces at first. yep, the implementation has been tested in real life cases and should be stable and trustworthy (of course I'm happy to learn about possible bugs) we can use some more people tossing around with the ideas in there and send us some new use cases that maybe push up the need for more elaborate API design that e.g. allows for better integration with Woody and the like the API is quite basic ATM, but as you can see from the samples it seems to offer already enough to be quite useable (IMHO) main thing that is lacking ATM is some more detailed docos and/or wiki-pages, but again: the samples should get you started Quote from blocks.properties: snip / What's the status of the apple block can tell you only one person I guess, so I will cc him. Can you give any status information, Marc? Joerg Joerg, thx for forwarding, and to the enterested audience: sorry for missing out on this... regards, -marc= -- Marc Portierhttp://outerthought.org/ Outerthought - Open Source, Java XML Competence Support Center Read my weblog at http://radio.weblogs.com/0116284/ [EMAIL PROTECTED] [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Desing patterns used by Cocoon
Nicolas Maisonneuve wrote: i would like to know the list of all the design patterns used by cocoon (and avalon) i know cocoon use : - MVC - Separation of concern and ? serious_answer You will never get such a list without compiling it yourself, if that is even possible. Is this for a class assignment? You may find a person here willing to help you find evidence of a few specific patterns, but you are going to have to do the work yourself. There are - to put it mildly - a lot of different patterns used. /serious_answer alternative_answer Sure, no problem. Just send me a list of all the patterns that exist, and I'll let you know which ones Cocoon uses. /alternative_answer alternative_answer Patterns? We don't need no stinkin' patterns! /alternative_answer - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Cocoon 2.1.2 on Jboss 4.0.0.DR2
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I got the same error not a week ago but with JBoss 3.2.2 and Tomcat 4.1.27. It's the Deli block messing things up. It's totaly unstable so if you uncomment the line that says exclude.block.deli=true and recompile you'll be fine... Good luck! /Mike - -Original Message- From: YKPrajapati [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 04, 2003 4:19 PM To: [EMAIL PROTECTED] Subject: Cocoon 2.1.2 on Jboss 4.0.0.DR2 I am trying to deploy the latest release of Cocoon i.e. 2.1.2 as webapp on JBoss 4.0.0.DR2 (built in Tomcat 4.1.24). I get following exception: 10:10:35,083 ERROR [STDERR] Caused by: com.hp.hpl.jena.rdf.arp.ParseException: {E201} Syntax error when processing EOF. Input to RDF parser ended prematurely. This is often related to an XML parser abort. Encountered EOF Was expecting one of: XML ELEMENT CONTENT start element rdf:RDF start element rdf:Description general start element tag 10:10:35,085 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.RDFParser.generateParseException(RDFParser.jav a:2208) 10:10:35,085 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.RDFParser.jj_consume_token(RDFParser.java:2095 ) 10:10:35,085 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.RDFParser.root(RDFParser.java:1325) 10:10:35,086 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.RDFParser.embeddedFile(RDFParser.java:1308) 10:10:35,086 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.ARPFilter.parse(ARPFilter.java:293) 10:10:35,087 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.JenaReader.read(JenaReader.java:227) 10:10:35,087 ERROR [STDERR] ... 129 more Can anybody help me figuring out what's wrong ? FYI: I was able to deploy Cocoon 2.1 webapp on same JBoss installation successfully. - -YKP - - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -BEGIN PGP SIGNATURE- Version: PGP 8.0.2 iQA/AwUBP6gHUYTNuy8mcLTPEQKURgCfbmttAczvc59z4u4/pWM/dg+xZt0AnjsW r+gwE9Eytf/7uIHNmSe+vlwo =bJuX -END PGP SIGNATURE- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: i18n: how to override locale date format?
It uses DateFormat.getDateInstance(style, locale). How Java handles the locale don't know, but it hadles it correctly: According to Polish rules it should be (and IS) -MM-dd. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: XSP/ESQL escaping
Where and how is formatMessage() implemented? That is the code we really need to see, I think. Thanks for your time The formatMessage is implemented above the problem in the xsp logic section, and it (currently) only does this : xsp:logic public string formatMessage(String message) { return instring.replaceAll(\n, br/) } /xsp:logic the problem area in the xsp, like I said looks like this bodyxsp:exprformatMessage(esql:get-xml column=body/)/xsp:expr/body The problem occurs when the xsp:expr contains tags (i.e. if I do the replace \n --- foo , then all is well, but \n --- foo/ will not work. ) rgds Anders - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Desing patterns used by Cocoon
Geoff Howard wrote: Nicolas Maisonneuve wrote: i would like to know the list of all the design patterns used by cocoon (and avalon) serious_answer snip/ /serious_answer alternative_answer snip/ /alternative_answer alternative_answer snip/ /alternative_answer alternative-answer All of the 23 GOF patterns. With a few hundred source files, I' ready to bet you can find an instance of every single GOF pattern under org.apache.cocoon.*. /alternative-answer Ugo - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: XSP/ESQL escaping
Yes, you cannot use tags inside java strings in this fashion. When XSP sees this tag, it tries to insert a whole block of code to output the tag into the SAX output, which should give you a compilation error. I'm actually not certain how it is you are able to pass the results of esql:get-xml into a function call without getting compilation errors. The get-xml tag also turns into a whole block of code, not an expression which can be passed to a function. What version of Cocoon are you using? In C2.0.3, which I am using, you would be unable to do this, and you would be unable to do substitutions inside the returned XML. Instead, you'd have to get the results using get-string, do your substitutions (using lt; in place of ), then run the resulting String through an XML parser to get it into the SAX stream. (A good example of this is the code that implements get-xml in the ESQL logicsheet, which is in your cocoon jar file.) HTH. -Christopher |-+ | | Anders Forsgren | | | [EMAIL PROTECTED]| | | rmers.com | | || | | 11/04/2003 04:31 | | | PM | | | Please respond to| | | users| | || |-+ --| | | | To: [EMAIL PROTECTED] | | cc: | | Subject: Re: XSP/ESQL escaping | --| Where and how is formatMessage() implemented? That is the code we really need to see, I think. Thanks for your time The formatMessage is implemented above the problem in the xsp logic section, and it (currently) only does this : xsp:logic public string formatMessage(String message) { return instring.replaceAll(\n, br/) } /xsp:logic the problem area in the xsp, like I said looks like this bodyxsp:exprformatMessage(esql:get-xml column=body/)/xsp:expr/body The problem occurs when the xsp:expr contains tags (i.e. if I do the replace \n --- foo , then all is well, but \n --- foo/ will not work. ) rgds Anders - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
re: problem with caching of jpegs by Internet Explorer
Hi, I have been creating a web site with Cocoon 2.1.2 that dynamically generates jpeg/png images. The problem is that when the site is viewed by Internet Explorer, old cached images are view and the jpegs/png images do not refresh despite being modified from the last access to the site. This can be fixed on the client side by selecting on the browser 'Internet Options - Settings - Check for newer version of stored pages' and changing the setting to 'Every visit to the page' instead of 'Automatically' but this is not a good solution if others wish to view the page. Is there anything I can do in Cocoon to make sure that changes to the jpegs/pngs are shown whenever the site is accessed? Thanks in advance, Jim - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[WOODY] binding xml of a multiple repeaters inclusion
hy , - what the xml binding file for this data ? description info email[EMAIL PROTECTED]/email/info contacts contact id="1" firstnameLucien/firstname phones phone id="1" nr="+32-2-222"/ phone id="2" nr="+32-2-221"/ /phones /contact contact id="2" firstnameJoris/firstname phones phone id="3" nr="+32-2-223"/ phone id="4" nr="+32-2-224"/ /phones /contact /contacts/description - in the binding repeater definition we must set : unique-row-id unique-path but when we don"t have a id attribute , how do it ? thanks nicolas maisonneuve PS : Without the binding i tried to create aformwith this model of data (multiple repeater inclusion) and it's work !
RE: problem with caching of jpegs by Internet Explorer
You could test for access by IE using the browser selector, and serve them the file with an explicit expiry in the pipeline: map:parameter name=expires value=access plus 5 minutes/ Cheers Con -Original Message- From: jim basilakis [mailto:[EMAIL PROTECTED] Sent: Wednesday, 5 November 2003 11:20 a.m. To: [EMAIL PROTECTED] Subject: re: problem with caching of jpegs by Internet Explorer Hi, I have been creating a web site with Cocoon 2.1.2 that dynamically generates jpeg/png images. The problem is that when the site is viewed by Internet Explorer, old cached images are view and the jpegs/png images do not refresh despite being modified from the last access to the site. This can be fixed on the client side by selecting on the browser 'Internet Options - Settings - Check for newer version of stored pages' and changing the setting to 'Every visit to the page' instead of 'Automatically' but this is not a good solution if others wish to view the page. Is there anything I can do in Cocoon to make sure that changes to the jpegs/pngs are shown whenever the site is accessed? Thanks in advance, Jim - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Why do I get a java.net.MalformedURLException?
Joerg Heinicke wrote: Jon Bedworth wrote: Please can someone help ... I have been developing an application on my own server using Cocoon 2.1 and Tomcat. Things work fine. Yet when I transfer this to a server that is also using Tomcat but a newer version of Cocoon (version 2.1.2), I get the following error when I try to access certain pages: org.apache.cocoon.ProcessingException: Failed to execute pipeline.: org.apache.cocoon.ProcessingException: Failed to execute pipeline.: java.net.MalformedURLException: no protocol: XML_entities\ISOnum.ent which seems to relate to a problem with an entity definition file I have in a sub-directory (XML_entities). Has something happened in the newer release to cause this? This entity file is a standard file, and there is nothing 'malformed' about it that i can see. As far as I know only the Xerces version has changed related to this problem. Maybe you can try to switch back. (cc-ing David Crossley, who seems not to be on this list) (I am a digest subscriber, but only look occasionally.) Apart from the suggestion from Joerg, i cannot think of anything changed in Cocoon that might cause this. Jon, here are a few more comments: Is the Java version the same on both machines? The error message is not saying that the file or its contents are malformed. It is saying that the URL to the file is malformed. I presume that you are aware that these entity sets are already provided by the Cocoon core: http://cocoon.apache.org/2.1/userdocs/concepts/catalog.html What are you trying to do with ISOnum.ent that you would need to use a hard-coded URL? To help further, we would need to know more information: what you are trying to achieve, the sitemap snippet that invokes this pipeline, the xml instance that is being processed, more context from the logfile, etc. --David - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: XSP/ESQL escaping
Sigh :( Feels like a lot of work to make a linebreak a br/ tag...If I rephrase the question: What would be the simplest way of displaying the database strings with correct linebreaks in html (except using pre in the xsl)? thanks Anders Yes, you cannot use tags inside java strings in this fashion. When XSP sees this tag, it tries to insert a whole block of code to output the tag into the SAX output, which should give you a compilation error. I'm actually not certain how it is you are able to pass the results of esql:get-xml into a function call without getting compilation errors. The get-xml tag also turns into a whole block of code, not an expression which can be passed to a function. What version of Cocoon are you using? In C2.0.3, which I am using, you would be unable to do this, and you would be unable to do substitutions inside the returned XML. Instead, you'd have to get the results using get-string, do your substitutions (using lt; in place of ), then run the resulting String through an XML parser to get it into the SAX stream. (A good example of this is the code that implements get-xml in the ESQL logicsheet, which is in your cocoon jar file.) HTH. -Christopher |-+ | | Anders Forsgren | | | [EMAIL PROTECTED]| | | rmers.com | | || | | 11/04/2003 04:31 | | | PM | | | Please respond to| | | users| | || |-+ --| | | | To: [EMAIL PROTECTED] | | cc: | | Subject: Re: XSP/ESQL escaping | --| Where and how is formatMessage() implemented? That is the code we really need to see, I think. Thanks for your time The formatMessage is implemented above the problem in the xsp logic section, and it (currently) only does this : xsp:logic public string formatMessage(String message) { return instring.replaceAll(\n, br/) } /xsp:logic the problem area in the xsp, like I said looks like this bodyxsp:exprformatMessage(esql:get-xml column=body/)/xsp:expr/body The problem occurs when the xsp:expr contains tags (i.e. if I do the replace \n --- foo , then all is well, but \n --- foo/ will not work. ) rgds Anders - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Cocoon 2.1.2 on Jboss 4.0.0.DR2
Mike, That did the trick...things are working great. I also see performance improvements in latest version (2.1.2) over 2.1 while webapp deployment. Thanks a lot. Appreciated your inputs. -YKP [EMAIL PROTECTED] wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I got the same error not a week ago but with JBoss 3.2.2 and Tomcat 4.1.27. It's the Deli block messing things up. It's totaly unstable so if you uncomment the line that says exclude.block.deli=true and recompile you'll be fine... Good luck! /Mike - -Original Message- From: YKPrajapati [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 04, 2003 4:19 PM To: [EMAIL PROTECTED] Subject: Cocoon 2.1.2 on Jboss 4.0.0.DR2 I am trying to deploy the latest release of Cocoon i.e. 2.1.2 as webapp on JBoss 4.0.0.DR2 (built in Tomcat 4.1.24). I get following exception: 10:10:35,083 ERROR [STDERR] Caused by: com.hp.hpl.jena.rdf.arp.ParseException: {E201} Syntax error when processing EOF. Input to RDF parser ended prematurely. This is often related to an XML parser abort. Encountered EOF Was expecting one of: XML ELEMENT CONTENT start element rdf:RDF start element rdf:Description general start element tag 10:10:35,085 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.RDFParser.generateParseException(RDFParser.jav a:2208) 10:10:35,085 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.RDFParser.jj_consume_token(RDFParser.java:2095 ) 10:10:35,085 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.RDFParser.root(RDFParser.java:1325) 10:10:35,086 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.RDFParser.embeddedFile(RDFParser.java:1308) 10:10:35,086 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.ARPFilter.parse(ARPFilter.java:293) 10:10:35,087 ERROR [STDERR] at com.hp.hpl.jena.rdf.arp.JenaReader.read(JenaReader.java:227) 10:10:35,087 ERROR [STDERR] ... 129 more Can anybody help me figuring out what's wrong ? FYI: I was able to deploy Cocoon 2.1 webapp on same JBoss installation successfully. - -YKP - - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -BEGIN PGP SIGNATURE- Version: PGP 8.0.2 iQA/AwUBP6gHUYTNuy8mcLTPEQKURgCfbmttAczvc59z4u4/pWM/dg+xZt0AnjsW r+gwE9Eytf/7uIHNmSe+vlwo =bJuX -END PGP SIGNATURE- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: XSP/ESQL escaping
Yes, it is a pain, isn't it? XML just doesn't care to know about or deal with whitespace, and that really is a pain when whitespace IS content! To answer your question, it depends. If you just have a string (no XML markup in the database), then something like this is the easiest: xsp:logic String instring = esql:get-string column=body/; java.util.StringTokenizer st = new java.util.StringTokenizer(instring, \n, true); while (st.hasMoreTokens()) { String token = st.nextToken(); if (\n.equals(token)) { br/ } else { xsp:exprtoken/xsp:expr } } /xsp:logic If what is in your database contains XML markup, you'll need to do something more like this (mostly lifted from the ESQL logicsheet): xsp:logic String instring = esql:get-string column=body/; instring.replaceAll(\n, gt;br/); org.apache.cocoon.components.parser.Parser newParser = null; try { newParser = (org.apache.cocoon.components.parser.Parser) this.manager.lookup(org.apache.cocoon.components.parser.Parser.ROLE); InputSource __is = new InputSource(new StringReader(rawXML)); XSPUtil.include(__is, this.contentHandler, newParser); } catch (Exception e) { getLogger().error(Could not include page, e); } finally { if (newParser != null) this.manager.release((Component) newParser); } /xsp:logic -Christopher Anders Forsgren [EMAIL PROTECTED] 11/04/2003 05:55 PM Please respond to users To:[EMAIL PROTECTED] cc: Subject:Re: XSP/ESQL escaping Sigh :( Feels like a lot of work to make a linebreak a br/ tag...If I rephrase the question: What would be the simplest way of displaying the database strings with correct linebreaks in html (except using pre in the xsl)? thanks Anders
RE: How to write Serializer output to a temp file?
Try SourceWritingTransformer from the sitemap or else cocoon.processPipelineTo from a flowscript. Unico: I decided to bite the bullet and add flowscript to my appit worked perfectly! Thanks for the pointer! Andrzej Jan Taramina Chaeron Corporation: Enterprise System Solutions http://www.chaeron.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
problems with identity transformations and namespaces
ugh... more problems since upgrading to 2.1 Some of my source xml uses a namespace (it's mixed). The prefix is idf and my namespace declaration is like this: xsl:stylesheet version=1.0 xmlns:xsl=http://www.w3.org/1999/XSL/Transform; xmlns:idf=http://paraliansoftware.com/kompas/idf-1.0; I'm using two stylesheets in a row in my pipeline. If my first style sheet has an identity transformation like: xsl:template match=*|@*|comment()|processing-instruction()|text() xsl:copy xsl:apply-templates select=*|@*|comment()|processing-instruction()|text()/ /xsl:copy /xsl:template then I get an error saying: Namespace for prefix 'http://paraliansoftware.com/kompas/idf-1.0' has not been declared. It looks like it's mistaking the namespace for the prefix. Weird. I specified xalan as the transformer type, thinking it was XSLTC or something, but it's not. This used to work fine in 2.0.4. If I don't use an identity transformer everything is fine. any ideas? thanks again, Justin - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Obtaining the objectModel in javascript and flow.
There is some documentation that says I can get the objectModel using "cocoon.environment.objectModel" however if I use this in my _javascript_ I recieve a "The undefined value has no properties." message. Joe
How to write Serializer output to a temp file?
I've been searching the docs and wiki (plus googling), but can't seem to find anything on the best way to take the output of a serializer (in my case, PDF output) and store that in a temp file, with an auto-generated filename. Anythingalready out there in the way of actions/transformers/serializers that can do this? Andrzej Jan Taramina Chaeron Corporation: Enterprise System Solutions http://www.chaeron.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]