Re: referencing a form from JS

2012-05-12 Thread Arno Haase
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Thanks for that solution. It's not really a beauty, but it is way better than what I had previously ;-) Am 12.05.2012 21:46, schrieb Bryan Lewis: > We dealt with this issue by writing a javascript function to find > the mangled ID, based on the origin

Re: referencing a form from JS

2012-05-12 Thread Bryan Lewis
We dealt with this issue by writing a javascript function to find the mangled ID, based on the original ID. Maybe it'll help. We''l pass the ID of the containing element, often a div, to narrow the search. // Returns the ID of a component with a name beginning with the partialId. // When Tapestr

Re: referencing a form from JS

2012-05-12 Thread Arno Haase
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Thanks for posting this. I am not sure how it helps though - that piece of code assumes that the ID of the form is known while I try to figure out what the id of the form is. Am 12.05.2012 19:06, schrieb Lenny Primak: > Perhaps this will help: > >

Re: referencing a form from JS

2012-05-12 Thread Lenny Primak
Perhaps this will help: http://code.google.com/p/flowlogix/source/browse/tapestry-services/src/main/resources/com/flowlogix/web/mixins/DisableAfterSubmit.js Notice setSubmittingElement() call On May 12, 2012, at 10:45 AM, Arno Haase wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 >

Re: referencing a form from JS

2012-05-12 Thread Arno Haase
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 It does, unfortunately. When the form is initially rendered, Tapestry assigns it the id I assign in the .tml file. On subsequent *AJAX* refreshs, Tapestry appends some number to the initial id. I have ... in the .tml file, and a DOM insp

Re: referencing a form from JS

2012-05-12 Thread Thiago H. de Paula Figueiredo
On Sat, 12 May 2012 11:59:42 -0300, Arno Haase wrote: So referencing the form by its ID is out, since the form is assigned a new and different ID after each AJAX zone refresh. This won't happen if you give an explicit id (not t:id, id) for the form. -- Thiago H. de Paula Figueiredo Indepen

referencing a form from JS

2012-05-12 Thread Arno Haase
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I want a JavaScript event handler to programatically submit a form. This works well using form.performSubmit() (I want Tapestry's AJAX submit). The tricky part is that the form being submitted is part of the zone that is being refreshed by the submit,

Re: Null Pointer Exception

2012-05-12 Thread Felix Gonschorek
i am getting this error (NPE in FilterInputStream.close()) when a bot or crawler tries to access an invalid asset path. when i have a png like this: http://www.myhhost.de/assets/59f0e7531f25d4c0/some/subfolder/gfx/logo.png crawlers often try to crawl the "folders" of this path: http://www.myhho

Re: Joining tapestry exception handling

2012-05-12 Thread Felix Gonschorek
you have to pay attention not to let your log4j smtp logger append in "sync" mode - your system will stall, until the logging message has been sent (which could be a few seconds, depending how you send your mail). your have to use an async logger. this is an example configuration i use in my system

Re: Lightweight TapestryTools update site

2012-05-12 Thread Igor Drobiazko
Great job, Gavin. I'm going to update on monday, test it and provide my feedback immediately. On Sat, May 12, 2012 at 2:34 PM, Gavin Lei wrote: > Hi all, > > I have improved TapestryTools' attributes/methods support in content > assist of TML editor, and add message support messages support. >

Re: Joining tapestry exception handling

2012-05-12 Thread Bob Harner
You couldd also have the logging system send the emails. Log4j can handle this quite easily. On May 11, 2012 7:35 AM, "Dmitry Gusev" wrote: > Try this: > > http://tapestry.apache.org/overriding-exception-reporting.html > > On Fri, May 11, 2012 at 3:21 PM, jeczmien >wrote: > > > I need advice how

Re: Lightweight TapestryTools update site

2012-05-12 Thread Gavin Lei
Hi all, I have improved TapestryTools' attributes/methods support in content assist of TML editor, and add message support messages support. When type ${message: and then cmd + space, all the available messages for the page will be suggested in the content assist list. Fix three issues: [1] htt

How to prevent form being submit in mixins when validation failed

2012-05-12 Thread Fight Ice
I have a mixins to validate the username field and email field using ajax. but in my ValidateField.js file, i use: Event.observe(this.sourceField.form,'submit',this.doSubmit.bindAsEventListener(this)); doSubmit:function(event){ return this.state; } but the form still submit even the "d

Re: How to add an URL-anchor to a redirect?

2012-05-12 Thread René Bernhardsgrütter
Hi Thaigo, thanks for you answer! Use PageRenderLinkSource to create a Link to the page you want, add the query parameters, then return it in your event handler method. That's it. I didn't know PageRenderLinkSource, so I couldn't create the link that easily. For other users: @Inject