I just completed 14 Days of WordPress Plugins + 7 Bonus Plugins!

Text Hover

Author:Scott Reilly
Version:1.0
Last update:15 April 2008
Compatibility:WP 2.2+, 2.3+ and 2.5+
Comments:go here
Download:[ zip ]
Description:

Add hover text to regular text in posts. Handy for providing explanations of names, terms, phrases, and acronyms mentioned in your blog.

Extended Description

Hover text are defined as terms/acronyms/phrasees that you expect to use in your blog posts and the expand text you wish to appear when the visitor hovers their mouse over the term. The admin options form for the plugin explains the format, which is quite simple. An example of which is shown here :

WP => WordPress
Matt => Matt Mullenweg
The Scooby Shack => the bar where the gang hangs out

Note: This is not the same as my Text Replace plugin, which defines terms which you would use but that you want replaced by the associated replacement text when displayed on your blog. Text Hover adds the hover text as additional information for when visitors hover over the term, which is otherwise displayed in the post as you typed it.

Screenshots

  • A screenshot of the admin options page for the plugin, where you define the terms/acronyms/phrases and their related hover text

    screenshot 1

  • A screenshot of the plugin in action for a post when the mouse is hovering over a defined hover text term

    screenshot 2


Installation

  1. Download the file text-hover.zip and unzip it into your wp-content/plugins/ directory.
  2. Activate the plugin through the ‘Plugins’ admin menu in WordPress.
  3. Go to the Options ? Text Hover (or in WP 2.5: Setings ? Text Hover) admin options page. Optionally customize the options (namely to define the terms/acronyms and their explanations).
  4. Use the terms/acronyms in a post (terms/acronyms appearing in existing posts will also be affected by this plugin).

Frequently Asked Questions

  • Q: In my posts, hover text terms do not appear any differently than regular text (though I can hover over them and see the hover text)! What gives?

    A: The plugin currently makes use of the standard HTML tag <acronym> to specify the terms and their hover text. Browsers have default handling and display of <acronym>. It’s possibly that the CSS for your theme is overriding the default display. I use the following in my site’s styles.css file to ensure it displays for me in the manner I prefer (which, by the same token, you can use more CSS formatting to further format the hover terms) :

    acronym {
      border-bottom:1px dotted #000;
    }

  • Q: Does this plugin modify the post content in the database?

    A: No. The plugin filters post content on-the-fly.

  • Q: Will this work for posts I wrote prior to installing this plugin?

    A: Yes.

  • Q: What post fields get handled by this plugin?

    A: The plugin filters the post content and post excerpt fields.

  • Q: Is the plugin case sensitive? =

    A: By default, yes. You can change this by manually editing the plugin file and changing the argument to the function c2c_text_hover() from $case_sensitive=true to $case_sensitive=false.


Release Log


Copyright & Disclaimer

Copyright © 2007-2008 by Scott Reilly (aka coffee2code)

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.


Acknowledgements

Thanks to all those who have contributed feedback and support!