[jQuery] Small change to JTip

[jQuery] Small change to JTip

I wanted to be able to define my own cursor in JTip via the URL passed
and didn't see a way of doing it so I modified the JTip code slightly to
do this:
Before:
if(params['link'] !== undefined){
$('#' + linkId).bind('click',function(){window.location = params['link']});
$('#' + linkId).css('cursor','pointer');
    }
After:
if(params['cursor'] === undefined){params['cursor'] = 'pointer'};
    
$('#' + linkId).css('cursor', params['cursor']);
        
if(params['link'] !== undefined){
$('#' + linkId).bind('click',function(){window.location = params['link']});
    }
You can then specify the cursor in the URL like this:
href="mypage.htm?cursor=crosshair
Feedback is appreciated.
Rey...
_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/























    • Topic Participants

    • rey