I have a program the I want to combine into one single cgi file. It basically is a search program for a database (Postgres). Let me break it down a little:
SCRIPT 1: Determines whether the user logged in is a NORMAL USER or ADMINISTRATOR. Then, if it's the ADMINISTRATOR it generates a form with a username field and dropdown for dates. If it's a NORMAL USER it defaults to that username and generates a form with only a 00-00-00 to 00-00-00 dropdown.
SCRIPT 2: This is the admin script for processing the data from the admin search form that script 1 generates
SCRIPT 3: This processes the normal user form generated by script 1.
All of these are broken down in subroutines except where a few variables are defined and were i determine the USER.
Should i even put these in a subroutine? And can i have if-elsif-else statement inside of larger if-elsif-else statments?
Thanks,
Nick
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.