Sorry - I should have been more specific about what I'm doing. This should address the questions.

When the user first clicks on the page, it will dump a text box in front of them, saying 'Enter the first few letters.' Based on that, the program will load and weed out all the entries in the 1000+ array that have those first few letters. Then, it returns a page with the text box at the top(so they know what they typed in) and *just* the matching entries.

Based on the distribution of beginning letters, I'd say they'd never get a return page with more than 100 entries on it. (At most, maybe 200.) I realize those are stretching, but I honestly don't think they'd happen often. (If they did during testing, I could build a page-breaker and make it return two pages.)

Now, I realize all this is *way* too much to ask for. I'm not asking for it. All I'd like is a little advice on how to handle turning this data into a web page.

It's going to be:

name=cost=number

And it will come out in a table with a few other things: (chk = checkbox, txt = textfield)

--------------------------------
|chk|name|cost|number|txt|
--------------------------------

Now, as I understand Perl, it doesn't interpolate while or for loops. So if I make the statement

print table(...
...
foreach ... {
...
...
}
...
)

then my code won't work, because the for hasn't been dealt with before the print tries to print.

Am I wrong? Are these things dealt with automagically, and Perl is just all the more amazing? I'm thinking it's not. Does this mean I have to do the table tags by hand?


In reply to Re: Yet Another Stupid CGI Question by chaoticset
in thread Yet Another Stupid CGI Question by chaoticset

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • 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:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.