imediasun1,
<!DOCTYPE HTML>
<html>
<head>
<title>Untitled</title>
<script src="http://code.jquery.com/jquery-1.9.1.js"></script>
<style type="text/css">
.preview{
max-height: 200px;
max-width: 300px;
}
</style>
</head>
<body>
<input type="file" name="my-pic" id="file-field" class="image"/>
<div id="photo_copy" ></div>
<script>
$(function(){
$(".image").change(showPreviewImage_click);
})
function showPreviewImage_click(e) {
var $input = $(this);
var inputFiles = this.files;
if(inputFiles == undefined || inputFiles.length == 0) return;
var inputFile = inputFiles[0];
var img = $('<img/>',{'class':'preview'});
img.appendTo($('#photo_copy'))
var reader = new FileReader();
reader.onload = function(event) {
img.attr("src", event.target.result);
};
reader.onerror = function(event) {
alert("I AM ERROR: " + event.target.error.code);
};
reader.readAsDataURL(inputFile);
}
</script>
</body>
</html>