#D8CX: I pledge that Advanced Text Formatter will have a full Drupal 8 release on the day that Drupal 8 is released.
This module is just a formatter (display) of textfield, text area and text format. The idea behind this is to provide a simple solution, easy to setup, with few dependencies to display text on website.
The trim function in this module is taken from Views module with a few modifications.
- Text (Drupal 7.x Core)
- Filter (Drupal 7.x Core)
Download the module and simply copy it into your contributed modules folder:
[for example, your_drupal_path/sites/all/modules] and enable it from the modules administration/management page.
More information at: Installing contributed modules (Drupal 7)
After successful installation, browse to the "Manage Display" settings page, for the entity (Node content type, for example) with a text field, text area or text format, choose Advanced Text from the formatters list
- Trim length: The maximum number of characters the a field can be. Set this to 0 if you don't want to cut the text. Otherwise, input a positive integer.
- Ellipsis: If checked, a "..." will be added if a field was trimmed.
- Word Boundary: If checked, this field be trimmed only on a word boundary. This is guaranteed to be the maximum characters stated or less. If there are no word boundaries this could trim a field to nothing.
- Token Replace: Run token replace on this field.
- Filter: Filter the value of this field.
- None: No filter.
- Selected Text Format: Use the format that is chosen by user when he inputs the value.
- Limit allowed HTML tags: A list of HTML tags that can be used.
- Drupal: Filter this field by using Drupal's filters.
- Allowed HTML tags (when Filter is Limit allowed HTML tags): Specify tags which should not be stripped.
- Format (when Filter is Drupal): Drupal's filters.
- Convert line breaks into HTML: Converts line breaks into <p> and <br> in an intelligent fashion.
If you want to display the list of available tokens, you just need to install Token module, then go to Manage Fields page, edit the field, and select the "Show available tokens in field's description" (see the 4th and 5th screenshot)
Since 7.x-1.4, you will be able to insert token to a CKEditor 3.5+ AND TinyMCE 3.x editor (by clicking on the token as usual).
For other WYSIWYG editors, I don't have much time to work on and I'm very appreciated if someone can help me for adding support for those editors.
But please remember that you still can copy the token and paste into your editor.
Currently, the 8.x-1.x-dev branch of Token module isn't compatible with Drupal 8. That means you cannot see the "Browse available tokens", but you still can use tokens and this module does replace the tokens.
- Maintenance status: Actively maintained
- Development status: Under active development
- Module categories: Content, Content Construction Kit (CCK), Content Display, Fields
- Reported installs: 3,284 sites currently report using this module. View usage statistics.
- Downloads: 18,669
- Last modified: 2 December 2014
- Stable releases for this project are covered by the security advisory policy.
Look for the shield icon below.