function showTocToggle(showtxt,hidetxt) {
	if(document.getElementById) {
		show = '<img src="'+PLUGIN_BASE+'images/arrow_down.gif" alt="'+showtxt+'" />';
		hide = '<img src="'+PLUGIN_BASE+'images/arrow_up.gif" alt="'+hidetxt+'" />';

	    document.writeln(
			'<div class=\'toctoggle\'><a href="javascript:toggleToc()" class="toc">' +
		    '<span id="showlink" style="display:none;">' + show + '</span>' +
		    '<span id="hidelink">' + hide + '</span>' + 
			'</a></div>'
		);
	}
}

function toggleToc() {
	var toc = document.getElementById('tocinside');
	var showlink=document.getElementById('showlink');
	var hidelink=document.getElementById('hidelink');

	if(toc.style.display == 'none') 
	{
		toc.style.display = tocWas;
		hidelink.style.display='';
		showlink.style.display='none';
	} 
	else 
	{
		tocWas = toc.style.display;
	    toc.style.display = 'none';
	    hidelink.style.display='none';
	    showlink.style.display='';
	}
}
