我該怎麼做? 我試圖進入一些指定的連接(與urllib的),但要做到這一點,我需要登錄如何使用Python登錄到網站?
我從網站這個來源:
<form id="login-form" action="auth/login" method="post">
<div>
<!--label for="rememberme">Remember me</label><input type="checkbox" class="remember" checked="checked" name="remember me" /-->
<label for="email" id="email-label" class="no-js">Email</label>
<input id="email-email" type="text" name="handle" value="" autocomplete="off" />
<label for="combination" id="combo-label" class="no-js">Combination</label>
<input id="password-clear" type="text" value="Combination" autocomplete="off" />
<input id="password-password" type="password" name="password" value="" autocomplete="off" />
<input id="sumbitLogin" class="signin" type="submit" value="Sign In" />
這可能嗎?
請注意,在某些情況下,您需要使用submit()。請參閱:http://lists.idyll.org/pipermail/twill/2006-August/000526.html我確認這個問題,對我來說,使用submit()作品登錄www.pge.com。 – user391339 2014-09-11 07:47:41
是否有Python 3.6的解決方案?它似乎斜紋不支持Python 3.5或3.6。我試着下載它並使用'2to3'來轉換它,但是現在當我試圖導入它時,我得到了'ModuleNotFoundError'。 – CGFoX 2017-08-02 11:04:53
實際上,我可以通過使用/轉換Twill 1.8.0來解決'ModuleNotFoundError',並用'pip install'安裝'lxml'和'requests'。 但是現在當我嘗試導入時出現'SyntaxError',因爲某處False = 0 .... – CGFoX 2017-08-02 11:18:32