Owning Palette: CGI Template VIs
Installed With: Internet Toolkit
Writes a reply to the HTTP connections that the cgi connection info input specifies.

![]() |
cgi connection info contains information about a specific CGI connection. Wire the cgi connection info output of the CGI Read Request VI to this input. |
![]() |
header contains the header section of the reply, which traditional parsed-header CGI applications write to standard out. |
![]() |
content contains the content data part of the reply, which traditional parsed-header CGI applications write to standard out. If you do not specify a header string, the content string must be an HTML document. |
![]() |
cgi connection info out returns the same value as cgi connection info. |
An HTTP reply consists of a header followed by content. The default behavior of the server is to construct a header that implies a success status (200) and content consisting of HTML text (text/html). If the CGI VI must override this default behavior, it uses the header parameter. Create a header that contains parameter lines of server directives or HTTP header lines. The server can interpret server directives, while other header lines are written as part of the header sent to the client. If the first line in the header begins with HTTP/, the server does not parse the header for directives but sends it directly to the client.
The CGI/1.1 specification defines the following three server directives:
According to HTTP specification, the server replaces end-of-line characters with the CRLF character sequence before sending the header to the client.