Tell-a-friend can be dangerous: if a spammer finds your form, they can use *your* computer resources to send out lots of spam -- which will be traced back to you. Only allow authenticated users to use this feature, and make some provision to limit the amount of messages each user is allowed to send. You have been warned!
As for how to send the actual message, there are plenty of mail modules on CPAN. I think MIME::Lite can do what you want with a minimum of fuss.
Adding a link to your existing pages depends on how your site is designed. If you're using any kind of templating system, it's easy -- add it once to the appropriate template. If you aren't -- then you should :-) but you might, in a pinch, do a quick search and replace for <BODY> (or some other location that exists in your pages), and put <BODY><A HREF="your page">tell a friend</a>. There are perl one-liners that can do that for you.
Printer-friendly pages? The answer again depends on how your site is designed, but if the data is coming from a database and then rendered by a template, just make a "printer" version of the template that doesn't include the printer-unfriendly elements :)
Update: eieio's suggestion re: CSS is a very good one, too.
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.