Re: Download images/movies

2004-08-24 Thread Andy Turner
I would also recommend using PATH_INFO instead of a query string. This will more reliably set the filename then the content disposition will. The HTML would be: Untitled Page picture link I would agree that slurping the entire file is a bad idea. However you don't need to use read. You

Re: Need help with a string parsing problem

2004-01-22 Thread Andy Turner
On Wed, Jan 21, 2004 at 10:39:09PM -0600, Ken Williams wrote: > This is probably because 5.6 expands the whole for(...) list in > advance, but 5.8 evaluates it lazily. Ah, but I'm using stock Perl on Panther, which is 5.8.1-RC3. It also happens on my Debian Unstable box which is running 5.8.2.

Re: Need help with a string parsing problem

2004-01-18 Thread Andy Turner
There some sort of regexp strangeness going on here that I can't grok. Your script doesn't work for me unless I print out the values of $1 AND $2. If I just print out one it doesn't work either. turner:~$ cat foo.pl $_ = "UA-UI1,3,4,6"; m~(..)\-(..)(\d.+)~; for $CC( $1 .. $2 ) { for $n ( split /,

Re: Need help with a string parsing problem

2004-01-18 Thread Andy Turner
On Sat, Jan 17, 2004 at 10:19:24PM -0800, Kim Helliwell wrote: > I need to take a string like this: > > UA-UI1,3,4,6 > > and expand it into an array of components like this: > > UA1 UA3 UA4 UA6 UB1 UB3 UB4 UB6 ... UI1 UI3 UI4 UI6 How's this? my $str = "UA-UI1,3,4,6"; if ( my( $from, $to, $nums