Hello,

I would like to have the startbutton(#startbutton) play my audio when clicked however if the user clicks the startbutton again i would like for my audio to stop until the user clicks the start button (#startbutton) again and at that point the audio will play from the begin.

As of now the code below is only working for the volume button which mutes and unmutes the volume.

Can anyone please help me???? I welcome and appreciate any suggestions or help.

This is the jQuery HTML5 audio library i am using (http://buzz.jaysalvat.com/)

Code:
$( function() {
    var $volume = $( '#volume' );
    var $start = $('#startbutton');
        
    // Buzz audio library

    buzz.defaults.formats = [ 'ogg', 'mp3' ];

    var Sound = new buzz.sound( 'audio/birthday' );

//startbutton control 
   
$start.click(function(){
    if (!buzz.isSupported()) {

    	}else{
    
    Sound.play().fadeIn( 5000 );
		}
    });

//volume button control

    $volume.click( function() {
    $("div.target").toggleClass("Sound On");
        if ( $( this ).hasClass( 'all' ) && $(this).attr("value") === "Sound On") {
             Sound.mute();
            $( this ).removeClass( 'all' ).addClass( 'none' );
            $(this).attr("value" , "Sound Off");
            
        } else if ( $( this ).hasClass( 'none' ) && $(this).attr("value") === "Sound Off" ) {
           
            Sound.unmute();
            $( this ).removeClass( 'none' ).addClass( 'all' );
            $(this).attr("value", "Sound On");
        }
        return false;
    });

});