Hi guys, I was wondering about the following code and if it's possible
to chain it. At the moment it works fine as is, I'm just curious if it
is possible.

My original code:
$('#greyLink').click(function(){

var getLink = $(this).prev().prev().attr("href");
return getLink.slice(getLink.indexOf("r=")+2, getLink.indexOf("&tp"));

});

what I've tried:

$('#greyLink').click(function(){

return $(this).prev().prev().attr("href")[0].slice(this.indexOf("r=")
+2, this.indexOf("&tp"));

});

&

$('#greyLink').click(function(){

return $(this).prev().prev().attr("href").this.slice(this.indexOf("r=")
+2, this.indexOf("&tp"));

});

Reply via email to