templateのフォーマッタのシグネチャをPrintf 同様、...を使うように変更したので、
コンパイル時に、
template.go:14: cannot use UrlHtmlFormatter (type func(w io.Writer, v
interface { }, fmt string)) as type func(io.Writer, string, ...interface {
interface { }, fmt string)) as type func(io.Writer, string, ...interface {
が発生します。
以下のように修正してください。
func UrlHtmlFormatter(w io.Writer,fmt string , v...interface{}) {
template.HTMLEscape(w, []byte(http.URLEscape(v[0].(string))));
}