Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??
Thinking of the user is what prompted this post. OK, it was really about my lack of experience when it comes to lookahead assertions. However, I was thinking that the user may not be as familiar with the config files that will be managed by this application. Instead of forcing the user to know all the syntax rules for the config files, I check to make sure the syntax is correct. If it is not correct, I don't think I would want to take a guess at what the user meant. I'm not a mind reader. And if I simply accept the user input without being sure that the syntax and parameters are correct, there is a high probability that the program will fail due to the incorrect config information.

Let's say you dial a phone number and enter a 1 then area code then the number. You then get the recorded response informing you that you don't have to dial a 1 first. My guess is that you are thinking the phone company should understand that you don't know how to use a telephone and are not willing to learn. Therefore they should just connect you to the number you dialed. OK. Perhaps you misdialed the area code and you really did have to dial a one. Well now the phone company has connected you but not to the number you dialed and not to the number you intended to dial. Now two people are frustrated (you and the person you just disturbed for no reason).

I think it is very important that we understand most people will say the same thing in different ways. At the same time, we must understand that many software applications only understand the information if it is presented in a specific manner. I'm, sorry if this is offensive to you but I will never trust the user input implicitly and will always strive to be sure the data conforms to its pre-defined parameters.

In reply to Re: Re: Regex (lookahead) Confusion by ChrisR
in thread Regex (lookahead) Confusion by ChrisR

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 admiring the Monastery: (7)
As of 2024-04-26 09:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found