I made a form in that is supposed to send people's messages to my e-mail. How come it isn't working? The website it is on is:

http://www.freewebs.com/soccerman_291/qicpage.html

Recommended Answers

All 7 Replies

The action tag is used to tell the browser which web server application will process the form data. The "mailto:" is used for hyperlinking to a client's email client. Combining them is... not going to work.

You need to use a server-side email script, in whatever language you use for server-side development.

Combining them is... not going to work.

Your basically wrong there Thomas. It does work.

I looked closer at the code for the given webpage and discovered the submit and reset butttons were outside the form element.

When I moved these I discovered that my machine tries to send using Outlook. If I didn't have outlook I suspect that it may not work... or the browser may try and send itself - I may try on linux later.

That's what I said: "mailto" is an instruction to the client's email program. Thus, it is relying on machine-specific configurations. The proper way to email form data is to use a server-side email script.

soccerdevil221: You will probably find that your web host does supply a sendmail script, in perl this is often called SendMail.pm. Sending email using this a matter of calling a function. But free webhosts often restrict this module so that it can only send email to the webmasters registered email address (to prevent it being used for spam).

The easiest way to get email to yourself from your website will be using the provided sendmail form. Alternatively you can use other fre web based email form providers, which can be used from any website: http://www.response-o-matic.com/overview.htm

Sorry none of this is a step-by-step guide, but hopefully it helps.

its easy in php, perl, python any serverside script
if your host includes a \cgi-bin folder off the root(the usual place for cgi scripts) Big Nosed Bird has a great, easy, internally documented, piece of cake to install and operate form handler freeware

the forms generated by the link posted immediately above still require a server handler to submit to, "form processor" in their documentation in php, if the host does not supply a sendmail handler server scripting (php asp),or access to cgi, for this account there are a number of hosted mail servers

it is possible to generate a link that accesses the user's email client to send directed prefilled mail on a single click, the names and details fields usually required for a serverside mail may have to be entered, but there is small chance of the email address being faked, something like

<a href="mailto:myaddress@myhost.com?subject=Mysite Web page Enqiry&body=Enquiry from Mysite, 'Contact Us' page.%0A%0aI am seeking further information on%0AItem __________%0A%0AItem __________%0A%0AItem __________%0A">email us</a>
Member Avatar for diafol

Does freewebs support/allow server-side scripts?

I see from their blurb that you can install all matter of apps/widgets. They have an email function:

Send Email Blasts To Your Members
Keep your visitors coming back for more by adding them to your own mailing list. Ongoing email updates help you share the latest and greatest from you and your website. We do the list management so you don't have to.

Whether or not this allows you to receive as well as send, I don't know.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.