Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
B
beego
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
go
beego
Commits
259617f6
Commit
259617f6
authored
Jul 25, 2013
by
astaxie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
remove markdown
parent
ab08aa9c
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
10 deletions
+0
-10
template.go
template.go
+0
-1
utils.go
utils.go
+0
-9
No files found.
template.go
View file @
259617f6
...
@@ -23,7 +23,6 @@ func init() {
...
@@ -23,7 +23,6 @@ func init() {
beegoTplFuncMap
=
make
(
template
.
FuncMap
)
beegoTplFuncMap
=
make
(
template
.
FuncMap
)
BeeTemplateExt
=
make
([]
string
,
0
)
BeeTemplateExt
=
make
([]
string
,
0
)
BeeTemplateExt
=
append
(
BeeTemplateExt
,
"tpl"
,
"html"
)
BeeTemplateExt
=
append
(
BeeTemplateExt
,
"tpl"
,
"html"
)
beegoTplFuncMap
[
"markdown"
]
=
MarkDown
beegoTplFuncMap
[
"dateformat"
]
=
DateFormat
beegoTplFuncMap
[
"dateformat"
]
=
DateFormat
beegoTplFuncMap
[
"date"
]
=
Date
beegoTplFuncMap
[
"date"
]
=
Date
beegoTplFuncMap
[
"compare"
]
=
Compare
beegoTplFuncMap
[
"compare"
]
=
Compare
...
...
utils.go
View file @
259617f6
...
@@ -2,7 +2,6 @@ package beego
...
@@ -2,7 +2,6 @@ package beego
import
(
import
(
"fmt"
"fmt"
"github.com/russross/blackfriday"
"html/template"
"html/template"
"regexp"
"regexp"
"strings"
"strings"
...
@@ -17,14 +16,6 @@ func webTime(t time.Time) string {
...
@@ -17,14 +16,6 @@ func webTime(t time.Time) string {
return
ftime
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
{
func
Substr
(
s
string
,
start
,
length
int
)
string
{
bt
:=
[]
rune
(
s
)
bt
:=
[]
rune
(
s
)
if
start
<
0
{
if
start
<
0
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment