contentDisposition set Content-disposition and response file
(file, name, dispositionType string)
| 459 | |
| 460 | // contentDisposition set Content-disposition and response file |
| 461 | func (ctx *HttpContext) contentDisposition(file, name, dispositionType string) (err error) { |
| 462 | ctx.Response().SetHeader(HeaderContentDisposition, fmt.Sprintf("%s; filename=%s", dispositionType, name)) |
| 463 | ctx.File(file) |
| 464 | return |
| 465 | } |
| 466 | |
| 467 | // Bind decode req.Body or form-value to struct |
| 468 | func (ctx *HttpContext) Bind(i interface{}) error { |
no test coverage detected