Ok, I am currently building a webtool for my work. I have just started to use perl ( which I love) but I am having trouble getting data from one file to another. I have a cgi main page and a script on another page that takes the data and submits it to a database. The trouble is I need to then get the time the second page was submited from the second page onto the first page. I am sure I need to add something like


$date = "main.pl"; open (FILE, "< $data") || die "$!"; $timestamp = $time; close (FILE);


I need to get the timestamp from the second page to be appended to a field in the first page. Im not asking for you to tell me how to do it step by step but any information would be great.

Thanx alot :) Ohh, I have only been using perl for 3 weeks or so :(

In reply to File manipulation by rootkidd

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.