Hi there!
I'm trying to retrieve the integer value in the string: #10
So I'm using the JS Split function
Is the code I'm using, but I keep getting a comma before my result..
in this case, my result is ",10"
What should I do?
Thanks!
Kind Regards
Matthew
P.S. I know that it's an array, but is there still anyway for me to get rid of the comma?
I'm trying to retrieve the integer value in the string: #10
So I'm using the JS Split function
Code:
<script type="text/javascript"> var str="#10"; document.write(str.split("#")); </script>
in this case, my result is ",10"
What should I do?
Thanks!
Kind Regards
Matthew
P.S. I know that it's an array, but is there still anyway for me to get rid of the comma?
Comment