Document.write inside an href

What’s the correct syntax to do a document write within an href link?


<a href="<script language='JavaScript1.2' type='text/javascript'>document.write(EventTerm);</script>" target="_blank">Terms &amp; Conditions</a>

I’ve tried this:

<a href="javascript:document.write(EventTerm);">Terms &amp; Conditions</a>

but it just writes the URL to the window.