Gossamer Forum
Home : General : Perl Programming :

Illegal variable name.

Quote Reply
Illegal variable name.
I've got the following script that keeps returning the error "Illegal variable name.". The trouble is, I don't see any variables which might cause any conflicts with reserved names. Can anyone help? Thanks!
Code:
#/usr/local/bin/perl -w

#___________________________________________________________________________
#
# index.cgi
#
# Revision : 16:06 12/11/01
#
# Author : Wiliam Stephens
# E-Mail : wilstephens@hotmail.com
#
#___________________________________________________________________________


$| = 1;

use CGI;
$query = new CGI;

print $query->header;

@listhtml = (index.apricot.html,
index.butter.html,
index.garden.html,
index.greek.html,
index.maple.html,
index.raspberry.html,
index.strawberry.html,
index.natural.html
);

$htmlrand = $listhtml[int rand @listhtml];

open (FILE, "</home/fba/beta.rachelsorganic.co.uk/$htmlrand");
@html = <FILE>;
close FILE;

print "@html";

exit;

- wil
Subject Author Views Date
Thread Illegal variable name. Wil 20623 Nov 12, 2001, 8:23 AM
Thread Re: [Wil] Illegal variable name.
Paul 19473 Nov 12, 2001, 8:48 AM
Thread Re: [RedRum] Illegal variable name.
Wil 19465 Nov 12, 2001, 8:53 AM
Thread Re: [Wil] Illegal variable name.
Paul 19441 Nov 12, 2001, 8:55 AM
Thread Re: [RedRum] Illegal variable name.
Wil 19613 Nov 12, 2001, 8:58 AM
Post Re: [Wil] Illegal variable name.
Paul 19320 Nov 12, 2001, 9:00 AM
Thread Re: [Wil] Illegal variable name.
Stealth 19394 Nov 12, 2001, 9:06 AM
Post Re: [Chewbaca] Illegal variable name.
Paul 19345 Nov 12, 2001, 9:11 AM
Thread Re: [Chewbaca] Illegal variable name.
Wil 19444 Nov 12, 2001, 9:12 AM
Thread Re: [Wil] Illegal variable name.
Paul 19884 Nov 12, 2001, 9:16 AM
Thread Re: [RedRum] Illegal variable name.
Wil 19526 Nov 12, 2001, 9:21 AM
Thread Re: [Wil] Illegal variable name.
Chaz 19520 Nov 12, 2001, 9:35 AM
Thread Re: [CP] Illegal variable name.
Wil 19410 Nov 12, 2001, 9:45 AM
Thread Re: [Wil] Illegal variable name.
Paul 19346 Nov 12, 2001, 9:49 AM
Thread Re: [RedRum] Illegal variable name.
Wil 19456 Nov 12, 2001, 9:52 AM
Post Re: [Wil] Illegal variable name.
Paul 19274 Nov 12, 2001, 9:55 AM
Thread Re: [Wil] Illegal variable name.
Paul 19868 Nov 12, 2001, 9:52 AM
Thread Re: [RedRum] Illegal variable name.
Wil 19372 Nov 12, 2001, 9:54 AM
Thread Re: [Wil] Illegal variable name.
Paul 19493 Nov 12, 2001, 9:56 AM
Thread Re: [RedRum] Illegal variable name.
Wil 19452 Nov 12, 2001, 10:04 AM
Post Re: [Wil] Illegal variable name.
Paul 19245 Nov 12, 2001, 10:08 AM
Thread Re: [Wil] Illegal variable name.
Paul 19311 Nov 12, 2001, 10:11 AM
Thread Re: [RedRum] Illegal variable name.
Wil 19343 Nov 12, 2001, 10:21 AM
Thread Re: [Wil] Illegal variable name.
Paul 19310 Nov 12, 2001, 10:26 AM
Thread Re: [RedRum] Illegal variable name.
Wil 15947 Nov 12, 2001, 1:07 PM
Thread Re: [Wil] Illegal variable name.
Paul 15855 Nov 12, 2001, 1:47 PM
Thread Re: [RedRum] Illegal variable name.
Wil 15840 Nov 13, 2001, 2:28 AM
Thread Re: [Wil] Illegal variable name.
Paul 15949 Nov 13, 2001, 5:04 AM
Thread Re: [RedRum] Illegal variable name.
Wil 15952 Nov 13, 2001, 5:28 AM
Thread Re: [Wil] Illegal variable name.
Paul 15774 Nov 13, 2001, 5:35 AM
Thread Re: [RedRum] Illegal variable name.
Wil 15771 Nov 13, 2001, 5:43 AM
Post Re: [RedRum] Illegal variable name.
Wil 15704 Nov 13, 2001, 5:43 AM
Thread Re: [Wil] Illegal variable name.
Paul 15867 Nov 13, 2001, 5:47 AM
Thread Re: [RedRum] Illegal variable name.
Wil 15811 Nov 13, 2001, 6:09 AM
Thread Re: [Wil] Illegal variable name.
Paul 15834 Nov 13, 2001, 6:15 AM
Thread Re: [RedRum] Illegal variable name.
Wil 15821 Nov 13, 2001, 6:30 AM
Thread Re: Illegal variable name.
Wil 15722 Nov 13, 2001, 8:42 AM
Thread Re: [Wil] Illegal variable name.
Paul 15949 Nov 13, 2001, 8:47 AM
Post Re: [RedRum] Illegal variable name.
Wil 15707 Nov 13, 2001, 9:01 AM
Post Re: [Wil] Illegal variable name.
Chaz 15773 Nov 13, 2001, 6:11 AM
Thread Re: [RedRum] Illegal variable name.
sponge 15882 Nov 12, 2001, 2:36 PM
Thread Re: [PerlFreak] Illegal variable name.
Paul 16042 Nov 12, 2001, 3:17 PM
Thread Re: [RedRum] Illegal variable name.
sponge 15915 Nov 13, 2001, 11:10 AM
Post Re: [PerlFreak] Illegal variable name.
Paul 15691 Nov 13, 2001, 11:46 AM
Post Re: [Wil] Illegal variable name.
Paul 19375 Nov 12, 2001, 9:36 AM
Thread Re: [Wil] Illegal variable name.
Paul 15777 Nov 13, 2001, 11:52 AM
Thread Re: [RedRum] Illegal variable name.
Wil 15780 Nov 13, 2001, 12:11 PM
Thread Re: [Wil] Illegal variable name.
Paul 15838 Nov 13, 2001, 12:19 PM
Post Re: [RedRum] Illegal variable name.
Wil 15661 Nov 13, 2001, 12:23 PM