资源简介
飞机订票系统。loadrunner11自带的飞机票系统,从其中进行摘取
代码片段和文件信息
/* $Id: testcgi.cv 1.1 2004-10-26 12:32:40 evgenyk Exp $ [MISCCSID] */
/* -----------------------------------------------------------------
Name: testcgi.c
title: CGI test program
Package: Xitami web server
Written: 96/10/01 Pieter Hintjens
Revised: 97/09/29 Pieter Hintjens
Synopsis: Generates an HTML test page containing the arguments passed
to the CGI process.
To build this program you must download the SFL package from
www.imatix.com.
Copyright: Copyright (c) 1998 iMatix
License: This is free software; you can redistribute it and/or modify
it under the terms of the XITAMI License Agreement as provided
in the file LICENSE.TXT. This software is distributed in
the hope that it will be useful but without any warranty.
------------------------------------------------------------------ -*/
#include “sfl.h“ /* SFL functions */
static Bool dump_symbol (SYMBOL *symbol ...);
static char *time_str (void);
int
main (int argc char *argv [])
{
SYMTAB
*symbols;
int
index;
char
*curdir;
size_t
content_length;
printf (“Content-Type: text/html\n\n“);
printf (“tle>CGI Test Program tle>\n“);
printf (“\n“);
printf (“CGI Test Program
\n“);
/* Print argument variables if any */
if (argc > 1)
{
printf (“Arguments To Testcgi
\n“);
printf (“\n“);
for (index = 1; index < argc; index++)
printf (“Argument %d : %s\n“ index argv [index]);
printf (“
\n“);
}
/* Print POST data variables coming from stdin if present */
content_length = (size_t) env_get_number (“HTTP_CONTENT_LENGTH“ 0);
if (content_length)
{
symbols = sym_create_table ();
if (symbols)
{
if (cgi_parse_file_vars (symbols stdin ““ content_length) > 0)
{
printf (“POST Data Variables
\n“);
printf (“\n“);
sym_exec_all (symbols dump_symbol);
printf (“
\n“);
}
sym_delete_table (symbols);
}
}
/* Print URL query variables coming from QUERY_STRING */
symbols = sym_create_table ();
if (symbols)
{
if (cgi_parse_query_vars (symbols
env_get_string (“QUERY_STRING“ ““) ““) > 0)
{
printf (“QUERY_STRING Variables
\n“);
printf (“\n“);
sym_exec_all (symbols dump_symbol);
printf (“
\n“);
}
sym_delete_table (symbols);
}
/* Print environment variables
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2018-10-17 15:58 WebTours\
目录 0 2018-10-17 11:29 WebTours\cgi-bin\
文件 34 2004-10-26 20:32 WebTours\cgi-bin\readme.txt
目录 0 2018-10-17 11:29 WebTours\cgi-src\
文件 4822 2004-10-26 20:32 WebTours\cgi-src\testcgi.c
文件 1610 2004-10-26 20:32 WebTours\cgi-src\testcgi1.c
文件 1333 2004-10-26 20:32 WebTours\cgi-src\testcgi2.c
文件 1308 2004-10-26 20:32 WebTours\cgi-src\testcgi3.c
文件 1312 2004-10-26 20:32 WebTours\cgi-src\testcgi4.c
文件 1336 2004-10-26 20:32 WebTours\cgi-src\testcgi5.c
文件 1295 2004-10-26 20:32 WebTours\cgi-src\testcgi6.c
文件 1453 2004-10-26 20:32 WebTours\cgi-src\testcgi7.c
文件 175 2004-10-26 20:32 WebTours\cgi-src\testperl.pl
文件 0 2018-10-17 15:58 WebTours\cgierr.log
文件 8050 2004-10-26 20:18 WebTours\ddnsdef.xm
文件 52 2004-10-26 20:18 WebTours\defaults.cfg
目录 0 2018-10-17 11:29 WebTours\errors\
文件 20 2004-10-26 20:32 WebTours\errors\footer.htm
文件 37 2004-10-26 20:32 WebTours\errors\header.htm
文件 57 2004-10-26 20:32 WebTours\errors\text-400.htm
文件 43 2004-10-26 20:32 WebTours\errors\text-401.htm
文件 45 2004-10-26 20:32 WebTours\errors\text-402.htm
文件 47 2004-10-26 20:32 WebTours\errors\text-403.htm
文件 53 2004-10-26 20:32 WebTours\errors\text-404.htm
文件 74 2004-10-26 20:32 WebTours\errors\text-412.htm
文件 39 2004-10-26 20:32 WebTours\errors\text-413.htm
文件 46 2004-10-26 20:32 WebTours\errors\text-500.htm
文件 46 2004-10-26 20:32 WebTours\errors\text-501.htm
文件 61 2004-10-26 20:32 WebTours\errors\text-502.htm
文件 142 2004-10-26 20:18 WebTours\ftpadios.txt
文件 1266 2004-10-26 20:18 WebTours\ftpdirs.aut
............此处省略159个文件信息
评论
共有 条评论