|
@@ -433,6 +433,14 @@ func (s *Script) LoadScript(downloadnode, script string, isfile ...string) {
|
|
S.Push(lua.LString(result))
|
|
S.Push(lua.LString(result))
|
|
return 1
|
|
return 1
|
|
}))
|
|
}))
|
|
|
|
+ //根据正文获取发布时间
|
|
|
|
+ s.L.SetGlobal("getPublishtime", s.L.NewFunction(func(S *lua.LState) int {
|
|
|
|
+ detail := S.ToString(-2)
|
|
|
|
+ contenthtml := S.ToString(-1)
|
|
|
|
+ publishtime := util.GetPublishtime([]string{contenthtml, detail})
|
|
|
|
+ S.Push(lua.LString(publishtime))
|
|
|
|
+ return 1
|
|
|
|
+ }))
|
|
}
|
|
}
|
|
|
|
|
|
//
|
|
//
|