I think this is because you're using your trademark 'dirname(__FILE__)' to create the links. You could fix it by changing that function to one of the ones that outputs just the domain. Another alternative is to disable the link you're presently visiting.. but that's more of a pain.

James