Importing HTML from Dreamweaver

john2aus 23 Jul, 2009
Hi,

I have made a form in Dreamweaver and I want to insert it into ChronoForms in Joomla. I created a new form and then in the "Form html" I pasted the code (as seen below), the basics of it looks like this:

Start
<form id="form1" name="form1" method="post" action="">
  <h1><strong>Registration Form</strong></h1>
  <h2>Weekend Accomadation & Meals (not inc Fri meal)</h2>
  <table width="471" border="1" cellpadding="0">
    <tr>
      <td width="189"> </td>
      <td width="143" align="center">Accomadation<br />
      (no. persons)<br /></td>
      <td width="123" align="center">Meals<br />
        (no. persons)</td>
    </tr>
    
    <tr>
      <td align="left" valign="middle"><p>Adults (15+)<br />
        Seniors/Pentioners<br />
        Child (15-14)<br />
        Toddler (under 4)
        <br />
      </p></td>
      <td align="center" valign="middle"><p>
        <label>$30
          <input name="acc_adult" type="text" id="acc_adult" size="5" />
  


then a bit more code...

Ending...

        <input name="post_code" type="text" id="post_code" size="30" />
      <input name="email" type="text" id="email" size="30" maxlength="15" /></td>
    </tr>
  </table>
  <p>
    <label>
      <input type="submit" name="sub" id="sub" value="Submit Form" />
    </label>
  </p>
</form>


Then, I created a table to store the data. However, when I click submit on my form it takes me back to my home page but nothing comes up in my table!

What am I missing - can you guide me to solving the problem.

Thanks.
nml375 23 Jul, 2009
G'day,
Remove the <form></form> tag pair. These are added by CF on-the-fly.

/Fredrik
GreyHead 23 Jul, 2009
Hi john2aus,

You *must* leave out the <form . . .> and </form> tags - ChronoForms creates it's own and it there are two sets the form breaks. There may be some other problems but this is the first I saw.

Bob
john2aus 24 Jul, 2009
Thanks, that did it. That is a very useful feature of this extension!

Here is my sample code:

 <p>
    <label><strong>Sample Form</strong><br />
    </label>
  </p>
  <table width="305" border="1" cellspacing="6" cellpadding="0">
    <tr>
      <td width="289"><label>Name...
          <input type="text" name="name1" id="name1" />
      </label></td>
    </tr>
    <tr>
      <td><label>Will you tick this...
        <input type="checkbox" name="fam_pkg" id="fam_pkg" />
      </label></td>
    </tr>
  </table>
  <p>
    <label>
      <input type="submit" name="sub" id="sub" value="Submit From" />
    </label>
  </p>


Now I want it to email to me in a table form as follows:

<p>Hare are the results:</p>
<table width="550" border="1" cellspacing="6" cellpadding="0">
  <tr>
    <td width="247">Name</td>
    <td width="279">{name here}</td>
  </tr>
  <tr>
    <td>Will you tick this</td>
    <td>{on or off here}</td>
  </tr>
</table>


How do I do this in ChronoForms (set up the emails)?

Thanks a lot.
GreyHead 24 Jul, 2009
Hi john2aus,

Please check out the Email tutorial from the Tutorials link above. Once you have created an Email Setup there will be a corresponding Email template, click the HTML link in the rich text editor there and paste in your table code. (Note that if you paste html directly into the rich text window it will be mangled as < become < etc.)

Bob
john2aus 24 Jul, 2009
Hi,

The "auto-generator" for emails was excellent! I am very happy with my purchase of this form program!

Can you point me in the right direction for some html form tutorials in Dreamweaver that tell how to add validation to fields (i.e. phone field is numbers only...etc) ?
GreyHead 24 Jul, 2009
Hi john2aus,

I've no idea about Dreamwever but you can add validation directly in ChronoForms - either use the Validation tab; or you can add class names in your Form HTML like 'required' or 'validate-alpha', 'validate-digits' The list is on the Validation tab I think.

Bob
john2aus 24 Jul, 2009
Thanks a lot for your help.
This topic is locked and no more replies can be posted.