Restored from previous forum. Originally posted by ittraining.
My Problem: i like to program a tool for
sending formular-dates (FORM Datas) like you would do
by hand if you type in datas in a webpage-formular and
send it manually to a webserver.
I like to emulate this by a program.
is there anyone which have a short example-code or hint for me,
how to do this?
Thanks a lot
Ulli
Sending FORM-Datas (like a Browser)
-
- PureBasic Guru
- Posts: 16777133
- Joined: Tue Apr 22, 2003 7:42 pm
Restored from previous forum. Originally posted by El_Choni.
I think you must first send an HTTP header, I don't know how that works exactly. The data of the form you want to send can be converted with the URLEncode() function of the CGI library.
Bye,
PS: if you use PB Windows, you can use URLDownloadToFile_() as explained here:
viewtopic.php?t=628 Tiny code to download a web page%2Ffile&Forum_Title=Tricks %27n%27 Tips
Edited by - El_Choni on 23 April 2002 09:23:11
Edited by - El_Choni on 23 April 2002 09:23:42
I think you must first send an HTTP header, I don't know how that works exactly. The data of the form you want to send can be converted with the URLEncode() function of the CGI library.
Bye,
PS: if you use PB Windows, you can use URLDownloadToFile_() as explained here:
viewtopic.php?t=628 Tiny code to download a web page%2Ffile&Forum_Title=Tricks %27n%27 Tips
Edited by - El_Choni on 23 April 2002 09:23:11
Edited by - El_Choni on 23 April 2002 09:23:42
Yeah I would love to do this also. Perhaps with send keys or an API call...
Gotta research it though. Anyone???
I personally want to do it for my personal use so I can build an
app that will automatically log me into mutiple pages... with a single
button click....
But for regular stuff there is an excellent program called AI RoboForm
<a href="http://www.roboform.com/" target="_blank">http://www.roboform.com/</a>...
Tom
Gotta research it though. Anyone???
I personally want to do it for my personal use so I can build an
app that will automatically log me into mutiple pages... with a single
button click....
But for regular stuff there is an excellent program called AI RoboForm
<a href="http://www.roboform.com/" target="_blank">http://www.roboform.com/</a>...
Tom
Usually you send the data in the form at the end of the url
After the "?" appears every variable and its value separed by &
http://www.google.com/search?q=purebasic
will be the same as i type purebasic and press the search button.
With passwords, normally can't do it by this way.
After the "?" appears every variable and its value separed by &
http://www.google.com/search?q=purebasic
will be the same as i type purebasic and press the search button.
With passwords, normally can't do it by this way.
ARGENTINA WORLD CHAMPION
ricardo : Not really true. GET (the method to you reference) is *one* way to send data to a CGIish program. POST is probably more commonly used. Either way to simulate this you'd have to speak HTTP to a web server. I'm sure there are many existing CGI/network libraries for this out there and I think the forum post above mentions some helpful links.
http://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html
FYI from the HTTP RFC. Reads like stereo instruction but contains everything ya need to know if you're going to roll your own solution..
Good luck! Doot!
http://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html
FYI from the HTTP RFC. Reads like stereo instruction but contains everything ya need to know if you're going to roll your own solution..
Good luck! Doot!
-Mitchell
Check out kBilling for all your billing software needs!
http://www.k-billing.com
Code Signing / Authenticode Certificates (Get rid of those Unknown Publisher warnings!)
http://codesigning.ksoftware.net
Check out kBilling for all your billing software needs!
http://www.k-billing.com
Code Signing / Authenticode Certificates (Get rid of those Unknown Publisher warnings!)
http://codesigning.ksoftware.net