go ahead... be a heretic | |
PerlMonks |
Re: Re: Perlmonk's "best pratices" in the real worldby schweini (Friar) |
on Nov 13, 2003 at 16:20 UTC ( [id://306829]=note: print w/replies, xml ) | Need Help?? |
That BBX-code i mentioned works in the sense of being 'functional' - i.e. does what it's supposed to do, but impossible to expand. actually, for the last year, i've been replacing all of it with my perl-code, and this meditation was in part inspired by the fear that ina couple of years, some poor schmuck will have to look at my code the same dazzled way i've been looking at that BBX stuff. re: CGI.pm i've always used it in the 'old school' way of getting my params (via Vars()) with it, and then basically forgetting about it. i prefer using my own header-generators and HTML-printing subs. re: strict/warning i frankly tried it a couple of times, but got annoyed by the a bit over-pedantic messages makeing a big fuss about nothing too serious. but iread about 'no strict vars' somewhere, so i'll give that a shot... re: placeholders i've actually been advocating placeholders on the DBI-list and here (i think) a couple of times, because i am so in love with them (you can't imagine the effect that BBX code had on my mental health) re: OO agreed - i think OO is cool for complex modules (DBI, Tk, etc.), where inheritance and friends actually make sense - but my apps that simply use all that funcionality tend to be a lot cleaner without OO... re: templates for 'normal' websites i guess i'd agree, but right now i'm working on this intranet-thing, and since basically all content is generated by my html-creator-subs, and formatted on the fly according to the data, i doubt that they would help me a lot right now.. re: CGI::App I still don't get that one..i use the good ol' if ($in{action} eq "foo") style, and simply refuse to believe that using subs instead of conditionals make that much of a difference... re: PM-style very cool theory why perlmonks code they way they seem to!
In Section
Meditations
|
|