$(document).ready(function() {
  $('#categorysubmenu').css('display','none');
  $('.categorymenu .linkcolor').click(function(){
	  $('#categorysubmenu').slideToggle();
	  return false;
  });
  // Notice the use of the each() method to acquire access to each elements attributes
  $('.tooltip').each( function() {
	  $(this).qtip({
          content: $(this).attr('alt'),
          position: {
              corner: {
                 target: 'bottomMiddle',
                 tooltip: 'topMiddle'
              },
              adjust: {
            	 y: 5
              }
           },
          style: {
	          textAlign: 'center',
	          tip: 'topMiddle', // Give it a speech bubble tip with automatic corner detection
	          name: 'dark' // Style it according to the preset 'cream' style
	       }

	  });
  });
  $('.tooltipshare').each( function() {
	  $(this).qtip({
          content: $(this).attr('alt'),
          position: {
              corner: {
                 target: 'rightMiddle',
                 tooltip: 'leftMiddle'
              },
              adjust: {
            	 y: 5
              }
           },
          style: {
	          textAlign: 'center',
	          tip: 'leftMiddle', // Give it a speech bubble tip with automatic corner detection
	          name: 'dark' // Style it according to the preset 'cream' style
	       }

	  });
  });

});