From: Scott Klement <sk@xxxxxxxxxxxxxxxx>
Date: 2005/09/15 Thu PM 08:27:21 GMT
To: ftpapi@xxxxxxxxxxxxx
Subject: Re: HTTP/1.1 500 Internal Server Error
Sender: Scott Klement <sk@xxxxxxxxxxxxxxxx>
I am receiving the HTTP/1.1 500 Internal Server Error with the
http_url_post_xml(). Any suggestions on where to look for an answer?
HTTPAPI is an HTTP client. It connects to HTTP servers and issues
commands to them.
When something goes wrong on the server (usually program that it calls is
crashing or otherwise ending abnormally) the server will report "500
Internal Server Error"
So the question becomes, what's going wrong on the server that's causing
it to crash?
a) Are you sending something incorrect? A well-written server
shouldn't just crash because you sent it invalid data, instead
it should tell you what you did wrong. However, there are a lot
of servers out there that aren't well written.
b) Is there a bug in HTTPAPI that may be causing IT to send something
incorrect?
c) Is everything you're sending correct, but there's just a bug in
the server code?
It's awfully hard to narrow something like this down when all you know is
that some kind of error occurred on the server. It sure would be easier
if we knew what the error was, instead of just "an error occurred".
One thing in your code that did make me raise an eyebrow was that you're
telling the server that your document is encoded with UTF-8. It sure
doesn't look like UTF-8 to me! It looks like EBCDIC data in an RPG
variable. Granted, it won't be EBCDIC when it hits the server, since
HTTPAPI will translate it, but it won't be UTF-8 either. It'll probably
be ISO-8859-1.
I don't know if that has anything to do with the error or not.
If you can't figure it out by trial and error, you'll probably have to
contact the server's admin and see if he can give you more info about
what's going wrong.
Usually, when an internal server error is sent to the HTTP client, the
server will also make a log with more detail about what went wrong. The
server's admin should be able to look at that log and provide you with
more more info.
-----------------------------------------------------------------------
This is the FTPAPI mailing list. To unsubsribe from the list send mail
to majordomo@xxxxxxxxxxxxx with the body: unsubscribe ftpapi mymailaddr
-----------------------------------------------------------------------