Bug with queryDictionary?
Bug with queryDictionary?
- Subject: Bug with queryDictionary?
- From: Pascal Robert <email@hidden>
- Date: Fri, 08 Jul 2011 11:34:29 -0400
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