Page 1 of 1
Form Failing to Email Properly
Posted: Thu Oct 08, 2009 4:24 am
by motherlover
I have a form spanning mulitple pages that saves input data to an array. This then emails what has been input by the user into it to an address. This used to work but something must have changed because now when the user completes the form the email is sent but every variable in the array comes back as the character "A".
I can't work out why every variable becomes an A? If anyone could point me in the right direction I would be really greatful.
I have another single page form that does the same thing which works.
I can post the code but it's massive.
Re: Form Failing to Email Properly
Posted: Thu Oct 08, 2009 4:40 am
by robnet
You'll need to post the code. - Make sure you post it in code=php tags otherwise it will be pretty much unreadable.
Re: Form Failing to Email Properly
Posted: Thu Oct 08, 2009 7:46 am
by Eric!
How are you sending the data from the multiple page form to your php code?
I would guess something in the server configuration you were relying on but didn't know it was recently changed.
Re: Form Failing to Email Properly
Posted: Mon Oct 19, 2009 9:09 am
by motherlover
Code: Select all
global $config,$pathtoroot,$function,$wills1,$wills2,$wills3,$wills4,$wills5;
// reset wills session
if($_GET['sessionreset'] == 'true'){
$session = array('wills1',
'wills2',
'wills3',
'wills4',
'wills5'
);
foreach($session as $value){
unset($_SESSION[$value]);
# $unset .= $value;
}
#echo $unset;
#exit();
}
// start page
if (empty($_GET['page'])) {
$abc = explode(' ','a b c d e f g h i j k l m n o p q r s t u v w x y z 0 1 2 3 4 5 6 7 8 9');
$key = $abc[rand(0,35)].$abc[rand(0,35)].$abc[rand(0,35)].$abc[rand(0,35)].$abc[rand(0,35)].$abc[rand(0,35)];
$wills1 = $_SESSION['wills1'];
$html_p1_bornoutsideuk1 = false;
$html_p1_bornoutsideuk2 = false;
if ($wills1[p1_bornoutsideuk]=='yes') {
$html_p1_bornoutsideuk1 = ' checked="checked"';
} elseif ($wills1[p1_bornoutsideuk]=='no') {
$html_p1_bornoutsideuk2 = ' checked="checked"';
}
$html_p1_livedoutsideuk1 = false;
$html_p1_livedoutsideuk2 = false;
if ($wills1[p1_livedoutsideuk]=='yes') {
$html_p1_livedoutsideuk1 = ' checked="checked"';
} elseif ($wills1[p1_livedoutsideuk]=='no') {
$html_p1_livedoutsideuk2 = ' checked="checked"';
}
$html_p1_marriedbefore1 = false;
$html_p1_marriedbefore2 = false;
if ($wills1[p1_marriedbefore]=='yes') {
$html_p1_marriedbefore1 = ' checked="checked"';
} elseif ($wills1[p1_marriedbefore]=='no') {
$html_p1_marriedbefore2 = ' checked="checked"';
}
$html_p1_notmarried = false;
if($wills1[p1_notmarried]=='true'){
$html_p1_notmarried = ' checked="checked"';
}
$html_p1_marriedsoon = false;
if($wills1[p1_marriedsoon]=='true'){
$html_p1_marriedsoon = ' checked="checked"';
}
$snippet .= '
<h1>Wills Questionnaire: Page 1 of 5</h1>
<p>Please complete this questionnaire as fully as possible. It would be helpful
if you would return it to us before your appointment. If you already have a Will,
you may find it more convenient to mark the alterations on a photocopy, which would
make the completion of the relevant parts of this form unnecessary.</p>
'.$extra.'
<h2>PART A - YOU AND YOUR FAMILY</h2>
<form method="post" action="'.$_SERVER['PHP_SELF'].'?page=2&check=true">
<input type="hidden" name="function" value="page2" />
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2"><h3>1: YOUR DETAILS</h3></td>
</td>
<tr>
<td class="cell1">Your forenames/surname:</b>*</td>
<td>
<input type="text" name="wills1[p1_name_fore]" value="'.$wills1[p1_name_fore].'" style="width:130px" />
<input type="text" name="wills1[p1_name_sur]" value="'.$wills1[p1_name_sur].'" style="width:130px" />
</td>
</tr>
<tr>
<td class="cell1">Your email:</b>*</td>
<td><input type="text" name="wills1[p1_email]" value="'.$wills1[p1_email].'" /></td>
</tr>
<tr>
<td class="cell1">Contact address:</b>*</td>
<td><textarea name="wills1[p1_address]">'.$wills1[p1_address].'</textarea></td>
</tr>
<tr>
<td class="cell1">Contact Postcode:</b>*</td>
<td><input type="text" name="wills1[p1_postcode]" value="'.$wills1[p1_postcode].'" /></td>
</tr>
<tr>
<td class="cell1">Contact tel no:</b></td>
<td><input type="text" name="wills1[p1_tel]" value="'.$wills1[p1_tel].'" /></td>
</tr>
<tr>
<td class="cell1">Date of birth:</b></td>
<td><input type="text" name="wills1[p1_dob]" value="'.$wills1[p1_dob].'" /></td>
</tr>
<tr>
<td class="cell1">Occupation:</b></td>
<td><input type="text" name="wills1[p1_occupation]" value="'.$wills1[p1_occupation].'" /></td>
</tr>
<tr>
<td class="cell1">Were you born outside the UK?</b></td>
<td>
<input type="radio" name="wills1[p1_bornoutsideuk]" value="yes" style="width:auto;"'.$html_p1_bornoutsideuk1.' /> yes
<input type="radio" name="wills1[p1_bornoutsideuk]" value="no" style="width:auto;"'.$html_p1_bornoutsideuk2.' /> no
</td>
</tr>
<tr>
<td class="cell1">Have you ever lived outside the UK?</b></td>
<td>
<input type="radio" name="wills1[p1_livedoutsideuk]" value="yes" style="width:auto;"'.$html_p1_livedoutsideuk1.' /> yes
<input type="radio" name="wills1[p1_livedoutsideuk]" value="no" style="width:auto;"'.$html_p1_livedoutsideuk2.' /> no
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2"><h3>2: YOUR HUSBAND/WIFE/PARTNER</h3></td>
</td>
<tr>
<td class="cell1">Forenames/surname:</b></td>
<td>
<input type="text" name="wills1[p1_partner_fore]" value="'.$wills1[p1_partner_fore].'" style="width:130px" />
<input type="text" name="wills1[p1_partner_sur]" value="'.$wills1[p1_partner_sur].'" style="width:130px" />
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2"><h3>3: MARRIAGE/PARTNERSHIP DETAILS</h3></td>
</td>
<tr>
<td class="cell1">Date of Marriage:</b></td>
<td>
<input type="text" name="wills1[p1_datofmarriage]" value="'.$wills1[p1_datofmarriage].'" style="width:100px;" />
</td>
</tr>
<tr>
<td class="cell1">Please tick this box if you are not married to your partner</b></td>
<td>
<input type="checkbox" name="wills1[p1_notmarried]" value="true" style="width:auto;"'.$html_p1_notmarried.' />
</td>
</tr>
<tr>
<td class="cell1">Please tick this box if you are intending to marry/re-marry in the near future</b></td>
<td>
<input type="checkbox" name="wills1[p1_marriedsoon]" value="true" style="width:auto;"'.$html_p1_marriedsoon.' />
</td>
</tr>
<tr>
<td class="cell1">Has either of you been married before?</b></td>
<td>
<input type="radio" name="wills1[p1_marriedbefore]" value="yes" style="width:auto;"'.$html_p1_marriedbefore1.' /> yes
<input type="radio" name="wills1[p1_marriedbefore]" value="no" style="width:auto;"'.$html_p1_marriedbefore2.' /> no
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2"><h3>4: YOUR CHILDREN
(INCLUDING YOUR CHILDREN FROM A PREVIOUS MARRIAGE OR RELATIONSHIP)</h3>
Full names, dates of birth, and address if different from yours.
</td>
</td>
<tr>
<td class="cell1">Child 1 Name:</b></td>
<td>
<input type="text" name="wills1[p1_child1_name]" value="'.$wills1[p1_child1_name].'" />
</td>
</tr>
<tr>
<td class="cell1">Child 1 Date of Birth:</b></td>
<td>
<input type="text" name="wills1[p1_child1_dob]" style="width:100px;" value="'.$wills1[p1_child1_dob].'" />
</td>
</tr>
<tr>
<td class="cell1">Child 1 Address:</b></td>
<td>
<textarea name="wills1[p1_child1_address]" style="height:40px;">'.$wills1[p1_child1_address].'</textarea>
</td>
</tr>
<tr>
<td class="cell1">Child 2 Name:</b></td>
<td>
<input type="text" name="wills1[p1_child2_name]" value="'.$wills1[p1_child2_name].'" />
</td>
</tr>
<tr>
<td class="cell1">Child 2 Date of Birth:</b></td>
<td>
<input type="text" name="wills1[p1_child2_dob]" value="'.$wills1[p1_child2_dob].'" style="width:100px;" />
</td>
</tr>
<tr>
<td class="cell1">Child 2 Address:</b></td>
<td>
<textarea name="wills1[p1_child2_address]" style="height:40px;">'.$wills1[p1_child2_address].'</textarea>
</td>
</tr>
<tr>
<td class="cell1">Child 3 Name:</b></td>
<td>
<input type="text" name="wills1[p1_child3_name]" value="'.$wills1[p1_child3_name].'" />
</td>
</tr>
<tr>
<td class="cell1">Child 3 Date of Birth:</b></td>
<td>
<input type="text" name="wills1[p1_child3_dob]" value="'.$wills1[p1_child3_dob].'" style="width:100px;" />
</td>
</tr>
<tr>
<td class="cell1">Child 3 Address:</b></td>
<td>
<textarea name="wills1[p1_child3_address]" style="height:40px;">'.$wills1[p1_child3_address].'</textarea>
</td>
</tr>
<tr>
<td class="cell1" colspan="2">
Please note :
<ul>
<li>Illegitimate and adopted children (but not stepchildren) generally have the same rights of inheritance as other children, unless you specify differently.</li>
<li>Children excluded from benefit under your Will may have a right to claim a share of your property in certain circumstances. Please ask for advice if appropriate.</li>
</ul>
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2"><h3>5: CHILDREN OF YOUR HUSBAND/WIFE/ PARTNER\'S PREVIOUS MARRIAGES OR RELATIONSHIPS </h3>
</td>
</tr>
<tr>
<td class="cell1">Please give full names, dates of birth and address if different from yours:</b></td>
<td>
<textarea name="wills1[p1_children_other]">'.$wills1[p1_children_other].'</textarea>
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2"><h3>6: USER TEST</h3>
</td>
</tr>
<tr>
<td class="cell1" colspan="2">Please type the code you see below into the box to allow you to continue.</b><br />if you are having any problems seeing the image or using this form please contact a member of staff from the contact details <a href="'.$config['urlroot'].'contact/index.php">here</a>.
</td>
</tr>
<tr>
<td class="cell1">
<img src="'.$config['urlroot'].'_code/module_wills_q/usertest.php?key='.$key.'" alt="user test" />
<input type="hidden" name="key" value="'.$key.'" />
</td>
<td>
<input type="text" name="test" value="" size="30" maxlength="10" />
</td>
</tr>
</table>
<div style="float:right"><input type="submit" value="next page" style="width:80px" /></div>
</form>
<small>* mandatory field</small>
';
#### PAGE 2
} elseif ($_POST['function']=='page2' or $_GET['page'] == '2') {
if($_GET['check']=='true'){
$_SESSION['wills1'] = $_POST['wills1'];
}
$wills1 = $_SESSION['wills1'];
$wills2 = $_SESSION['wills2'];
$wills3 = $_SESSION['wills3'];
$wills4 = $_SESSION['wills4'];
$wills5 = $_SESSION['wills5'];
## STOP EMAIL INJECTION (nasty hack that hijacks email forms)
foreach ($_REQUEST AS $value) {
if(eregi("MIME-Version: ",$value)) {
die('Get out, spammer.');
}
}
#### HUMAN TEST
if (strtoupper($_POST[key]) != strtoupper($_POST[test]) and $_GET['check'] === 'true') {
$snippet = '<span style="color:red;">The user test codes do not match. <a href="'.$_SERVER['PHP_SELF'].'">Please go back and try again</a>.<br /><br /></span>';
## CHECK FORM FILLED OUT
} elseif (empty($wills1[p1_name_fore]) OR empty($wills1[p1_name_sur]) OR empty($wills1[p1_email]) OR empty($wills1[p1_address]) OR empty($wills1[p1_postcode]) and $_GET['check'] === 'true') {
$snippet = 'Error, you did not fill out all the mandatory fields. <a href="'.$_SERVER['PHP_SELF'].'">Please go back and try again</a>.<br /><br /><br /><br /><br /><br /><br /><br /><br /><br />';
} elseif (MailVal($wills1[p1_email], 2) and $_GET['check'] != 'false') {
$snippet = 'Error, your email address appears to be incorrect. <a href="'.$_SERVER['PHP_SELF'].'">Please go back and try again</a>.<br /><br /><br /><br /><br /><br /><br /><br /><br /><br />';
} elseif($_GET['check'] != 'false') {
header("location:".$_SERVER['PHP_SELF']."?page=2&check=false");
} else {
$html_p2_houseinyourname1 = false;
$html_p2_houseinyourname2 = false;
if ($wills2[p2_houseinyourname]=='yes') {
$html_p2_houseinyourname1 = ' checked="checked"';
} elseif ($wills2[p2_houseinyourname]=='no') {
$html_p2_houseinyourname2 = ' checked="checked"';
}
$html_p2_housejoint1 = false;
$html_p2_housejoint2 = false;
if ($wills2[p2_housejoint]=='yes') {
$html_p2_housejoint1 = ' checked="checked"';
} elseif ($wills2[p2_housejoint]=='no') {
$html_p2_housejoint2 = ' checked="checked"';
}
$html_p2_housepartners1 = false;
$html_p2_housepartners2 = false;
if ($wills2[p2_housepartners]=='yes') {
$html_p2_housepartners1 = ' checked="checked"';
} elseif ($wills2[p2_housepartners]=='no') {
$html_p2_housepartners2 = ' checked="checked"';
}
$html_p2_houserented1 = false;
$html_p2_houserented2 = false;
if ($wills2[p2_houserented]=='yes') {
$html_p2_houserented1 = ' checked="checked"';
} elseif ($wills2[p2_houserented]=='no') {
$html_p2_houserented2 = ' checked="checked"';
}
$html_p2_houseother1 = false;
$html_p2_houseother2 = false;
if ($wills2[p2_houseother]=='yes') {
$html_p2_houseother1 = ' checked="checked"';
} elseif ($wills2[p2_houseother]=='no') {
$html_p2_houseother2 = ' checked="checked"';
}
$html_p2_propertyheldas1 = false;
$html_p2_propertyheldas2 = false;
$html_p2_propertyheldas3 = false;
if ($wills2[p2_propertyheldas]=='Joint Tenants') {
$html_p2_propertyheldas1 = ' checked="checked"';
} elseif ($wills2[p2_propertyheldas]=='Tenants in Common') {
$html_p2_propertyheldas2 = ' checked="checked"';
} elseif ($wills2[p2_propertyheldas]=='Don\'t know') {
$html_p2_propertyheldas3 = ' checked="checked"';
}
$html_p2_mortinsure1 = false;
$html_p2_mortinsure2 = false;
if ($wills2[p2_mortinsure]=='yes') {
$html_p2_mortinsure1 = ' checked="checked"';
} elseif ($wills2[p2_mortinsure]=='no') {
$html_p2_mortinsure2 = ' checked="checked"';
}
$html_p2_business1 = false;
$html_p2_business2 = false;
if ($wills2[p2_business]=='yes') {
$html_p2_business1 = ' checked="checked"';
} elseif ($wills2[p2_business]=='no') {
$html_p2_business2 = ' checked="checked"';
}
$html_p2_businesstype1 = false;
$html_p2_businesstype2 = false;
$html_p2_businesstype3 = false;
if ($wills2[p2_businesstype]=='Company') {
$html_p2_businesstype1 = ' checked="checked"';
} elseif ($wills2[p2_businesstype]=='Partnership') {
$html_p2_businesstype2 = ' checked="checked"';
} elseif ($wills2[p2_businesstype]=='In your sole name') {
$html_p2_businesstype3 = ' checked="checked"';
}
$html_p2_jointassets1 = false;
$html_p2_jointassets2 = false;
if ($wills2[p2_jointassets]=='yes') {
$html_p2_jointassets1 = ' checked="checked"';
} elseif ($wills2[p2_jointassets]=='no') {
$html_p2_jointassets2 = ' checked="checked"';
}
$html_p2_assetsabroad1 = false;
$html_p2_assetsabroad2 = false;
if ($wills2[p2_assetsabroad]=='yes') {
$html_p2_assetsabroad1 = ' checked="checked"';
} elseif ($wills2[p2_assetsabroad]=='no') {
$html_p2_assetsabroad2 = ' checked="checked"';
}
$snippet .= '
<h1>Wills Questionnaire: Page 2 of 5</h1>
<h2>PART B - YOUR HOME AND OTHER ASSETS</h2>
<form method="post" action="'.$_SERVER['PHP_SELF'].'?page=3">
<input type="hidden" name="key" value="'.$key.'" />
<input type="hidden" name="test" value="'.$test.'" />
<input type="hidden" name="function" value="page3" />
<input type="hidden" name="wills1[p1_name_fore]" value="'.$wills1[p1_name_fore].'" />
<input type="hidden" name="wills1[p1_name_sur]" value="'.$wills1[p1_name_sur].'" />
<input type="hidden" name="wills1[p1_email]" value="'.$wills1[p1_email].'" />
<input type="hidden" name="wills1[p1_address]" value="'.$wills1[p1_address].'" />
<input type="hidden" name="wills1[p1_postcode]" value="'.$wills1[p1_postcode].'" />
<input type="hidden" name="wills1[p1_tel]" value="'.$wills1[p1_tel].'" />
<input type="hidden" name="wills1[p1_dob]" value="'.$wills1[p1_dob].'" />
<input type="hidden" name="wills1[p1_occupation]" value="'.$wills1[p1_occupation].'" />
<input type="hidden" name="wills1[p1_bornoutsideuk]" value="'.$wills1[p1_bornoutsideuk].'" />
<input type="hidden" name="wills1[p1_livedoutsideuk]" value="'.$wills1[p1_livedoutsideuk].'" />
<input type="hidden" name="wills1[p1_partner_fore]" value="'.$wills1[p1_partner_fore].'" />
<input type="hidden" name="wills1[p1_partner_sur]" value="'.$wills1[p1_partner_sur].'" />
<input type="hidden" name="wills1[p1_datofmarriage]" value="'.$wills1[p1_datofmarriage].'" />
<input type="hidden" name="wills1[p1_notmarried]" value="'.$wills1[p1_notmarried].'" />
<input type="hidden" name="wills1[p1_marriedsoon]" value="'.$wills1[p1_marriedsoon].'" />
<input type="hidden" name="wills1[p1_marriedbefore]" value="'.$wills1[p1_marriedbefore].'" />
<input type="hidden" name="wills1[p1_child1_name]" value="'.$wills1[p1_child1_name].'" />
<input type="hidden" name="wills1[p1_child1_dob]" value="'.$wills1[p1_child1_dob].'" />
<input type="hidden" name="wills1[p1_child1_address]" value="'.$wills1[p1_child1_address].'" />
<input type="hidden" name="wills1[p1_child2_name]" value="'.$wills1[p1_child2_name].'" />
<input type="hidden" name="wills1[p1_child2_dob]" value="'.$wills1[p1_child2_dob].'" />
<input type="hidden" name="wills1[p1_child2_address]" value="'.$wills1[p1_child2_address].'" />
<input type="hidden" name="wills1[p1_child3_name]" value="'.$wills1[p1_child3_name].'" />
<input type="hidden" name="wills1[p1_child3_dob]" value="'.$wills1[p1_child3_dob].'" />
<input type="hidden" name="wills1[p1_child3_address]" value="'.$wills1[p1_child3_address].'" />
<input type="hidden" name="wills1[p1_children_other]" value="'.$wills1[p1_children_other].'" />
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2"><h3>6: YOUR HOME - is your home </h3></td>
</td>
<tr>
<td class="cell1">a) Owned in your name alone?</b></td>
<td>
<input type="radio" name="wills2[p2_houseinyourname]" value="yes" style="width:auto;"'.$html_p2_houseinyourname1.' /> yes
<input type="radio" name="wills2[p2_houseinyourname]" value="no" style="width:auto;"'.$html_p2_houseinyourname2.' /> no
</td>
</tr>
<tr>
<td class="cell1">b) Owned in joint names with your husband/wife/partner?</b></td>
<td>
<input type="radio" name="wills2[p2_housejoint]" value="yes" style="width:auto;"'.$html_p2_housejoint1.' /> yes
<input type="radio" name="wills2[p2_housejoint]" value="no" style="width:auto;"'.$html_p2_housejoint2.' /> no
</td>
</tr>
<tr>
<td class="cell1">c) Owned in the name of your husband/wife/partner?</b></td>
<td>
<input type="radio" name="wills2[p2_housepartners]" value="yes" style="width:auto;"'.$html_p2_housepartners1.' /> yes
<input type="radio" name="wills2[p2_housepartners]" value="no" style="width:auto;"'.$html_p2_housepartners2.' /> no
</td>
</tr>
<tr>
<td class="cell1">d) Rented:</b></td>
<td>
<input type="radio" name="wills2[p2_houserented]" value="yes" style="width:auto;"'.$html_p2_houserented1.' /> yes
<input type="radio" name="wills2[p2_houserented]" value="no" style="width:auto;"'.$html_p2_houserented2.' /> no
</td>
</tr>
<tr>
<td class="cell1">e) Other - eg provided by a relative?</b></td>
<td>
<input type="radio" name="wills2[p2_houseother]" value="yes" style="width:auto;"'.$html_p2_houseother1.' /> yes
<input type="radio" name="wills2[p2_houseother]" value="no" style="width:auto;"'.$html_p2_houseother2.' /> no
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2"><h3>7: FURTHER QUESTIONS ABOUT YOUR HOME</h3></td>
</td>
<tr>
<td class="cell1">If your answer to 6 (b) is yes, is the property held as:</b></td>
<td>
Joint Tenants
<input type="radio" name="wills2[p2_propertyheldas]" value="Joint Tenants" style="width:auto;"'.$html_p2_propertyheldas1.' /><br />
Tenants in Common
<input type="radio" name="wills2[p2_propertyheldas]" value="Tenants in Common" style="width:auto;"'.$html_p2_propertyheldas2.' /><br />
Don\'t know
<input type="radio" name="wills2[p2_propertyheldas]" value="Don\'t know" style="width:auto;"'.$html_p2_propertyheldas3.' /><br />
</td>
</tr>
<tr>
<td class="cell1" colspan="2">Who holds the deeds ?</b></td>
</td>
<tr>
<td class="cell1">Name:</td>
<td>
<input type="text" name="wills2[p2_deedname]" style="width:100px;" value="'.$wills2['p2_deedname'].'" />
</td>
</tr>
<tr>
<td class="cell1">Ref:</td>
<td>
<input type="text" name="wills2[p2_deedref]" style="width:100px;" value="'.$wills2['p2_deedref'].'" />
</td>
</tr>
<tr>
<td class="cell1">Address:</td>
<td>
<textarea name="wills2[p2_deedaddress]">'.$wills2['p2_deedaddress'].'</textarea>
</td>
</tr>
<tr>
<td class="cell1">If your answer to question 6 (c) was YES please give more details:</td>
<td>
<textarea name="wills2[p2_housemoredetails]">'.$wills2['p2_housemoredetails'].'</textarea>
</td>
</tr>
<tr>
<td class="cell1">Please state the approximate value of your house and the size of any mortgage:</b></td>
<td>
Value: <input type="text" name="wills2[p2_value]" style="width:100px;" value="'.$wills2['p2_value'].'" /><br />
Mortgage: <input type="text" name="wills2[p2_mortgage]" style="width:100px;" value="'.$wills2['p2_mortgage'].'" />
</td>
</tr>
<tr>
<td class="cell1">Will any mortgage be paid off through insurance on your death?</b></td>
<td>
<input type="radio" name="wills2[p2_mortinsure]" value="yes" style="width:auto;"'.$html_p2_mortinsure1.' /> yes
<input type="radio" name="wills2[p2_mortinsure]" value="no" style="width:auto;"'.$html_p2_mortinsure2.' /> no
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1"><h3>8: DO YOU HAVE A BUSINESS?</h3></td>
<td>
<input type="radio" name="wills2[p2_business]" value="yes" style="width:auto;"'.$html_p2_business1.' /> yes
<input type="radio" name="wills2[p2_business]" value="no" style="width:auto;"'.$html_p2_business2.' /> no
</td>
</tr>
<tr>
<td class="cell1">If yes, state type of business:</b></td>
<td>
Company
<input type="radio" name="wills2[p2_businesstype]" value="Company" style="width:auto;"'.$html_p2_businesstype1.' /><br />
Partnership
<input type="radio" name="wills2[p2_businesstype]" value="Partnership" style="width:auto;"'.$html_p2_businesstype2.' /><br />
In your sole name
<input type="radio" name="wills2[p2_businesstype]" value="In your sole name" style="width:auto;"'.$html_p2_businesstype3.' /><br />
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td colspan="2" class="cell1"><h3>9: OTHER ASSETS</h3></td>
</td>
<tr>
<td class="cell1">Please list your other main assets below and give approximate values:</td>
<td>
<textarea name="wills2[p2_otherassets]">'.$wills2['p2_otherassets'].'</textarea>
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td colspane="2" class="cell1"><h3>10: JOINT ASSETS</h3></td>
</tr>
<tr>
<td class="cell1">Do you have any jointly owned assets?</td>
<td>
<input type="radio" name="wills2[p2_jointassets]" value="yes" style="width:auto;"'.$html_p2_jointassets1.' /> yes
<input type="radio" name="wills2[p2_jointassets]" value="no" style="width:auto;"'.$html_p2_jointassets2.' /> no
</td>
</tr>
<tr>
<td class="cell1">If yes, please give a general description, and their approximate values, and the name(s) of the other owner(s).</td>
<td>
<textarea name="wills2[p2_jointassetsdetail]">'.$wills2['p2_jointassetsdetail'].'</textarea>
</td>
</tr>
<tr>
<td colspan="2">
Please note: Jointly owned assets generally pass to the joint owner automatically
and cannot be given away by Will, unless special arrangements are made.
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1"><h3>11: DO YOU OWN ANY ASSETS ABROAD?</h3></td>
<td>
<input type="radio" name="wills2[p2_assetsabroad]" value="yes" style="width:auto;"'.$html_p2_assetsabroad1.' /> yes
<input type="radio" name="wills2[p2_assetsabroad]" value="no" style="width:auto;"'.$html_p2_assetsabroad2.' /> no
</td>
</tr>
<tr>
<td class="cell1">If yes, please give a general description, and their approximate values, and the name(s) of the other owner(s).</td>
<td>
<textarea name="wills2[p2_assetsabroaddetail]">'.$wills2['p2_assetsabroaddetail'].'</textarea>
</td>
</tr>
</table>
<div style="float:right"><input type="submit" value="next page" style="width:80px" /></div>
</form>
<small>* mandatory field</small>
';
}
#### PAGE 3
} elseif ($_POST['function']=='page3' or $_GET['page']=='3') {
if($_GET['check'] != 'false'){
$_SESSION['wills2'] = $_POST['wills2'];
}
$wills1 = $_SESSION['wills1'];
$wills2 = $_SESSION['wills2'];
$wills3 = $_SESSION['wills3'];
$wills4 = $_SESSION['wills4'];
$wills5 = $_SESSION['wills5'];
if($_GET['check'] != 'false'){
header("location:".$_SERVER['PHP_SELF']."?page=3&check=false");
}
$html_p3_houseinyourname1 = false;
$html_p3_houseinyourname2 = false;
$html_p3_houseinyourname3 = false;
if ($wills3[p3_houseinyourname]=='yes') {
$html_p3_houseinyourname1 = ' checked="checked"';
} elseif ($wills3[p3_houseinyourname]=='no.') {
$html_p3_houseinyourname2 = ' checked="checked"';
} elseif ($wills3[p3_houseinyourname]=='no') {
$html_p3_houseinyourname3 = ' checked="checked"';
}
$html_p2_execbunkers1 = false;
$html_p2_execbunkers2 = false;
if ($wills3[p2_execbunkers]=='yes') {
$html_p2_execbunkers1 = ' checked="checked"';
} elseif ($wills3[p2_execbunkers]=='no') {
$html_p2_execbunkers2 = ' checked="checked"';
}
$snippet .= '
Re: Form Failing to Email Properly
Posted: Mon Oct 19, 2009 9:11 am
by motherlover
Code: Select all
<h1>Wills Questionnaire: Page 3 of 5</h1>
<h2>PART C - FUNERAL, EXECUTORS, GUARDIANS</h2>
<form method="post" action="'.$_SERVER['PHP_SELF'].'?page=4">
<input type="hidden" name="key" value="'.$key.'" />
<input type="hidden" name="test" value="'.$test.'" />
<input type="hidden" name="function" value="page4" />
<input type="hidden" name="wills1[p1_name_fore]" value="'.$wills1[p1_name_fore].'" />
<input type="hidden" name="wills1[p1_name_sur]" value="'.$wills1[p1_name_sur].'" />
<input type="hidden" name="wills1[p1_email]" value="'.$wills1[p1_email].'" />
<input type="hidden" name="wills1[p1_address]" value="'.$wills1[p1_address].'" />
<input type="hidden" name="wills1[p1_postcode]" value="'.$wills1[p1_postcode].'" />
<input type="hidden" name="wills1[p1_tel]" value="'.$wills1[p1_tel].'" />
<input type="hidden" name="wills1[p1_dob]" value="'.$wills1[p1_dob].'" />
<input type="hidden" name="wills1[p1_occupation]" value="'.$wills1[p1_occupation].'" />
<input type="hidden" name="wills1[p1_bornoutsideuk]" value="'.$wills1[p1_bornoutsideuk].'" />
<input type="hidden" name="wills1[p1_livedoutsideuk]" value="'.$wills1[p1_livedoutsideuk].'" />
<input type="hidden" name="wills1[p1_partner_fore]" value="'.$wills1[p1_partner_fore].'" />
<input type="hidden" name="wills1[p1_partner_sur]" value="'.$wills1[p1_partner_sur].'" />
<input type="hidden" name="wills1[p1_datofmarriage]" value="'.$wills1[p1_datofmarriage].'" />
<input type="hidden" name="wills1[p1_notmarried]" value="'.$wills1[p1_notmarried].'" />
<input type="hidden" name="wills1[p1_marriedsoon]" value="'.$wills1[p1_marriedsoon].'" />
<input type="hidden" name="wills1[p1_marriedbefore]" value="'.$wills1[p1_marriedbefore].'" />
<input type="hidden" name="wills1[p1_child1_name]" value="'.$wills1[p1_child1_name].'" />
<input type="hidden" name="wills1[p1_child1_dob]" value="'.$wills1[p1_child1_dob].'" />
<input type="hidden" name="wills1[p1_child1_address]" value="'.$wills1[p1_child1_address].'" />
<input type="hidden" name="wills1[p1_child2_name]" value="'.$wills1[p1_child2_name].'" />
<input type="hidden" name="wills1[p1_child2_dob]" value="'.$wills1[p1_child2_dob].'" />
<input type="hidden" name="wills1[p1_child2_address]" value="'.$wills1[p1_child2_address].'" />
<input type="hidden" name="wills1[p1_child3_name]" value="'.$wills1[p1_child3_name].'" />
<input type="hidden" name="wills1[p1_child3_dob]" value="'.$wills1[p1_child3_dob].'" />
<input type="hidden" name="wills1[p1_child3_address]" value="'.$wills1[p1_child3_address].'" />
<input type="hidden" name="wills1[p1_children_other]" value="'.$wills1[p1_children_other].'" />
<input type="hidden" name="wills2[p2_houseinyourname]" value="'.$wills2[p2_houseinyourname].'" />
<input type="hidden" name="wills2[p2_housejoint]" value="'.$wills2[p2_housejoint].'" />
<input type="hidden" name="wills2[p2_housepartners]" value="'.$wills2[p2_housepartners].'" />
<input type="hidden" name="wills2[p2_houserented]" value="'.$wills2[p2_houserented].'" />
<input type="hidden" name="wills2[p2_houseother]" value="'.$wills2[p2_houseother].'" />
<input type="hidden" name="wills2[p2_propertyheldas]" value="'.$wills2[p2_propertyheldas].'" />
<input type="hidden" name="wills2[p2_deedname]" value="'.$wills2[p2_deedname].'" />
<input type="hidden" name="wills2[p2_deedref]" value="'.$wills2[p2_deedref].'" />
<input type="hidden" name="wills2[p2_deedaddress]" value="'.$wills2[p2_deedaddress].'" />
<input type="hidden" name="wills2[p2_housemoredetails]" value="'.$wills2[p2_housemoredetails].'" />
<input type="hidden" name="wills2[p2_value]" value="'.$wills2[p2_value].'" />
<input type="hidden" name="wills2[p2_mortgage]" value="'.$wills2[p2_mortgage].'" />
<input type="hidden" name="wills2[p2_mortinsure]" value="'.$wills2[p2_mortinsure].'" />
<input type="hidden" name="wills2[p2_business]" value="'.$wills2[p2_business].'" />
<input type="hidden" name="wills2[p2_businesstype]" value="'.$wills2[p2_businesstype].'" />
<input type="hidden" name="wills2[p2_otherassets]" value="'.$wills2[p2_otherassets].'" />
<input type="hidden" name="wills2[p2_jointassets]" value="'.$wills2[p2_jointassets].'" />
<input type="hidden" name="wills2[p2_jointassetsdetail]" value="'.$wills2[p2_jointassetsdetail].'" />
<input type="hidden" name="wills2[p2_assetsabroad]" value="'.$wills2[p2_assetsabroad].'" />
<input type="hidden" name="wills2[p2_assetsabroaddetail]" value="'.$wills2[p2_assetsabroaddetail].'" />
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2"><h3>12: FUNERAL</h3></td>
<tr>
<td class="cell1">You may specify in your Will if you wish to be :</b></td>
<td width="30%">
Buried <input type="radio" name="wills3[p3_houseinyourname]" value="yes" style="width:auto;"'.$html_p3_houseinyourname1.' /><br />
Cremated <input type="radio" name="wills3[p3_houseinyourname]" value="no." style="width:auto;"'.$html_p3_houseinyourname2.' /><br />
No preference <input type="radio" name="wills3[p3_houseinyourname]" value="no" style="width:auto;"'.$html_p3_houseinyourname3.' />
</td>
</tr>
<tr>
<td colspan="2" class="cell1">
Please note :
<ul>
<li>You should make these wishes known to your immediate family as well and not rely on what is in your Will.</li>
<li>If you wish to leave any part of your body for medical purposes tell your family and your doctor and carry a donor card.</li>
</ul>
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2">
<h3>13: EXECUTORS</h3>
<br /><br />
List below up to four chosen executors stating if you wish them to act as substitute executors only:
</td>
</tr>
<tr>
<td class="cell1">1 Full Name:</b></td>
<td>
<input type="text" name="wills3[p3_exec1_name]" value="'.$wills3['p3_exec1_name'].'" />
</td>
</tr>
<tr>
<td class="cell1">1 Address:</b></td>
<td>
<textarea name="wills3[p3_exec1_address]" style="height:40px;">'.$wills3['p3_exec1_address'].'</textarea>
</td>
</tr>
<tr>
<td class="cell1">2 Full Name:</b></td>
<td>
<input type="text" name="wills3[p3_exec2_name]" value="'.$wills3['p3_exec2_name'].'" />
</td>
</tr>
<tr>
<td class="cell1">2 Address:</b></td>
<td>
<textarea name="wills3[p3_exec2_address]" style="height:40px;">'.$wills3['p3_exec2_address'].'</textarea>
</td>
</tr>
<tr>
<td class="cell1">3 Full Name:</b></td>
<td>
<input type="text" name="wills3[p3_exec3_name]" value="'.$wills3['p3_exec3_name'].'" />
</td>
</tr>
<tr>
<td class="cell1">3 Address:</b></td>
<td>
<textarea name="wills3[p3_exec3_address]" style="height:40px;">'.$wills3['p3_exec3_address'].'</textarea>
</td>
</tr>
<tr>
<td class="cell1">4 Full Name:</b></td>
<td>
<input type="text" name="wills3[p3_exec4_name]" value="'.$wills3['p3_exec4_name'].'" />
</td>
</tr>
<tr>
<td class="cell1">4 Address:</b></td>
<td>
<textarea name="wills3[p3_exec4_address]" style="height:40px;">'.$wills3['p3_exec4_address'].'</textarea>
</td>
</tr>
<tr>
<td class="cell1">Would you like Partners from our firm to act as your executor?</b></td>
<td>
<input type="radio" name="wills3[p2_execbunkers]" value="yes" style="width:auto;"'.$html_p2_execbunkers1.' /> yes
<input type="radio" name="wills3[p2_execbunkers]" value="no" style="width:auto;"'.$html_p2_execbunkers2.' /> no
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2">
<h3>14: GUARDIANS</h3>
</td>
</tr>
<tr>
<td class="cell1">1 Full Name:</b></td>
<td>
<input type="text" name="wills3[p3_guard1_name]" value="'.$wills3['p3_guard1_name'].'" />
</td>
</tr>
<tr>
<td class="cell1">1 Address:</b></td>
<td>
<textarea name="wills3[p3_guard1_address]" style="height:40px;">'.$wills3['p3_guard1_name'].'</textarea>
</td>
</tr>
<tr>
<td class="cell1">2 Full Name:</b></td>
<td>
<input type="text" name="wills3[p3_guard2_name]" value="'.$wills3['p3_guard2_name'].'"/>
</td>
</tr>
<tr>
<td class="cell1">2 Address:</b></td>
<td>
<textarea name="wills3[p3_guard2_address]" style="height:40px;">'.$wills3['p3_guard2_address'].'</textarea>
</td>
</tr>
</table>
<div style="float:right"><input type="submit" value="next page" style="width:80px" /></div>
</form>
<small>* mandatory field</small>
';
#### PAGE 4
} elseif ($_POST['function']=='page4' or $_GET['page']=='4') {
if($_GET['check'] != 'false'){
$_SESSION['wills3'] = $_POST['wills3'];
}
$wills1 = $_SESSION['wills1'];
$wills2 = $_SESSION['wills2'];
$wills3 = $_SESSION['wills3'];
$wills4 = $_SESSION['wills4'];
$wills5 = $_SESSION['wills5'];
if($_GET['check'] != 'false'){
header("location:".$_SERVER['PHP_SELF']."?page=4&check=false");
}
$html_p4_giftsdealt1 = false;
$html_p4_giftsdealt2 = false;
if ($wills4[p4_giftsdealt]=='yes') {
$html_p4_giftsdealt1 = ' checked="checked"';
} elseif ($wills4[p4_giftsdealt]=='no') {
$html_p4_giftsdealt2 = ' checked="checked"';
}
$html_p4_residuetopartner = false;
if($wills4[p4_residuetopartner]=='yes'){
$html_p4_residuetopartner = ' checked="checked"';
}
$html_p4_residuetochildren = false;
if($wills4[p4_residuetochildren]=='yes'){
$html_p4_residuetochildren = ' checked="checked"';
}
$html_p4_residuetochildrenage = false;
if ($wills4[p4_residuetochildrenage] == '18'){
$html_p4_residuetochildrenage1 = ' SELECTED';
} elseif ($wills4[p4_residuetochildrenage] == '21'){
$html_p4_residuetochildrenage2 = ' SELECTED';
} elseif ($wills4[p4_residuetochildrenage] == '25'){
$html_p4_residuetochildrenage3 = ' SELECTED';
}
$snippet .= '
<h1>Wills Questionnaire: Page 4 of 5</h1>
<h2>PART D - BENEFICIARIES</h2>
<br />
<br />
<form method="post" action="'.$_SERVER['PHP_SELF'].'?page=5">
<input type="hidden" name="key" value="'.$key.'" />
<input type="hidden" name="test" value="'.$test.'" />
<input type="hidden" name="function" value="page5" />
<input type="hidden" name="wills1[p1_name_fore]" value="'.$wills1[p1_name_fore].'" />
<input type="hidden" name="wills1[p1_name_sur]" value="'.$wills1[p1_name_sur].'" />
<input type="hidden" name="wills1[p1_email]" value="'.$wills1[p1_email].'" />
<input type="hidden" name="wills1[p1_address]" value="'.$wills1[p1_address].'" />
<input type="hidden" name="wills1[p1_postcode]" value="'.$wills1[p1_postcode].'" />
<input type="hidden" name="wills1[p1_tel]" value="'.$wills1[p1_tel].'" />
<input type="hidden" name="wills1[p1_dob]" value="'.$wills1[p1_dob].'" />
<input type="hidden" name="wills1[p1_occupation]" value="'.$wills1[p1_occupation].'" />
<input type="hidden" name="wills1[p1_bornoutsideuk]" value="'.$wills1[p1_bornoutsideuk].'" />
<input type="hidden" name="wills1[p1_livedoutsideuk]" value="'.$wills1[p1_livedoutsideuk].'" />
<input type="hidden" name="wills1[p1_partner_fore]" value="'.$wills1[p1_partner_fore].'" />
<input type="hidden" name="wills1[p1_partner_sur]" value="'.$wills1[p1_partner_sur].'" />
<input type="hidden" name="wills1[p1_datofmarriage]" value="'.$wills1[p1_datofmarriage].'" />
<input type="hidden" name="wills1[p1_notmarried]" value="'.$wills1[p1_notmarried].'" />
<input type="hidden" name="wills1[p1_marriedsoon]" value="'.$wills1[p1_marriedsoon].'" />
<input type="hidden" name="wills1[p1_marriedbefore]" value="'.$wills1[p1_marriedbefore].'" />
<input type="hidden" name="wills1[p1_child1_name]" value="'.$wills1[p1_child1_name].'" />
<input type="hidden" name="wills1[p1_child1_dob]" value="'.$wills1[p1_child1_dob].'" />
<input type="hidden" name="wills1[p1_child1_address]" value="'.$wills1[p1_child1_address].'" />
<input type="hidden" name="wills1[p1_child2_name]" value="'.$wills1[p1_child2_name].'" />
<input type="hidden" name="wills1[p1_child2_dob]" value="'.$wills1[p1_child2_dob].'" />
<input type="hidden" name="wills1[p1_child2_address]" value="'.$wills1[p1_child2_address].'" />
<input type="hidden" name="wills1[p1_child3_name]" value="'.$wills1[p1_child3_name].'" />
<input type="hidden" name="wills1[p1_child3_dob]" value="'.$wills1[p1_child3_dob].'" />
<input type="hidden" name="wills1[p1_child3_address]" value="'.$wills1[p1_child3_address].'" />
<input type="hidden" name="wills1[p1_children_other]" value="'.$wills1[p1_children_other].'" />
<input type="hidden" name="wills2[p2_houseinyourname]" value="'.$wills2[p2_houseinyourname].'" />
<input type="hidden" name="wills2[p2_housejoint]" value="'.$wills2[p2_housejoint].'" />
<input type="hidden" name="wills2[p2_housepartners]" value="'.$wills2[p2_housepartners].'" />
<input type="hidden" name="wills2[p2_houserented]" value="'.$wills2[p2_houserented].'" />
<input type="hidden" name="wills2[p2_houseother]" value="'.$wills2[p2_houseother].'" />
<input type="hidden" name="wills2[p2_propertyheldas]" value="'.$wills2[p2_propertyheldas].'" />
<input type="hidden" name="wills2[p2_deedname]" value="'.$wills2[p2_deedname].'" />
<input type="hidden" name="wills2[p2_deedref]" value="'.$wills2[p2_deedref].'" />
<input type="hidden" name="wills2[p2_deedaddress]" value="'.$wills2[p2_deedaddress].'" />
<input type="hidden" name="wills2[p2_housemoredetails]" value="'.$wills2[p2_housemoredetails].'" />
<input type="hidden" name="wills2[p2_value]" value="'.$wills2[p2_value].'" />
<input type="hidden" name="wills2[p2_mortgage]" value="'.$wills2[p2_mortgage].'" />
<input type="hidden" name="wills2[p2_mortinsure]" value="'.$wills2[p2_mortinsure].'" />
<input type="hidden" name="wills2[p2_business]" value="'.$wills2[p2_business].'" />
<input type="hidden" name="wills2[p2_businesstype]" value="'.$wills2[p2_businesstype].'" />
<input type="hidden" name="wills2[p2_otherassets]" value="'.$wills2[p2_otherassets].'" />
<input type="hidden" name="wills2[p2_jointassets]" value="'.$wills2[p2_jointassets].'" />
<input type="hidden" name="wills2[p2_jointassetsdetail]" value="'.$wills2[p2_jointassetsdetail].'" />
<input type="hidden" name="wills2[p2_assetsabroad]" value="'.$wills2[p2_assetsabroad].'" />
<input type="hidden" name="wills2[p2_assetsabroaddetail]" value="'.$wills2[p2_assetsabroaddetail].'" />
<input type="hidden" name="wills3[p3_houseinyourname]" value="'.$wills3[p3_houseinyourname].'" />
<input type="hidden" name="wills3[p3_exec1_name]" value="'.$wills3[p3_exec1_name].'" />
<input type="hidden" name="wills3[p3_exec1_address]" value="'.$wills3[p3_exec1_address].'" />
<input type="hidden" name="wills3[p3_exec2_name]" value="'.$wills3[p3_exec2_name].'" />
<input type="hidden" name="wills3[p3_exec2_address]" value="'.$wills3[p3_exec2_address].'" />
<input type="hidden" name="wills3[p3_exec3_name]" value="'.$wills3[p3_exec3_name].'" />
<input type="hidden" name="wills3[p3_exec3_address]" value="'.$wills3[p3_exec3_address].'" />
<input type="hidden" name="wills3[p3_exec4_name]" value="'.$wills3[p3_exec4_name].'" />
<input type="hidden" name="wills3[p3_exec4_address]" value="'.$wills3[p3_exec4_address].'" />
<input type="hidden" name="wills3[p2_execbunkers]" value="'.$wills3[p2_execbunkers].'" />
<input type="hidden" name="wills3[p3_guard1_name]" value="'.$wills3[p3_guard1_name].'" />
<input type="hidden" name="wills3[p3_guard1_address]" value="'.$wills3[p3_guard1_address].'" />
<input type="hidden" name="wills3[p3_guard2_name]" value="'.$wills3[p3_guard2_name].'" />
<input type="hidden" name="wills3[p3_guard2_address]" value="'.$wills3[p3_guard2_address].'" />
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2"><h3>15: CASH GIFTS</h3></td>
</td>
<tr>
<td class="cell1">Please give the name and address of the beneficiary and the
amount to be given, with the age of anyone who is under 18 .</td>
<td>
<textarea name="wills4[p4_cashgifts]">'.$wills4['p4_cashgifts'].'</textarea>
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2">
<h3>16: GIFTS OF PERSONAL EFFECTS</h3>
<br /><br />
Alternatively, if you so wish, gifts of articles can be dealt with informally by a letter to your executors:
</td>
</tr>
<tr>
<td class="cell1">Please indicate :</b></td>
<td>
<input type="radio" name="wills4[p4_giftsdealt]" value="yes" style="width:auto;"'.$html_p4_giftsdealt1.' /> yes
<input type="radio" name="wills4[p4_giftsdealt]" value="no" style="width:auto;"'.$html_p4_giftsdealt2.' /> no
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2">
<h3>17: THE RESIDUE</h3>
<br />
<br />
</b>.
</td>
</tr>
<tr>
<td class="cell1" colspan="2">
<input type="checkbox" name="wills4[p4_residuetopartner]" value="yes" style="width:auto;"'.$html_p4_residuetopartner.' />
Everything to my husband/wife/partner named at question 2 above, outright, but if he/she has died then to my children, named at question 4 above, equally;</b>
</td>
</tr>
<tr>
<td class="cell1" colspan="2">
<input type="checkbox" name="wills4[p4_residuetochildren]" value="yes" style="width:auto;"'.$html_p4_residuetochildren.' />
Everything to my children, named at question 4 above, equally and any other children of mine;</b>
</td>
</tr>
<tr>
<td class="cell1" colspan="2">You may choose the age at which your children will receive their entitlement.</b>
<select name="wills4[p4_residuetochildrenage]" />
<option>choose</option>
<option'.$html_p4_residuetochildrenage1.'>18</option>
<option'.$html_p4_residuetochildrenage2.'>21</option>
<option'.$html_p4_residuetochildrenage3.'>25</option>
</select>
</tr>
<tr>
<td class="cell1">
To my husband/wife/partner named at question 2 above, but if he/she has died before me to the
person(s)/organisation(s) named below. If not in equal shares, then show the share each is
to take.
</td>
<td>
<textarea name="wills4[p4_residueshares]">'.$wills4['p4_residueshares'].'</textarea>
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2">
<h3>18: IF NONE OF THE ABOVE CHOICES IS APPROPRIATE</h3>
</td>
</tr>
<tr>
<td class="cell1">1 Full Name:</td>
<td>
<input type="text" name="wills4[p4_other1_name]" value="'.$wills4['p4_other1_name'].'" />
</td>
</tr>
<tr>
<td class="cell1">1 Share:</td>
<td>
<input type="text" name="wills4[p4_other1_share]" value="'.$wills4['p4_other1_share'].'" />
</td>
</tr>
<tr>
<td class="cell1">1 Address:</td>
<td>
<textarea name="wills4[p4_other1_address]" style="height:40px;">'.$wills4['p4_other1_address'].'</textarea>
</td>
</tr>
<tr>
<td class="cell1">2 Full Name:</td>
<td>
<input type="text" name="wills4[p4_other2_name]" value="'.$wills4['p4_other2_name'].'" />
</td>
</tr>
<tr>
<td class="cell1">2 Share:</td>
<td>
<input type="text" name="wills4[p4_other2_share]" value="'.$wills4['p4_other2_share'].'" />
</td>
</tr>
<tr>
<td class="cell1">2 Address:</td>
<td>
<textarea name="wills4[p4_other2_address]" style="height:40px;">'.$wills4['p4_other2_address'].'</textarea>
</td>
</tr>
<tr>
<td class="cell1" colspan="2">
Who is to benefit if the recipient dies before you?</b>
</td>
</tr>
<tr>
<td class="cell1">1 Full Name:</td>
<td>
<input type="text" name="wills4[p4_otherifdies1_name]" value="'.$wills4['p4_otherifdies1_name'].'" />
</td>
</tr>
<tr>
<td class="cell1">1 Share:</td>
<td>
<input type="text" name="wills4[p4_otherifdies1_share]" value="'.$wills4['p4_otherifdies1_share'].'" />
</td>
</tr>
<tr>
<td class="cell1">1 Address:</td>
<td>
<textarea name="wills4[p4_otherifdies1_address]" style="height:40px;">'.$wills4['p4_otherifdies1_address'].'</textarea>
</td>
</tr>
<tr>
<td class="cell1">2 Full Name:</td>
<td>
<input type="text" name="wills4[p4_otherifdies2_name]" value="'.$wills4['p4_otherifdies2_name'].'" />
</td>
</tr>
<tr>
<td class="cell1">2 Share:</td>
<td>
<input type="text" name="wills4[p4_otherifdies2_share]" value="'.$wills4['p4_otherifdies2_share'].'" />
</td>
</tr>
<tr>
<td class="cell1">2 Address:</td>
<td>
<textarea name="wills4[p4_otherifdies2_address]" style="height:40px;">'.$wills4['p4_otherifdies2_address'].'</textarea>
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2">
<h3>19: OTHER ISSUES</h3>
</td>
</tr>
<tr>
<td class="cell1">
Do you have any issues that worry you or other queries you may wish to raise with regard to making
your will? (For example issues regarding Inheritance Tax.)
</td>
<td>
<textarea name="wills4[p4_otherissues]">'.$wills4['p4_otherissues'].'</textarea>
</td>
</tr>
</table>
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2">
<h3>OTHER POINTS TO NOTE</h3>
<ol>
<li>A Will is usually completely cancelled if you marry after making it. You will need to make another Will immediately, or one which takes a forthcoming marriage into account.</li>
<li>On divorce, gifts to your husband/wife are cancelled as is his/her appointment as executor but the rest of the Will stands. This can create problems and it is better to make a new Will.</li>
<li>If you are not making any provision for a husband/wife/partner, or a former husband/wife/partner, it is possible that he/she could make a claim against your estate. If this does apply please seek further advice from us.</li>
<li>Please feel free to ask us for our help or advice or more information on any topic related to your Will.</li>
</ol>
</td>
</tr>
</table>
<div style="float:right"><input type="submit" value="next page" style="width:80px" /></div>
</form>
<small>* mandatory field</small>
';
#### PAGE 5
} elseif ($_POST['function']=='page5' or $_GET['page']=='5') {
if($_GET['check'] != 'false'){
$_SESSION['wills4'] = $_POST['wills4'];
}
$wills1 = $_SESSION['wills1'];
$wills2 = $_SESSION['wills2'];
$wills3 = $_SESSION['wills3'];
$wills4 = $_SESSION['wills4'];
$wills5 = $_SESSION['wills5'];
if($_GET['check'] != 'false'){
header("location:".$_SERVER['PHP_SELF']."?page=5&check=false");
}
$html_p5_powerofatt1 = false;
$html_p5_powerofatt2 = false;
if ($wills5[p5_powerofatt]=='yes') {
$html_p5_powerofatt1 = ' checked="checked"';
} elseif ($wills5[p4_giftsdealt]=='no') {
$html_p5_powerofatt2 = ' checked="checked"';
}
$snippet .= '
<h1>Wills Questionnaire: Page 5 of 5</h1>
<h2>PART E - Lasting POWER OF ATTORNEY</h2>
<form method="post" action="'.$_SERVER['PHP_SELF'].'?page=6">
<input type="hidden" name="key" value="'.$key.'" />
<input type="hidden" name="test" value="'.$test.'" />
<input type="hidden" name="function" value="complete" />
<input type="hidden" name="wills1[p1_name_fore]" value="'.$wills1[p1_name_fore].'" />
<input type="hidden" name="wills1[p1_name_sur]" value="'.$wills1[p1_name_sur].'" />
<input type="hidden" name="wills1[p1_email]" value="'.$wills1[p1_email].'" />
<input type="hidden" name="wills1[p1_address]" value="'.$wills1[p1_address].'" />
<input type="hidden" name="wills1[p1_postcode]" value="'.$wills1[p1_postcode].'" />
<input type="hidden" name="wills1[p1_tel]" value="'.$wills1[p1_tel].'" />
<input type="hidden" name="wills1[p1_dob]" value="'.$wills1[p1_dob].'" />
<input type="hidden" name="wills1[p1_occupation]" value="'.$wills1[p1_occupation].'" />
<input type="hidden" name="wills1[p1_bornoutsideuk]" value="'.$wills1[p1_bornoutsideuk].'" />
<input type="hidden" name="wills1[p1_livedoutsideuk]" value="'.$wills1[p1_livedoutsideuk].'" />
<input type="hidden" name="wills1[p1_partner_fore]" value="'.$wills1[p1_partner_fore].'" />
<input type="hidden" name="wills1[p1_partner_sur]" value="'.$wills1[p1_partner_sur].'" />
<input type="hidden" name="wills1[p1_datofmarriage]" value="'.$wills1[p1_datofmarriage].'" />
<input type="hidden" name="wills1[p1_notmarried]" value="'.$wills1[p1_notmarried].'" />
<input type="hidden" name="wills1[p1_marriedsoon]" value="'.$wills1[p1_marriedsoon].'" />
<input type="hidden" name="wills1[p1_marriedbefore]" value="'.$wills1[p1_marriedbefore].'" />
<input type="hidden" name="wills1[p1_child1_name]" value="'.$wills1[p1_child1_name].'" />
<input type="hidden" name="wills1[p1_child1_dob]" value="'.$wills1[p1_child1_dob].'" />
<input type="hidden" name="wills1[p1_child1_address]" value="'.$wills1[p1_child1_address].'" />
<input type="hidden" name="wills1[p1_child2_name]" value="'.$wills1[p1_child2_name].'" />
<input type="hidden" name="wills1[p1_child2_dob]" value="'.$wills1[p1_child2_dob].'" />
<input type="hidden" name="wills1[p1_child2_address]" value="'.$wills1[p1_child2_address].'" />
<input type="hidden" name="wills1[p1_child3_name]" value="'.$wills1[p1_child3_name].'" />
<input type="hidden" name="wills1[p1_child3_dob]" value="'.$wills1[p1_child3_dob].'" />
<input type="hidden" name="wills1[p1_child3_address]" value="'.$wills1[p1_child3_address].'" />
<input type="hidden" name="wills1[p1_children_other]" value="'.$wills1[p1_children_other].'" />
<input type="hidden" name="wills2[p2_houseinyourname]" value="'.$wills2[p2_houseinyourname].'" />
<input type="hidden" name="wills2[p2_housejoint]" value="'.$wills2[p2_housejoint].'" />
<input type="hidden" name="wills2[p2_housepartners]" value="'.$wills2[p2_housepartners].'" />
<input type="hidden" name="wills2[p2_houserented]" value="'.$wills2[p2_houserented].'" />
<input type="hidden" name="wills2[p2_houseother]" value="'.$wills2[p2_houseother].'" />
<input type="hidden" name="wills2[p2_propertyheldas]" value="'.$wills2[p2_propertyheldas].'" />
<input type="hidden" name="wills2[p2_deedname]" value="'.$wills2[p2_deedname].'" />
<input type="hidden" name="wills2[p2_deedref]" value="'.$wills2[p2_deedref].'" />
<input type="hidden" name="wills2[p2_deedaddress]" value="'.$wills2[p2_deedaddress].'" />
<input type="hidden" name="wills2[p2_housemoredetails]" value="'.$wills2[p2_housemoredetails].'" />
<input type="hidden" name="wills2[p2_value]" value="'.$wills2[p2_value].'" />
<input type="hidden" name="wills2[p2_mortgage]" value="'.$wills2[p2_mortgage].'" />
<input type="hidden" name="wills2[p2_mortinsure]" value="'.$wills2[p2_mortinsure].'" />
<input type="hidden" name="wills2[p2_business]" value="'.$wills2[p2_business].'" />
<input type="hidden" name="wills2[p2_businesstype]" value="'.$wills2[p2_businesstype].'" />
<input type="hidden" name="wills2[p2_otherassets]" value="'.$wills2[p2_otherassets].'" />
<input type="hidden" name="wills2[p2_jointassets]" value="'.$wills2[p2_jointassets].'" />
<input type="hidden" name="wills2[p2_jointassetsdetail]" value="'.$wills2[p2_jointassetsdetail].'" />
<input type="hidden" name="wills2[p2_assetsabroad]" value="'.$wills2[p2_assetsabroad].'" />
<input type="hidden" name="wills2[p2_assetsabroaddetail]" value="'.$wills2[p2_assetsabroaddetail].'" />
<input type="hidden" name="wills3[p3_houseinyourname]" value="'.$wills3[p3_houseinyourname].'" />
<input type="hidden" name="wills3[p3_exec1_name]" value="'.$wills3[p3_exec1_name].'" />
<input type="hidden" name="wills3[p3_exec1_address]" value="'.$wills3[p3_exec1_address].'" />
<input type="hidden" name="wills3[p3_exec2_name]" value="'.$wills3[p3_exec2_name].'" />
<input type="hidden" name="wills3[p3_exec2_address]" value="'.$wills3[p3_exec2_address].'" />
<input type="hidden" name="wills3[p3_exec3_name]" value="'.$wills3[p3_exec3_name].'" />
<input type="hidden" name="wills3[p3_exec3_address]" value="'.$wills3[p3_exec3_address].'" />
<input type="hidden" name="wills3[p3_exec4_name]" value="'.$wills3[p3_exec4_name].'" />
<input type="hidden" name="wills3[p3_exec4_address]" value="'.$wills3[p3_exec4_address].'" />
<input type="hidden" name="wills3[p2_execbunkers]" value="'.$wills3[p2_execbunkers].'" />
<input type="hidden" name="wills3[p3_guard1_name]" value="'.$wills3[p3_guard1_name].'" />
<input type="hidden" name="wills3[p3_guard1_address]" value="'.$wills3[p3_guard1_address].'" />
<input type="hidden" name="wills3[p3_guard2_name]" value="'.$wills3[p3_guard2_name].'" />
<input type="hidden" name="wills3[p3_guard2_address]" value="'.$wills3[p3_guard2_address].'" />
<input type="hidden" name="wills4[p4_cashgifts]" value="'.$wills4[p4_cashgifts].'" />
<input type="hidden" name="wills4[p4_giftsdealt]" value="'.$wills4[p4_giftsdealt].'" />
<input type="hidden" name="wills4[p4_residuetopartner]" value="'.$wills4[p4_residuetopartner].'" />
<input type="hidden" name="wills4[p4_residuetochildren]" value="'.$wills4[p4_residuetochildren].'" />
<input type="hidden" name="wills4[p4_residuetochildrenage]" value="'.$wills4[p4_residuetochildrenage].'" />
<input type="hidden" name="wills4[p4_residueshares]" value="'.$wills4[p4_residueshares].'" />
<input type="hidden" name="wills4[p4_other1_name]" value="'.$wills4[p4_other1_name].'" />
<input type="hidden" name="wills4[p4_other1_share]" value="'.$wills4[p4_other1_share].'" />
<input type="hidden" name="wills4[p4_other1_address]" value="'.$wills4[p4_other1_address].'" />
<input type="hidden" name="wills4[p4_other2_name]" value="'.$wills4[p4_other2_name].'" />
<input type="hidden" name="wills4[p4_other2_share]" value="'.$wills4[p4_other2_share].'" />
<input type="hidden" name="wills4[p4_other2_address]" value="'.$wills4[p4_other2_address].'" />
<input type="hidden" name="wills4[p4_otherifdies1_name]" value="'.$wills4[p4_otherifdies1_name].'" />
<input type="hidden" name="wills4[p4_otherifdies1_share]" value="'.$wills4[p4_otherifdies1_share].'" />
<input type="hidden" name="wills4[p4_otherifdies1_address]" value="'.$wills4[p4_otherifdies1_address].'" />
<input type="hidden" name="wills4[p4_otherifdies2_name]" value="'.$wills4[p4_otherifdies2_name].'" />
<input type="hidden" name="wills4[p4_otherifdies2_share]" value="'.$wills4[p4_otherifdies2_share].'" />
<input type="hidden" name="wills4[p4_otherifdies2_address]" value="'.$wills4[p4_otherifdies2_address].'" />
<input type="hidden" name="wills4[p4_otherissues]" value="'.$wills4[p4_otherissues].'" />
<table width="98%" border="0" cellspacing="1" class="emailbox bordered">
<tr>
<td class="cell1" colspan="2">
<p>We strongly recommend clients of more mature years to sign an Lasting Power of Attorney
to cover possible mental incapacity.</p>
</td>
</tr>
<tr>
<td class="cell1">Have you already signed an Lasting Power of Attorney?</b></td>
<td>
<input type="radio" name="wills5[p5_powerofatt]" value="yes" style="width:auto;" /> yes
<input type="radio" name="wills5[p5_powerofatt]" value="no" style="width:auto;" /> no
</td>
</tr>
<tr>
<td class="cell1">If no, would you like us to advise you about this?</b></td>
<td>
<input type="radio" name="wills5[p5_powerofattinform]" value="yes" style="width:auto;" /> yes
<input type="radio" name="wills5[p5_powerofattinform]" value="no" style="width:auto;" /> no
</td>
</tr>
<tr>
<td class="cell1" colspan="2">
<p>Please list below who you would like to act as your Attorney(s). It is wise to have at least
two, although it need not be necessary for both to act at the same time.</p>
</td>
</tr>
<tr>
<td class="cell1">1 Full Name:</b></td>
<td>
<input type="text" name="wills5[p5_powerofatt1_fullname]" />
</td>
</tr>
<tr>
<td class="cell1">1 Address:</b></td>
<td>
<textarea name="wills5[p5_powerofatt1_address]" style="height:40px;"></textarea>
</td>
</tr>
<tr>
<td class="cell1">2 Full Name:</b></td>
<td>
<input type="text" name="wills5[p5_powerofatt2_fullname]" />
</td>
</tr>
<tr>
<td class="cell1">2 Address:</b></td>
<td>
<textarea name="wills5[p5_powerofatt2_address]" style="height:40px;"></textarea>
</td>
</tr>
</table>
<div style="float:right"><input type="submit" value="complete" style="width:80px" /></div>
</form>
<small>* mandatory field</small>
';
#### EMAIL ANSWERS
} else {
$wills1 = $_SESSION['wills1'];
$wills2 = $_SESSION['wills2'];
$wills3 = $_SESSION['wills3'];
$wills4 = $_SESSION['wills4'];
$wills5 = $_SESSION['wills5'];
$email_answer = '
PART A - YOUR FAMILY
----------------------------
1: YOUR DETAILS
forenames/surname: '.$wills1[p1_name_fore].' '.$wills1[p1_name_sur].'
email: '.$wills1[p1_email].'
Contact address: '.$wills1[p1_address].'
Contact Postcode: '.$wills1[p1_postcode].'
Contact tel no: '.$wills1[p1_tel].'
Date of birth: '.$wills1[p1_dob].'
Occupation: '.$wills1[p1_occupation].'
Were you born outside the UK? '.$wills1[p1_bornoutsideuk].'
Have you ever lived outside the UK? '.$wills1[p1_livedoutsideuk].'
2: YOUR HUSBAND/WIFE/PARTNER
Forenames/surname: '.$wills1[p1_partner_fore].' '.$wills1[p1_partner_sur].'
3: MARRIAGE/PARTNERSHIP DETAILS
Date of Marriage: '.$wills1[p1_datofmarriage].'
Not married to your partner: '.$wills1[p1_notmarried].'
Intending to marry/re-marry in the near future: '.$wills1[p1_marriedsoon].'
Has either of you been married before? '.$wills1[p1_marriedbefore].'
4: YOUR CHILDREN (INCLUDING YOUR CHILDREN FROM A PREVIOUS MARRIAGE OR RELATIONSHIP)
Child 1 Name: '.$wills1[p1_child1_name].'
Child 1 Date of Birth: '.$wills1[p1_child1_dob].'
Child 1 Address: '.$wills1[p1_child1_address].'
Child 2 Name: '.$wills1[p1_child2_name].'
Child 2 Date of Birth: '.$wills1[p1_child2_dob].'
Child 2 Address: '.$wills1[p1_child2_address].'
Child 3 Name: '.$wills1[p1_child3_name].'
Child 3 Date of Birth: '.$wills1[p1_child3_dob].'
Child 3 Address: '.$wills1[p1_child3_address].'
5: CHILDREN OF YOUR HUSBAND/WIFE/ PARTNER\'S PREVIOUS MARRIAGES OR RELATIONSHIPS
Please give full names, dates of birth and address if different from yours:
'.$wills1[p1_children_other].'
PART B - YOUR HOME AND OTHER ASSETS
-----------------------------------
6: YOUR HOME - is your home
Owned in your name alone? '.$wills2[p2_houseinyourname].'
Owned in joint names with your husband/wife/partner? '.$wills2[p2_housejoint].'
Owned in the name of your husband/wife/partner? '.$wills2[p2_housepartners].'
Rented: '.$wills2[p2_houserented].'
Other - eg provided by a relative? '.$wills2[p2_houseother].'
7: FURTHER QUESTIONS ABOUT YOUR HOME
If your answer to 6 (b) is yes, property held as: '.$wills2[p2_propertyheldas].'
Who holds the deeds ?
Name: '.$wills2[p2_deedname].'
Ref: '.$wills2[p2_deedref].'
Address: '.$wills2[p2_deedaddress].'
If your answer to question 6 (c) was YES please give more details:
'.$wills2[p2_housemoredetails].'
Approximate value of house: '.$wills2[p2_value].'
Approximate size of mortgage: '.$wills2[p2_mortgage].'
Will any mortgage be paid off through insurance on your death? '.$wills2[p2_mortinsure].'
8: DO YOU HAVE A BUSINESS? '.$wills2[p2_business].'
type of business: '.$wills2[p2_businesstype].'
9: OTHER ASSETS
'.$wills2[p2_otherassets].'
10: DO YOU HAVE JOINTLY OWNED ASSETS? '.$wills2[p2_jointassets].'
'.$wills2[p2_jointassetsdetail].'
11: DO YOU OWN ANY ASSETS ABROAD? '.$wills2[p2_assetsabroad].'
'.$wills2[p2_assetsabroaddetail].'
PART C - FUNERAL, EXECUTORS, GUARDIANS
--------------------------------------
12: FUNERAL
You may specify in your Will if you wish to be : '.$wills3[p3_houseinyourname].'
13: EXECUTORS
1 Full Name: '.$wills3[p3_exec1_name].'
1 Address: '.$wills3[p3_exec1_address].'
2 Full Name: '.$wills3[p3_exec2_name].'
2 Address: '.$wills3[p3_exec2_address].'
3 Full Name: '.$wills3[p3_exec3_name].'
3 Address: '.$wills3[p3_exec3_address].'
4 Full Name: '.$wills3[p3_exec4_name].'
4 Address: '.$wills3[p3_exec4_address].'
Would you like Partners from our firm to act as your executor?
14: GUARDIANS
1 Full Name: '.$wills3[p3_guard1_name].'
1 Address: '.$wills3[p3_guard1_address].'
2 Full Name: '.$wills3[p3_guard2_name].'
2 Address: '.$wills3[p3_guard2_address].'
PART D - BENEFICIARIES
----------------------
15: CASH GIFTS
'.$wills4[p4_cashgifts].'
16: GIFTS OF PERSONAL EFFECTS
gifts of articles to be dealt with informally by a letter to your executors:
'.$wills4[p4_giftsdealt].'
17: THE RESIDUE
18: IF NONE OF THE ABOVE CHOICES IS APPROPRIATE
1 Full Name: '.$wills4[p4_other1_name].'
1 Share: '.$wills4[p4_other1_share].'
1 Address: '.$wills4[p4_other1_address].'
2 Full Name: '.$wills4[p4_other2_name].'
2 Share: '.$wills4[p4_other2_share].'
2 Address: '.$wills4[p4_other2_address].'
Who is to benefit if the recipient dies before you?
1 Full Name: '.$wills4[p4_otherifdies1_name].'
1 Share: '.$wills4[p4_otherifdies1_share].'
1 Address: '.$wills4[p4_otherifdies1_address].'
2 Full Name: '.$wills4[p4_otherifdies2_name].'
2 Share: '.$wills4[p4_otherifdies2_share].'
2 Address: '.$wills4[p4_otherifdies2_address].'
19: OTHER ISSUES
'.$wills4[p4_otherissues].'
PART E - Lasting POWER OF ATTORNEY
-----------------------------------
Have you already signed an Lasting Power of Attorney? '.$wills5[p5_powerofatt].'
If no, would you like us to advise you about this? '.$wills5[p5_powerofattinform].'
Attorney(s):
1 Full Name: '.$wills5[p5_powerofatt1_fullname].'
1 Address: '.$wills5[p5_powerofatt1_address].'
2 Full Name: '.$wills5[p5_powerofatt2_fullname].'
2 Address: '.$wills5[p5_powerofatt2_address].'
';
$snippet = '
<h1>Wills Questionnaire: Completed</h1>
Thank you for contacting us, we will be in contact as soon as possible.<br /><br />
<br /><br /><br /><br /><br /><br /><br /><br /><br /><br />';
## EMAIL BACK TO AGENCY
$wills1[p1_name_fore] = addslashes($wills1[p1_name_fore]);
$wills1[p1_name_sur] = addslashes($wills1[p1_name_sur]);
$mail_headers = "From: $wills1[p1_name_fore] $wills1[p1_name_sur] <$wills1[p1_email]>\r\n";
$mail_headers .= "CC: mail@bunkers.co.uk\r\n";
$mail_to = 'maxwell.wright@bunkers.co.uk';
#$mail_to = "Curtis Hard <curtis@mindworks.co.uk>";
#$mail_to = "Craig Morey <craigmorey@mac.com>";
$mail_subject = 'Bunkers Wills Questionnaire';
$mail_message = 'The following visitor to the Bunkers website posted the following Wills Questionnaire :
'.$email_answer.'
------------
end of email
------------
';
mail($mail_to, $mail_subject, $mail_message, $mail_headers);
## EMAIL BACK TO USER
$mail_headers = "From: Bunkers Solicitors <mail@bunkers.co.uk>\r\n";
$mail_to = "$wills1[p1_name_fore] $wills1[p1_name_sur] <$wills1[p1_email]>";
#$mail_to = "Craig Morey <craigmorey@mac.com>";
$mail_subject = 'Bunkers Wills Questionnaire';
$mail_message = 'Thanks for your interest in Bunkers Solicitors, and sending an email through the online Wills questionnaire.
This is confirmation that your email to Bunkers Solicitors has been sent
The details you sent were:
'.$email_answer.'
We will try to get back to you on this matter as soon as possible.
Please be advised this is an automatically generated message and as such no response is necessary.
';
mail($mail_to, $mail_subject, $mail_message, $mail_headers);
$session = array('wills1',
'wills2',
'wills3',
'wills4',
'wills5'
);
foreach($session as $value){
unset($_SESSION[$value]);
# $unset .= $value;
}
}
Re: Form Failing to Email Properly
Posted: Mon Oct 19, 2009 9:16 am
by motherlover
The Email generated:
PART A - YOU AND YOUR FAMILY
----------------------------
1: YOUR DETAILS
forenames/surname: A A
email: A
Contact address: A
Contact Postcode: A
Contact tel no: A
Date of birth: A
Occupation: A
Were you born outside the UK? A
Have you ever lived outside the UK? A
2: YOUR HUSBAND/WIFE/PARTNER
Forenames/surname: A A
3: MARRIAGE/PARTNERSHIP DETAILS
Date of Marriage: A
Not married to your partner: A
Intending to marry/re-marry in the near future: A Has either of you been married before? A
4: YOUR CHILDREN (INCLUDING YOUR CHILDREN FROM A PREVIOUS MARRIAGE OR RELATIONSHIP)
Child 1 Name: A
Child 1 Date of Birth: A
Child 1 Address: A
Child 2 Name: A
Child 2 Date of Birth: A
Child 2 Address: A
Child 3 Name: A
Child 3 Date of Birth: A
Child 3 Address: A
5: CHILDREN OF YOUR HUSBAND/WIFE/ PARTNER'S PREVIOUS MARRIAGES OR RELATIONSHIPS Please give full names, dates of birth and address if different from yours:
A
PART B - YOUR HOME AND OTHER ASSETS
-----------------------------------
6: YOUR HOME - is your home
Owned in your name alone? A
Owned in joint names with your husband/wife/partner? A Owned in the name of your husband/wife/partner? A
Rented: A
Other - eg provided by a relative? A
7: FURTHER QUESTIONS ABOUT YOUR HOME
If your answer to 6 (b) is yes, property held as: A Who holds the deeds ?
Name: A
Ref: A
Address: A
If your answer to question 6 (c) was YES please give more details:
A
Approximate value of house: A
Approximate size of mortgage: A
Will any mortgage be paid off through insurance on your death? A
8: DO YOU HAVE A BUSINESS? A
type of business: A
9: OTHER ASSETS
A
10: DO YOU HAVE JOINTLY OWNED ASSETS? A
A
11: DO YOU OWN ANY ASSETS ABROAD? A
A
PART C - FUNERAL, EXECUTORS, GUARDIANS
--------------------------------------
12: FUNERAL
You may specify in your Will if you wish to be : A
13: EXECUTORS
1 Full Name: A
1 Address: A
2 Full Name: A
2 Address: A
3 Full Name: A
3 Address: A
4 Full Name: A
4 Address: A
Would you like Partners from our firm to act as your executor?
14: GUARDIANS
1 Full Name: A
1 Address: A
2 Full Name: A
2 Address: A
PART D - BENEFICIARIES
----------------------
15: CASH GIFTS
A
16: GIFTS OF PERSONAL EFFECTS
gifts of articles to be dealt with informally by a letter to your executors:
A
17: THE RESIDUE
Everything to my husband/wife/partner named at question 2 above, outright, but if he/she has died then to my children, named at question 4 above, equally: A
Everything to my children, named at question 4 above, equally and any other children of mine: A
Age at which your children will receive their entitlement: A If not in equal shares, then show the share each is to take:
A
18: IF NONE OF THE ABOVE CHOICES IS APPROPRIATE
1 Full Name: A
1 Share: A
1 Address: A
2 Full Name: A
2 Share: A
2 Address: A
Who is to benefit if the recipient dies before you?
1 Full Name: A
1 Share: A
1 Address: A
2 Full Name: A
2 Share: A
2 Address: A
19: OTHER ISSUES
A
PART E - Lasting POWER OF ATTORNEY
-----------------------------------
Have you already signed an Lasting Power of Attorney?
If no, would you like us to advise you about this?
Attorney(s):
1 Full Name:
1 Address:
2 Full Name:
2 Address:
Re: Form Failing to Email Properly
Posted: Tue Oct 20, 2009 11:10 am
by motherlover
Basically it spans multiple pages by loading the inputted fields into "hidden" inputs on the next pages. If you go to page 3 and then click back to the first it sets them all to A. I don't get why this is happening.
I'm sorry the code is so long. It basically does the same thing 5 times (once each page).
Any help would be really appriciated as I am at my wits end.
The form itself is at:
http://www.bunkers.co.uk/individuals/Pr ... willsq.php