Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

comment on

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

++dws, and thankyou for saying it. This is a similar point to the one I was trying to make in Being a heretic and going against the party line..

It's not that I have anything using modules, nor that I don't appreciate the long term benefits of the tested-ness (sorry for that but I simply couldn't think of a better way of putting it) that comes from using the proven solutions and would probably do so in most cases for production work or anything that I had to revisit more than once.

However, even assuming that you know the right module to use rather than needing to go through a long list of possibles to determine which one is right, it can still be a pain.

As an example, in this post, I set out to 'do it the right way' and use CGI.pm. After nearly 2 hours of trying, I gave up and hand-rolled my html output because I could not work out the right combination of maps, anonymous arrays and CGI functions to produce the output I wanted. I came close a couple of times, but as soon as I tried to add the final peice to the puzzle it just crashed around my ears.

So I opted for a loop and some print statements and it worked first time (honest!) and took less than 5 minutes. When I chose to add an extra (left-hand) column to my table, it was obvious exactly where and how to do it. I gave up completely on the idea when was trying to using CGI.pm.

I admit, by the time I got to writing the homebrew version, I had the benefit of a lot of thinking that I had aquired trying to do the CGI/maps/distributive function method. Even so, a 24:1 ratio of time taken to achieve a solution (actually higher as I never did) would pay for a lot of maintainence were that ever necessary.

I guess you pays your money and makes your choice, but if I am paying the bills, I will opt for the 'simple solution' over the 'right way' every time.


Cor! Like yer ring! ... HALO dammit! ... 'Ave it yer way! Hal-lo, Mister la-de-da. ... Like yer ring!

In reply to Re: Simplicity vs. Doing It Right by BrowserUk
in thread Simplicity vs. Doing It Right by dws

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 drinking their drinks and smoking their pipes about the Monastery: (4)
As of 2024-04-26 06:44 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found