(function ($) {
  $.fn.showhide = function (settings) {

    settings = jQuery.extend({
       showText: "[show details]",
       hideText: "[hide details]"
    }, settings);

    return this.each(function () {
      $(this).hide();
      $(this).prev().append(' <a class="show_link" href="#">' +  settings.showText + '</a>');

      var show_link = $(this).prev().children('.show_link');

      show_link.click(function () {
        //$(".h3_list").show("slow");
        if (show_link.html() == settings.showText) {
            show_link.parent().next().show("slow");
            show_link.html(settings.hideText);
        } else {
            show_link.parent().next().hide("slow");
            show_link.html(settings.showText);
        }
        return false;
      });
    });
  };
})(jQuery);