Cgic

来自开放百科 - 灰狐
跳转到: 导航, 搜索

cgic: an ANSI C library for CGI Programming

http://www.boutell.com/cgic/

Functions

  • Parses form data, correcting for defective and/or inconsistent browsers
  • Transparently accepts both GET and POST form data
  • Accepts uploaded files as well as regular form fields
  • Provides functions to set and retrieve "cookies" (browser-side persistent information)
  • Handles line breaks in form fields in a consistent manner
  • Provides string, integer, floating-point, and single- and multiple-choice functions to retrieve form data
  • Provides bounds checking for numeric fields
  • Loads CGI environment variables into C strings which are always non-null
  • Provides a way to capture CGI situations for replay in a debugging environment, including file uploads and cookies

Install

wget http://www.boutell.com/cgic/cgic205.tar.gz
tar zxvf cgic205.tar.gz
cd cgic205
make 
cp capture.exe /var/www/cgi-bin/
http://localhost/cgi-bin/capture.exe // use Cygwin

Build

gcc -o cgictest.html cgictest.c libcgic.a
http://localhost/cgi-bin/cgictest.html
分享您的观点
个人工具
名字空间

变换
操作
导航
工具箱