package yatwiki
import (
"html/template"
"net/http"
)
func (this *WikiServer) routeFormatting(w http.ResponseWriter, r *http.Request) {
pto := DefaultPageTemplateOptions(this.opts)
pto.CurrentPageName = "Formatting help"
content := `
Formatting help
- [h]header[/h]
- [b]bold[/b]
- [u]underline[/u]
- [i]italic[/i]
- [s]strikethrough[/s]
- [spoiler]spoiler[/spoiler]
- [list] item [*] item [/list]
- [url=address]title[/url]
- [article=page name]title[/article] or [rev=id]title[/rev]
- [img]image-url[/img]
- [imgur]asdf.jpg[/imgur]
`
if len(this.opts.ContentedBBCodeTag) > 0 {
content += `
- [` + this.opts.ContentedBBCodeTag + `]abc[/` + this.opts.ContentedBBCodeTag + `]
`
}
content += `
- [code]fixed width[/code]
- [section=header]content[/section]
- [youtube]id[/youtube]
- [html]raw html[/html]
`
pto.Content = template.HTML(content)
this.servePageResponse(w, r, pto)
}