Javascript explode function |
|
|
|
Written by Administrator
|
giovedě, 21 agosto 2008 |
If you are looking for an Explode function in Javascript the Split
method of string class could be really helpful.
In the example below the three elements of a date are stored in the array a;
with the alert we are showing then the year.
<script language="Javascript">
var Dt = "01/08/2005";
a = Dt.split('/');
alert (a[2]);
</script>
|
Last Updated ( sabato, 23 agosto 2008 )
|