Notification Is Not Showed After Redirecting As Expected

When I am at the admin side, ı clik a button and making it them go to index.php and come back after doing something at at frontend. But after coming to admin I can not make fn_set_notification() work.


<br />
return array(CONTROLLER_STATUS_REDIRECT, Registry::get('config.admin_index')."?dispatch=orders.manage", 'A', 'http');<br />
		fn_set_notification('N', __('notice'), "something to notice.....");<br />

```<br />
<br />
It doesn't work. Browser shows the notification not at the admin, but at FRONTEND. After the process I click frontof the website; I can see the notification which is expected to showed at admin after redirecting.

I think, you should call the fn_set_notification function before the return… string as the php code is not executed after this line

I understand that the issue is based on placing the file under controllers/frontend/myfile.php Becuase the file is in the frontend folder, all operates work at frontend.

hi,



you should use workaround:


  1. instead of 2 lines use this one:

return array(CONTROLLER_STATUS_REDIRECT, Registry::get('config.admin_index')."?dispatch=orders.manage&show_notice=1", 'A', 'http');



2. edit file “app/controllers/backend/orders.php” or “app/addons/MY_ADDON/controllers/backend/orders.post.php” (if you use module) and add the code in the end:

if ($mode == 'manage' && !empty($_REQUEST['show_notice'])) {
fn_set_notification('N', __('notice'), "something to notice.....");
}




Let us know if it helps



Best regards,

WSA team