Thanks Armin. I worked it out. One issue was the code was missing quote marks around the URL, which I totally missed. I then was able to combine it with another existing script in the "Custom <head> content" section, and it works perfectly now. Would be handy though to have this as an optional field in the site title section of the Lay settings, so you could optionally enter a custom URL for the sit title link?
Thanks again for your tips as always.