We have moved to Github. Please open tickets there.

Opened 17 months ago

Closed 11 months ago

Last modified 6 months ago

#4275 closed Enhancement (fixed)

forward_url after login

Reported by: ismayil.khayredinov Owned by: Harsha K
Priority: normal Milestone: Elgg 1.9.0
Component: Core Version: 1.8.2
Severity: minor Keywords:
Cc: brett@… Difficulty: trivial

Description

Can we add a config setting or a hook to override default forward_url for the login action?

Change History (11)

comment:1 Changed 17 months ago by brettp

The only reason not to is the pending events / hooks rewrite for 1.9.

I do see the use for this, though I definitely prefer a hook to a config setting.

comment:2 Changed 16 months ago by cash

  • Summary changed from forwar_url after login to forward_url after login

We need to develop guidance on when to use config settings and when to use hooks. Hooks offer more flexibility but have a higher overhead (more code to load and compile).

comment:3 Changed 16 months ago by ismayil.khayredinov

After reading some of the questions related to this in the community, I must agree with Brett on using a hook. People want to do all kinds of things: forward on first login only, forward when xyz criteria is met etc.

comment:4 Changed 16 months ago by cash

Do we implement this for 1.8.x or for 1.9?

comment:5 Changed 16 months ago by brettp

  • Difficulty set to trivial
  • Milestone changed from Needs Review to Elgg 1.9.0

1.9 is the target for the hooks rewrite. We made an exception for one hook because without it we couldn't properly support RSS. This hook would be a new feature, so I think it can wait. Please comment if anyone thinks we need more discussion.

comment:6 Changed 16 months ago by Harsha K

  • Owner set to Harsha K

comment:7 Changed 16 months ago by ismayil.khayredinov

After looking at the code again, it looks like we don't really need a hook. We could just add another hidden input to the login form and use it in action as a forward url.

comment:8 Changed 16 months ago by cash

Plugin hooks tend to be about changing how Elgg acts while views are about how Elgg looks. Because of that, I prefer the plugin hook over the view approach. What's the advantage of using the view?

comment:9 Changed 16 months ago by ismayil.khayredinov

Ah, sorry I wasn't clear. I was thinking about a solution that could be introduced in 1.8 still.

comment:10 Changed 11 months ago by Cash Costello

  • Resolution set to fixed
  • Status changed from new to closed

Fixes #4275 adds a login:forward, user hook - thanks to Ismayil

Changeset: daa9ce72199d6c354c874e94185f742a5bee8f2c

comment:11 Changed 6 months ago by hellekin

Could that fix be integrated in 1.8.10?

Note: See TracTickets for help on using tickets.