alexbridge / symfony-bundle-contact
Symfony 2的通用联系表单Bundle,适用于您的网站
dev-master
2016-06-13 17:44 UTC
Requires
- sensio/framework-extra-bundle: ~3.0,>=3.0.2
- symfony/framework-bundle: ~2.3
This package is not auto-updated.
Last update: 2024-09-14 19:25:37 UTC
README
Symfony 2的通用联系表单Bundle,适用于您的网站。
字段
- 姓名
- 电子邮件
- 主题
- 信息
安装
-
composer require alexbridge/symfony-bundle-contact
-
启用Bundle
// app/AppKernel.php public function registerBundles() { $bundles = array( // ... new Alexo\ContactBundle\ContactBundle(), ); }
-
注册路由
// app/config/routing.yml contact: resource: "@ContactBundle/Controller/" type: annotation prefix: /contact
配置
contact:
# an array email addresses to receive contact messages
receiver_emails: []
路由
- 将
contact
路由添加到您的视图和路由生成中 - 访问
/contact
URI以查看联系表单