Home | Contact Us | Log In | Help
HOME NEW LISTING MOST POPULAR HIGHEST RATED SCRIPTS ADD SCRIPT DOWNLOADS FORUM
Tutorials
  ASP.Net & C#
  ASP
  Perl and PHP
  Java Scripts
  C and C++
  Ajax Tutorials
  J2ee, J2Me, Java
  Python & Ruby Rail
  Crystal Report
  Sap
  CGI
  XML
  Cold Fusion & CFML
  HTML, DHTML & CSS
  Dreamweaver
  FLASH
  Photoshop/Web Designing
  Tools & Utilities
  Oracle/D2K
  Sql Server
  MySql
  Domain Name Registration
  Remotely Hosting
  Web/Server Application
  Hotel Marketing
  Internet and Law
   Search Engine Optimization/SEO
E-Commerce
Interview Questions
PERL and PHP 12
Beginner's Introduction to Perl

Perl is the Swiss Army chainsaw of scripting languages: powerful and adaptable. It was first developed by Larry Wall, a linguist working as a systems administrator for NASA in the late 1980s, as a way to make report processing easier. Since then, it has moved into a large number of roles: automating system administration, acting as glue between different computer systems; and, of course, being one of the most popular languages for CGI programming on the Web

PERL - Practical Extraction and Report Language

Created in 1987 by Larry Wall, the UNIX based language has evolved into a powerful tool for the internet. It was designed as a quick-fix patch program for UNIX based systems. The language is very simplistic, offering optimum flexibility, perfect for short, straightforward scripting.

Since then its popularity has increased due to its flexibility, portability, usefulness, and its varied features. To get started, load a simple text editor program and follow along in our examples.

Comments and statements
Comments can be inserted into a program with the # symbol, and anything from the # to the end of the line is ignored (with the exception of the first line). The only way to stretch comments over several lines is to use a # on each line.

Everything else is a Perl statement which must end with a semicolon, like the last line above.

Interpolation
The following code prints apples and pears using concatenation:
$a = 'apples';  $b = 'pears';  print $a.' and '.$b;  
It would be nicer to include only one string in the final print statement, but the line
print '$a and $b';  
prints literally $a and $b which isn't very helpful. Instead we can use the double quotes in place of the single quotes:
print "$a and $b";  
The double quotes force interpolation of any codes, including interpreting variables. This is a much nicer than our original statement. Other codes that are interpolated include special characters such as newline and tab. The code \n is a newline and \t is a tab
Installing a Perl Script

. To learn how to get a Perl script installed and running, we'll use the simple script below. When it is run, it will produce a web page with some simple text on it. To begin, copy and paste the script below into your favorite text editor (Notepad, Word, etc.):

Now, you will need to know where Perl is on your web server. This is because you may need to change the top line in this script. If you are unsure where Perl is, ask your web host or telnet your server and type the which perl command at the prompt:

  Copyright 2000-2006 © SoloScript.com, All rights reserved.