- Plugin Name: JSM's Non-Breaking Space for French Content
- Stable Version: 1.9.0
- Author: JS Morisset
- Description: Adds a non-breaking space between words and punctuation marks to avoid inappropriate line-breaks in French.
- License: GPLv3
- Requires PHP: 5.5 or newer
- Requires WordPress: 4.0 or newer
- Tested Up To WordPress: 5.3.2
- Last Updated: 1 day ago
- Plugin Homepage »
This plugin adds non-breaking spaces required by the French language in the content, excerpt, comments, text widget, and WooCommerce short description — skipping over pre-formatted code blocks, styles and scripts.
<!--:fr--> HTML tag is found (used by some multilingual plugins), non-breaking spaces are added only between the
<!--:--> HTML tags.
There are no plugin settings — simply install and activate the plugin.
Filters for Developers
'nbsp_french_add_filters' ( array $filter_names )
An associative array of filter names (and priority) for the plugin to hook.
'the_title' => 10,
'the_content' => 10,
'the_excerpt' => 10,
'comment_text' => 10,
'widget_title' => 10,
'widget_text' => 10,
'woocommerce_short_description' => 10,
To hook additional filters, include their names (and priority) in the 'nbsp_french_add_filters' array, or hook them individually in your functions.php:
array( 'NbspFrench', 'filter' ), 10, 1 );
'nbsp_french_currencies' ( $regex )
A regular expression of recognized currency symbols.