Trying to hand data to functions from an .on() map
<p>I'm currently working on some JQuery code which will make it so that tooltips appear next to the user's mouse when they mouse over certain objects. There's about 13 unique tooltips, each of which has a number of different triggers. I'm just having a bit of a trouble figuring out a way to pass data to my functions so that I don't have to create 13 sets of nearly-identical functions with different identifiers. Here's the code I'm using, which works but requires being copied multiple times:</p>

<pre><code>jQuery(document).ready(function($){

function phpTooltipPosition(event) {
    var phptooltipX = event.pageX - 8;
    var phptooltipY = event.pageY + 8;
    $('#marpole').css({top: phptooltipY, left: phptooltipX});
}

function phpMethod(event) {
    $('#marpole').removeClass('hidden')
    phpTooltipPosition(event);
}

function phpHide() {
    $('#marpole').addClass('hidden');
}


$('.marpole').on({
    mousemove : phpTooltipPosition,
    mouseenter : phpMethod,
    mouseleave: phpHide
});
});
</code></pre>

<p>When I was reading up on this I read that using an event map for .on() makes it so that you can't pass data to functions... is there a workaround for this?</p>
