• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Posting vars programatically from component to Direct Action
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Posting vars programatically from component to Direct Action


  • Subject: Re: Posting vars programatically from component to Direct Action
  • From: Arturo PĂ©rez <email@hidden>
  • Date: Sat, 17 Apr 2004 09:50:00 -0400

On Apr 17, 2004, at 8:49 AM, Randall Perry wrote:

Ah, well, there are lots of different ways to do that. Your technique
is a new
one to me (clever!). You can always do the typical thing of creating a
variable
(public or with appropriate setters/getters) and doing
WOComponent nextPage = pageWithName("theNextPage");
nextPage.takeValueForKey(val, "variableName");


Will this work when passing vars to a Direct Action? Does WO consider DA's a
'page'.

Yeah, what I was looking for was how to append form vars to a response so
they can be picked up by request in the receiving DA.

Ah, ok. You want do to this:

		NSMutableDictionary dict = new NSMutableDictionary();
		dict.setObjectForKey(user, "username");
		WOComponent red = pageWithName("WORedirect");
		red.takeValueForKey(context().directActionURLForActionNamed("myDA",
					dict), "url");
		return red;


That, obviously, redirects to your DA with the parameters passed in the NSMutableDictionary. The interface WOActionResults may be relevant to you in this case if you don't want a redirect.


You could go right ahead and use a WOHiddenField.
Ok. Should've checked for that. May be the most straightforward way to do
it. My purpose is to prevent the user from seeing the info.

Well, a curious (or malign) user can still see the data in a hidden field.
So, depending on how confidential you need that data to be this may or may not
be appropriate.
----
WO in philadelphia - wanna cheesesteak with that?
Please visit webobjects.meetup.com.
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.



  • Follow-Ups:
    • Re: Posting vars programatically from component to Direct Action
      • From: Randall Perry <email@hidden>
References: 
 >Re: Posting vars programatically from component to Direct Action (From: Randall Perry <email@hidden>)

  • Prev by Date: Re: Posting vars programatically from component to Direct Action
  • Next by Date: making associations between eomodeler files
  • Previous by thread: Re: Posting vars programatically from component to Direct Action
  • Next by thread: Re: Posting vars programatically from component to Direct Action
  • Index(es):
    • Date
    • Thread