Re: Combination of ERXApplication.replaceApplicationPath, Session-Cookies and Ajax doesn't work

2015-11-08 Thread CHRISTOPH WICK | i4innovation GmbH, Bonn
Hello Samuel,

you saved my day. Thx a lot.

C.U.CW
--
The three great virtues of a programmer are Laziness, Impatience and Hubris. 
(Randal Schwartz)

> On 08.11.2015, at 15:58, Samuel Pelletier  wrote:
> 
> Hi Christoph,
> 
> All my apps are like this. The only things special I see if you need to 
> override domainForIDCookies() in the Session class but I  think it is also 
> required for non Ajax app. Does non Ajax request works ?
> 
> My generic solution is this because of an app that serve multiple domains :
> 
> Add this attribute to the session class:
>   private String cookieDomainID;
> 
> And overide thid method:
>   @Override
>   public String domainForIDCookies() {
>   if (cookieDomainID == null) {
>   cookieDomainID = super.domainForIDCookies();
>   cookieDomainID = 
> application()._rewriteURL(cookieDomainID);
>   log.warn("cookieDomain: "+ cookieDomainID);
>   }
>   return cookieDomainID;
>   }
> 
> 
> Samuel
> 
> 
>> Le 2015-11-07 à 22:09, CHRISTOPH WICK | i4innovation GmbH, Bonn 
>>  a écrit :
>> 
>> Hi list,
>> 
>> has anyone the combination of
>> 
>> - ERXApplication.replaceApplicationPath and
>> - SessionID stored in cookies and
>> - Ajax (from Wonder's Ajax-Framework)
>> 
>> successfully working in combination?
>> 
>> I don't get it up and running on a test-server. In my case each click on a 
>> submit button in a form containing Ajax-Update-Containers is returning to 
>> the "Main"-page. Somewhere in the whole stack, WebObjects forgets the 
>> session and starts as if a new session was created.
>> 
>> And help is welcome.
>> Thx, C.U.CW
>> --
>> The three great virtues of a programmer are Laziness, Impatience and Hubris. 
>> (Randal Schwartz)
>> 
>> ___
>> Do not post admin requests to the list. They will be ignored.
>> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
>> Help/Unsubscribe/Update your Subscription:
>> https://lists.apple.com/mailman/options/webobjects-dev/samuel%40samkar.com
>> 
>> This email sent to sam...@samkar.com
> 



signature.asc
Description: Message signed with OpenPGP using GPGMail
 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Combination of ERXApplication.replaceApplicationPath, Session-Cookies and Ajax doesn't work

2015-11-08 Thread Samuel Pelletier
Hi Christoph,

All my apps are like this. The only things special I see if you need to 
override domainForIDCookies() in the Session class but I  think it is also 
required for non Ajax app. Does non Ajax request works ?

My generic solution is this because of an app that serve multiple domains :

Add this attribute to the session class:
private String cookieDomainID;

And overide thid method:
@Override
public String domainForIDCookies() {
if (cookieDomainID == null) {
cookieDomainID = super.domainForIDCookies();
cookieDomainID = 
application()._rewriteURL(cookieDomainID);
log.warn("cookieDomain: "+ cookieDomainID);
}
return cookieDomainID;
}


Samuel


> Le 2015-11-07 à 22:09, CHRISTOPH WICK | i4innovation GmbH, Bonn 
>  a écrit :
> 
> Hi list,
> 
> has anyone the combination of
> 
> - ERXApplication.replaceApplicationPath and
> - SessionID stored in cookies and
> - Ajax (from Wonder's Ajax-Framework)
> 
> successfully working in combination?
> 
> I don't get it up and running on a test-server. In my case each click on a 
> submit button in a form containing Ajax-Update-Containers is returning to the 
> "Main"-page. Somewhere in the whole stack, WebObjects forgets the session and 
> starts as if a new session was created.
> 
> And help is welcome.
> Thx, C.U.CW
> --
> The three great virtues of a programmer are Laziness, Impatience and Hubris. 
> (Randal Schwartz)
> 
> ___
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> https://lists.apple.com/mailman/options/webobjects-dev/samuel%40samkar.com
> 
> This email sent to sam...@samkar.com


 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Combination of ERXApplication.replaceApplicationPath, Session-Cookies and Ajax doesn't work

2015-11-07 Thread CHRISTOPH WICK | i4innovation GmbH, Bonn
Hi list,

has anyone the combination of

- ERXApplication.replaceApplicationPath and
- SessionID stored in cookies and
- Ajax (from Wonder's Ajax-Framework)

successfully working in combination?

I don't get it up and running on a test-server. In my case each click on a 
submit button in a form containing Ajax-Update-Containers is returning to the 
"Main"-page. Somewhere in the whole stack, WebObjects forgets the session and 
starts as if a new session was created.

And help is welcome.
Thx, C.U.CW
--
The three great virtues of a programmer are Laziness, Impatience and Hubris. 
(Randal Schwartz)



signature.asc
Description: Message signed with OpenPGP using GPGMail
 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com