Hello, for a website I'm building now, I need to work with both Python, and HTML. The database is Python, and the grafic interface is going to be in HTML. That's the assignment. I've tried to use the GET tool in HTML, but so far it won't work. This is just a try what I'm doing right now, but I've got excactly NO F*CKING CLUE what to do. THe HTML I use to get this form:
form method="action" action="cgi2shl.py"
In python stands this file:
#!/Programme/Python/python
"Script: Trewatment of parameters with GET, Standard CGI"
# -*- coding: ISO-8859-1 -*-
para_l=string.split(para,"&")
ll=len(para_1)
para_d={}
pattern="[a-z]+"
for i in range(11):
data=para_l[i]
j=regex.match(pattern,data)
key=data[:j]
value=data[j+1:]
if not para_d.has_key(key):
para_d[key]=[value]
else:
para_d[key]=para_d[key]+[value]
I think you have a server-side issue.
Consider closing all your HTML tags though, this will aid accessibility in the future. This should help you: http://www.w3schools.com/xhtml/xhtml_why.asp
Bookmarks