[ create a new paste ] login | about

Link: http://codepad.org/CmHHo0iG    [ raw code | fork ]

Plain Text, pasted on Jan 21:
1
2
3
4
5
6
7
8
9
10
11
$('.chart-toggle').click(function(){
	// get the value of data-chart-toggle="x"
	var clicked = $(this).data('chart-toggle');

	// my objects are called dyGraph_<name>
	var object = window['dyGraph_' + clicked];

	$("tr[data-chart='" + clicked + "']").toggle();
	object.resize();
	return false;
});


Create a new paste based on this one


Comments: