How to break out of href attribute?

I was learning about XSS and found a website that takes my input say “example“(without quotes) and converts it to <a href = "example.com/search/**example**" > Link </a>

After hit and trial, I found that it HTML encodes “,’,<,> . Is there a way for me to implement alert(1); here?