I've tried to use the modules, without success. My own ignorance is undoubtedly responsible. I'm still trying to learn Perl, after several years of writing scripts, and I haven't studied the modules.
I tried to limit the amount of information that I included in my original problem declaration because I know that much of it would be superfluous, but here's a little background.
The application is a shopping cart system. The main script, named kart.cgi, does contain a
content command line. Most of the output takes place in another script, called config.cgi. The latest script is called register.cgi, and contains no
print statements. All information is passed to config for output.
All of the subroutines for registration are in the register.cgi script, but control remains with kart.cgi. I thought that by using the
require command, the
content would be negated when the subroutines were accessed, but apparently not. :-)
Until the visitor inputs the information that I am trying to output with the cookie, how can I write it to his or her cookie file? Ergo, I need to collect the data before I can write it out. If I was simply creating a visit count, or something like that, I could write the cookie as soon as the kart.cgi is opened.
To the best of my knowledge, the \r\n at the end of a print statement is only important as a delimiter when viewing source code. Is there another reason why it should be in the
Set-cookie: command line?
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.