/*+++++++++++++++++
  cgi.h - header file for cgi support functions
  markus@mhoenicka.de 7-3-01
  $Id: cgi.h,v 1.4 2002/12/13 20:34:31 mhoenicka Exp $

   This program is free software; you can redistribute it and/or modify
   it under the terms of the GNU General Public License as published by
   the Free Software Foundation; either version 2 of the License, or
   (at your option) any later version.
   
   This program is distributed in the hope that it will be useful,
   but WITHOUT ANY WARRANTY; without even the implied warranty of
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
   GNU General Public License for more details.
   
   You should have received a copy of the GNU General Public License
   along with this program; if not, see <http://www.gnu.org/licenses/>

   ++++++++++++++++++++++++*/

#define CGI_PLAIN 0
#define CGI_HTML 1
#define CGI_NAME_LENGTH 32
#define HTML_FRAG_EXT ".html"
#define HTML_FRAG_SIZE 4096

int is_cgi(char** request_method, char** content_length, char* delayed_cgi_errmsg);
void write_err(char* message);
void cgi_header(int type);
int decode_cgi(char* cgi_data, struct liliform* ptr_first);
char* load_html(char* basename, char* sharedir);
