• 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: Bug with queryDictionary?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Bug with queryDictionary?


  • Subject: Re: Bug with queryDictionary?
  • From: George Domurot <email@hidden>
  • Date: Fri, 08 Jul 2011 09:30:59 -0700

Hi Pascal,

For your dictLangue() dictionary, how about creating it from this.context().request().formValues(), then adding your langue key+value?

Then update your urlPourDA to return everything up until the "?".

(Not tested, but I think that should work.)

-G


On Jul 8, 2011, at 8:34 AM, Pascal Robert wrote:

> I have a strange problem with query arguments. I have one link that I generated with:
>
> LienChangeLangue: WOHyperlink {
>  href = uriPourDA;
>  queryDictionary = dictLangue;
> }
>
> where "uriPourDa" is :
>
>  public String uriPourDA() {
>    return this.context().request().uri().replaceAll("[\\?|\\&]langue=[0-9]", "");
>  }
>
>  public NSDictionary<String, String> dictLangue() {
>    return !estFrancais() ? new NSDictionary<String, String>("1", "langue") : new NSDictionary<String, String>("2", "langue");
>  }
>
> The reason I'm using the URI is that I don't want people to change pages when they switch languages, I want them to be on the same page. That works fine when I don't have any other query arguments.
>
> But if I'm on another page that already have query arguments, like this:
>
> Hyperlink2: WOHyperlink {
> 	actionClass = "DirectAction";
> 	directActionName = "voirInfoMembre";
> 	?noMembre = numeroMembreSecret;
> }
>
> The generated URL is like this:
>
>  http://127.0.0.1/cgi-bin/WebObjects/Registre.woa/-52718/wa/voirInfoMembre?noMembre=KgsudeSxmbM=?langue=1
>
> So the second argument have a ? instead of a &. Is this a WO 5.3.3 bug? Wonder (latest legacy) is there too, but it's not a full Wonder app. _______________________________________________
> 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

 _______________________________________________
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

  • Follow-Ups:
    • Re: Bug with queryDictionary?
      • From: Pascal Robert <email@hidden>
References: 
 >Bug with queryDictionary? (From: Pascal Robert <email@hidden>)

  • Prev by Date: Re: AjaxInPlaceEditor expensive???
  • Next by Date: Re: Bug with queryDictionary?
  • Previous by thread: Bug with queryDictionary?
  • Next by thread: Re: Bug with queryDictionary?
  • Index(es):
    • Date
    • Thread