My problem is that when I search for my site on google (a Wordpress page), it shows the correct web address, but clicking the link redirects to a site selling Windows keys.
However, if I actually type the address into the address bar and visit the site manually, I reach my site correctly. What is the name for this kind of attack? I want to research and fix the problem, but I don't know the terminology, and there seem to be a lot of different ways to compromise a web page.
Also, any recommendations for how to fix this would be appreciated.