My plugin init function:

function init(){

    craft()->entries->onSaveEntry = function(Event $event) {

        //redirect to wanted url



Is there a fancy way to redirect to my plugin url if, for example the entry channel is jobs.

Or I have to use header() function. Thank you in advance.

2 Answers 2


You can use the HttpRequestService:


In Craft 3 we are looking at something similar to:


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.