Description#

With this plugin you can put on your page a random quotation from predefinied list. I use it in my wiki's header section :)

Predefined list is a wiki page with Your favourite golden thoughts in specific format. Every quotation should be put in single line in following format:
*quotation|author
or
*quotation\n

Installation#

  • Copy quotation.jar(info) into your wiki's WEB-INF/lib.
  • (Optional) Add the package name of the Quotation Plugin (pl.tsz.jspwiki.plugin) to the jspwiki.plugin.searchPath in your WEB-INF/jspwiki.properties. If you don't do that, you have to prefix the plugin name with its package name when using it in your page.
  • Restart your servlet engine.

Plugin parameters#

page name of wiki page from which plugin should read quotations (this parameter is REQUIRED)
author if set to 'true' plugin will display quotation's author
authorAsTitle if set to 'true' plugin will display quotation's author also as quotation's DIV title
styleClass css style class
link if set to 'true' plugin will set onclik action to open page with quotations definitions

Example#

Sample page with quotations and plugin invocation of this page.

[{QuotationPlugin page=QuotationPluginExample,
author=true,styleClass=quotation,link=true,authorAsTitle=true}]

!Example quotations

*Anyone who has never made a mistake has never tried anything new. | A. Einstein
*Cover me. I'm changing lanes.|Bumper sticker
*Any given program, when running, is obsolete
*To err is human, to forgive is not company policy|         Commerce Laws  
Sample css to add to the jspwiki.css style definitions.
.quotation {
	margin-right: 40px;
	margin-top: 18px;
}
.quotation .quotationDIV {
	text-align: right;
	height: 20px;
	line-height: 20px;
	color: green;
	font-family: verdana;
	font-size: 11pt;
	font-style: italic;
}
.quotation .authorDIV {
	margin-right: 20px;
	color: gray;
	text-align: right;
	font-family: verdana;
	font-size: 7pt;
	font-style: normal;
	font-weight: normal;
}

Effects#

QuotationPlugin.png
<div class="quotation">
  <div class="quotationDIV" title="A. Einstein" onclick="location.href='Wiki.jsp?page=QuotationPluginExample'">
    &bdquo;Anyone who has never made a mistake has never tried anything new.&rdquo;
  </div>
  <div class="authorDIV">A. Einstein </div>
</div>

TomaszSzymko


Very nice plugin! Please add a note that the package name is pl.tsz.jspwiki.plugin This should either be used in the plugin invocation or added to the searchPath property.

--NascifAbousalhNeto, 21-Sep-2006

Add new attachment

Only authorized users are allowed to upload new attachments.

List of attachments

Kind Attachment Name Size Version Date Modified Author Change note
png
QuotationPlugin.png 2.3 kB 1 21-Sep-2006 16:24 193.0.236.149
jar
quotation-src.jar 13.1 kB 2 15-Oct-2006 22:40 TomaszSzymko v.1.0.1
jar
quotation.jar 14.9 kB 2 15-Oct-2006 22:40 TomaszSzymko v.1.0.1
« This page (revision-17) was last changed on 03-Mar-2011 11:11 by Janne Jalkanen