Perl Archive

  • FTP files with Perl and NET::FTP

    FTP files with Perl and NET::FTP

    Needed to run some reports out of Oracle then FTP them. Could probably do this easier with normal shell command or something but I only have access to Perl at work. So thankfully NET::FTP is an installed module which made this quite painless. The main...

    Project info

  • Getting a date in Perl using time and localtime

    Getting a date in Perl using time and localtime

    3 lines of code to output the date in Perl. In this instance getting yesterdays date. Firstly we get our time by calling the time function, which stores the number of seconds since the systems epoch time – normally 1st January 1970 UTC – If...

    Project info

  • Sending mail and attachments from Perl using NET::SMTP

    Sending mail and attachments from Perl using NET::SMTP

    Sending a mail attachment using NET::SMTP is pretty easy, the only really hard bit is making sure the module is installed on your server and that of course you can run Perl. I’ve written this primarily from doing this from a server but you could...

    Project info