what conclusion did you make from that latter piece of info? ;-)
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>
Roland Maynard wrote:
Andrew Gaffney wrote:
roland maynard wrote:
I am able to view my CGI script fine in Mozilla on my linux
machine, but when I use internet explorer, it displays a blank
page. If you view the source code, the code is there that
should be displayed. I am using HTML-Template. Any s
is message:
http://www.mail-archive.com/beginners%40perl.org/msg59382.html
MIME::Lite can be installed using that 'manual' method. So can
Mail::Sender, which is another module for sending mail with attachments.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To
x27;running.pdf';
Any ideas?
I would try changing those to full paths. It's not advisable to rely
on an assumption about the working directory. Optionally you can set
the working directory with the chdir() function.
/ Gunnar
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contac
guration of the mail server. You could
for instance try to change
my $mail_host = 'smtp.dcs.kcl.ac.uk';
to
my $mail_host = 'localhost';
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional c
Werner Otto wrote:
Gunnar Hjalmarsson wrote:
If you don't get any error messages, another theory is that it
has something to do with the configuration of the mail server.
You could for instance try to change
my $mail_host = 'smtp.dcs.kcl.ac.uk';
to
my $mail_host = 'loc
Werner Otto wrote:
I've tried to change to localhost , no go...
Okay.
Add this line at the top of the script:
use CGI::Carp 'fatalsToBrowser';
Change this line:
$msg->send;
to
$msg->send or die "Error sending msg: $!";
--
Gunnar Hjalmarsson
Emai
Werner Otto wrote:
Gunnar Hjalmarsson wrote:
Add this line at the top of the script:
use CGI::Carp 'fatalsToBrowser';
The permissions on running.pdf was not correct. It helps if you
know how to debug!
Talking about debugging... You should get the habit of including:
use stric
d end up with saying $main::surname instead of $surname etc.
Normally you should declare your variables lexically using my() the
first time they appear:
my $surname = param("surname");
I recommend that you read this article:
http://perl.plover.com/FAQs/Namespaces.html
--
Gun
s, and submit it,
you'll receive a copy of the message. That's for your record, for your
convenience. Personally I think that makes sense.
That said, spammers and other abusers should certainly be taken into
consideration when dealing with mail via the web.
--
Gunnar Hjalmarsson
Em
Camilo Gonzalez wrote:
Gunnar Hjalmarsson wrote:
I think you are exaggerating, Randal. How much convenience are
you ready to sacrifice in order to fight possible abusers?
If you want to contact me privately, you can click the link
below. If you fill the form, including your own email address,
and
Brad Lhotsky wrote:
Gunnar Hjalmarsson wrote:
If you want to contact me privately, you can click the link
below. If you fill the form, including your own email address,
and submit it, you'll receive a copy of the message. That's for
your record, for your convenience. Personally I think
d qw(somefunction);
somefunction();
}
or
my $mod = 'Module';
eval "use $mod qw(somefunction)";
unless ($@) {
somefunction();
}
Please see:
perldoc perlmod
perldoc -f eval
HTH
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
die "'phrap fasta1' failed: $?";
system("vi test.pl") == 0 or die "'vi test.pl' failed: $?";
Please test the above, and let us know if it helped you figure out the
reason why no files are generated when you run the program via CGI.
--
Gunnar Hj
Bill Jones wrote:
Gunnar Hjalmarsson wrote:
Gunnar Hjalmarsson wrote:
If you want to contact me privately, you can click the link
below. If you fill the form, including your own email
address, and submit it, you'll receive a copy of the message.
That's for your record, for your c
Xiangli Zhang wrote:
Gunnar Hjalmarsson wrote:
system(" perl test1.pl");
This is a better way to run another Perl program:
eval "require 'test1.pl'" or die "Couldn't require test1.pl: $@";
system("phrap fasta1");
system("vi test
ion
makes sense to me, and CGI::ContactForm was designed accordingly. So
far, nobody who is using (or thinking of using) the module has
objected to the fact that it sends a copy of the message to the
sender.
Of course, it would be possible to make the sending of a copy
optional. Maybe something to consider
Xiangli Zhang wrote:
I use perl cgi to upload file(any type: text or image)
from web browser. The file was created, but is empty.
See http://www.w3.org/TR/html4/interact/forms.html#h-17.13.4
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL
at's the file's
permissions? (644 required, I suppose.)
Btw, exactly where is the file located?
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>
_file = 'z';
chmod 0755, $r_file or die "Cannot chmod $r_file: $!";
Err.. Since when doesn't 644 mean that a file is "world readable"? The
difference between 755 and 644 is that the execute bit is set when the
former is true, but if the file isn't going
wrong...
Any suggestions?
A wild guess, without knowing what the error message is, is that you
need to untaint $ENV{PATH}:
$ENV{PATH} = '';
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-ma
t;Location" header (with or without CGI.pm's redirect()
function), you can pass the string as a query string. But if cgi2 is
another Perl program, using the require() function may be a better
alternative.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubsc
[ Please do not top-post! ]
Xiangli Zhang wrote:
Gunnar Hjalmarsson wrote:
Xiangli Zhang wrote:
I am trying to redirect from cgi1(with one string variable say
$str with value from its calling parent html form) to cgi2, I
know I can use redirect function of CGI model to implement
redirection.
But i
That output wouldn't be correct, since the array contains six
elements, not five.
This code:
my $ref = $me->{verd_result}->[0];
print "len = " . @$ref, "\n";
for ( 0 .. $#$ref ) {
defined $ref->[$_] and print " v[$_]=$ref->[$_]\n"
Charles K. Clarkson wrote:
Gunnar Hjalmarsson wrote:
Siegfried Heintze wrote:
Consider the following program:
my $me;
$me->{verd_result}->[0][2]=5;
$me->{verd_result}->[0][5]=34;
print "len = ", [EMAIL PROTECTED]>{verd_result}->[0]}};
for (@{$me->{verd_result}->[
://groups.google.com/groups?threadm=1a1fc02.0408171946.2abd7dca%40posting.google.com
Otherwise, post a short but complete program using Perl that
illustrates the problem you tried to explain in English...
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail
ld be easier to advise.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>
[ Please type your reply *below* the quoted part of the message you
are replying to. ]
Chris Welch wrote:
Gunnar Hjalmarsson wrote:
Chris Welch wrote:
I have a dilemma, I am processing CGI forms and I need to come
up with a regex that will accept HTML entities (i.e., " or
{),
Your descri
e, and
encode the HTML critical characters each time you read it for display,
or you can encode the HTML critical characters before storing "stuff",
so that the stored data come (partially) HTML encoded and ready for
display whenever you read it.
Let me know if you think I have misunde
m{curr} };
@{ $m{curr_2} } = back @{ $m{prev} };
my %months =
map { $_, sprintf '%02d-%d', @{ $m{$_} } } qw/curr prev curr_2/;
print "\$months{$_}: $months{$_}\n" for qw/curr prev curr_2/;
Outputs:
$months{curr}: 09-2004
$months{prev}: 08-2004
$months{curr_2
olves
both the security issue AND the displaying in a web page issue?
That being the case, surely it would be safer to convert things to
entities on the off chance of something being a bit dodgy...
Your approach is ... unusual, and AFAIU unnecessary.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.c
CGI.pm's escapeHTML() function.
perldoc CGI
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>
gular expressions isn't so bad,
but if you really want to do it right, it's worth pulling in a
parsing engine like HTML::Parser or HTML::TreeBuilder or something
along those lines...
I can't see what this has to do with HTML parsing.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-
k here *after having tried* if you encounter problems that you
are not able to resolve by help of the docs.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>
Chris Devers wrote:
On Thu, 9 Sep 2004, Gunnar Hjalmarsson wrote:
I can't see what this has to do with HTML parsing.
The immediate problem has nothing to do with parsing, but it seemed
like some of the suggestions given were starting to go in that
direction.
Maybe.
The reason for my remark is
let the
first script retrieve the output from the 3rd-party script by help of
LWP::UserAgent, and have it display it.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://lea
calculating the width, something that I thought web browsers and
HTML were designed to avoid. What am I missing to force the
cells to (at least) a fixed width?
The width attribute for cells is deprecated. Try setting table width
for the inner tables instead.
--
Gunnar Hjalmarsson
Email: http
o abandon tables for content
positioning on HTML pages.
But you would be better off if you asked that question in a forum for
HTML.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
&l
re of?
Normally you need to be concerned about it. The fact that a program is
invoked via CGI makes no difference in this respect.
The flock() function is one way to deal with it in Perl. See "perldoc
-f flock".
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsu
cript is invoked, so in that respect I can
understand what you mean. But would mod_perl have a significant
impact on speed in any other respect? Isn't it still a set of code
that shall be executed?
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-ma
, and I'd like to add CGI::Minimal to the list.
Can you recommend me some tricks to make it work a little faster?
No.
If I want to use the OOP style, is it possible to load only some
methods and not all?
Sure, that's what you normally do, isn't it? However, whether you
import a few fun
Chris Devers wrote:
Gunnar Hjalmarsson wrote:
Chris Devers wrote:
if you need a speed boost then the best strategies are to [a]
use a smaller subset of CGI.pm,
Does that really make a lot of difference?
That was my understanding, but I admit I haven't benchmarked it.
If only importing pa
t via its fully qualified name: $main::myvar
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>
Chris Devers wrote:
Gunnar Hjalmarsson wrote:
Btw, wonder how the autoloading affects that. I mean, when
running under mod_perl, you normally *want* everything to be
loaded at the start of the server, right?
Well, everything you're likely to use, yeah.
There doesn't seem to be muc
he problem?
Well, you are not even letting us know from which line that error
message comes...
I don't know anything about those modules you are using, but I suppose
that their docs describe how to check for success. There is where I
would start the debugging work.
A mailing list should be th
r instance opening files. So that's what I
recommend you to do: Revise the code in the modules, and make sure you
capture possible failures when they occur.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additio
;s possible to use a remote MTA instead. It should be
noted that many scripts include a simple pipe to the local mail
program, and a remote MTA precludes that technique.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional comm
else Perl will complain about O_RDWR and/or O_CREAT instead. The
latter are imported by default when using Fcntl, but need to be
explicitly imported if you explicitly import anything else.
perldoc Exporter
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe,
g to do with CGI, so you should
have posted it to the [EMAIL PROTECTED] list instead.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>
Aben Siatris wrote:
DÅa Tuesday 28 September 2004 11:42 Gunnar Hjalmarsson napÃsal:
Octavian Rasnita wrote:
I have a hash that have multiple sub hashes and I want to sort
it by a sub key.
For example, I have:
$comp{$code}{$year}{profit}.
And I want to sort the $code values after the value of the
Octavian Rasnita wrote:
Gunnar Hjalmarsson wrote:
You don't need another hash.
perldoc -f sort
perldoc -q "sort a hash"
my @codes = sort {
$comp{$a}{$year}{profit}
<=>
$comp{$b}{$year}{profit}
} keys %comp;
I have tried th
Ivanca S wrote:
I'm beginner in perl; I mean I have absolutely no experience. Could
anybody tell me waht would be the first steps for learning perl?
http://learn.perl.org/
I am intrested to write cgi perl scripts
http://cgi.resourceindex.com/Documentation/CGI_Tutorials/
--
G
OS X)
To allow somebody but the web server to open a script created file for
reading, have the script give it 0644 permissions.
It sounds as if you need to read up on the Unix/Linux permissions system.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail
t find a way in Lincoln's book to detect this
condition so I can respond accordingly to the client. Does anyone
here know how this might be done?
It's explained in "perldoc CGI".
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PR
>cgi_error()) {
print $Q->header;
$message = $Q->cgi_error();
&error_trap($message);
}
Yeah, I noticed too that the OO interface works. Nevertheless I'm
inclined to believe that it is a bug in CGI.pm and/or its docs, but it
would be good if somebody with more CGI.pm experience co
What can I do limit string length to 40 characters?
Use a suitable function, or a regex, or something like that. What have
you tried?
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTEC
note that people can submit to the script using e.g. their
own form, so if you want to *make sure* that longer strings are not
accepted, the maxlength attribute is not sufficient, and can *never*
replace a proper validation of the form data.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-
int $res->content;
As you can see, it's very easy to fake the HTTP_REFERER.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>
Victor wrote:
I need to access a variable like this: $cgi->param($variable);
This doesn't work.
But this works: $cgi->param('name');
The first try ($cgi->param($variable)) ends with a "Internal server error".
Please post a short but complete program that illus
;/, $str_file);
Please show us the form.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>
hould add
enctype="multipart/form-data"
to the tag.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>
n't
need to use any of the above methods. To have die messages appear in the
browser you'd better do:
use CGI::Carp 'fatalsToBrowser';
die "test die";
HTH
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e
something in my
perl code
You shouldn't store the file in the cgi-bin tree. Store it somewhere
else, and you'll probably notice a difference.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-ma
econd message in this thread?
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
This
would be the path on the filesystem:
/var/www/html/images/file.png
while this would be one way to write the URL:
/images/file.png
" File does not exist: /var/www/html/var, referer:
http://mymachine/cgi-bin/image.cgi";
--
Gunnar Hjalmarsson
Email: http://www.gu
s already a document root, and the /images
directory should have been put there.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
. Under xhtml-sctrict should be
inserted: checked="checked"! How to achieve this?
Other than printing the checkbox manually, I don't know.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional comm
ang="en-US">
Hello World, Address, Colours
START
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
-BGCOLOR=>'blue',
-dtd=>[ '-//W3C//DTD XHTML 1.0 Strict//EN',
'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd' ]
);
But the resulting markup does not validate as XHTML 1.0 Strict, does it?
I'm thinking of t
Judy & Jim Schueckler wrote:
I need code to remove one or more leading or trailing spaces without
removing internal spaces.
perldoc -q space
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-
Zazen wrote:
Hi dude! I have an orrible trouble with this poor cgi: is a client
pop3 web based gateway.The function "connetti()" never been called and
i don't know why!! ...
Weren't the advices you got in comp.lang.perl.misc good enough?
--
Gunnar Hjalmarsson
Email: http
wns, etc.
I am experienced in Perl and have have worked with simple HTML. I was
told CGI might be the way to go in developing such an application. My
question is, does that seem reasonable?
Absolutely. Please study the CGI.pm docs to get started.
perldoc CGI
--
Gunnar Hjalmarsson
Email: http://ww
stop spam.
The 'spamfilter' regex is one of them, and there is also a cookie based
method for preventing automated messages from being sent.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mai
[EMAIL PROTECTED] wrote:
The problem is that after the first successful send/receive, all
subsequent executions contain the same initial data: the parameters
never get reset with 'newer' data.
I wasn't able to reproduce the described problem.
--
Gunnar Hjalmarsson
Email: http:
[EMAIL PROTECTED] wrote:
On Nov 20, 11:52 pm, [EMAIL PROTECTED] (Gunnar Hjalmarsson) wrote:
[EMAIL PROTECTED] wrote:
The problem is that after the first successful send/receive, all
subsequent executions contain the same initial data: the parameters
never get reset with 'newer'
ming you are using CGI.pm,
print header(-status => '204 No Content');
HTH
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
e I have done:
Well, the code you posted is far too much to my taste. Please post a
_small_ but complete program that illustrates the problem you are having.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
search.cpan.org/perldoc?CGI::UploadEasy#EXAMPLE
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
generate a list of dates:
Why are you asking this question on the beginners-cgi list?
Anyway, the code in this message might be useful to you:
http://www.mail-archive.com/[EMAIL PROTECTED]/msg90421.html
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail
Mimi Cafe wrote:
Hi,
I am trying to process a directory and all subdirectory recursively and
Please do not multi-post!!
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http
<
Maybe you meant that to be
sub deletePage {
You need a content-type header here.
print CGI::header();
print "File was deleted successfully!";
}
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
F
# slurp the whole thing
$links = <$TXT>;# into a scalar
}
while ( $links =~
m|(.+?)|gsi ) {
print "$1\n";
}
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
command line and got:
Undefined subroutine &main::populateEmail called at ./cgi_list_bug.pl line 6
This same question (without the missing 'sub') has already been asked
and answered in clpmisc.
http://groups.google.com/group/comp.lang.perl.misc/browse_frm/thread/c8c266eb779a4cb4
reliable way to
determine e.g. text or binary.
What's the purpose of your desire to know the file type?
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
age about an insecure environment command.
Did it just say "insecure environment"? On my box it says: "Insecure
$ENV{PATH} ...", which means that you need to untaint the $ENV{PATH}
variable. The easiest way to do that is:
$ENV{PATH} = '';
Please read more about Perl
Adam Jimerson wrote:
Gunnar Hjalmarsson wrote:
Adam Jimerson wrote:
are you using the -T switch on your
script? When I tried to open "/usr/bin/mail" with that switch on I get a
error message about an insecure environment command.
Did it just say "insecure environment"
Adam Jimerson wrote:
Gunnar Hjalmarsson wrote:
Adam Jimerson wrote:
Do I need to specify anything for the $ENV{PATH} or do I just leave it
blank
It depends. You have to take into consideration whether your program
relies on any of the paths. If not, it's fine to leave it blank.
The
Dermot Paikkos wrote:
This is all very OT
Is a discussion about taintedness off topic on a Perl-CGI list? Don't
think so.
and the thread is running strongly on perl-beginners.
:-/
And...?
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e
Adam Jimerson wrote:
Gunnar Hjalmarsson wrote:
There is only one suspected variable to consider, i.e. $name, which is
probably tainted. Untaint it, and you are done. ( You remember where to
find out how, right? ;-) )
According to perlsec I need to use it as a key in a hash or reference a
l => '/style/ContactForm.css',
);
You find the module at CPAN:
http://search.cpan.org/dist/CGI-ContactForm/
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: beginners-cgi-unsubscr...@perl.org
For additional commands, e-mail: beginners-cgi-h...@perl.org
http://learn.perl.org/
Adam Jimerson wrote:
Gunnar Hjalmarsson wrote:
You don't say what to do if the untainting fails. This code:
if ($name =~ /^([...@\w.]+)$/) {
$name = $1;
};
should better be:
if ($name =~ /^([...@\w.]+)$/) {
$name = $1;
} else {
die "Untainting of the name failed";
}
Pleas
Adam Jimerson wrote:
On Jan 11, 8:21 am, nore...@gunnar.cc (Gunnar Hjalmarsson) wrote:
Adam Jimerson wrote:
It seams I over looked the space, is it possible to include spaces in the
search string?
Of course it is. What you call search string is a regular expression.
Obviously you have some
Adam Jimerson wrote:
Gunnar Hjalmarsson wrote:
Adam Jimerson wrote:
Yea I looked it up and all I needed to do was add \s for whitespaces,
Which would also allow for newlines. That sounds dangerous to me, and is
an example why it's not a good idea to write your own code, that allows
).'='.uri_escape($args{$key});
}
my $query = join ';', @args;
print $q->redirect("$url?$query");
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: beginners-cgi-unsubscr...@perl.org
For additional commands, e-mail: beginners-cgi-h...@perl.org
http://learn.perl.org/
"cwt_page_content"
with page_id = 5///
I need to make changes in that page source. I am unable to find where
that page is located. Can you please help me telling how to find
those files to change the content in that.
Look in the source of index.cgi.
--
Gunnar Hjalmarsson
Email: http://www
Lewis Kirk wrote:
Which is obviously a real beginner question.
Yes, but not a CGI question in any way.
Please post it to the beginners list instead. When you do, post as a new
message, and not as a reply to a message about some other topic.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc
ike a module I wrote,
CGI::UploadEasy, could be useful to you.
http://search.cpan.org/dist/CGI-UploadEasy/
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: beginners-cgi-unsubscr...@perl.org
For additional commands, e-mail: beginners-cgi-h...@per
tanding of
small code fragments, provided that you try on your own first. Please
post such possible questions to the beginners list, unless they are CGI
related.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: beginners-cgi-unsubscr...@pe
t...@asgweb.net wrote:
I have a routine that is intended to purge duplicates from a list of
emails. It's currently not working.
perldoc -q duplicate
What has this to do with CGI?
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: begi
me, $value;
push @cookie_values, $value if $name eq 'var';
}
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
--
To unsubscribe, e-mail: beginners-cgi-unsubscr...@perl.org
For additional commands, e-mail: beginners-cgi-h...@perl.org
http://learn.perl.org/
1 - 100 of 110 matches
Mail list logo