CFMAIL using flash form

Discussion in 'Programming' started by knoxdigit, Dec 22, 2006.

  1. #1
    Hi there,

    I have just started using coldfusion and flash forms for that matter. Just wondering if someone can help me get my form working. I'm not sure if it will work using the current format or whether I need to use remoting, but here it is anyway...

    <div id="Layer4">
    <cfif isDefined("form.tutor_request")>
    <cfmail
    from= #form.tutor_request#
    to="emailaddress.com"
    subject="New Tutoring Request"
    server="localhost">
    First Name : #form.FirstName#
    Last Name : #form.LastName#
    Address : #form.Address#
    City/Town : #form.CityTown#
    State : #form.State#
    Postcode : #form.Postcode#
    Phone : #form.Phone#
    Email : #form.Email#
    Mobile : #form.Mobile#
    Prospective Student Name : #form.StudentName#
    Age : #form.Age#
    Tutoring Subject/Area : #form.TutoringSubject#
    How did you hear about us : #form.HowFind#
    If other : #form.Other#
    If referral : #form.Referral#
    </cfmail>
    <cflocation url="http://www.achievetuition/request_confirm.html">
    </cfif>
    <cfform name="form.tutor_request" height="620" width="600" format="flash" skin="haloblue">
    <cfformgroup type="panel" label=" Tutoring Request Form" style="color:##0066FF; fontSize:12; text-align: left;">

    <cfformgroup type="Horizontal" label="Name">
    <cfinput type="Text" name="FirstName" width="100" required>
    <cfinput type="Text" name="LastName" width="100" required>
    </cfformgroup>
    <cfinput type="Text" name="Address" label="Address:" width="210" required>
    <cfinput type="Text" name="CityTown" label="City/Town:" width="210" required>
    <cfformgroup type="HBox">
    <cfformgroup type="VBox">
    <cfselect name="State" label=" State:" width="100">
    <option>Select</option>
    <option>QLD</option>
    <option>NSW</option>
    <option>VIC</option>
    <option>TAS</option>
    <option>SA</option>
    <option>WA</option>
    <option>NT</option>
    <option>ACT</option>
    </cfselect>
    </cfformgroup>
    </cfformgroup>
    <cfinput type="Text" name="Postcode" Label="Postcode:" width="100" required>
    <cfinput type="text" name="Phone" label="Phone:" width="210" validate="noblanks,telephone" required="no">
    <cfinput type="text" name="Mobile" label="Mobile:" width="210" validate="telephone" required="no">
    <cfinput type="text" name="Email" Label="Email:" width="210" required>
    <cfinput type="Text" name="StudentName" Label="Prospective Student Name:" width="210" required="no">
    <cfinput type="Text" name="Age" Label="Age:" width="100" required="no">
    <cftextarea name="TutoringSubjects" label="Tutoring Subject(s)/Areas:" rows="6"></cftextarea>
    <cfformgroup type="HBox">
    <cfformgroup type="VBox">
    <cfselect name="HowHear" label=" How did you find us:" width="210">
    <option>Select</option>
    <option>Google</option>
    <option>Yahoo</option>
    <option>MSN</option>
    <option>Other Search Engine</option>
    <option>Referral</option>
    <option>Website</option>
    <option>Newspaper</option>
    <option>Flyer</option>
    <option>Email</option>
    <option>Other</option>
    </cfselect>
    </cfformgroup>
    </cfformgroup>
    <cfinput type="Text" name="Other" Label="If other please specify:" width="210" required="no">
    <cfinput type="Text" name="Referral" Label="If referral by whom:" width="210" required="no">
    <cfformgroup type="horizontal" style="horizontalAlign:left">
    <cfinput type="Submit" name="submitBtn" value="Submit">
    </cfformgroup>
    </cfformgroup>

    </cfform>

    </div>

    With <cfform name="form.tutor_request" included I don't receive an error but the form is not displayed. With "name" ommitted the form is displayed but won't send to my email address.

    Please let me know what I am doing wrong, much appreciated.

    Jon Viney
    http://www.achievetuition.com.au
     
    knoxdigit, Dec 22, 2006 IP
  2. datropics

    datropics Peon

    Messages:
    309
    Likes Received:
    3
    Best Answers:
    1
    Trophy Points:
    0
    #2
    Change
    <cfform name="form.tutor_request" height="620" width="600" format="flash" skin="haloblue">

    To
    <cfform name="tutor_request" height="620" width="600" format="flash" skin="haloblue">
     
    datropics, Dec 25, 2006 IP