Two things...
1. you never call your
playPause
function, so to play you must use the mouse...
2. click on the button not only runs the bitrate function but also post-back to the server side, and that resets the page...
You may change your code like this...
<button onclick="bitrates(); return false;">play</button>
That
return false;
will stop the post-back...