Http post and http get

n3d!m nedimmuminovic at gmail.com
Wed Jan 25 17:23:29 EST 2012


I am writing python script which will log into openSIS (Student information system) and get grades. Demo of website is available here: http://demo.os4ed.com/
Here is code which works for that site:

#!/usr/bin/python
import requests
user_login={'USERNAME':'student','PASSWORD':'student'}
r=requests.post("http://demo.os4ed.com/index.php", data=user_login)
r=requests.get("http://demo.os4ed.com/for_export.php?modname=Grades/Transcripts.php&modfunc=save&_openSIS_PDF=true&controller=Y&st_arr[]=1", cookies=r.cookies)
print r.text

My problem is when I try the same thing with my school's openSIS. It returns me error:
<SCRIPT language=javascript>history.back();alert("You must choose at least one student and marking period");</SCRIPT>

Their openSIS is installed on port 8080. Does port 8080 causes problem with my script?





More information about the Python-list mailing list