MCPcopy Create free account
hub / github.com/devfeel/dotweb / Inline

Method Inline

context.go:456–458  ·  view source on GitHub ↗

Inline sends a response as inline, opening the file in the browser. if file not exists, response 404 for issue #39

(file, name string)

Source from the content-addressed store, hash-verified

454// if file not exists, response 404
455// for issue #39
456func (ctx *HttpContext) Inline(file, name string) (err error) {
457 return ctx.contentDisposition(file, name, "inline")
458}
459
460// contentDisposition set Content-disposition and response file
461func (ctx *HttpContext) contentDisposition(file, name, dispositionType string) (err error) {

Callers

nothing calls this directly

Calls 1

contentDispositionMethod · 0.95

Tested by

no test coverage detected