call server action from JavaScript

call server action from JavaScript

  

Hi,

I want to redirect to login page on session timeout.

I have a java script timer, from there i am going to trigger log out server action.

How to call server action from JavaScript.


Solution

Hi All,

Thanks i figured it out. Its working as expected. 

$('#"+LogoutDiv.Id+"').click();




Solution

Sekar wrote:

Hi All,

Thanks i figured it out. Its working as expected. 

$('#"+LogoutDiv.Id+"').click();




Hi, may I know, how do you implement the javascript? Is it on client-side? and you implement the javascript by (js in client-action/ js in screen / js in block / js in module / js in global / run as server? Where do you implement the javascript(on login's client action) ?

Thank you for your help