debian man page for ns_connreturnfile

Query: ns_connreturnfile

OS: debian

Section: 3aolserv

Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar

Ns_ConnReturnFile(3aolserver)				   AOLserver Library Procedures 			     Ns_ConnReturnFile(3aolserver)

__________________________________________________________________________________________________________________________________________________

NAME
Ns_ConnReturnFile - Return a file as a complete response
SYNOPSIS
#include "ns.h" int Ns_ConnReturnFile(conn, status, type, file)
ARGUMENTS
Ns_Conn conn (in) Pointer to open connection. char *file (in) Pointer to filename string. int status (in) HTTP status code. char *type (in) Pointer to mimetype string. _________________________________________________________________
DESCRIPTION
This routine is used to generate complete responses, including the HTTP status code specified by the status argument and appropriate head- ers followed by the contents of the file specified with the file argument. This routine utilizes the underlying builtin file-server code (aka, "fastpath"). As such, it shares the fastpath capabilities to automatically cache pre-read or memory mapped copies of the files and can safely support multiple, simultaneous responses. The following headers are included in the output: Last-modified Constructed based on the modification time of the given file. Content-length Constructed based on the size of the give file. Content-type Constructed with the given type argument. If type is NULL, the type will be determined based on the filename using the Ns_GetMime- Type routine
SEE ALSO
Ns_ConnFlush(3), Ns_ConnReturnOpenFd(3), Ns_GetMimeType(3)
KEYWORDS
connnection, response AOLserver 4.0 Ns_ConnReturnFile(3aolserver)
Related Man Pages
ns_conncondsetheaders(3aolserv) - debian
ns_connqueueheaders(3aolserv) - debian
ns_connreturndata(3aolserv) - debian
ns_connreturnfdex(3aolserv) - debian
ns_connreturnopenchannel(3aolserv) - debian
Similar Topics in the Unix Linux Community
awk or sed - Convert 2 lines to 1 line
Find columns in a file based on header and print to new file
Weird 'find' results
A (ksh) Library For and From UNIX.com
New UNIX and Linux History Sections