PDA

Click to See Complete Forum and Search --> : CGI


mrbig
Oct 4th, 1999, 02:07 AM
Does anyone have a tutorial about making CGI with Visual Basic 6.0.

I heard you need a file like cgi.bas



------------------
Thanks for your help

DVint
Oct 5th, 1999, 07:41 AM
Last I heard, CGI programs were created with Perl or C. If VB6 can create them too, I want to know about it too.

------------------

webman
Oct 7th, 1999, 03:10 AM
CGI programs can be written in any language. You just have to go through the effort of getting the data from the browser by getting a handle to the standard input file and reading it. The data being sent to you is stored in a way similar to .ini files in that you get controlname=value;nextcontrolname=value;etc. (might be a comma instead of a semicolon, I haven't done it the hard way in a long time). When you are ready to write back to the browser you simply write your VB output to the standard output file handle. Both handles are easily available through an API call. The CGI.bas file you mentioned makes a lot of this easier for you but the last time I saw it it was for wincgi (different from cgi) and would require the coding of the standard in and out file handles as it uses different files. Since you're talking about VB6 you must be on a microsoft platform and I would ask you why you wouldn't just want to use ASPs? If the logic gets too advanced for VBScript, you can easily call a VB ActiveX dll from VBScript in your ASP and do whatever you want. ASPs make getting the data to and from the browser using CGI a snap (yes, ASPs use CGI to communicate to the browser).

------------------
WebMan

[This message has been edited by webman (edited 10-08-1999).]

ufjessey
Jan 25th, 2000, 12:50 AM
I use asp & vb cgi to develop web based
applications.
I'd tested the performance:
Asp need to be compiled and then execute,
but vb-cgi is already executable ...
so I found vb-cgi is little bit quicker.
VB can be used for standard cgi or cgi-win, and both can handle two byte character well.
The standard vb-cgi program can be run
under any cgi-bin web site, including IIS.
The best thing for vb-cgi is ..
there are lots of MS or 3rd party api to
call.
This is just a personal opinion.