> Dave Fowlie wrote:
>
> Right I'm trying to convert an existing PERL cgi file (which used to
> run on a Linux machine)
>
> I've got Active Perl installed on my Win2k box....and I started
> writing the file using perlscript as an ASP page.
>
> I immediately bumped into a problem.
>
> There's lots of lists (arrays) in the original Perl Code....and I
> still want to use them, cause they're part of what makes Perl
> functional.....but IIS complains that the @ symbol can only be used
> once and only at the top of the page for one of the ASP inbuilt @
> directives......
>
> How then are you supposed to implement an array in ASP file using
> PerlScript as the scripting language?
>
> Do you have to use the .plx extension that gets installed into IIS?
My guess is that the first statement in your Perl code is an array
declaration?
I've run into the same problem. In ASP PerlScript, your first line
can't begin with a '@' character because the ASP engine thinks you're
talking to it.
Assuming your code looks similar to the following:
<%@ language=PerlScript %>
<HTML>
<HEAD>...</HEAD>
<%
@array = ($stuff, $more_stuff, $etc);
...
%>
either use my() to scope the array variable. (Since you have 'use
strict;' as the first line in your script, right?). Or you might try
this:
<%
# dummy comment
@array = (...);
...
%>
...as long as the @ isn't the first character after the <% delimiter.
If this doesn't help, or this isn't the case, I'll need more info.
HTH
--
-Tim Hammerquist <[EMAIL PROTECTED]>
The great tragedy of Science -- the slaying
of a beautiful hypothesis by an ugly fact.
-- Thomas Henry Huxley
_______________________________________________
Perl-Win32-Web mailing list
[EMAIL PROTECTED]
http://listserv.ActiveState.com/mailman/listinfo/perl-win32-web