Fixed canonical URLs.

they will now work correctly on (for example) profile pages.