A perl-javascript question (?)  :)

I sometime code javascript in my scripts like:

my $script=<<EOS;
function foo {
        alert('message from foo\\n');
        }
EOS

then do :

print $q->start_html(-script=>'$script');

But this requires the "escapes" have to be "escaped" ... Does anyone have an
alternative... IS there a "switch" in perl to "handle" this ? 

jwm

-----Original Message-----
From: Rob Helmer [mailto:[EMAIL PROTECTED]]
Sent: August 15, 2002 17:59
To: [EMAIL PROTECTED]
Subject: Re: perl module problem


Hello,


Isn't this offtopic for the perl-javascript list?
I haven't seen an on-topic one for a while :) I'll have to think of
something to post soon.

Anyway, you CAN take code from the module and put it into your own
program, but you would probably be better off just installing the
perl module into your home directory on your ISP and using 
"use lib" in your program to refer to the specific library you need.

That keeps things nice and modularized.

In "compiled" languages like C, you can statically or dynamically
compile other libraries into your binary, but Perl is generally run
as an interpreted language so you don't do it this way ( it may
be possible, I don't really know ).



HTH,
Rob Helmer

On Thu, Aug 15, 2002 at 09:33:21PM +0000, [EMAIL PROTECTED] wrote:
> Hi I have a question please. My ISP have not instaled a Perl Module whitch
I need for my script. So my script doesn't work. I am a programer so I
remember it is a way to add functions (methods) from that library to the
script and you not need that library. Your script will get the methosds form
his source. Am I right?
> 10x
> 
> 
> 
> 
>
----------------------------------------------------------------------------
-----------------------
> Runbox Mail Manager (free trial version - this tag is removed upon
subscription)
> Try your own premium email account for free at http://111.runbox.com
> 100MB storage, no ads, fast webmail, access on any device, retrieve and
filter email.
> 

Reply via email to