Dear fellow monks,
this one is language-independent and therefore quite offtopic, but I hope to get some input though ...
I am starting my first CGI project and want to build an application using LAMP. I've read a lot in books and The Monastery and learned how to get things working. Of course I will use strict, CGI and DBI and I plan to write the whole thing the literate programming style.
What I am wondering about is how to get the different functions, web-forms etc. organized. It's no big application at all, but I'd like it to be well done ... after thinking and sleeping over it, I would start building these files:
- index.pl
"Home" of the application with links to the different other scripts
- app_func.pm
Functions used by all other scripts: print page_header (whith navigation bar, window-title and app.-logo), print page_foot, connect to database, define colors and what not)
- patients.pl
Implementing the functions for adding, modifying and deleting patients)
- tests.pl
Functions for running tests on the patients (run test, print result, search for old test ...)
- and so on ...
Would this be a good start or are these too much files for a relatively small thingy?
Is building a module with standard functions the right way (app_func.pm)??
I appreciate any wisdom, comments, hints - thank you!
weini
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.