I developed a Web-Service with Web 1.0. Running fine and fast. Now I got some problems with SSL on the Mac and decided to re-compile with the latest Xojo version and WEB 2.0. But it doesn’t work:
WebRequest.GetRequestHeader gives me this error:
Type “WebRequest” has no member named “GetRequestHeader”
ContentType = Request.GetRequestHeader( “Content-Type” )
Also other methods seem to be vanished:
They are listed in the documentation without any deprecation remark. But the methods are not any longer in the WebRequest Method List?
I read Geoffs blog entry about converting WF 1.0 to 2.0 - but it did not help here. I did not find any complete documentation about what is changed. Is there any? The release notes were not helpful here.
I am sure that I can not be the only one with this issue. Did I miss something? Thank you for any support!
There were significant changes here for Web 2.0. You should review the documentation for WebRequest.
Entity → Parameter (If I remember correctly)
GetHeaderNames → HeaderNames
GetRequestHeader → Header
var contentType as String = Request.Header( "Content-Type" )
Thanks a lot - very helpful!
Entity seems to be “Body” now …? And I found this: “WebRequest.Entity and WebRequest.Status have been removed from the documentation”. But what is the replacement for the functionality?
btw. WebRequest.Header was an array before - now a string?
WebRequest.Print is gone? WebRequest.Status?
Yes, I saw the WebRequest Doc-Page. Not very helpful wrt. to update to 2.0. Is there any complete list of changes to check/compare against? Thanks again …
For returning anything, including Status, you’ll use the WebResponse parameter of WebApplication.HandleURL, if I remember correctly (not at my computer).
It now behaves like a Dictionary. You should review its documentation.
Not that I’m aware of.
Thanks a lot. I owe you a beer !
They SHOULD prepare something like a guide and a list. Or at least prepare a good documentation. It’s a great pity.