I have copied your js code dot for dot, letter by for letter, and semicolon for semicolon: Why is the second alert dialog box returning "undefined?"

$(document).ready(function(){
    //set up event handler for a_file...
    $('#a_file').change(function(){
        //alert('Something has changed');
        value = $(this).attr('value');
        alert(value);
    });
});


And why aren't you using "var value = "?