I've been googling for a few hours on this with no luck.

im wondering if its possible to have a <input type="file"> and pass that data into a variable (and then execute it as code using eval())

like
Code:
mainLevelData=document.getElementById('file1').fileContents;
or what an alternative would be to achieve this. (it has to be some kind of dialouge to choose file from)