diff --git a/doc/effective_go.html b/doc/effective_go.html index 5f27284aaf..6adf7e5558 100644 --- a/doc/effective_go.html +++ b/doc/effective_go.html @@ -2954,8 +2954,7 @@ const templateStr = ` </head> <body> {{if .}} -<img src="http://chart.apis.google.com/chart?chs=300x300&amp;cht=qr&amp;choe=UTF-8&amp;chl={{urlquery .}}" -/> +<img src="http://chart.apis.google.com/chart?chs=300x300&cht=qr&choe=UTF-8&chl={{urlquery .}}" /> <br> {{html .}} <br> @@ -2994,7 +2993,7 @@ from data items passed to templ.Execute, in this case the form value. Within the template text (templateStr), double-brace-delimited pieces denote template actions. -The piece from the {{if .}} +The piece from {{if .}} to {{end}} executes only if the value of the current data item, called . (dot), is non-empty. That is, when the string is empty, this piece of the template is suppressed. diff --git a/doc/effective_go.tmpl b/doc/effective_go.tmpl index 6607894820..46d774ad4e 100644 --- a/doc/effective_go.tmpl +++ b/doc/effective_go.tmpl @@ -2884,7 +2884,7 @@ from data items passed to templ.Execute, in this case the form value. Within the template text (templateStr), double-brace-delimited pieces denote template actions. -The piece from the {{html "{{if .}}"}} +The piece from {{html "{{if .}}"}} to {{html "{{end}}"}} executes only if the value of the current data item, called . (dot), is non-empty. That is, when the string is empty, this piece of the template is suppressed. diff --git a/doc/progs/eff_qr.go b/doc/progs/eff_qr.go index fc92bd0efa..5d1fd38e06 100644 --- a/doc/progs/eff_qr.go +++ b/doc/progs/eff_qr.go @@ -31,8 +31,7 @@ const templateStr = ` {{if .}} - +
{{html .}}