Re: WOPopupButton and WOForm's <href>
Re: WOPopupButton and WOForm's <href>
- Subject: Re: WOPopupButton and WOForm's <href>
- From: Sacha Mallais <email@hidden>
- Date: Wed, 20 Jul 2005 16:18:44 -0700
On Jul 20, 2005, at 3:39 PM, Baiss Eric Magnusson wrote:
I had a WOHyperLink which would go play a movie when clicked on.
Now I want the movie to be selected from a WOPopupButton populated
with movie file names. I set the WOPopupButton's additional
<onChange> binding to <"submit();"> and bound the WOForm's <href>
attribute to a method returning a String, which is a concatenation
of the WOPopupButton's <selection> attribute and a path.
But if I set the <href> attribute of a WOForm, the RR look is not
called during Submit and the re-direction occurs to the value of
the <href> which is set at the time the page is first rendered,
when the file name is null, not at the time of the Submit.
I can't find a way to simulate the action of a WOHyperLink from the
WOForm's bindings.
Hmm... I don't know how to simulate a hyperlink, but I do know how to
simulate a form submit, which is what you appear to be trying to do.
First change your onChange event to: "this.form.submit(); return
false;" I'm not sure why the "return false;" is required, but AFAIK
it is. Second, don't use the href binding of the form, use the
action binding instead, which will call a normal action on your page.
Then use your action method to generate the response you would like,
including the correct content type, etc. and Bob's your uncle.
HTH,
sacha
--
Sacha Michel Mallais - 800 lb. gorilla
Global Village Consulting Inc.: http://www.global-village.net/
Bottom posting is your friend:
http://www.river.com/users/share/etiquette/
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden