r6 - 24 May 2008 - 07:02:50 - MarcusLeonardYou are here: TWiki >  Plugins Web > LightboxPlugin
Tags:
, create new tag

Lightbox Plugin

Lightbox is set of Javascript and CSS files that provides improved image viewing functionality. When a user clicks on the image, the full size image will display without advancing the browser to a new page.

Usage

  • Attach images and thumbnails to a topic
  • Use one of the lightbox TWiki tags to display the thumbnail image.

Syntax

To add lightbox functionality to a TWiki topic, use

   %LIGHTBOX{ _options_ }%
or
   %BEGINLIGHTBOX{ _options_ }%
   _text_
   %ENDLIGHTBOX%

If successful, a dotted box with a clickable thumbnail should appear.

option default comments
image '' The large display image
thumbnail '' The click-able thumbnail image
float 'right' thumbnail placement on topic page
border see below thumbnail border style
caption '' caption to appear in thumbnail img alt tag and under large image

Note, TWiki-wide defaults can be set using

  • Set LIGHTBOXPLUGIN_BORDER = 1px dashed #22638C
  • Set LIGHTBOXPLUGIN_FLOAT =

  • IDEA! If your text is to short, the thumbnail will overlap use height to fix this.
   <div style="border:1px dashed #22638c;padding:4px;height:200px; ">

Example

%LIGHTBOX{ image="img-test.jpg"  thumbnail="tmb-test.jpg" caption="This is a test"}%

Plugin Installation Instructions

Note: You do not need to install anything on the browser to use this plugin. The following instructions are for the administrator who installs the plugin on the server where TWiki is running.

  • Download the ZIP file from the Plugin Home (see below)
  • Unzip LightboxPlugin.zip in the root of your twiki installation
    Content:
    File: Description:
    data/TWiki/LightboxPlugin.txt plugin description
    lib/TWiki/Plugins/LightboxPlugin.pm plugin perl code
    pub/TWiki/LightboxPlugin/lightbox.css stylesheet
    pub/TWiki/LightboxPlugin/lightbox.js javascript
    pub/TWiki/LightboxPlugin/blank.gif empty image
    pub/TWiki/LightboxPlugin/close.gif close image button
    pub/TWiki/LightboxPlugin/loading.gif image loading animation
    pub/TWiki/LightboxPlugin/overlay.png overlay image
    pub/TWiki/LightboxPlugin/ScreenShot001.jpg thumbnail example
  • Enable the plugin in configure or LocalSite.cfg
  • Test if the installation was successful:
    • A dotted box with a clickable thumbnail should appear.
      ScreenShot001.jpg

Plugin Info

  • Set SHORTDESCRIPTION = TWiki hooks to the Lightbox Javascript package for better thumbnail clickthrough

This TWiki extension includes v1.0 of Lightbox.

Plugin Author: TWiki:Main.HenriAanstoot, TWiki:Main.ScottHoge
Copyright: © 2006, TWiki:Main.HenriAanstoot
License: GPL (GNU General Public License)
Plugin Version: 5 Apr 2007 (13273)
Change History:  
5 Apr 2007: Added blank.gif to the package
23 Mar 2007: Added Plugin code with TWiki Tags
22 Sep 2006: Initial version
TWiki Dependency: $TWiki::Plugins::VERSION 1.1 (TWiki 4.0)
CPAN Dependencies: none
Other Dependencies: none
Perl Version: 5.005
Plugin Home: http://TWiki.org/cgi-bin/view/Plugins/LightboxPlugin
Feedback: http://TWiki.org/cgi-bin/view/Plugins/LightboxPluginDev
Appraisal: http://TWiki.org/cgi-bin/view/Plugins/LightboxPluginAppraisal

Related Topic: TWiki:Plugins.ImageGalleryPlugin

Contributors: TWiki:Main/HenriAanstoot, TWiki:Main/ScottHoge

Topic attachments
I Attachment Action Size Date Who Comment
elsemd5 LightboxPlugin.md5 manage 0.2 K 05 Apr 2007 - 15:56 ScottHoge md5 checksums
ziptgz LightboxPlugin.tgz manage 27.3 K 05 Apr 2007 - 15:56 ScottHoge Untar and run the installer script, if there is one
zipzip LightboxPlugin.zip manage 30.1 K 05 Apr 2007 - 15:56 ScottHoge unzip, correct the permissions, and run the installer script, if there is one
Edit | WYSIWYG | Attach | Printable | Raw View | Backlinks: Web, All Webs | History: r6 < r5 < r4 < r3 < r2 | More topic actions
Plugins.LightboxPlugin moved from Plugins.LightboxAddOn on 23 Mar 2007 - 20:55 by PeterThoeny - put it back
 
Powered by TWiki
This site is powered by the TWiki collaboration platformCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback SourceForge.net Logo