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

Add event to acp_main.php to notice admin #2775

Closed
wants to merge 3 commits into from

Conversation

ForumHulp
Copy link
Contributor

Like the notice on the main acp page, extensions should be able to generate their own notice for the admin. There is already a html event acp_main_notice_after so it should be able to do their own notice.

http://area51.phpbb.com/phpBB/viewtopic.php?f=111&t=45987

Like the notice on the main acp page, extensions should be able to generate their own notice for the admin. There is already a html event acp_main_notice_after so it should be able to do their own notice.

http://area51.phpbb.com/phpBB/viewtopic.php?f=111&t=45987
* @since 3.1.0-RC3
*/
$vars = array();
extract($phpbb_dispatcher->trigger_event('core.acp_main_notice', compact($vars)));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use $phpbb_dispatcher->dispatch('core.acp_main_notice'); if there are not parameters (without the $vars = ... and without the extract())

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok done

@dhruvgoel92
Copy link
Contributor

Please read through https://wiki.phpbb.com/Git#Branch_Names and correct branch name and commit messages. Also if there is no existing ticket for this patch at tracker.phpbb.com/issues/ please feel free to open a new one. Thanks for the patch, it looks good to me.

* @event core.acp_main_notice
* @since 3.1.0-RC3
*/
$phpbb_dispatcher->trigger_event('core.acp_main_notice');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dispatch instead of trigger_event

As Joas Schilling asked
@nickvergessen
Copy link
Contributor

Merged with 64f2d77

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

Successfully merging this pull request may close these issues.

3 participants