JQueryPlugin

jQuery JavaScript library for Foswiki

Description

WikiRing Powered by
WikiRing Consultants

"jQuery is a fast, concise, JavaScript Library that simplifies how you traverse HTML documents, handle events, perform animations, and add Ajax interactions to your web pages."

Coding Standards

See JQuery Coding Standards This plugin contains the latest version of the jQuery JavaScript library. See also Foswiki:Development.UsingJQueryWithFoswiki for more information on using jQuery with Foswiki.

Further references and tutorials

Using compressed javascript and css files

All jQuery plugins are shipped with uncompressed js and css files, as well as minified and gzip compressed. For instance the jquery.autocomplete comes with the following set:
  1. /pub/System/JQueryPlugin/plugins/autocomplete/jquery.autocomplete.uncompressed.js
  2. /pub/System/JQueryPlugin/plugins/autocomplete/jquery.autocomplete.js
  3. /pub/System/JQueryPlugin/plugins/autocomplete/jquery.autocomplete.js.gz

There is a Makefile in the /pub/System/JQueryPlugin root directory that grants all these files are up to date. By default all files in the JQueryPlugin package are up to date. So you only have to issue a make in the root directory if you wish to modify one of the files underneath. This will update all minified and gzipped files as needed. Enable the {JQueryPlugin}{Debug} flag in configure, to use the uncompressed files right away to omit the make step during development of further javascript components.

Apache can be configured to automatically use the .gz files if present using mod_rewrite as follows:

  <FilesMatch ".*\.(js|css)$">
    RewriteEngine On
    RewriteCond %{HTTP:Accept-encoding} gzip
    RewriteCond %{REQUEST_FILENAME}.gz -f
    RewriteRule ^(.*)$ %{REQUEST_URI}.gz [L,QSA]
  </FilesMatch>

  <Files *.js.gz>
    AddEncoding gzip .js
    ForceType application/x-javascript
  </Files>

  <Files *.css.gz>
    AddEncoding gzip .css
    ForceType text/css
  </Files>

So whenever the browser accepts encoding the file as gzip and the file with the .gz does exist in the filesystem, then trigger an internal redirect while still enforcing the original mine-type. The browser on the other side will unzip the css and js files automatically. This will drastically reduce bandwidth and speed up interactive performance.

Available jQuery plugins

1. Autocomplete (active)

Autocomplete an input field to enable users quickly finding and selecting some value, leveraging searching and filtering. By giving an autocompleted field focus or entering something into it, the plugin starts searching for matching entries and displays a list of values to choose from. By entering more characters, the user can filter down the list to better matches. This can be used to enter previous selected values, eg. for tags, to complete an address, eg. enter a city name and get the zip code, or maybe enter email addresses from an addressbook.

See also JQueryjaxHelper for examples on how to integrate autocompletion into Foswiki.

2. bgiframe (active)

A jQuery plugin that helps ease the pain when having to deal with IE z-index issues. This plugin is enabled by default.

3. blockUI

The jQuery BlockUI Plugin lets you simulate synchronous behavior when using AJAX, without locking the browser. When activated, it will prevent user activity with the page (or part of the page) until it is deactivated. BlockUI adds elements to the DOM to give it both the appearance and behavior of blocking user interaction.

4. Button

This is a simple way to render nice buttons in Foswiki. It can be used to replace submit and reset buttons of html forms as well. FamFamFamContrib is recommended to display nice icons on buttons. Note, that this widget does not participate on the jquery theme roller. This is independent.

5. Chili

Chili is the jQuery code highlighter plugin.

Features:

6. Cookie

Easy cookie handling using jQuery.

7. Corner

This plugin adds cross-browser support for rounded corners. For modern browsers the appropriate css attributes are used while there is a fallback strategy for others.

8. Cycle

The jQuery Cycle Plugin is a lightweight slideshow plugin. Its implementation is based on the JQueryInnerFade Plugin by Torsten Baldes, the Slideshow Plugin by Matt Oakes, and the jqShuffle Plugin by Benjamin Sterling. It supports pause-on-hover, auto-stop, auto-fit, before/after callbacks, click triggers and many transition effects. It also supports, but does not require, the Metadata Plugin and the Easing Plugin.

9. Easing (active)

Uses the built in easing capabilities added In jQuery 1.1 to offer multiple "easing" effects.

10. Farbtastic

Farbtastic is a jQuery plug-in that can add one or more color picker widgets into a page. Each widget is then linked to an existing element (e.g. a text field) and will update the element's value when a color is selected. Farbtastic uses layered transparent PNGs to render a saturation/luminance gradient inside of a hue circle. No Flash or pixel-sized divs are used.

There's a color formfield for easy integration into Foswiki DataForms.

11. FluidFont

Recompute the font size of an element based on its width.

12. Focus

This plugin sets the focus on a form input field or textarea of a form when the page is loaded.

13. Form

The jQuery Form Plugin allows you to easily and unobtrusively upgrade HTML forms to use AJAX. The main methods, ajaxForm and ajaxSubmit, gather information from the form element to determine how to manage the submit process. Both of these methods support numerous options which allows you to have full control over how the data is submitted. Submitting a form with AJAX doesn't get any easier than this!

14. Foswiki (active)

This is plugin takes care of loading the jQuery core and default plugins and performs any initialization steps specific to Foswiki, For instance, it reads all <meta> tags from the html head as they have been set by Foswiki and constructs the foswiki javascript object to be used by other javascript plugins.

In addition it adds some basic Foswiki tags to make life easier using jQuery plugins, most notably %JQREQUIRE{"pluginName"}% to load a subsequent jQuery plugin and all of its dependencies, taking care where and how it is added to the html page.

Curent default plugins are: jquery.easing, jquery.metadata, jquery.bgiframe, jquery.hoverIntent

15. Gradient

Adds a gradient to the background of an element.

16. hoverIntent (active)

hoverIntent is similar to jQuery's built-in "hover" function except that instead of firing the onMouseOver event immediately, hoverIntent checks to see if the user's mouse has slowed down (beneath the sensitivity threshold) before firing the onMouseOver event.

17. ImageTooltip (active)

18. InnerFade

InnerFade is a small plugin for the jQuery-JavaScript-Library. It's designed to fade you any element inside a container in and out. These elements could be anything you want, e.g. images, list-items, divs. Simply produce your own slideshow for your portfolio or advertisings. Create a newsticker or do an animation.

19. LiveQuery (active)

Live Query utilizes the power of jQuery selectors by binding events or firing callbacks for matched elements auto-magically, even after the page has been loaded and the DOM updated.

20. MaskedInput

This is a masked input plugin for the jQuery javascript library. It allows a user to more easily enter fixed width input where you would like them to enter the data in a certain format (dates,phone numbers, etc). It has been tested on Internet Explorer 6/7, Firefox 1.5/2/3, Safari, Opera, and Chrome. A mask is defined by a format made up of mask literals and mask definitions. Any character not in the definitions list below is considered a mask literal. Mask literals will be automatically entered for the user as they type and will not be able to be removed by the user.

21. Masonry

Masonry is a layout plugin for jQuery. Think of it as the flip side of CSS floats. Whereas floating arranges elements horizontally then vertically, Masonry arranges elements vertically then horizontally according to a grid. The result minimizes vertical gaps between elements of varying height, just like a mason fitting stones in a wall.

22. Media

jQuery Media Plugin for converting elements into rich media content.

Supported Media Players:

Supported Media Formats:
Any types supported by the above players, such as:

23. Metadata (active)

This plugin is capable of extracting metadata from classes, random attributes, and child elements.

24. NatEdit

The NatEdit is an wiki editor that helps in learning the TML Language by providing a GUI. By design, this is not a wysiwyg editor that tries to generate the correct TML in the background. Instead, the user is still in charge of writing correct wiki markup but with a bit more of assistance as a plain browser textarea. Therefor this editor helps to lower the learning curve but will not get in your way once you are aware of wiki markup.

25. QueryObject

This extension creates a singleton query string object for quick and readable query string modification and creation. This plugin provides a simple way of taking a page's query string and creating a modified version of this with little code.

26. Rating

The Star Rating Plugin is a plugin for the jQuery Javascript library that creates a non-obstrusive star rating control based on a set of radio input boxes.

It turns a collection of radio boxes into a neat star-rating control. It creates the interface based on standard form elements, which means the basic functionality will still be available even if Javascript is disabled.

27. Shake

jQuery plugin to emulate “shake” on login failure in OSX login box.

28. ShrinkUrls

Shrinks all urls in a given container whose link text exceeds a given size and have no white spaces in it, that is don't wrap around nicely. If the text is skrunk, the original text is appended to the title attribute of the anchor.

29. SimpleModal

SimpleModal is a lightweight jQuery plugin that provides a simple interface to create a modal dialog.

30. Slimbox

Slimbox 2 is a 4 KB visual clone of the popular Lightbox 2 script by Lokesh Dhakar, written using the jQuery javascript library. It was designed to be very small, efficient, standards-friendly, fully customizable, more convenient and 100% compatible with the original Lightbox 2.

31. Superfish (active)

Superfish is an enhanced Suckerfish-style menu jQuery plugin that takes an existing pure CSS drop-down menu (so it degrades gracefully without JavaScript). Features:

32. Supersubs (active)

This is a companion plugin to superfish. It resizes superfish submenus to fit their contents.

33. Tabpane

This implements an alternative tabpane widget. There is already one in jquery-ui, however as long as jquery-ui is still in flux, this alternative offers a safe substitute well integrated into Foswiki.

Individual tabs can be loaded on demand using a REST call. Installing Foswiki:Extensions/RenderPlugin is recommended for that.

Tabpanes can be nested. Tabs can be extended in height automatically. Heights can be auto-updated to follow windows resize events. Tabpanes can be established as part of reloaded content via ajax.

Note that this widget does not participate in jquery-ui themerolling. It does match JQueryButton in terms of look & feel.

34. TextboxList

Turns a text input into a Facebook like list widget with autocompletion. This plugin adds a new formfield type textboxlist to DataForms.

35. Toggle

This is a lightweigted widget to add a toggle feature similar to the TwistyPlugin. It uses the means available in jQuery only, i.e. it selectors to toggle the display of all matching elements.

36. Tooltip (active)

Display a customized tooltip instead of the default one for every selected element. Tooltips can be added automatically to any element that has got at title attribute thus replacing the standard tooltip as displayed by the browsers with a customizable one.

Content can be reloaded using AJAX. For example, this can be used to display an image preview in a tooltip. Have a look at the thumbnail REST service of Foswiki:Extensions/ImagePlugin how to load the thumnail from the backend dynamically.

37. Treeview

Lightweight and flexible transformation of an unordered list into an expandable and collapsable tree, great for unobtrusive navigation enhancements. Supports both location and cookie based persistence.

Subtrees can be loaded on demand using AJAX. See the Foswiki:Extensions/RenderPlugin how to implement such REST handlers easily.

38. UI

Widget collection for jQuery. This is the official userinterface library.

39. Validate

Very powerful client-side form validation framework (article).

40. WikiWord

This plugin allows to create a WikiWord on the base of a set of input elements. The value of these are concatenated and the result is normalized to be a valid WikiWord. For example, this can be used to derive a topic name from a free-form topic title text.

Installation Instructions

You do not need to install anything in the browser to use this extension. The following instructions are for the administrator who installs the extension on the server.

Open configure, and open the "Extensions" section. Use "Find More Extensions" to get a list of available extensions. Select "Install".

If you have any problems, or if the extension isn't available in configure, then you can still install manually from the command-line. See http://foswiki.org/Support/ManuallyInstallingExtensions for more help.

Plugin Info

Author(s): Michael Daum
Copyright: 2007-2010 Michael Daum http://michaeldaumconsulting.com
License: GPL
Release: 3.51
Version: 7299 (2010-04-30)
Change History:  
30 Apr 2010: (3.51) fixed initial classes of click-areas in treeviews
29 Mar 2010: (3.42) disable plugin when prerequisites are not met
28 Mar 2010: (3.41) fix ZonePlugin listed as optional dependency (not optional for Foswiki 1.0.x installations)
26 Mar 2010: (3.40) externalized grid and fullcalendar modules into plugins of their own; upgraded to jquery-ui 1.7.2; only load i18n support matching the current site language
20 Mar 2010: (3.31) Minifier CPAN libs removed from plugin. They will be in core CPAN lib in Foswiki 1.1
14 Mar 2010: (3.30) upgraded validate to v1.7; added wikiword validation method; fixed computation of line-height in fluidfont; fixed height issue in tabpane
03 Mar 2010: made ZonePlugin an optional dependency
01 Mar 2010: improved js and css compression using yuicompressor; improved simplemodal integration to foswiki to create modal dialogs with less additional javascript; added custom events to textboxlist: AddValue, DeleteValue , Reset and Clear
12 Feb 2010: added livequery and rewrote all initializers to use it; added rating formfield type; updated jqGrid to latest version; improved foswiki integration and documentation of various plugins; upgraded jwplayer coming with media plugin; using Foswiki:Extensions/ZonePlugin now to optimize page load time
08 Feb 2010: added query-object
28 Jan 2010: added jquery-1.4.1, corner, fluidfont, fullcalendar, localscroll, masonry, scrollto, serialscroll, slimbox; deprecated jquery.nifty; disabled JQSCRIPT and JQSTYLE
11 Nov 2009: added jqGrid library; reorganized documentation
07 Nov 2009: updated Superfish to 1.4.8 and added examples topic, added supersubs plugin, moved JQuery examples from Sandbox to System
29 Oct 2009: added SCRIPTSUFFIX to foswiki var set (CDot)
14 Sep 2009: added perls tubs for jquery.ui, so that you can pull it in via JQREQUIRE now; reworked plugin initialization to allow elements to be init'ed when loaded via ajax; fixed BUTTON to play nicely with TwistyPlugin; only load ui-theme if you jqrequire the ui library
20 Aug 2009: made JQueryPlugin SafeWikiPlugin compatible
02 Jul 2009: improved parsing of foswiki meta tags in html header; fixed jqTreeview initialisation for jquery-1.3.x; fixed chili initialisation; dropped support for konqueror3
23 Jun 2009: added jquery.focus, jquery.textboxlist, jquery.farbtastic; jquery.gradient; added color and textboxlist formfield types; made JQueryPlugin pluggable itself; added animation switching tabs; improved automaxexpand feature in tabs
28 Apr 2009: added jquery.media, jquery.simplemodal, shell highlightning for chilli
03 Feb 2009: fixed tabpane not being rendered using a rest handler; added id to tabs that can be used to init the first active one; added compressed version of blockUI; replaced ICONTOPIC preference variable with ICONSEARCHPATH to search for icons in multiple directories (defaults to all of FamFamFamContrib)
15 Jan 2009: fixed click target for relative urls in %BUTTON{}%; yet another jquery.wikiword fix
13 Jan 2009: fixed jquery.wikiword not to depend on outside string libraries; added foswiki alias to global javascript variables (Eugen Mayer)
08 Jan 2009: certified for foswiki/compat; fixed BUTTON target for non-wikiword topics
12 Dec 2008: fixed a series of IE6+IE7 issues
18 Nov 2008: added jquery.ifixpng; improved BUTTON tag to have submit and clear and reset buttons; ie6 fixes for BUTTONs; added missing jquery.wikiword plugin
13 Nov 2008: added automaxexpand for TABPANES ; added jquery.shake plugin; reworked BUTTON tag
15 Oct 2008: added jquery.autocomplete, jquery.cycle
20 Jul 2008: added jquery.form, jquery.maskedinput, jquery.validate
15 Jul 2008: updated to ui-1.5.2; added async treeview; added async options to tabpane
03 Jul 2008: updated to ui-1.5.1
05 Jun 2008: updated to jquery-1.2.6 and ui-1.5-RC1
30 Apr 2008: repackaged to contain jquery UI
13 Feb 2008: upgrade to jquery-1.2.3, as well as most plugins
17 Jan 2008: added jquery.metadata plugin; implemented a jquery.tabpane plugin; updated jquery.dimensions plugin; added jquery.empty plugin to ease development of new plugins
15 Nov 2007: use skin independent way to add javascript files to header
10 Oct 2007: upgraded to jQuery-1.1.4; compressed js and css
12 Jul 2007: initial package containing jQuery-1.1.3.1
Dependencies:
NameVersionDescription
Foswiki::Plugins::ZonePlugin>=2.1Required
Home: Foswiki:Extensions/JQueryPlugin
Support: Foswiki:Support/JQueryPlugin
Attach
js
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
jquery-1.2.6.js.gz
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
js
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
js
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
jquery-1.3.2.js.gz
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
js
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
js
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
jquery-1.3.2p1.js.gz
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
js
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
js
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
jquery-1.4.2.js.gz
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
js
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
js
jquery.js (54.57K)
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
js
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
jquery.patch
jquery.patch (0.51K)
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
js
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
Makefile
Makefile (0.25K)
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
Makefile.include
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
png
Saved by install script
version 1 uploaded by AdminUser on 30 Apr 2010 - 17:24
spacer