Joomla v1.6 - 方法与方法在控制器中哪里设置自定义成功消息?
在 Joomla! 1.6 联系表单提交,我想设置一条自定义的成功消息,以便前端用户提交联系表单后可以看到该消息。
基本上有两个问题:-
- 我使用的是 Joomla! 提供的默认联系表单组件 (
com_contact
)。 v1.6。但我无法找到提交联系表格的正确区域。邮件正在发送。所以我需要知道页面名称和页面名称。该组件的方法名称,从前端触发邮件。 - 如何在联系表单组件的特定方法中设置自定义消息(就像在管理员面板中一样),让前端用户知道他已经能够成功地将邮件发送给相关人员?
预先感谢所有可以提供帮助的人。
In Joomla! 1.6 Contact Form submission, I want to set a custom successful message, so that the front-end user can view that message after he submits the contact form.
There are 2 problems basically:-
- I am using the default Contact Form component (
com_contact
), as provided by the Joomla! v1.6. But I am unable to find the proper area from where the contact form is submitted & the mail is being sent. So I need to know the page name & the method name of this component, firing the mail from the front-end. - How to set the custom messages (just like in the administrator panel) in the particular method of contact form component, to let the front-end user know that he has been able to successfully send the mail to the concerned staff?
Thanks in advance to all who can help.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
要显示消息,
请使用
$this->setMessage(JText::_('COM_YOURCOMPONENT_MESSAGE'));
(如果您位于控制器中)。或者使用
And Email是通过
JoomlaRoot/components/com_contact/controllers/contact.php
发送的,找到函数
submit()
,邮件发送代码写在这里。To show Message
use
$this->setMessage(JText::_('COM_YOURCOMPONENT_MESSAGE'));
if you are in controller.or use
And Email is sent through
JoomlaRoot / components / com_contact / controllers / contact.php
find the function
submit()
, the mailing code is written here.