Feature Request #4375

Remove redirect() from the Request class

Added by Kiall Mac Innes 5 months ago. Updated about 1 month ago.

Status:Closed Start date:12/31/2011
Priority:Normal Due date:
Assignee:Kiall Mac Innes % Done:

100%

Category:-
Target version:v3.3.0
Resolution:fixed Points:1

Description

Remove `Request::redirect()` and move it to the `HTTP` class, with a helper method in `Controller`

Associated revisions

Revision dca0a3c1
Added by Kiall Mac Innes 5 months ago

First stab at documentation for #4373, #4374, #4375 and #4377.

Refs #4373 / Refs #4374 / Refs #4375 / Refs #4377

Revision 0c6854b0
Added by Kiall Mac Innes 4 months ago

Merge pull request #194 from kohana/3.3/feature/RequestResponseCleanup

Fixes #4377, #4375, #4374, #4373, #4319

Revision 6e4d4a36
Added by Kiall Mac Innes 4 months ago

Fixup CodeBench controller for $request->redirect() changes. Refs #4375.

Revision 7719279b
Added by Kiall Mac Innes 4 months ago

Refs #4375 - Add redirect helper method

Revision 0a826ab6
Added by Kemal Delalic about 1 month ago

Refs #4375: redirect() parameter order

Revision a2a196fe
Added by Kemal Delalic about 1 month ago

Refs #4375: redirect() parameter order

Revision fc8ecf02
Added by Kemal Delalic about 1 month ago

Refs #4375: redirect() parameter order

Revision 0f149bce
Added by Kiall Mac Innes about 1 month ago

Add test for HTTP::redirect(). Refs #4375.

History

Updated by Kiall Mac Innes 5 months ago

Fixed in 669f3850608f823dd0966d003ce5e0053f77692a in the 3.3/feature/RequestResponseCleanup branch.

Should get merged to 3.3/develop soon.

Updated by Kiall Mac Innes 4 months ago

  • Status changed from Assigned to Closed
  • % Done changed from 0 to 100
  • Resolution set to fixed

Updated by Dmitry T. 4 months ago

  • Status changed from Closed to Feedback

What abount interchanging url and code parameters order? (code is optional, and url is required)

Updated by Jeremy Bush 4 months ago

I think I agree. I also think that we should encourage using HTTP::redirect() over $this->redirect() in controllers. I'm not even sure why we need the controller method.

Updated by dexcell - 3 months ago

Agree with Dmitry
parameter should be (url, code)

Updated by Kemal Delalic about 1 month ago

Pull request for the right parameter order: https://github.com/kohana/core/pull/233

Updated by Woody Gilk about 1 month ago

I think having `Controller::redirect` is a good idea, it allows users the ability to do some additional processing in the controller before redirecting.

Updated by Woody Gilk about 1 month ago

  • Status changed from Feedback to Closed

Merged Kemal's pull request.

Also available in: Atom PDF