iLTC Home
Bookmark iLTC!

Categories

Perl
  • Perl Tutorials Beginners

  • Javascript
  • Javascript Tutorials
  • Javascript Tutorials Beginners

  • HTML
  • HTML Tutorials

  • Command Line
  • Command Line Tutorials

  • How Tos
  • Other Tips and Tricks



  • <script type='text/javascript'>
    1727891

    iLoveTheCode.com

    What Environmental Variables are Available

    In PERL, to view all Environmental Variables type:

    foreach $ev(keys %ENV) {
    print "$ev - $ENV{$ev}<br>";
    }

    The Environmental Variables names will be in all caps on the left while their value is on the right.

    To access any of these Environmental Variables anytime, just type $ENV{'VAR_NAME'} where VAR_NAME is the name of the Environmental Variable:

    Example:

    For the query string:
    $ENV{'QUERY_STRING'}

    For the user's IP address:
    $ENV{'REMOTE_ADDR'}



    Copy and Paste Perl Code:

    #!/usr/bin/perl

    print "Content-type:text/html\n\n";

    foreach $ev(keys %ENV) {
    print "$ev - $ENV{$ev}<br>";
    }

    exit;




    Previous Article: Matching at the Beginning and End
    Next Article: Exit a Script or Subroutine in Perl






    Search iLTC w/ Google




    Recent Articles

  • HTML Font Code
  • Javascript and CSS - Easy Pop Up Help Balloons
  • Use OnMouseOver in Javascript
  • Use onMouseOut in Javascript
  • Use innerHTML to Change Text on a Page
  • Renaming a File with Perl's RENAME Function
  • PRINT to Browser with document.write Command in Javascript
  • Passing an Argument or Variable to a Javascript
  • Opening an Alert Box in Javascript
  • Opening a REMOTE WINDOW in Javascript
  • OPEN and WRITE a Data File in Perl
  • OPEN and READ a Data File in Perl
  • Mimic Typing from a Textfield in a Textarea with Javascript
  • Javascript Reset Form








  • Perl Programming - Javascript Programming - HTML Code - Mac Unix Command Line - Maybe Some PHP - Free Scripts - ILoveTheCode
    All Content © 2006-2009 iLoveTheCode.com


    Contact Chris | About this Site


    1727616
    Counter by iLoveTheCode.com


    Last Modified: Saturday, 10-Jan-2009 05:40:25 EST



    Hosted as well :)
    Home-brewed logo - 1997