Original patch by Martin Panter, new policy fixes by me.
Attach a file by drag & drop or click to upload