Hi, I am trying to parse a mail to get the body of a mail in the simplist way possible. I have tried Email::Simple but a hmtl tags are returned when I parse the mail which is no good.
I have managed to get the body with no tags using MIME::Parser BUT I am having a few issues with it:
(Note ...
I am unzipping 2 logfiles from 2 different server. One file is name serverA.zip and the other server2.zip. However there is 1 file inside each which is always named by the date and both are the same (ie the file inside both zip files have the same name).
How can I rename them to avoid a...
I have never had to work with XML before and I am looking for a way to read an XML file post it to a url and read the response. Any help would be great as this is a complete new one for me
I have a large daily log file created from merging 2 smaller log files. I need to sort the file by time. All of the fields are delimited by space. Originally I was thinking of using a hash with the Time as a key and the line as a value but I cant as not all the times are unique.
Any ideas...
I am having one of those monday mornings!!!! Can some please tell me why the following 2 lines print the string with the array position at the begining of each line.
eg
0Hello
1I am well
2How are you
.
.
.
I know it is simple but i cant see it.
$FileString doesnt contain the index at all...
I am using Cygwin and I have downloaded the lastest version of this module (DBI) which I wish to install:
I type:
perl makefile.pl
make
make test
make install.
When I run the script calling this module i get the following error. I have installed this module with ppm previously with no...
I am using this module to get the body of a mail. When I execute the script below, 2 file are generated one html and one txt file. However both files are randomly named (it seems). I wish to specify the name of the .txt file and html files, (call them NewMsg.txt and NewMsg.html) respectively...
I have written a script which firstly removes the 'from' email address from a .msg file. I inherited this algorithm (well it was handed and told to code it) but it turns out it must search through an MDaemon backup folder containing a large amount of .msg files (100,000 +). The MDaemon set up is...
i have created a batch file and I now wish to run it from a perl script. How do I execute it? Can I do it with the system() command??? I am using windows.
Firstly thanks for all your help in finding this module.
The module (UUID.pm) is now present in C:/Perl/site/lib and C:/Perl/site but when I run the simple script to test it I get the following error.
-------------------
#!/usr/bin/perl
use Data::UUID;
my $uf = Data::UUID->new(); # creates a...
I am writing into a db and have to create a unique random value for each entry. The value can be made up of any number of digits, chars or letters.
Any help would be great.
I have data stored in 2 variables $Execution_Time and $Description.
I am trying to write the data into a table emails as follows:
$dbh->do('INSERT INTO Emails (ID, date_entered, description, deleted) VALUES ("1", "$Execution_Time", "$Description","0")');
but the word description is written...
I am learning CGI programming and have found the following script. I am getting the error :
Content-Type: text/html; charset=ISO-8859-1
Cannot open C:/Perl/Sample_Scripts/guestbook: No such file or directory at helpd
esk.cgi line 33.
when I run the following script:
#!/usr/bin/perl -wT
use...
I am looking for a way to change the date modified of a file.
I have copied a file into a new folder and I have the date modified of the original file in a variable $DateModified
($DateModified) = (stat ($file1) )[9];
I now wish to change the modified date for $file2 to $DateModified.
I have copied a number of .msg files into a new folder in a script. Is there a way in which I can limit the files copied by the Windows 'Date modified' value/date.
Lets say I only want to copy the .msg files with date modified > last 7 days into the folder.
Is there anyway of removing case sensitivity from a template in the above module?
ex: $template = q(Path : <% Tst %>);
if I match the text "Path : < xxxx >"
xxxx is returned from Tst.
if I match the text "path : < xxxx >"
nothing is returned Tst but it is defined.
I can do it using...
I am looking to extra the 'to' address, from address and first 100 lines of the body of the mail from an email. I was trying to use the Mail::Internet module cannot overcome a compile error that is produced. Can anyone suggest another was around the problem. A different module perhaps
I am working with this module for the first time. I have a few v simple questions. When I try to execute a simple script using the module I get the following error.
Can't locate auto/Mail/Internet/autosplit.ix in @INC (@INC contains: C:/Perl/lib
C:/Perl/site/lib .) at...
I am looking for a way to capture the ouptut I generate from the code below into a nice hash. The ouptut is in the following format:
$VAR1 = {
'Element' => [
#0
{
'Name' => 'Michael'...
Firstly thank you for all your info on my previous query.
I have come accross the Template::Extract module which will make my life a lot easier when extracting data. The module is present, but when I run the following sample code I get the following error...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.