robertw has asked for the wisdom of the Perl Monks concerning the following question:
Dear Perlmonks I imported html which i want to parse but when i pass it into a subroutine as a scalar i can only get the input in an array, When i pass the string into the sub and then set it to an array change that array back to the original string scalar value? Sorry guys I really have no idea how to handle this, and I can give some of my test scripts for clarity:S thank you so much
my $html = "hello"; routine($html); sub routine { print $_; print " "; print @_; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: subroutine scalar string input
by BrowserUk (Patriarch) on Oct 20, 2012 at 23:44 UTC | |
|
Re: subroutine scalar string input
by 2teez (Vicar) on Oct 20, 2012 at 23:51 UTC | |
by robertw (Sexton) on Oct 21, 2012 at 20:03 UTC | |
|
Re: subroutine scalar string input
by ikegami (Patriarch) on Oct 20, 2012 at 23:19 UTC |