Scot Robnett wrote:
Does anyone know how I capture the value of an operation that defaults to
STDOUT? For instance if I want to do something like
#!/usr/bin/perl -w
use strict;
my $value = `perl -c someapp.cgi`; # prints to STDOUT
print "Content-type: text/html\n\n";
print "Result: $value";
This
> do I need them every time I declare a variable?
Nope. The parens force "list context". Without them is "scalar" context.
For example...
my @foo = qw(1 2 3 4 5);
my $x = @foo; # =5, the number of elements
my ($y) = @foo; # =1, the first element
Certain functions and operations will do diffe
Quick question:
my( $string ) = "you ordered " . $q->param('quantity') . " foobars\n";
What with the '( )' do I need them every time I declare a variable?
Thanks!
Dave
( kora musician / audiophile / web master @ cora connection / Ft. Worth, TX, USA)
==
Does anyone know how I capture the value of an operation that defaults to
STDOUT? For instance if I want to do something like
#!/usr/bin/perl -w
use strict;
my $value = `perl -c someapp.cgi`; # prints to STDOUT
print "Content-type: text/html\n\n";
print "Result: $value";
This obviously won't wo
On Wednesday, Mar 5, 2003, at 17:44 US/Pacific, mel awaisi wrote:
[..]
Could someone please look at my script and tell me why i am getting
this!!! please
[EMAIL PROTECTED] cgi-bin]# ./renamer.pl&
[2] 11033
[1] Exit 127renamer.pl
[EMAIL PROTECTED] cgi-bin]# usage: ./renamer.pl in