How to use Content-Type: Multipart / Related

I want to send a binary file to the user and have some HTML display in the browser. I am using a CGI-BIN script with apache2. I found this example on page 4 . The link also shows detailed information about the multi-page / sibling type of content. Here is what I have tried so far:

Content-Type: Multipart / Related; boundary = "boundary-content"; start = ""; type = \ "text / plain \" "

--boundary-content
Content-Disposition: inline
Content Type: text / plain
Content-ID: <abc>

hi

--boundary-content
Content Type: application / octet-stream
Content-Disposition: attachment; filename = myfile
Content-ID: 2

...

--boundary-content

Content-Type . hi myfile ...?

+3
1

, MIME

0

Source: https://habr.com/ru/post/1759933/


All Articles