Re: Cocoon Plumber
Thanks a lot! I look forward to trying this out as soon as I can... cheers, —ml— - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How can i acces to Class from a Class name ?
> > Instead you could also use > > var perfil = hs.createQuery("mypackage.MyClass as > myClass where id = " + > id).uniqueResult(); > > Note that in Java you would normally do something > like > > MyClass myClass = (MyClass) > hs.createQuery("mypackage.MyClass as myClass > where id = " + id).uniqueResult(); > > This is required since createQuery returns an Object > and not a MyClass. > This could mean that you would need another class > that in turn would > query the database. > I used this and it works, but i think to access the first item in the list is not very elegant ... var perfil = getById("mypackage.MyClass", id); function getById(c, id){ return hs.find("from " + c + " where id = " + id).get(0); } __ LLama Gratis a cualquier PC del Mundo. Llamadas a fijos y móviles desde 1 céntimo por minuto. http://es.voice.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Xsp logicsheet method invocation
Thanks, That seems like a lot of work since I already have a nice java utility that I was hoping to use as my generator to create xml from database data. How is something like this usually done with Cocoon? i.e. My generator already produces regular xml which I'd like to feed to an xsl stylsheet. I guess I could do it using files instead of trying to pass it directly from generator to transformer, but that seems kind of kludgy. Jeff -Original Message- From: Tobia [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 06, 2007 8:35 AM To: users@cocoon.apache.org Subject: Re: Xsp logicsheet method invocation Schmitz, Jeffrey A wrote: > My logicsheet function which serves as my generator produces (and > returns) an xml string. Why, before it gets passed to my xsl > transformer are all the angle brackets converted to < and >, and > is there a way to stop this behavior? Because your "xml string" is just a text node (a string) inside the xml document you're generating. You cannot write literal < and > in xml text nodes, because they delimit tags, so Cocoon escapes them for you. The only reason you would need to output literal < and > is to create output elements, but that is done with and . See the samples in src/blocks/xsp/samples/java/ "P".toLowerCase() left Hello generates: Hello Tobia - 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 logicsheet method invocation
Schmitz, Jeffrey A wrote: > My logicsheet function which serves as my generator produces (and > returns) an xml string. Why, before it gets passed to my xsl > transformer are all the angle brackets converted to < and >, and > is there a way to stop this behavior? Because your "xml string" is just a text node (a string) inside the xml document you're generating. You cannot write literal < and > in xml text nodes, because they delimit tags, so Cocoon escapes them for you. The only reason you would need to output literal < and > is to create output elements, but that is done with and . See the samples in src/blocks/xsp/samples/java/ "P".toLowerCase() left Hello generates: Hello Tobia - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Losing flowscript variables values
I have this problem after upgrading from 2.1.7 to 2.1.9. 1. Flowscript stores request attrs to vars. 2. Flowscript calls function in another script 3. If neccesary a SendPageAndWait in the other script 4. Back in flowscript vars are null It looks as if the vars are getting nulled from calling the function or from the SendPageAndWait. Any suggestions? Thanks, Gary - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Xsp logicsheet method invocation
Ok, let me try to phrase it simpler. My logicsheet function which serves as my generator produces (and returns) an xml string. Why, before it gets passed to my xsl transformer are all the angle brackets converted to < and >, and is there a way to stop this behavior? I've searched for an answer and read through all the xsp/logicsheet stuff and don't see this described anywhere. Thanks, Jeff -Original Message- From: Schmitz, Jeffrey A Sent: Monday, February 05, 2007 3:12 PM To: users@cocoon.apache.org Subject: RE: Xsp logicsheet method invocation In a related question, my java code is generating XML code to return to the cocoon pipeline via the xsp generator. However, somewhere along the way all the angle brackets are getting converted into < and >, before getting sent to my xsl transformer. Is there a way to make cocoon NOT do this conversion on my generator output so that my xsl transform will properly transform the code? Thanks Jeff -Original Message- From: Schmitz, Jeffrey A Sent: Monday, February 05, 2007 1:49 PM To: users@cocoon.apache.org Subject: Xsp logicsheet method invocation Hello, I'm trying use and xsp generator that uses a logic sheet, and I'm almost there, but there's something I don't understand. For some reason, in my logicsheet xsl file, I have to put xml tags around my java function invocation, otherwise, when I try to invoke the associated sitemap pipeline, cocoon returns immediately with no data, without ever invoking my function. Here's what I have to make my logicsheet xsl look like in order to get it to run: runfunc() However, I don't want the junkTags returned as I don't want to process them in my xml transform. I'd rather be able to just do: runfunc() Here is the xsp file that references the logicsheet xsl. http://apache.org/xsp"; xmlns:util="http://apache.org/xsp/util/2.0"; xmlns:DiagML="http://www.boeing.com/MyTag";> Again, it works fine as long as I have the junkTag's, so I must have everything configured ok for the logicsheet. Thanks, jeff - 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: Preventing "ambiguous imports" in flowscript
Hi, Niels van Kampenhout wrote: Lionel Barth wrote: I had the same problem updating from 2.1.7 to 2.1.10. I found a solution in http://wiki.apache.org/cocoon/JavascriptForJavaProgrammers : "*Note:* Be sure to make importPackage(...) the first code line in your script, or you may get an "Ambiguous import" error on the second and following runs of your script when attempting to reference an imported class." Thanks Lionel, I also found this Wiki page and tried that, but it doesn't really help. The strange thing is this: the application uses an ajax-like javascript framework to load pages in the background and display them in the browser without page reloading. If I request those different pages separately in the browser, everything works fine, and even more weird, after that the complete application also works fine without the ambiguous import errors. I only get them when I load the complete application directly after starting Cocoon. I think I worked around the problem by avoiding "importPackage()" altogether and importing only the actual classes with "importClass()" instead. Thanks, Niels - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: manager.lookup fails without exception
On Monday 05 February 2007 17:22, Tobia wrote: > Tilman Rassy wrote: > > dbHelper = (DbHelper)this.manager.lookup(DbHelper.ROLE); > > > > this fails for some reason, but no exception is thrown. The server > > simply replies with response code 500. > > I cannot help you with your code, but I can tell you that in some cases > the exception is only displayed in the console where you started Cocoon. > > Start cocoon.sh (or .bat as appropriate) and redirect stdout/stderr to > an additional log file, or leave the terminal open. Thank you for your advice. Meanwhile, we descovered why the lookup fails - a jar was lacking in WEB-INF/lib, so a class could not be loaded - but we still do not understand what happens to the exception. Perhaps it has something to do with the element in the pipeline. Best regards, Tilman - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Preventing "ambiguous imports" in flowscript
Lionel Barth wrote: I had the same problem updating from 2.1.7 to 2.1.10. I found a solution in http://wiki.apache.org/cocoon/JavascriptForJavaProgrammers : "*Note:* Be sure to make importPackage(...) the first code line in your script, or you may get an "Ambiguous import" error on the second and following runs of your script when attempting to reference an imported class." Thanks Lionel, I also found this Wiki page and tried that, but it doesn't really help. The strange thing is this: the application uses an ajax-like javascript framework to load pages in the background and display them in the browser without page reloading. If I request those different pages separately in the browser, everything works fine, and even more weird, after that the complete application also works fine without the ambiguous import errors. I only get them when I load the complete application directly after starting Cocoon. Suggestions, anyone...? Thanks, Niels - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
multivaluefield using the 'double-listbox' and AJAX
Hi, Does anyone already fixed the mutivaluefield in double-listbox styling, in combination with AJAX in cocoon 2.1.9 or 2.1.10? Grtz, Joost - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]