title: Python login script
body: <p>I have the following script to logon to a url,but on submit in the webpage i call</p>
  
  <pre><code>&lt;input type=button value="go"  onclick="Search()";&gt;
  </code></pre>
  
  <p>How to do the same in the following script instead of submit......</p>
  
  <pre><code>import urllib, urllib2, time
  username = "sumname"
  password = "test"
  interval = 10
  data = {"username":username,"password":password,"submit":"sign in"}
  value = urllib.urlencode(data)
  request = urllib2.Request("http://127.0.0.1/accounts/login/",value)
  print "request="%request
  #while (1):
  open = urllib2.urlopen(request)
  response = open.read()
  response=str(response)
  print response
  </code></pre>
  
  <p>Thanks...</p>