Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

G'day Anand,

Welcome to the monastery.

I suspect you're doing something like this:

$ perl -le ' my $password = "abc$def"; print $password; ' abc

With the warnings pragma, you'd get:

$ perl -le ' use warnings; my $password = "abc$def"; print $password; ' Name "main::def" used only once: possible typo at -e line 3. Use of uninitialized value $def in concatenation (.) or string at -e l +ine 3. abc

Now you get a warning (which might get lost in log files, scrolled off the screen, or otherwise not be noticed) but the problem remains (i.e. 'abc' is still output).

With the strict pragma, you'd get:

$ perl -le ' use strict; use warnings; my $password = "abc$def"; print $password; ' Global symbol "$def" requires explicit package name at -e line 4. Execution of -e aborted due to compilation errors.

Now you have an error which would be pretty hard not to notice as your program has aborted before it even started to run. If you follow the strict link I provided, you'll find more information about this under "strict vars".

So, the first lesson to take away from this is to add

use strict; use warnings;

to start of all your scripts (unless you have a very good reason for not doing so).

Anyway, that's all guesswork on my part as you haven't posted any code. All user input should be viewed as suspicious so I won't be suggesting ways to fix code I haven't seen: I could end up causing you far worse problems than a simple failed login. Have a read of "How do I post a question effectively?" then, following those guidelines, update your post with something we can work with ("How do I change/delete my post?" tells you how to do that).

-- Ken


In reply to Re: Need help in while entering password by kcott
in thread Need help in while entering password by anandooty

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (11)
As of 2024-03-28 09:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found