Thank you for being a valued part of the CNET community. As of December 1, 2020, the forums are in read-only format. In early 2021, CNET Forums will no longer be available. We are grateful for the participation and advice you have provided to one another over the years.

Thanks,

CNET Support

General discussion

Need a contact form

Jul 22, 2007 5:09PM PDT

Hello,

I need a contact form on my website, that will send to my email address what the visitor enter in the form fields. The problem is that I can't run any php scripts.. is there a way to use some html form?

Discussion is locked

- Collapse -
Sure
Jul 22, 2007 11:16PM PDT

Just about any site that has code examples for websites should have such a thing. It was pretty common once upon a time, but since PHP (and similar systems) allows the email address to be hidden, and thus thwart automated bots that troll the Internet looking for email addresses to send spam to... They fell into disuse.

- Collapse -
Use a MailTo link
Jul 23, 2007 6:15AM PDT

Just place a "MailTo" link on your page, such as"
mailto:xx@yy.zz&cc=aa@bb.cc&bcc=dd@ee.ff&subject=subwhat%20%26%20more&body=You%20can%20enter%20whatever%20here

Using a MailTo link will open and address the user's defined mail program.

Note: You can place To, Cc, Bcc, Subject and even Body fields in that one line, or not. The "&" is a separator of those fields.
There are no spaces anywhere there, but if you need spaces in the fields, you use a "%20" instead.
If you need the "&" character, then use "%26"

Last note. You can test this line by just pasting the above into an Address ar of a browser and see what happens.

- Collapse -
re
Jul 23, 2007 11:01PM PDT

Thank you for your suggestions! I found a site that offers remotely hosted contact forms, www.emailmeform.com . Basically, I paste the html code in my website, and it calls the php script on their server who sends the email.