Hostname
Returns the hostname derived from the Host HTTP header.
func (c *Ctx) Hostname() string
// GET http://google.com/search
app.Get("/", func(c *fiber.Ctx) error {
c.Hostname() // "google.com"
// ...
})
Returned value is only valid within the handler. Do not store any references.
Make copies or use theImmutable
setting instead. Read more…