NIHVIVO-2796: Re-factored contact form templates

This commit is contained in:
manolobevia 2011-06-29 20:48:32 +00:00
parent 74a48d09a3
commit f6a0fdebfe
4 changed files with 38 additions and 35 deletions

View file

@ -5,10 +5,12 @@
<p>${datetime}</p>
<#if spamReason??>
<div style="color:red;">
<section id="error-alert" role="alert">
<img src="${urls.images}/iconAlert.png" width="24" height="24" alert="Error alert icon" />
<p>REJECTED - SPAM</p>
<p>${spamReason}</p>
</div>
</section>
</#if>
${msgText}

View file

@ -8,15 +8,21 @@
<head>
<title>${subject}</title>
</head>
<body>
<h3>${subject}</h3>
<p><strong>From:</strong> ${name}</p>
<p><strong>Email address:</strong> ${emailAddress}</p>
<p>
<strong>From:</strong> ${name}<br />
<strong>Email address:</strong> ${emailAddress}<br />
<strong>IP address:</strong> ${ip}<br />
<#if referrer??>
<em>Likely viewing page: ${referrer}</em><br />
<em>Likely viewing page: ${referrer}</em>
</#if>
<strong>Comments:</strong> ${comments}
</p>
<p><strong>Comments:</strong> ${comments}</p>
</body>
</html>

View file

@ -4,13 +4,10 @@
<h2>${title}</h2>
<#if errorMessage?has_content>
<div id="error-alert"><img src="${urls.images}/iconAlert.png"/>
<#if errorMessage?has_content>
<section id="error-alert"><img src="${urls.images}/iconAlert.png" role="error alert"/>
<p>${errorMessage}</p>
</div>
</#if>
</section>
</#if>
<p class="contactUsReturnHome">Return to the <a href="${urls.home}">home page</a>.</p>

View file

@ -2,38 +2,36 @@
<#-- Contact form -->
<div class="staticPageBackground feedbackForm">
<section class="staticPageBackground feedbackForm" role="region">
<h2>${title}</h2>
<p>Thank you for your interest in ${siteName}.
Please submit this form with questions, comments, or feedback about the content of this site.
</p>
<form name="contact_form" id="contact_form" action="${formAction}" method="post" onsubmit="return ValidateForm('contact_form');">
<input type="hidden" name="RequiredFields" value="webusername,webuseremail,s34gfd88p9x1"/>
<input type="hidden" name="RequiredFieldsNames" value="Name,Email address,Comments"/>
<input type="hidden" name="EmailFields" value="webuseremail"/>
<input type="hidden" name="EmailFieldsNames" value="emailaddress"/>
<input type="hidden" name="DeliveryType" value="contact"/>
<form name="contact_form" id="contact_form" class="customForm" action="${formAction}" method="post" onsubmit="return ValidateForm('contact_form');" role="contact form">
<input type="hidden" name="RequiredFields" value="webusername,webuseremail,s34gfd88p9x1" />
<input type="hidden" name="RequiredFieldsNames" value="Name,Email address,Comments" />
<input type="hidden" name="EmailFields" value="webuseremail" />
<input type="hidden" name="EmailFieldsNames" value="emailaddress" />
<input type="hidden" name="DeliveryType" value="contact" />
<label for="webusername">Full name</label>
<p><input style="width:33%;" type="text" name="webusername" maxlength="255"/></p>
<label for="webuseremail">Email address</label>
<p><input style="width:25%;" type="text" name="webuseremail" maxlength="255"/></p>
<label for="webusername">Full name <span class="requiredHint"> *</span></label>
<input type="text" name="webusername" />
<label for="webuseremail">Email address <span class="requiredHint"> *</span></label>
<input type="text" name="webuseremail" />
<label>Comments, questions, or suggestions</label>
<label>Comments, questions, or suggestions <span class="requiredHint"> *</span></label>
<textarea name="s34gfd88p9x1" rows="10" cols="90"></textarea>
<div class="buttons">
<input id="submit" type="submit" value="Send Mail"/>
<input id="submit" type="submit" value="Send Mail" />
</div
<p style="font-weight: bold; margin-top: 1em">Thank you!</p>
<p class="requiredHint">* required fields</p>
</form>
</section>
</div>
${stylesheets.add('<link rel="stylesheet" href="${urls.base}/edit/forms/css/customForm.css" />')}
${scripts.add('<script type="text/javascript" src="${urls.base}/js/commentForm.js"></script>')}