Skip to content

Commit

Permalink
Trigger download on file click.
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike Leone committed Aug 18, 2010
1 parent 7176b6a commit c0976dd
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions views/index.html.erb
Expand Up @@ -18,7 +18,7 @@
$(document).ready(function() {
initializeGoogleMap(lat, lon);
$('#file-browser').fileTree({ script: '/browse' }, function(file) {
alert(file);
window.location = "/download?file=" + escape(file);
});
});
</script>
Expand Down Expand Up @@ -70,7 +70,6 @@
<a href="javascript:slideToggle('files')" class="slider"><h2>File Browser<span id="files-icon"> (+) </span></h2></a>
<div class="blue-bar"></div>
<div id="files" class='condensed'>
Word.
<div id="file-browser"></div>
<div class="clear"></div>
</div>
Expand Down

0 comments on commit c0976dd

Please sign in to comment.