259617f6 by astaxie

remove markdown

1 parent ab08aa9c
...@@ -23,7 +23,6 @@ func init() { ...@@ -23,7 +23,6 @@ func init() {
23 beegoTplFuncMap = make(template.FuncMap) 23 beegoTplFuncMap = make(template.FuncMap)
24 BeeTemplateExt = make([]string, 0) 24 BeeTemplateExt = make([]string, 0)
25 BeeTemplateExt = append(BeeTemplateExt, "tpl", "html") 25 BeeTemplateExt = append(BeeTemplateExt, "tpl", "html")
26 beegoTplFuncMap["markdown"] = MarkDown
27 beegoTplFuncMap["dateformat"] = DateFormat 26 beegoTplFuncMap["dateformat"] = DateFormat
28 beegoTplFuncMap["date"] = Date 27 beegoTplFuncMap["date"] = Date
29 beegoTplFuncMap["compare"] = Compare 28 beegoTplFuncMap["compare"] = Compare
......
...@@ -2,7 +2,6 @@ package beego ...@@ -2,7 +2,6 @@ package beego
2 2
3 import ( 3 import (
4 "fmt" 4 "fmt"
5 "github.com/russross/blackfriday"
6 "html/template" 5 "html/template"
7 "regexp" 6 "regexp"
8 "strings" 7 "strings"
...@@ -17,14 +16,6 @@ func webTime(t time.Time) string { ...@@ -17,14 +16,6 @@ func webTime(t time.Time) string {
17 return ftime 16 return ftime
18 } 17 }
19 18
20 // MarkDown parses a string in MarkDown format and returns HTML. Used by the template parser as "markdown"
21 func MarkDown(raw string) (output template.HTML) {
22 input := []byte(raw)
23 bOutput := blackfriday.MarkdownBasic(input)
24 output = template.HTML(string(bOutput))
25 return
26 }
27
28 func Substr(s string, start, length int) string { 19 func Substr(s string, start, length int) string {
29 bt := []rune(s) 20 bt := []rune(s)
30 if start < 0 { 21 if start < 0 {
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!