|
@@ -911,6 +911,17 @@ func (s *Script) LoadScript(site *string, downloadnode, script string, isfile ..
|
|
|
}
|
|
|
return 1
|
|
|
}))
|
|
|
+ //针对中国招标投标公共服务平台三级页瑞数加密下载方法
|
|
|
+ s.L.SetGlobal("downloadByDataIntercept", s.L.NewFunction(func(S *lua.LState) int {
|
|
|
+ url := S.ToString(-4)
|
|
|
+ url_regex := S.ToString(-3)
|
|
|
+ timeout := S.ToInt(-2)
|
|
|
+ proxy := S.ToBool(-1)
|
|
|
+ headers := sp.DownloadByDataIntercept(url, url_regex, timeout, proxy)
|
|
|
+ table := sp.MapToLuaTable(S, headers)
|
|
|
+ S.Push(table)
|
|
|
+ return 1
|
|
|
+ }))
|
|
|
}
|
|
|
|
|
|
func (s *Script) Reload() {
|