title: How to pass array from java to javascript
body: <p>I want to pass a String Array From java to javascript. How can i acheive the same.
  using loadUrl, i am passing the Java String [] to a javascript Function. (String[] StringName--> ["hello", "hi"])</p>
  
  <p>But when i try to access the same in javascript</p>
  
  <pre><code>function displayString(StringName) {
      for(var i=0;i&lt;StringName.length;i++) {
           alert("path : " + StringName[i]);
      }
  }
  </code></pre>
  
  <p>i am expecting length to be 2 as there are only 2 items in the Java String[]. 
  But in javascript it is cominng as a String.
  Whatformat i have to use to get it as an array</p>