标签:bsp idt src code oal ext nts val res
‘‘‘ @Modify Time @Author ------------ ------- 2019/8/31 19:55 laoalo ‘‘‘ import requests from lxml import etree ‘‘‘ eval():将字符串str当成有效的表达式来求值并返回计算结果 ‘‘‘ url = ‘http://123.206.87.240:8002/qiumingshan/‘ response = requests.session() re = response.get(url=url).content.decode(‘utf-8‘) elements = etree.HTML(re).xpath(‘//div/text()‘)[0][0:-3] result = eval(elements) print(result,‘\n‘) data = { ‘value‘:result } flag = response.post(url=url,data=data).content.decode(‘utf-8‘) # flag_x = etree.HTML(flag) # # print(etree.tostring(flag_x,encoding=‘utf-8‘).decode(‘utf-8‘)) print(flag)
标签:bsp idt src code oal ext nts val res
原文地址:https://www.cnblogs.com/chrysanthemum/p/11482184.html