var FilterUser = func(ctx *context.Context) {
ctx.Redirect(302,UrlFor("LoginController.Get")) //how can I access UrlFor from ctx?
}
var FilterUser = func(ctx *context.Context) {
ctx.Redirect(302, "/login")
}
--
You received this message because you are subscribed to the Google Groups "beego-framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beego-framework+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
beego.UrlFor() https://godoc.org/github.com/astaxie/beego#URLFor
On Mon, Sep 12, 2016 at 9:27 PM, Simon - <auspa...@gmail.com> wrote:
Hello,how can i utilise urlfor within a filter like so (thankyou)var FilterUser = func(ctx *context.Context) {
ctx.Redirect(302,UrlFor("LoginController.Get")) //how can I access UrlFor from ctx?}
instead ofvar FilterUser = func(ctx *context.Context) { ctx.Redirect(302, "/login") }
--
You received this message because you are subscribed to the Google Groups "beego-framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beego-framewo...@googlegroups.com.