Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Flash message and redirect #1529

Closed
Zemistr opened this issue Apr 20, 2015 · 3 comments
Closed

Flash message and redirect #1529

Zemistr opened this issue Apr 20, 2015 · 3 comments

Comments

@Zemistr
Copy link

Zemistr commented Apr 20, 2015

I have this code:

<?php
namespace App\Modules\BackModule\Presenter;

class SignPresenter extends BasePresenter {
    public function actionOut() {
        $this->user->logout();
        $this->flashMessage('message.info.signed_out', 'info');
        // $this->redirect('in');
    }
}

Without redirect is everything OK and I see the message.
But, if I use $this->redirect('in');, message is not showed.

@ghost
Copy link

ghost commented Apr 22, 2015

i am using $this->flashMessage("msg"); and it works fine..

2015-04-20 12:36 GMT+02:00 Martin Zeman notifications@github.com:

I have this code:

user->logout(); $this->addInfoMessage('message.info.signed_out'); $this->redirect('in'); }} Without redirect is everything OK and I see the message. But, if I use $this->redirect('in');, message is not showed. — Reply to this email directly or view it on GitHub https://github.com//issues/1529.

@Zemistr
Copy link
Author

Zemistr commented Apr 22, 2015

And with $this->redirect('...'); ? :)

@Zemistr
Copy link
Author

Zemistr commented Apr 26, 2015

Fixed! 😄

Never ever use $this->template->something = something in injectMethod! 😅

@Zemistr Zemistr closed this as completed Apr 26, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant