var $date = '15-09-2001';
alert($date);
$date = $date.replace(/(\d+)-(\d+)-(\d+)/, '$3/$2/$1');
alert($date);
Neat. Except that you should have explain to Bey a little bit more about RegExp. You gave him the fish, ok, but you should have given him the rod, as well
Neat. Except that you should have explain to Bey a little bit more about RegExp. You gave him the fish, ok, but you should have given him the rod, as well
LOL! I was going to say the same thing. The rod and some fishing lessons.
Bookmarks