mirror of
https://github.com/kataras/iris.git
synced 2025-12-24 05:17:03 +00:00
Add history for v3.0.0.-beta.2. Some fixes to subdomains listening on local 127.0.0.1. Change GetURI to ParseURI
Examples and e-book updated also.
This commit is contained in:
@@ -25,11 +25,10 @@ func (ctx *Context) Redirect(urlToRedirect string, statusHeader ...int) {
|
||||
|
||||
// RedirectTo does the same thing as Redirect but instead of receiving a uri or path it receives a route name
|
||||
func (ctx *Context) RedirectTo(routeName string, args ...interface{}) {
|
||||
s, ok := ctx.station.RouteByName(routeName).Parse(args...)
|
||||
if ok {
|
||||
s := ctx.station.RouteByName(routeName).ParseURI(args...)
|
||||
if s != "" {
|
||||
ctx.Redirect(s, StatusFound)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// Error handling
|
||||
|
||||
Reference in New Issue
Block a user