title: not able to split english text from arabic text using javascript
body: <p>I was working on some module where I needed to grab the text from <code>html</code> <code>select</code> box and place the split text in further two text boxes(one for arabic and other for english). </p>
  
  <p>HTML SELECT box contains a text similar to "عربى::::arabic". Now when I tried to split this whole text from "::::" I got values on both indexs. But while placing them in textboxes, I was only able to place 0th i.e. عربى text. I wasn't able to paste english value to english textbox. HTML select box and textboxes picture:</p>
  
  <p><strong>JS code</strong></p>
  
  <pre><code>function process() {
                var x = $("#categoryNameId option:selected").text();
                var values =  x.split("::::");
                alert(values[0]);
                alert(values[1]);
  
                document.getElementById("categoryNameArId").value=values[0]; // arabic textbox
                document.getElementById("categoryNameId").value=values[1]; // english textbox
  
              }
  </code></pre>
  
  <p>Is there any way to paste splited English value to a textbox meant for English.</p>