aspose file tools*
The moose likes JSP and the fly likes jsp tags inside javascript function Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "jsp tags inside javascript function" Watch "jsp tags inside javascript function" New topic
Author

jsp tags inside javascript function

shah rah
Ranch Hand

Joined: Jan 04, 2007
Posts: 124


list1 size is 10 records
list2 size is 10 records
list3 size is 13 records


if I pass 1 to the function. , I get first alert "list1 size = 10 "
but the last alert which displays the List size = as 13.


if I pass 2 to the function. , I get second alert "list2 = 10"
but the last alert which displays the List size = as 13.



what is the reason? how are jsp scriptlets executed inside javascript?
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61766
    
  67

Nothing to do with Struts. Moved to the JSP forum.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61766
    
  67

Originally posted by shah rah:
how are jsp scriptlets executed inside javascript?


They aren't. Scriptlets -- along with all other server-side mechanisms -- are executed on the server long before the HTML page is sent to the browser and the JavaScript executes.

Perhaps this article will be helpful.
[ April 16, 2007: Message edited by: Bear Bibeault ]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: jsp tags inside javascript function