Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
XML over HTTPS POST.
Message
 
À
29/08/2006 14:12:56
Information générale
Forum:
Visual FoxPro
Catégorie:
Fonctions Windows API
Versions des environnements
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP1
Network:
Windows NT
Database:
Visual FoxPro
Divers
Thread ID:
01149489
Message ID:
01149574
Vues:
9
Sam... i've used WestWind's webconnect to do doing something like this. Check out a particular discussion on the msg board there by going to http://www.west-wind.com/wwthreads/ and do a msgboard search on 1P80RH9IZ. Try searching on ENCODEDBF and XMLTOCURSOR too.

Depending on the amt of data being sent, you may want to use XML or EncodeDBF / DecodeDBF to send and receive files. You can also simply push single record adds/updates/deletes from a vfp fatclient app by calling certain functions (URLs) you have created in your webserver WestWind app.

The following is from the online help at http://www.west-wind.com/webconnection/docs/ that gives u an idea on how to send a file.
oHTTP = CREATEOBJECT("wwHTTP")

*** Set mode to multi-part form
oHTTP.nHttpPostMode = 2

*** Post a file and a regular form variable
oHttp.AddPostKey("File","d:\temp\wws_invoice.pdf",.T.)
oHttp.AddPostKey("txtFileNotes","test note")

lcHTML = oHTTP.HTTPGet("http://localhost/wconnect/FileUpload.wwd")

*** Display result from server
ShowHTML(lcHTML)
In the example above, the user is calling http://localhost/wconnect/FileUpload.wwd. Your westwind app running on the webserver has a function called FILEUPLOAD which processes the file (saving it to disk, or to a DBF that gets processed, or whatever). The "wwd" is a script map extension that gets resolved/routed to the webconnection app. I believe that if the server has a cert, you can simply change the call from http to https.

I'll pull data out of a database based on timestamps, encode the file, and send it to the webserver by calling an https URL. The webserver receives it, converts it to a DBF, code spins thru it posting updates to a database, and a msg is returned to the client app. For small tables with very little changes, i'll do record-specific updates using AddPostKey instead of pushing a file.

The webserver function can return a msg, error codes, or anything you want. In the above example, that info is stored in lcHTML.


>Greetings.
>
>Has anyone ever done XML over HTTPS POST using VFP8.0?
>
>I think I need to us di_MD5DLL.dll, but I'm not sure.
>
>Any help is appreciated.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform