urlopen
#python
import json,urllib
from urllib.request import urlopen
url = 'http://api.k780.com'
params = {
'app' : 'finance.stock_history',
'symbol' : 'sh601318',
'date' : '20200512',
'appkey' : '10003',
'sign' : 'b59bc3ef6191eb9f747dd4e83c99f2a4',
'format' : 'json',
}
params = urllib.parse.urlencode(params)
f = urllib.request.urlopen('%s?%s' % (url, params))
nowapi_call = f.read()
#print nowapi_call
a_result = json.loads(nowapi_call)
if a_result:
if a_result['success'] != '0':
print(a_result['result'])
print("totline : ",a_result['result']['totline'])
print("disline : ",a_result['result']['disline'])
print("page : ",a_result['result']['page'])
print("name : ",a_resu