package main import ( "fmt" ) func Layout(f map[string]string) string { template := ` %s %s
%s
%s
%s ` return fmt.Sprintf(template, f["title"], f["head"], f["header"], f["main"], f["sidebar"], FooterText, f["bodyBottom"]) } func HyphaPage(hyphae map[string]*Hypha, rev Revision, content string) string { template := ` ` args := map[string]string{ "title": fmt.Sprintf(TitleTemplate, rev.FullName), "head": DefaultStyles, "header": DefaultHeader, "main": fmt.Sprintf(template, content), "sidebar": "", "footer": FooterText, } return Layout(args) }