我正试图通过登录银行网站并在向客户发布商品之前检查我的交易来实现我的业务自动化。我正在尝试使用python来实现这一点。到目前为止,它适用于facebook,我现在正在银行网站上试用。但我在想,如果网页有变化,这种方法就行不通了。还有其他的最佳方法吗?这里没有提供API,谢谢你的建议。这是密码from splinter import Browser
#userid
user_email = 'username'
# takes the password for the user account needed
user_pass = 'password'
# loads the firefox broswer
browser= Browser('firefox')
#selects bank as the website to load in the browser (have to load twice because the bank directs it to the main site for the first time)
browser.visit('https://www.cimbclicks.com.my/wps/portal/!ut/p/c0/04_SB8K8xLLM9MSSzPy8xBz9QJ_89Mw8_YJ0RUUAk9OZqw!!/')
browser.visit('https://www.cimbclicks.com.my/wps/portal/!ut/p/c0/04_SB8K8xLLM9MSSzPy8xBz9QJ_89Mw8_YJ0RUUAk9OZqw!!/')
# fills the userid
browser.fill('userid', user_email)
#still working on the password part (unfinished)
browser.fill('pass', user_pass)
#selects the login button(so far doesn't work. I'm still working on how to click this image, can't find id. works for facebook though)
button = browser.find_by_id('u_0_n')
button.click()