Browsing the Web (JNNC Technologies)


For knowing the concept of CGI, let us take a look at the scenario that takes place when users browse something on web using a specific URL.
  1. The browser you are using contacts the HTTP web server and demands for the URL.
  2. Web server will parse the URL and will search for the file name; if the requested file is found, immediately sends back that file to the browser or else sends an error message.
  3. The web browser takes the response from web server and display either file received or an error message.
If you are developing a web site and you required a CGI application to control then you can specify the name of the application in the URL (uniform resource locator) that you code in an HTML file.

Server Configuration

Before using the CGI programming, programmers should make sure that the Web server supports CGI and is well configured for handling CGI programs. By convention CGI files will have extension as .cgi, though they are C++ executable. By default, Apache Web Server is configured to run CGI programs in /var/www/cgi-bin. Programmers need to have a web server up and running in order to run any CGI program like Perl, shell etc.

Post a Comment

0 Comments

'; (function() { var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true; dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js'; (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq); })();