If what you want is to click on our custom legend item to toggle the series visibility you can try this:
<div class="myLegend" id="0">My legend for serie 1</div>
<div class="myLegend" id="1">My legend for serie 2</div>
I have given each div an ID equal to the series number. Then in javascript do:
$('div.myLegend').click(function () {
var theSeries = $(this).attr('id');
var chart = $('#container').highcharts();
var series = chart.series[theSeries];
if (series.visible) {
series.hide();
} else {
series.show();
}
});