$from_sender = 0;
$from_address = empty($user_email) ? get_bloginfo('email') : $user_email;
$from_name = empty($user_identity) ? get_bloginfo('name') : $user_identity;
// Send the email if it has been requested
if (array_key_exists('send', $_POST) && $_POST['send'] == 'true') {
    // Use current user info only if from name and address has not been set by the form
    if (!isset($_POST['fromName']) || !isset($_POST['fromAddress']) || empty($_POST['fromName']) || empty($_POST['fromAddress'])) {
        $from_name = empty($user_identity) ? get_bloginfo('name') : $user_identity;
        $from_address = $user_email;
    } else {
        $from_name = $_POST['fromName'];
        $from_address = $_POST['fromAddress'];
    }
    $override_name = mailusers_get_from_sender_name_override();
    $override_address = mailusers_get_from_sender_address_override();
    $exclude_sender = mailusers_get_from_sender_exclude();
    $exclude_id = $exclude_sender ? '' : $user_ID;
    // Analyse form input, check for blank fields
    if (!isset($_POST['mail_format']) || trim($_POST['mail_format']) == '') {
        $err_msg = $err_msg . __('You must specify the mail format.', MAILUSERS_I18N_DOMAIN) . '<br/>';
    } else {
        $mail_format = $_POST['mail_format'];
    }
    if (!isset($_POST['send_targets']) || !is_array($_POST['send_targets']) || empty($_POST['send_targets'])) {
        $err_msg = $err_msg . __('You must select at least a role.', MAILUSERS_I18N_DOMAIN) . '<br/>';
    } else {
        $send_targets = $_POST['send_targets'];
    }
    if (!isset($_POST['subject']) || trim($_POST['subject']) == '') {
        $err_msg = $err_msg . __('You must enter a subject.', MAILUSERS_I18N_DOMAIN) . '<br/>';
    } else {
 ></input>
			<?php 
_e('Copy sender (add sender email to Cc: header) when sending email.', MAILUSERS_I18N_DOMAIN);
?>
<br/>
		</td>
	</tr>
	<tr>
        <th><?php 
_e('From Sender<br/>Exclude', MAILUSERS_I18N_DOMAIN);
?>
</th>
		<td>
			<input 	type="checkbox" name="mailusers_from_sender_exclude" id="mailusers_from_sender_exclude" value="true"
					<?php 
if (mailusers_get_from_sender_exclude() == 'true') {
    echo 'checked="checked"';
}
?>
 ></input>
			<?php 
_e('Exclude sender from email recipient list.', MAILUSERS_I18N_DOMAIN);
?>
<br/>
		</td>
	</tr>
	<tr>
 		<th scope="row" valign="top">
            <label for="from_sender_name_override"><?php 
_e('From Sender<br/>Name Override', MAILUSERS_I18N_DOMAIN);
?>