What Is CGI Access for cPanel?

What Is CGI Access for cPanel? thumbnail
Website owners can access various CGI features through cPanel.

Web hosts provide cPanel for managing Web pages, scripts, site statistics and other website features. Common Gateway Interface, or CGI, is a protocol used to run guestbooks or other kinds of CGI scripts on websites, and cPanel provides a number of ways to get CGI access. Make a more useful website by learning how to access and install CGI scripts through cPanel.

  1. CGI Center

    • The cPanel CGI Center provides two main ways to integrate CGI into your website. You can access and install a number of scripts that already exist in the cPanel system, or use the Simple CGI Wrapper to create a CGI folder on your website to install scripts that you either make yourself or purchase from a programmer. Click on "CGI Center" after logging into your cPanel account to access these features.

    Types of Scripts

    • The CGI Center includes scripts for a guestbook, a random HTML generator that rotates text messages, a statistics counter, the current time and date, a countdown timer for New Year's or some other special occasion, CGI email, a website search engine and scripts for various kinds of advertising banners. Use the Simple CGI Wrapper if you want to use a script that is not included with cPanel.

    Installation

    • To install CGI scripts provided by cPanel, click on your chosen script from the menu in the CGI Center, then follow the instructions on that script's page to set up the script. Copy the provided HTML code and paste it in each page where you want to display that feature. For example, to display a guestbook on your homepage, copy and paste the HTML provided by cPanel to the HTML of your homepage. To add HTML in cPanel, go to "File Manager" in the main menu, select the folder that contains the Web page, select the Web page, choose "Code Editor," then copy and paste the HTML in that editor.

    Simple CGI Wrapper

    • The Simple CGI Wrapper lets you create a folder that automatically treats files posted there as CGI scripts. Click on "Simple CGI Wrapper" in the CGI Center and follow the instructions to create the folder. To install or access a script, go to "File Manager" in the cPanel main interface, choose the "/public_html" folder and select the "/scgi-bin" folder. Once inside that folder, you can access all existing CGI files. To install a new script, click on "Upload" and "Browse" to find the script on your computer. CPanel uploads it to that same CGI folder, then creates a specific website address for the script in the following format: YourWebsiteName.com/Scgi-bin/ScriptName.cgi.

    Other Methods

    • Advanced users can also use the command-line interface, or CLI, to access CGI. The process for this depends on your Web host's configuration. Ask the host for instructions about how to get SSH access and use CLI on the server that hosts your website. You also need a command-line text editor such as Vi, Pico or Emacs. Also, check if your host uses the suEXEC program, which also allows you to add your own CGI scripts. However, neither CLI nor suEXEC is necessary -- these methods are merely alternatives to the Simple CGI Wrapper.

Related Searches:

References

  • Photo Credit Jupiterimages/Pixland/Getty Images

Comments

Related Ads

Featured