My real program does more complicated stuff than I had presented in this post, but I just wanted to keep things simple.
But your question is far, far from simple. You ask an extremely broad question (in the sense that there are a lot of factors that play a role) whose answer isn't going to be purely Perl. Simplification only leads to suggestions (like 'wget') that isn't going to work for you. Note that wget has options to work with cookies - including saving/restoring them to/from file.
I'm not writing a web crawler, this is just something to automate a bunch of form post requests, and massage the data I get back. But that doesn't matter for getting the threading part right.
I will eventually be storing stuff in mysql, but this is a future PM question....
So it seems like speed isn't going to be that important. Why aren't you first focussing on getting the functionality working, then worry about speed? Perhaps by the time it's finished, the speed issue has resolved itself (for instance, because it's already fast enough, or the database is going to be the problem, or the retrieval is been done in the background)
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:
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, 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, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.
| & || & |
| < || < |
| > || > |
| [ || [ |
| ] || ] ||