Many customers ask to remove the actions (Edit, Del) from related list and the natural way to solve that is by removing Edit and Del permission on the profile.
However sometimes you need that the user have those permissions. For instance, when the user trigger a web service that update the record.
So, here the magic, using a simple line of jQuery:
Where lContacts is the ID of the related list.