var both = "20/06-2012$23:06=2012";
both = both.replace( /[^\d]/g,"-" ); // convert all non-digits to dash
var temp = both.split("-");
if ( temp.length != 6 ) { alert("kablooey! invald"); }
var dateA = temp.slice(0,3).join("/");
var dateB = temp.slice(3).join("/");
__________________
An optimist sees the glass as half full.
A pessimist sees the glass as half empty.
A realist drinks it no matter how much there is.