Unable to pass dropdown list data from web form to email

I have added 2 drop down list fields to the contact form of the site template I am using.
I do not understand JavaScript enough to know how to edit the forms.js file in order to pass the values from those two drop down fields to the email.

In the forms.js file you can see that it is running a function called: getValFromLabel and all the other fields are identified with labels, but when I tried to add a label class to the select fields, the form wouldn't submit at all.  

Can someone please help me edit the code so that I can pass the values from those two drop down lists?
Thank you!

The Contact Form's HTML
<h2>Contact Form</h2>
								<form id="form1">
									<div class="success"> Contact form submitted!<br>
										<strong>We will be in touch soon.</strong> 
									</div>
									<fieldset>
										<label class="name">
											<input type="text" value="NAME:">
											<span class="error">*This is not a valid name.</span> <span class="empty">*This field is required.</span> </label>
										<br>
                                        <label class="company_name">
											<input type="text" value="COMPANY/ORGANIZATION NAME:">
											<span class="empty">*This field is required.</span> </label>
										<br>
                                        
                                        <label class="website">
											<input type="text" value="WEBSITE:">
										</label>
										<br>
										<label class="email">
											<input type="email" value="E-MAIL:">
											<span class="error">*This is not a valid email address.</span> <span class="empty">*This field is required.</span> </label>
										<br>
										<label class="phone">
											<input type="tel" value="PHONE:">
											<span class="error">*This is not a valid phone number.</span> <span class="empty">*This field is required.</span> </label>
										<br>
                                        	
                                        	<select class="time">
                                            	<option value="">BEST TIME TO CONTACT YOU:</option>
                                                <option value="am">Contact me in the a.m.</option>
                                                <option value="pm">Contact me in the p.m.</option>
                                            </select>
                                            
                                       <br>
                                      
                                        	<select class="question">
                                                <option value="">SELECT ONE:</option>
                                            	<option value="new_business">Help with starting a new business</option>
                                                <option value="business_plan">Help with writing a business plan</option>
                                                <option value="audit">Company audit/analysis</option>
                                                <option value="project_mgmt">Project Management</option>
                                                <option value="other">Other</option>
                                            </select>
                                           
                                        <br>
                                            
                                        
										<label class="message">
											<textarea>ASK YOUR QUESTION:</textarea>
											<span class="error">*The message is too short.</span> <span class="empty">*This field is required.</span> </label>
										<br>
										<div class="btns"><a href="#" class="btn" data-type="submit"><span></span>Send</a><a href="#" class="btn" data-type="reset"><span></span>Clear</a></div>
									</fieldset>
								</form>

Open in new window

Attaching the mailHandler.php and forms.js files for refernce.
C--Users-0BE000774-Documents-Website.php
C--Users-0BE000774-Documents-Website-.js
deeayrianAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

lenamtlCommented:
Hi,

Which script are you using?
It's look like template monster form, you should contact them for support.
I have found a tutorial on their website that may help:
http://www.templatemonster.com/help/adding-fields-to-the-html-contact-form.html


I recommend you to use a more secure form script like this one:
http://codecanyon.net/item/just-forms-full/11301529

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
deeayrianAuthor Commented:
I have been in contact with Template Monster and unfortunately because I am trying to add a field type that didn't exist on the template when I purchased it, they won't help me without charging me extra.  

Thank you for the link to the tutorial on their website, but that doesn't help me either.  I can create a basic php form without an issue, but in this template, there is a Js file managing a lot of the functionality and that's where I am hung up.  I don't know how to make the select fields work with that Js because my Js knowledge is very weak.

I am accepting this as a solution because I am going to go ahead and use the better form script you suggested and completely replace the one in this template.  At least with the one you recommended, I can undersand the code and make adjustments as needed, plus it seems more secure.

Thank you!
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Web Development

From novice to tech pro — start learning today.