Auto Forward when Current Sound is Done

Hi I’m using this code

mp3path = "http://2-cubed.net/v2/audio/";
 music = ["track1.mp3", "track2.mp3", "track3.mp3"];
 t = 0;
 function loadTrack(t) {
 	song = new Sound(this);
 	song.loadSound(mp3path+music[t], true);
 }
 nextBut.onRelease = function() {
 	t<music.length-1 ? t++ : t=0;
 	loadTrack(t);
 };
 loadTrack(t);

This plays track 1 when you enter the site but does not forward to track 2 when track 1 is done. So after looking around here i came up with this code to forward the tracks.

song.onSoundComplete = function(){//
 // soundobject.start(secondsoffset,loops);
 	t<music.length-1 ? t++ : t=0;
 	loadTrack(t);
 }

This works but it only goes from track 1 to track 2. It does not go from track 2 to track 3.

So my question is how do you automatically go through all the tracks. And provide stop, play, forward functionality.

Does anyone know how to do this?