Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
jquery-upchunk's send function
send = (chunk, url) =>
fd = new FormData
fd.append(@opts.file_param, chunk)
xhr = new XMLHttpRequest'POST', url, true)
xhr.send(fd)'/tmp/' + current_user.lowname + '_' + params[:hash], 'a') do |upload|
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment