Last weekend I was working on some code and needed to pass two values to a client-side JavaScript function.
No problem except that one of the values for the function was going to be the ID of an XPage component. Since XPage ids are generated dynamically, I used the nifty getClientId() SSJS function to get the ID of the component but I ran that function in the Client-Side JavaScript to be run when a button was clicked.
Using SSJS in CSJS is very handy and sometimes the only way to do what you need to do within an XPage.
Hello, on other way around is it possible? passing CSJS variable to SSJS? inside "#{javascript: }";
I have not found a direct way to do that. You can write a value to a hidden field using CSJS then do a partial refresh and the refresh can use that info in SSJS.