You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Christina <le...@hotmail.com> on 2004/07/28 03:04:10 UTC

[CForm]widgets don't work with session?

I tried to fetch data from session in the validation sricpt of widgets. But it doesn't not work. 
Did I do something wrong or widgets are defined this way?
Here is the code which is working in flow, but it does't work in widgets. the error message is that "authContext is null"

 var contextMan = cocoon.getComponent(Packages.org.apache.cocoon.webapps.session.ContextManager.ROLE);
 var authContext = contextMan.getContext("authentication");
 var userNameFrag = authContext.getXML("/authentication/user_name");

Thank you for your information!