Allow viewers to send you Feedback regarding your Site

In this tutorial, we will cover how to allow viewers send you feedback through a simple form and some coldFusion. It will consist of one page. We will not be using screenshots, just some code. We will also try to keep it moving fast, although still not prior ColdFusion knowledge is required. On your mark. Set. Go!


Go Back

<html>
<head>
</head>
<body>

<cfif NOT IsDefined("form.submit")>
<form name="frmContact" Action="feedback.cfm" Method="Post">
Name <input type="text" name="txtFromName"><br>
Email <input type="text" name="txtFromEmail"><br>
Feedback <br><textarea name="txtFeedback" cols="40" class="textfields" rows="4"></textarea><br>
<input type="submit" name="submit" value="Send Feedback">
</form>
</cfif>

<cfif IsDefined("form.submit")>
<cfif #form.txtFromEmail# is "" OR #form.txtFeedback# is "">
Please go back and fill the entire form.
<cfelse>
<cfmail to = "omar@udnewbie.com"
from = "#form.txtFromEmail#"
Subject = "Feedback from Site"
type="HTML" >
#form.txtFeedback#
</cfmail>
<cfoutput>
Thank you <b> #form.txtFromName#</b>!<br>
You sent the following feedback:<br>
<b>#form.txtFeedback#</b>
</cfoutput>
</cfif>
</cfif>

</body>
</html>


Go Back

Omar Elbaga

Starting out as a fine artist, Omar Elbaga gradually moved to computer graphic arts. He was particularly amazed by the power of the World Wide Web, so he embarked upon building small-scale sites for fun utilizing HTML and his Art background. Falling in love with designing web pages and its potential, he began a career in web design. Omar has since been in the web development field for several years. With his head in computer books nearly 24 hours a day, Omar moved on to enhance his skills from web design to web programming.

Most of his work involves building database-driven web sites for small companies. Omar is currently running a popular Dreamweaver MX resource site named dmxfire.com

See All Postings From Omar Elbaga >>

Comments

Be the first to write a comment

You must me logged in to write a comment.