Hi,
I have script that will find the latest report file created (reports are generated everyday) and sends mail to recipients the link to that file. But the problem is the link is too long, file://systemip/folder1/folder2/folder3/abcdefghijklmnop.xls. i want to send mail with "LINK1" in place of this whole string. i tried
, it did not work. please help me.
here is part of my script,
use SendMail;
$smtpserver = "120.12.145.41";
$smtpport = 25;
$sender = "Naga<math\@yahoo.com>";
$recipient = "ABC<math1\@yahoo.com>";
$sm = new SendMail($smtpserver,$smtpport);
$sm->setDebug($sm->ON);
$sm->From($sender);
$sm->Subject("Reports Link");
$sm->To($recipient);
$sm->setMailBody("please click the following link to get the reports\n
+\n <a href=""\\\\111.1.34.100\\ABC\\Reports\\BCD\\Details\\MNO\$lates
+t_bb_xls">click here</a>");
if ($sm->sendMail() != 0) {
print $sm->{'error'}. "\n";
exit -1;
}
print "Done\n";
exit 0;
When i run this, i get mail and the it displays "please click the following link to get the reports\n\n <a href=""\\\\111.1.34.100\\ABC\\Reports\\BCD\\Details\\MNO\$latest_bb_xls">click here"
thanks in advance,
Naga
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.