Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
张磊
/
FileStorageBeego
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
259617f6
authored
2013-07-25 16:40:37 +0800
by
astaxie
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
remove markdown
1 parent
ab08aa9c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
10 deletions
template.go
utils.go
template.go
View file @
259617f
...
...
@@ -23,7 +23,6 @@ func init() {
beegoTplFuncMap
=
make
(
template
.
FuncMap
)
BeeTemplateExt
=
make
([]
string
,
0
)
BeeTemplateExt
=
append
(
BeeTemplateExt
,
"tpl"
,
"html"
)
beegoTplFuncMap
[
"markdown"
]
=
MarkDown
beegoTplFuncMap
[
"dateformat"
]
=
DateFormat
beegoTplFuncMap
[
"date"
]
=
Date
beegoTplFuncMap
[
"compare"
]
=
Compare
...
...
utils.go
View file @
259617f
...
...
@@ -2,7 +2,6 @@ package beego
import
(
"fmt"
"github.com/russross/blackfriday"
"html/template"
"regexp"
"strings"
...
...
@@ -17,14 +16,6 @@ func webTime(t time.Time) string {
return
ftime
}
// MarkDown parses a string in MarkDown format and returns HTML. Used by the template parser as "markdown"
func
MarkDown
(
raw
string
)
(
output
template
.
HTML
)
{
input
:=
[]
byte
(
raw
)
bOutput
:=
blackfriday
.
MarkdownBasic
(
input
)
output
=
template
.
HTML
(
string
(
bOutput
))
return
}
func
Substr
(
s
string
,
start
,
length
int
)
string
{
bt
:=
[]
rune
(
s
)
if
start
<
0
{
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment