1
0
Fork 0
firefox/docshell/test/browser/file_basic_multipart.sjs
Daniel Baumann 5e9a113729
Adding upstream version 140.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
2025-06-25 09:37:52 +02:00

24 lines
417 B
JavaScript

"use strict";
function handleRequest(request, response) {
response.setHeader(
"Content-Type",
"multipart/x-mixed-replace;boundary=BOUNDARY",
false
);
response.setStatusLine(request.httpVersion, 200, "OK");
response.write(`--BOUNDARY
Content-Type: text/html
<h1>First</h1>
Will be replaced
--BOUNDARY
Content-Type: text/html
<h1>Second</h1>
This will stick around
--BOUNDARY
--BOUNDARY--
`);
}