On Tue, Mar 16, 2010 at 11:47 AM, jbl wrote:
> I am reading a directory and creating an array of .png file names. I
> know for a fact that there are 1025 png files in the folder
> With $count = @files I get 1027
> With $last = $#files I get 1026
> $files [0] = .
> $files[1] = ..
> I have heard of
u. Also make sure that the
permissions comply with whatever the site's security policy is. Many
servers won't execute scripts that are world-readable, for instance.
HTH,
-- jay
--
This email and attachment(s): [ ] blogable; [ x ] ask first
output. See perldoc -f print for more detail.
You probably want something like
print while (<$fh>);
You could also store the file to an array first, or "slurp" the file,
if you want to eliminate the loop.
HTH,
--jay
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
server approach where all writes are dispatched to a single
writer process that serializes the write requests before committing
them to disk.
HTH,
-- jay
--
This email and attachment(s): [ ] blogable; [ x ] ask first; [ ]
private and confidential
d
to optimize your code; Perl does it for you.
Once more, just so we're clear on this: This isn't C, you don't need
to worry about code optimization.
Relax; don't worry; have a homebrew.
Personally I wish I had learned Java or PHP but I don't have the time
right now
7;s going to do. How proactive you have to be vs.
how reactive you have the luxury to be will depend mostly on your
hardware, and also whether you're using mod_perl, FastCGI, etc.. The
faster you can turn around database and HTTP requests as they come in,
the less important caching and pref
On 4/28/06, Mary Anderson <[EMAIL PROTECTED]> wrote:
>Hu Jay,
Thanks for the reply. There is a lot I don't know to chew on.
Could you just clue me in on a few things:
DATA::Dumper must be a perl module on CPAN?
POST and GET are elementary CGI commands that I had bet
he cached
queries keyed by a unique id for each session in BDB or something.
then just pass the session id as a hidden field. There are lots of
options here.
If your goal here is just to allow scrolling and you're not doing
anything else with the form, though, it may be ti
of Get. Failing that, check the return value. You should
really be taint checking anyway, so modifying the regex shouldn't be
too hard. In your action form, just do the opposite, more or less, of
what you do in your post form. If it starts with 'C_and_C', you know
i
error message shows--the error is being propagated
from MySQL's REGEXP operator. MySQL uses POSIX re, not Perl re or
even PCRE. The differences may be significant. If Clarkson's
recommendation doesn't fix the problem, you'll probably want to talk
to a MySQL list.
The
u were assigning to a variable instead of performing
a substitution. You also don't seem to actually increment count
anywhere.
Try something more like
my $count = 0 ;
s/\/ sub {
$count++;
my $return;
if ($count == 2) {
g this either. Is your question about
getting CGI.pm to generate dynamic content based on system command
output? Or is your question simply how to declutter a page full of
radio buttons? Or is your question something else entirely?
Whichever it is, giving some specific code you're having troubl
g for all kinds of trouble.
The best way to benchmark queries is from the command line, or
phpmyAdmin, which is designed for this. You can also use MySQL
Administrator and the Query Browser for this (I think). In any case,
you're looking for an application, not a feature of the programming
la
On Fri, 21 Jan 2005 18:03:29 -0500, Jay <[EMAIL PROTECTED]> wrote:
> On Fri, 21 Jan 2005 17:56:17 -0500, Jay <[EMAIL PROTECTED]> wrote:
> > On Fri, 21 Jan 2005 19:20:44 +, Mark Martin <[EMAIL PROTECTED]> wrote:
> > > Hi ,
> > > I'm getting c
y each time. If a row is added before the current
page, the first item on the page will be a repeat of something the
user has already seen. Probably, this won't be an issue for you.
If you need to make sure the user sees the info as it was at the time
they made the request, you'll need t
p {"$_ "} @row, "\n"
# or:
# print "", map {defined $_ ? "$_ " :
"(null)"} @row, "\n" ;
}
print "\n" ;
HTH,
--jay
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>
16 matches
Mail list logo