karser/tp-redactor-bundle
Composer 安装命令:
composer require karser/tp-redactor-bundle
包简介
Redactor Form Type
关键字:
README 文档
README
Installation
contributors: Bartłomiej Noszka bnlab
To instal this bundle, copy and paste to your composer.json
"friendsofsymfony/jsrouting-bundle": "dev-master",
"tp/redactor-bundle": "dev-master",
Rember to configure JsRoutingBundle guiding their README file.
Usage
in config.yml:
twig:
form:
resources:
- 'TPRedactorBundle:Form:redactor_widget.html.twig'
in routing.yml:
tp_redactor:
resource: "@TPRedactorBundle/Controller/"
type: annotation
add CSS and Javascript to your assetic:
- CSS:
'@TPRedactorBundle/Resources/public/css/redactor.css' - Javascripts:
'@TPRedactorBundle/Resources/public/js/redactor.js'and'@TPRedactorBundle/Resources/public/js/tp_redactor.js'
Configuration
RedactorBundle allows you to configure the RedactorJS editor. Options are managed by "config_sets".
in config.yml
tp_redactor: default_config_set: default config_sets: default: lang: fr basic: lang: fr formattingTags: - 'h2' - 'h3' - 'p' - 'blockquote'
Chose your config set at form building :
$builder->add('your_form_field', 'redactor', array('config_set' => 'basic'));
All supported redactor options can be found Here
统计信息
- 总下载量: 18
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2014-01-13