Made to Order Software Corporation Logo

MO Paragraph Trimmer Filter: Main Page

MO Paragraph Trimmer Filter Documentation

1.2

Summary

Description
Installation
Copyright (c) 2008-2011 Made to Order Software Corp.

Description

We use FCKeditor on all of our Drupal websites. This greatly helps in simplifying the editing of each web page.

The result is often much better because you much less hesitate to use some bold, Courier font, underscore, italic...

Having to type those in HTML, even though it is easy, makes it tedious!

Now with each great thing comes a downside... like all the WYSIWYG editor I've tested, once in a while, FCKeditor leaves a set of empty paragraphs at the end of the page.

For some sites, this is not much of a problem. Actually, some people like to keep some empty space at the end of their pages. For most of our sites, it is a problem, especially when there are footnotes. We do not want the footnotes to appear all the way at the bottom. They need to be right under the content!

For this reason we created this module. It searches your page content and removes empty paragraphs. It can delete these at the start, the end or in the middle of the paragraph.

At this time, it only deletes the default empty paragraphs created by WYSIWYG editors:

 <p>&nbsp;</p>

Thus, you can have the filter turned on and still insert empty lines by adding one more space in the empty line you want to keep. It then won't be removed.

Back to Summary

Installation

In order to install MO Paragraph trimmer filter, extract the tarball under your sites/all/modules folder.

Then go to Drupal on your site and enable this module. The module is found under Input filter. The module tells you when it gets installed (and uninstalled.)

Now go to your Input filters (Under Site configuration.) There you will be able to select your newly installed filter.

Click Save, then go back to the filter and click on Configure. There you can select what empty paragraphs you want removed. By default, only the end paragraphs are removed.

You can now test the filter by going to a node and adding empty lines at the start in between paragraphs and at the end to see the result.

There should be no problem with the order if you remove all the empty paragraphs. Otherwise, depending on the other filters you are using, you may need to push the MO Paragraph trimmer filter higher up in your list of filters (i.e. if you use the Foot notes filter, it will add the foot note and then the paragraphs at the end of the source node won't be removed if the Middle flag is not set.)

Back to Summary

Copyright (c) 2008-2011 Made to Order Software Corp.

http://www.m2osw.com/mo_trimmer_filter contact@m2osw.com

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Back to Summary
Documentation generated by Doxygen on Sat Mar 12 16:05:45 2011
Syndicate content