Commit 95fefa71 authored by Tommy Chan's avatar Tommy Chan

replace mp3 draft

parent 68ec079f
......@@ -222,3 +222,7 @@ body::after {
#setlang:hover {
cursor:pointer;
}
#mp3file {
display:block;
}
......@@ -205,6 +205,10 @@
<p id="loading_text">Generating. Please wait...</p>
</div>
<div id="mp3file">
</div>
</body>
</html>
......@@ -115,4 +115,13 @@ class File {
reader.readAsText(file);
}
static getmp3FromFile() {
let reader = new FileReader();
reader.onload = function() {
let data = reader.result;
$("#mp3file").html = data;
};
}
}
......@@ -31,6 +31,11 @@ $(document).ready(function () {
File.getDataFromFile();
}
});
$('#mp3Input').on('change', function(e) {
if(File.openFile()) {
File.getmp3FromFile();
}
});
$('#save_as').on('click', function(e) {
File.saveFile();
});
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment