Joomla3开发教程

Contact Component 事件

Contact events are triggered during the contact form submitting process.

onValidateContact

Description

This event is triggered after a contact form has been submitted. An example use case would be validating a captcha. If you return an Exception object form submission will be terminated.

Parameters

  • contact A reference to the person who will receive the form.
  • data A reference to the data in the $_POST variable.

Return Value

None on success or Exception on failure.

Called in files

  • components/com_contact/controllers/contact.php

onSubmitContact

Description

This event is triggered after a contact form has been submitted. You can use this for sending additional emails etc.

Parameters

  • contact A reference to the person who will receive the form.
  • data A reference to the data in the $_POST variable.

Return Value

None. Called in files

  • components/com_contact/controllers/contact.php


作者:张敏
原文:http://www.joomlachina.cn/shouce/doc/1916?article_id=1963
© Joomla教程网 版权所有 | 粤ICP备13002429号
MyJoomla.cn是由野草工作室创建并运营,与 Joomla! Project™ 没有任何关联或认可。使用 Joomla!® 名称、符号、徽标和相关商标须遵守 Open Source Matters, Inc. 授予的有限许可。

编程基础教程

站内链接