...

View Full Version : parsing a response object that contains string array.



vish_1x1
08-27-2010, 05:25 PM
Hello All,

I have a string array in a class file that contains 5 values, which I need to display on the jsp page.

but when I send it to the javascript it prints [Ljava.lang.String;@104f8b8 .

what do i do about it. I am a new to javascript.

Is there a way to get my array data from the response object.

Please help.

Old Pedant
08-27-2010, 08:25 PM
Nothing to do with JavaScript, per se.

The fault is in your Java code.

You *MUST* send that array as *TEXT*. That is, you will have to write Java code to convert the array into a form that JavaScript can understand.

You can *NOT* depend on Java to do the conversion for you. As you can see, it tries to convert the array to a standara Java serialized format, which nothing but Java will ever understand.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum