1

I am working with Craft 3 and in my controller, I am trying to do this

$this->redirect('https://foobar.test');

But it is throwing me back to the root url of my craft site. I am confused, what else do I need to do?

2

Forgot to add the return keyword :(

return $this->redirect('https://foobar.test');

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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