Jump to content

Send Form Via Email


hanlonj

Recommended Posts

Hi Guys,

 

I haven't used php for a while and so I need a pointer in the right direction.

 

This is the problem:

 

(This is for a friends' company so I have no say over adding a database etc.)

 

I have a form and it includes textfields, groups of check boxes and goups of radio buttons.

I want the user to fill out the form ( I can handle the form validation stuff myself).

I then want the user to hit "Send" and the form comes to me via email (i.e. no database usage).

 

Please see:

 

http://grungefreak.com/register.php

 

I am not too good with checkboxes and radio buttons. Can someone give me some high level advice on how I would gather all the info. and send via email without using a database.

 

I realise this is a very broad question so hit me back with some questions if you like.

 

Hanlonj

Link to comment
https://forums.phpfreaks.com/topic/55591-send-form-via-email/
Share on other sites

Radio buttons have a name and a value. If the name is 'sex' and button one has value 'male' and second values is 'female', than you can gather the information (if you form had method='post') with this: $_POST['sex'], this value can be male, female or something like unselected/noone/null

 

Checkboxes, im not sure, perhaps w3schools.com has a reference for that?

 

FD

Link to comment
https://forums.phpfreaks.com/topic/55591-send-form-via-email/#findComment-274784
Share on other sites

I have a group of textboxes that ask the user which hours they prefer to work e.g. checkBox1 = evenings, checkBox 2 = mornings etc. I know now that I can name the check boxes and give them each a value which will work fine for gathering information. But I saw somewhere that you should really use arrays in matters like this. Can anyone help with the array thing?

 

hj

Link to comment
https://forums.phpfreaks.com/topic/55591-send-form-via-email/#findComment-275429
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.