more-or-less


Gives More/Less functionality to a block of HTML content using Javascript and CSS

Add functionality that only displays the first few lines of a block of content with a “More/Less” link at the bottom, which when clicked, will expand or contract the content. Written with cross-browser compatibility in mind.

Example can be seen on http://jsfiddle.net/Xotic750/uu9Rk/

Now uses the DOMTokenList project: http://code.google.com/p/domtokenlist/

<wiki:gadget url="http://www.ohloh.net/p/641574/widgets/project_languages.xml" height="230" border="1" width="350"/>

<wiki:gadget url="http://www.ohloh.net/accounts/123602/widgets/account_detailed.xml" height="55" border="0"/>

http://stackoverflow.com/users/592253/xotic750'> http://stackoverflow.com/users/flair/592253.png?theme=dark' alt='profile for Xotic750 at Stack Overflow, Q&A for professional and enthusiast programmers' title='profile for Xotic750 at Stack Overflow, Q&A for professional and enthusiast programmers' width='208' height='58' />

Project Information

The project was created on May 15, 2013.

Labels:
JavaScript CSS html Library CrossPlatform