faq:using_com_mailto
Joomla! 1.5 provides a generic Mail-To-Friend component, called In your component, you will create a small form and Javascript action: <script language="JavaScript" type="text/javascript"> <!-- function mailToFriend() { if (document.mailToFriend) { window.open('about:blank', 'MailToFriend', 'width=400,height=300,menubar=yes,resizable=yes'); document.mailToFriend.submit(); } } --> </script> <form action="index2.php" name="mailToFriend" method="post" target="MailToFriend" style="display:inline"> <input type="hidden" name="option" value="com_mailto" /> <input type="hidden" name="link" value="<?php echo urlencode( JRequest::getURI() );?>" /> </form> ... <a href="javascript:void mailToFriend()"> <?php echo JText::_( 'Mail to Friend' );?></a>
When the link is clicked, it will open a new browser window with the wherein your visitor can enter the details for mailing. All you need to to is pass a |


