diff options
author | Maat <maat-pub@mageia.biz> | 2020-05-08 18:29:30 +0200 |
---|---|---|
committer | Maat <maat-pub@mageia.biz> | 2020-05-08 21:36:04 +0200 |
commit | 36bc1870f21fac04736a1049c1d5b8e127d729f4 (patch) | |
tree | 9d102331eeaf1ef3cd23e656320d7c08e65757ed /tests/event/fixtures/trigger_many_vars.test | |
parent | 8875d385d0579b451dac4d9bda465172b4f69ee0 (diff) | |
parent | 149375253685b3a38996f63015a74b7a0f53aa14 (diff) | |
download | forums-36bc1870f21fac04736a1049c1d5b8e127d729f4.tar forums-36bc1870f21fac04736a1049c1d5b8e127d729f4.tar.gz forums-36bc1870f21fac04736a1049c1d5b8e127d729f4.tar.bz2 forums-36bc1870f21fac04736a1049c1d5b8e127d729f4.tar.xz forums-36bc1870f21fac04736a1049c1d5b8e127d729f4.zip |
Merge remote-tracking branch 'upstream/prep-release-3.1.11'
Diffstat (limited to 'tests/event/fixtures/trigger_many_vars.test')
-rw-r--r-- | tests/event/fixtures/trigger_many_vars.test | 65 |
1 files changed, 65 insertions, 0 deletions
diff --git a/tests/event/fixtures/trigger_many_vars.test b/tests/event/fixtures/trigger_many_vars.test new file mode 100644 index 0000000000..5e0720d13b --- /dev/null +++ b/tests/event/fixtures/trigger_many_vars.test @@ -0,0 +1,65 @@ +<?php + + /** + * This event allows you to modify template variables for the posting screen + * + * @event core.posting_modify_template_vars + * @var array post_data Array with post data + * @var array moderators Array with forum moderators + * @var string mode What action to take if the form is submitted + * post|reply|quote|edit|delete|bump|smilies|popup + * @var string page_title Title of the mode page + * @var bool s_topic_icons Whether or not to show the topic icons + * @var string form_enctype If attachments are allowed for this form + * "multipart/form-data" or empty string + * @var string s_action The URL to submit the POST data to + * @var string s_hidden_fields Concatenated hidden input tags of posting form + * @var int post_id ID of the post + * @var int topic_id ID of the topic + * @var int forum_id ID of the forum + * @var bool submit Whether or not the form has been submitted + * @var bool preview Whether or not the post is being previewed + * @var bool save Whether or not a draft is being saved + * @var bool load Whether or not a draft is being loaded + * @var bool delete Whether or not the post is being deleted + * @var bool cancel Whether or not to cancel the form (returns to + * viewtopic or viewforum depending on if the user + * is posting a new topic or editing a post) + * @var array error Any error strings; a non-empty array aborts + * form submission. + * NOTE: Should be actual language strings, NOT + * language keys. + * @var bool refresh Whether or not to retain previously submitted data + * @var array page_data Posting page data that should be passed to the + * posting page via $template->assign_vars() + * @var object message_parser The message parser object + * @since 3.1.0-a1 + * @changed 3.1.0-b3 Added vars post_data, moderators, mode, page_title, + * s_topic_icons, form_enctype, s_action, s_hidden_fields, + * post_id, topic_id, forum_id, submit, preview, save, load, + * delete, cancel, refresh, error, page_data, message_parser + */ + $vars = array( + 'post_data', + 'moderators', + 'mode', + 'page_title', + 's_topic_icons', + 'form_enctype', + 's_action', + 's_hidden_fields', + 'post_id', + 'topic_id', + 'forum_id', + 'submit', + 'preview', + 'save', + 'load', + 'delete', + 'cancel', + 'refresh', + 'error', + 'page_data', + 'message_parser', + ); + extract($phpbb_dispatcher->trigger_event('core.posting_modify_template_vars', compact($vars))); |