Adds a compartment for use with Embperl. Embperl only uses the opcode
mask from it, not the package name. AddCompartment returns the newly-
created compartment so you can allow or deny certain opcodes. See the
Safe.pm documentation for details of setting up a compartment. See the
chapter about (Safe-)Namespaces and opcode restrictions for details on how Embperl uses compartments. Example: $cp = HTML::Embperl::AddCompartment('TEST');
$cp->deny(':base_loop');
MailFormTo($MailTo, $Subject, $ReturnField) | top |
Sends the content of the hash %fdat in the order specified by @Z<>ffld to
the given $MailTo addressee, with a subject of $Subject.
If you specify $ReturnField the value of that formfield will be used
as Return-Path. Usually, this will be the field where the user enters his
e-mail address in the form. If you specifiy the following example code as the action in your form <FORM ACTION="x/feedback.htm" METHOD="POST"
ENCTYPE="application/x-www-form-urlencoded"> The content of the form will be mailed to the given e-mail address. MailFormTo uses EMBPERL_MAILHOST as SMTP server or localhost
if non given. Example: <HTML>
<HEAD>
<TITLE>Feedback</TITLE>
</HEAD>
<BODY>
[- MailFormTo('webmaster@domain.xy',
'Mail from WWW Form', 'email') -]
Your data has been successfully sent!
</BODY>
</HTML> This will send an email with all the form fields to webmaster@domain.xy, with the
Subject 'Mail from WWW Form' and will set the Return-Path of the mail to the
address which was entered in the field with the name 'email'. NOTE: You must have Net::SMTP (from the libnet package) installed
to use this function.
exit will override the normal Perl exit in every Embperl document. Calling
exit will immediately stop any further processing of that file and send the
already-done work to the output/browser. NOTE 1: If you are inside of an Execute, Embperl will only exit this Execute, but
the file which called the file containing the exit with Execute will continue.
NOTE 2: If you write a module which should work with Embperl under mod_perl,
you must use Apache::exit instead of the normal Perl exit (as always
when running under mod_perl).
|