-
1. Re: JSFunction
fmarwede Dec 17, 2007 2:08 AM (in response to sankar_mariappan)Hi,
when you wanna access a client method from server side: this is not possible at all. Whenever you want a response from server there must be a request from client side first. Forget a 'server side request'.
The solution for you: polling. Use direct javascript polling (setInterval) with an AJAX call, or a4j:poll/a4j:push. -
2. Re: JSFunction
sankar_mariappan Dec 17, 2007 4:47 AM (in response to sankar_mariappan)Hi,
Thank you very much for your response..
I have a problem, i want navigate automatically when user auto logoff of the system...
Any way to navigate automatically when user auto logoff in JSF ?
Thanks & Regards,
Sankar. -
3. Re: JSFunction
fmarwede Dec 17, 2007 5:16 AM (in response to sankar_mariappan)Doesn't it work the 'normal way' - by defining some rules in navigation config. For example in mine I have:
<navigation-rule> <from-view-id>/restricted/modalPanels/quitpanel.xhtml</from-view-id> <navigation-case> <from-outcome>logout</from-outcome> <to-view-id>/login.xhtml</to-view-id> <redirect/> </navigation-case> </navigation-rule>
Okay, that is obviously not automatically, but I guess, something like this will work also for auto log off. Did you try that? (You have to set from-view-id to the page the auto log off goes from) -
4. Re: JSFunction
sankar_mariappan Dec 18, 2007 1:32 AM (in response to sankar_mariappan)Hi, this works when firing a link or any., But i wanna navigate automatically to other page when auto logoff of a user session...
Please tell me any way to implement....
I am using 4 Frame inside of our Application Main page so i am not having knowledge to implement the auto logoff. Otherwise we can use Filter.
I tried but its not working properly reason why when auto logoff it will show the session expired page in same window in another frame.
This is my problem to implement the autologoff... -
5. Re: JSFunction
cameronr Dec 18, 2007 2:12 AM (in response to sankar_mariappan)This might help. http://labs.jboss.com/file-access/default/members/jbossrichfaces/freezone/docs/devguide/en/html/ArchitectureOverview.html#RequestErrorsAndSessionExpirationHandling
In particular the onExpired() method. You could handle this in a frame and use javascript to go up to the parent document and display a logout message, or navigate to some different page.
Cheers
Cameron -
6. Re: JSFunction
cameronr Dec 18, 2007 2:14 AM (in response to sankar_mariappan)Oh - forgot to mention onExpired() will be called next time the user performs any ajax request. It won't 'automatically' be called without any user interaction but it is about as close as you can get.
-
7. Re: JSFunction
sankar_mariappan Dec 18, 2007 4:33 AM (in response to sankar_mariappan)Hi,
There is no function name in javascript and which attribute to call the onExpired() method -
8. Re: JSFunction
sankar_mariappan Dec 18, 2007 5:09 AM (in response to sankar_mariappan)This is great idea.,
Thank you very much for ur response
Can you tell me how to use onExpired() .
I am have no knowledge on this..
I am trying to auto logoff and this is very important issue for me...
thanks a lot.....