开发者

Submit button to submit a form in dreamweaver cs4

开发者 https://www.devze.com 2022-12-31 18:43 出处:网络
I can not get the form to submit with the button. The best luck I have had is to send a generic email with no data attached.

I can not get the form to submit with the button. The best luck I have had is to send a generic email with no data attached.

This is the code:

                  <input name="mailto: info@thebellimagegroup.com" type="submit" onClick=ma开发者_运维百科ilto: info@thebellimagegroup.com  value="Submit Form" id="mailto: info@thebellimagegroup.com" >

the value is: /frms/contact.con

Can anyone help????


Submit buttons generally aren't used for storing information -- as a rule, they just submit the page, and any other information (such as the email recipient's address) will be put in other inputs in the form. For example:

<form action="/frms/contact.con" method="post">

 <label>Subject: <input type="text" name="subject" value="" /></label>

 <label for="message-editor">Message</label>
 <textarea name="message" rows="6" cols="60" id="message-editor"></textarea>

 <input type="submit" value="Submit" />

 <input type="hidden" name="recipient" value="info@thebellimagegroup.com" />
</form>

In this example, the "action" attribute of the FORM element specifies the script on the server which will process the information once someone clicks Submit. The hidden input which I have named "recipient" specifies the email address, and the value of that will be sent in along with the rest of the form when it's submitted. All the submit button itself does is cause the browser to send the finished form off to the server for processing.

Note that the example I've given here probably won't work with your particular script, because the names I've selected for the example inputs ("subject", "message", and "recipient") probably don't match the ones your script expects.

Do you have documentation on how the /frms/contact.con script works? If so, check it -- it should tell you what to name your form elements. Failing that, and assuming that you know whatever programming language it was written in, you could read the code in contact.con to see what names it's expecting.

If all else fails, try a different server-side script, there are about eight zillion available.

0

精彩评论

暂无评论...
验证码 换一张
取 消