INNER CODE UNIT · Go

renderHTML

OWASP/wrongsecrets · scripts/sort_contibutors/main.go:212

func renderHTML(createdDate string, leaders, topContributors, contributors, testers, specialThanks []Contributor) string {
	var b strings.Builder
	b.WriteString(renderCreatedComment(createdDate))
	b.WriteString("<html><head></head><body>\n")
	writeHTMLSection(&b, "OWASP Project Leaders", leaders)
	writeHTMLSection(&b, "Top Contributors", topContributors)
	writeHTMLSection(&b, "Contributors", contributors)
	writeHTMLSection(&b, "Testers", testers)
	writeHTMLSection(&b, "Special mentions for helping out", specialThanks)
	b.WriteString("</body><html>\n")
	return b.String()
}

func writeHTMLSection(b *strings.Builder, title string, users []Contributor) {
	b.WriteString(title)
	b.WriteString(":\n")
	b.WriteString("<ul>\n")
	for _, user := range users {

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…