This does what you asked for, you might have to adjust the cookie name (currently "sessionID"), and again, it's probably useless.

use warnings; use strict; use CGI qw(:standard); use CGI::Cookie; my $cookies = CGI::Cookie->fetch; my $cookie = $cookies->{sessionID} || cookie(-name => 'sessionID', -value => 0, ); $cookie->value( $cookie->value + 1 ); print header(-cookie => $cookie), start_html(), start_form(), textfield(-name => "cookie", -value => $cookie->value), submit(), end_form(), end_html();

Perhaps the Pod for the interface for CGI::Cookie will start to shake some things loose. What it sounds like to me now, from your new description, is that you have a completely insecure set of applications which are passing around customer information in cookie values. This is a huge no-no and I would hope and expect no one here would help you to get it working that way if it's really the case.

Without much more info, and probably lots of sample code, showing how and what the login and sessioning is doing through each app, everything else is just a guessing game.


In reply to Re: Get Cookies for Form Input by Your Mother
in thread Get Cookies for Form Input by Anonymous Monk

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.