Tuesday, 28 January 2014

call Javascript via Apex Class


 Visualforce Page:



escape - This attribute which allows the HTML Tags and Javascripts. if we make escape = true, the character escape sequence displays as written.


Apex Class

Below is the screen shot for classes, where will have the string variable and calling the javascript on that variable.

 


Output:

when you execute the above code, the below alert box will appear.





No comments:

Post a Comment