Re: Match and split on array help with output

2009-04-16 Thread Dr.Ruud
Chas. Owens wrote: Dr.Ruud: p...@highdeck.com: /:\/\// Alternative: m~://~ What drove your choice of tildas here? Normally I would go for once of the matched delimiters (i.e. (), {}, [], or <>). The tilde just happens to be one of my favourite regex delimiters. I see "#" being used

Re: Match and split on array help with output

2009-04-15 Thread Chas. Owens
On Tue, Apr 14, 2009 at 13:58, Dr.Ruud wrote: > p...@highdeck.com wrote: > >> /:\/\// > > Alternative: > >  m~://~ snip What drove your choice of tildas here? Normally I would go for once of the matched delimiters (i.e. (), {}, [], or <>). -- Chas. Owens wonkden.net The most important skill a

Re: Match and split on array help with output

2009-04-15 Thread Dr.Ruud
p...@highdeck.com wrote: /:\/\// Alternative: m~://~ > print( ( split /\// )[ 2 ] ); print +( split m~/~ )[ 2 ]; -- Ruud -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Match and split on array help with output

2009-04-14 Thread John W. Krahn
John W. Krahn wrote: p...@highdeck.com wrote: Hi john, Hello, thanks for the prompt reply. Ok, here's what I'd like it to do. #!/usr/bin/perl # # Build Initial list and put into array. @serverlist = `/usr/bin/wget -q -O - http://www.amazon.co.uk`; for ($index = 0; $index

Re: Match and split on array help with output

2009-04-14 Thread John W. Krahn
p...@highdeck.com wrote: Hi john, Hello, thanks for the prompt reply. Ok, here's what I'd like it to do. #!/usr/bin/perl # # Build Initial list and put into array. @serverlist = `/usr/bin/wget -q -O - http://www.amazon.co.uk`; for ($index = 0; $index <= $#serverlist; $inde

Re: Match and split on array help with output

2009-04-14 Thread John W. Krahn
p...@highdeck.com wrote: Hi all, Hello, I have some basic code that I want to pull out the web addresses from web pages. Would like to keep it as basic as possible for easy reading. The line to replace http with newline seems to work ok. however the "match" line doesnt seem to pull out the r