Welcome, Registration, and other StartingPoints; Foswiki history & Wiki style; All the docs...
Restore | Raw | History | First | Previous | Next | Last | Close
You are here: System » JQueryPlugin » JQueryShrinkUrls

JQueryShrinkUrls

Homepage: http://michaeldaumconsulting.com
Author(s): Michael Daum
Version: 1.1

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.

Usage

 $("#container a").shrinkUrls({
   size:<number>,           // max size (default 25)
   include:'<regex>'       // regular expression a link text must
                           // match to be considered
   exclude:'<regex>'       // regular expression a link text must
                           // not match to be considered
   whitespace:<boolean>,   // true: even shrink if there's whitespace
                           // in the link text (default false)
   trunc:<head|middle|tail> // position where to insert the ellipsis
 });

Examples

todo

spacer
Copyright © 2014 Atomikos BVBA. Transaction Management for Extreme Transaction Processing and SOA Environments serving ISV, Commercial, OEM and Open Source Markets
Site map RSS ATOM