Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re^2: a "search engine" (ahem)

by hnd (Scribe)
on Jul 09, 2009 at 19:59 UTC ( [id://778685]=note: print w/replies, xml ) Need Help??


in reply to Re: a "search engine" (ahem)
in thread a "search engine" (ahem)

thanks apl but i cannot clearly understand your third point.... and since this is not my code so i actually cannot understand what $file is used for....

=====================================================
i'am worst at what do best and for this gift i fell blessed...
i found it hard it's hard to find well whatever
NEVERMIND

Replies are listed 'Best First'.
Re^3: a "search engine" (ahem)
by apl (Monsignor) on Jul 09, 2009 at 23:56 UTC
    Assune the find sub is called with $_ equal to SomeFile.html, but that file does not exist. The routine as written simply returns, and the user is left to wonder why nothing was displayed. I'm suggesting that a message be displayed explaining why nothing was displayed.

    The reason I suggested the name of the file be passed in a global variable (e.g. $path) is because $_ is used internally by Perl for a number of reasons. To prevent the path from being clobbered, it should be explicitly stored.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://778685]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others surveying the Monastery: (9)
As of 2024-04-24 07:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found