more formdata work.
This commit is contained in:
parent
d3cd5f3c9a
commit
050b5f2b87
1
Global.h
1
Global.h
@ -26,7 +26,6 @@ namespace jet {
|
|||||||
void setupFormURLEncoded(coreutils::ZString &formdata);
|
void setupFormURLEncoded(coreutils::ZString &formdata);
|
||||||
char *errorCursor = NULL;
|
char *errorCursor = NULL;
|
||||||
|
|
||||||
|
|
||||||
coreutils::CGIFormattedData cookies;
|
coreutils::CGIFormattedData cookies;
|
||||||
std::map<coreutils::MString, coreutils::MString> variables;
|
std::map<coreutils::MString, coreutils::MString> variables;
|
||||||
std::map<coreutils::MString, coreutils::MString> cgiVariables;
|
std::map<coreutils::MString, coreutils::MString> cgiVariables;
|
||||||
|
@ -43,17 +43,19 @@ namespace jet {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::cout << "013" << std::endl;
|
||||||
coreutils::ZString requestMethod(getenv("REQUEST_METHOD"));
|
coreutils::ZString requestMethod(getenv("REQUEST_METHOD"));
|
||||||
if(requestMethod == "POST") {
|
if(requestMethod == "POST") {
|
||||||
|
std::cout << "014: " << requestMethod << std::endl;
|
||||||
coreutils::ZString contentLength(getenv("CONTENT_LENGTH"));
|
coreutils::ZString contentLength(getenv("CONTENT_LENGTH"));
|
||||||
coreutils::ZString contentType(getenv("CONTENT_TYPE"));
|
coreutils::ZString contentType(getenv("CONTENT_TYPE"));
|
||||||
|
|
||||||
if(contentType == "multipart/form-data") {
|
if(contentType == "multipart/form-data") {
|
||||||
|
std::cout << "015" << std::endl;
|
||||||
coreutils::IMFMultipart postdata(0, contentLength.asInteger());
|
coreutils::IMFMultipart postdata(0, contentLength.asInteger());
|
||||||
|
std::cout << "016" << std::endl;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// else if(contentType == "application/x-www-form-urlencoded")
|
// else if(contentType == "application/x-www-form-urlencoded")
|
||||||
// global.setupFormURLEncoded(postdata);
|
// global.setupFormURLEncoded(postdata);
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
#!../jet-2.0
|
#!../jet-2.0
|
||||||
<upload name="imagefiledata" path="images/%name" />
|
<upload name="imagefiledata" path="images/%name" />
|
||||||
<jet sessiondir=".">
|
<jet cgi="true" sessiondir=".">
|
||||||
|
|
||||||
<dump file="./dump.txt" />
|
<dump file="./dump.txt" />
|
||||||
</jet>
|
</jet>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user