tweak cors, add headers to response
This commit is contained in:
parent
5b07c47e3a
commit
4311a7fb92
1 changed files with 2 additions and 0 deletions
|
@ -46,6 +46,8 @@ void ApiServer::answerClient(QTcpSocket* socket, const HttpRequest& request) {
|
||||||
}
|
}
|
||||||
|
|
||||||
reply_message = QSL("HTTP/1.0 200 OK \r\n"
|
reply_message = QSL("HTTP/1.0 200 OK \r\n"
|
||||||
|
"Access-Control-Allow-Origin: *\r\n"
|
||||||
|
"Access-Control-Allow-Headers: *\r\n"
|
||||||
"Content-Type: application/json; charset=\"utf-8\"\r\n"
|
"Content-Type: application/json; charset=\"utf-8\"\r\n"
|
||||||
"Content-Length: %1"
|
"Content-Length: %1"
|
||||||
"\r\n\r\n")
|
"\r\n\r\n")
|
||||||
|
|
Loading…
Add table
Reference in a new issue