News for January 2010

Try out a new jQuery 1.4 plugi…

Try out a new jQuery 1.4 plugin ‘MenuTree’ for dynamic menus and faq lists, an expandable/collapsable menu from a list… http://rant.cc/x6K

Posted: January 30th, 2010
Categories: Flipside
Tags:
Comments: No Comments.

Time to eat supper, do I want …

Time to eat supper, do I want chicken or waffles; both will do. http://yfrog.com/1ymu4lj

Posted: January 28th, 2010
Categories: Flipside
Tags:
Comments: No Comments.

Watching tooth fairy with whol…

Watching tooth fairy with whole family; didn’t know there was hockey in it, nice

Posted: January 28th, 2010
Categories: Flipside
Tags:
Comments: No Comments.

Celebrating day 14, http://jqu…

Celebrating day 14, http://jquery14.com/ by sharing a jQuery plugin on github.com : http://github.com/pixelhandler/jQuery-MenuTree-Plugin/

Posted: January 28th, 2010
Categories: Flipside
Tags:
Comments: No Comments.

Blog post for MenuTree plugin …

Blog post for MenuTree plugin on my blog… http://rant.cc/SC2 demo of behavior… http://rant.cc/z9V

Posted: January 28th, 2010
Categories: Flipside
Tags:
Comments: No Comments.

jQuery MenuTree Plugin hosted at github.com

This is my first post of social code using the github repository at :
http://github.com/pixelhandler/jQuery-MenuTree-Plugin/

A JavaScript plugin based on jQuery library that builds an expandable/collapsable menu tree from a list element

  • Requires JavaScript library: jQuery

  • Developed using jQuery version 1.4 … Plugin page

  • Demo of the plugin behavior showing both lists and definition list… Demo

  • Status : New plugin, give it a try!

  • Tracer plugin added and featured with demo.

  • Blog post for MenuTree plugin on my blog… Blog

How to build a menu tree that is expandable with jQuery

Your html will need to link to the jQuery plugin in the head element

Your html markup needs to use a list like…


Definition list - Term 1
Description not targeted, uses CSS classes to collapse/expanded view
Term 2
Description 2 with links listed
  1. Pixelhandler
  2. jQuery
Term 3
Description 4
Term 4
Description 4 with unordered list
  • One
  • Two

menuTree plugin plugin uses a few CSS classes for visual design…


#myTree .menuTree:before {
	content: "[+] ";
}

#myTree .expanded:before {
	content: "[-] ";
}

#myTree .collapsed {
	display: none;
}

At the end of your html markup, before the closing body element use a script to setup the function…


$(document).ready(function() {

	$('#myTree').menuTree({
    	animation: true,
		handler: 'slideToggle',
		hrefBegins: '#',
		trace: true
	});

});

This plugin has default options which you may override. The animation option may use jQuery toggle or slideToggle methods, or just use the default css option to show/hide the child list(s).

When called with the animation: true option the plugin uses the handler option to select slideToggle or toggle method to add effects to the display of child menu(s). You may set the speed as you please, e.g. speed: ’slow’. Also, you may indicate what the child menu(s) are marked up with, e.g. listElement: ‘ol’ instead of the default listElement: ‘ul’

The default options:


$.fn.menuTree.defaults = {

	// setup animation
	animation: false,
	handler: 'css',
	speed: 'fast',
	// setup hooks in markup
	listElement: 'ul',
	hrefBegins: '#',
	// uses 'tracer' plugin
	trace: false
};

If you have any questions, please feel free to ask them on the jQuery
meetup site, found here:
http://meetups.jquery.com/group/jquerylosangeles

Posted: January 28th, 2010
Categories: Social, development
Tags:
Comments: No Comments.

Just made my first jQuery plug…

Just made my first jQuery plugin… http://rant.cc/gW7

Posted: January 28th, 2010
Categories: Flipside
Tags:
Comments: No Comments.

Prediction: the next Apple dev…

Prediction: the next Apple device : suitcase that folds into flying automobile ; perhaps this is the only thing that would entertain Jobs ?

Posted: January 27th, 2010
Categories: Flipside
Tags:
Comments: No Comments.

@CantonDog Yes, the cost may b…

@CantonDog Yes, the cost may benefit the more powerful device as a choice; but at the expense of the multi-touch interface and expericence

Posted: January 27th, 2010
Categories: Flipside
Tags:
Comments: No Comments.

$499 to change your digital l…

$499 to change your digital life

Posted: January 27th, 2010
Categories: Flipside
Tags:
Comments: No Comments.