Sunday, April 19, 2015
Rich Text Areas / Field , lets is like a small editor which lets you format your content. Thats really cool feature when you want that field to merged into a PDF / Email or in an document. But whats not so cool is when you add an RTF to a Visualforce page you no longer can rerender the page and you have to let the page refresh fully. Thats really sad.
The visualforce RTF editor uses CKEditor which is widely used for the same purpose and has an open API / Method, which exactly was the Idea behind the custom-rtf component. Introduce some JS in the page and customize the toolbar and along with bring back the ability to rerender the page.
The visualforce RTF editor uses CKEditor which is widely used for the same purpose and has an open API / Method, which exactly was the Idea behind the custom-rtf component. Introduce some JS in the page and customize the toolbar and along with bring back the ability to rerender the page.
Introducing Custom-rtf
- Lets you customize the Toolbars
- Lets you rerender the VF page
- Easy to using vf component
Syntax
Attributes
- targetclass : Styleclass of the Textarea that needs to be rendered as RTF
- toolbar : Different toolbars available
Toolbar options
- Full
- Visualforce
- HomePageComponent
- SalesforceBasic
- EmailMultiFormat
- SalesforceLight
- Knowledge
- KnowledgeWithIframes
- ServiceCommunity