Documentation
¶
Overview ¶
Package download handles the client file downloads.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNone = errors.New("not found") ErrStat = errors.New("file download stored on this server cannot be found") )
Functions ¶
func Checksum ¶
Checksum serves the checksums for the requested file. The response is a text file named "checksums.txt" with the checksum and filename. The id string is the UID filename of the requested file.
func LastModified ¶ added in v1.9.11
LastModified returns the last modification date and time that can be used with a HTTP Last-Modified [header].
RFC1123 = "Mon, 02 Jan 2006 15:04:05 MST"
example output: Wed, 21 Oct 2015 07:28:00 GMT [header]:https://developer.mozilla.org/en-US/docs/Web/HTTP/Reference/Headers/Last-Modified
Types ¶
type Download ¶
type Download struct {
Dir dir.Directory // Dir is the absolute path to the download directory.
Inline bool // Inline is true if the file should attempt to display in the browser.
}
Download configuration.
type ExtraZip ¶ added in v0.9.0
type ExtraZip struct {
Extra dir.Directory // Extra is the absolute path to the extra directory.
Download dir.Directory // Download is the absolute path to the download directory.
}
ExtraZip configuration.
Click to show internal directories.
Click to hide internal directories.