发布时间:2019-08-06 09:03:36编辑:auto阅读(1948)
#!/usr/bin/python # -*- coding: UTF-8 -*- import execjs,os #执行本地自定义的js print execjs.compile('function test(){' 'return 5' '}' '' '' '').call("test") #获取系统的路径 paths=os.path.dirname(__file__) print paths dir=paths+"/js/modules.js" #执行*.js里的文件 print execjs.compile(open(dir).read().decode('utf-8')).call('add',3,4)
上一篇: Python3之数据库(以SQLite为
下一篇: Python3快速入门——(3)dict
48102
46789
37711
35037
29576
26237
25166
20203
19841
18315
5988°
6672°
6164°
6153°
7264°
6103°
6212°
6684°
6649°
8040°