Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

how to use request.setAttribute in javascript function.

843836Sep 26 2003 — edited Sep 26 2003
Here is my scenario.

I am storing all open windows handles in the array( javascript ).
I want to send this array to the servlet for which I need to do
request.setAttribute("jsArray", windowArray);

I am getting all kinds of errors while writing above statement in the javascript function.

Here is my code:

function save_javascript_array(){
<% request.setAttribute("jsArray", %> + winArray + <% ); %>
document.forms[0].action="/NASApp/inv/AuditServlet";
document.forms[0].submit();
}

Thanks in advance.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 24 2003
Added on Sep 26 2003
4 comments
3,880 views