Contact form e-mail integration Javascript HTML -


Hi, I would like to ask some help about my contact form because I do not know where I will include code in e- Mail is about to receive information in the contact form. Thanks in advance

  & lt; Center & gt; & Lt; Form name = 'Contact form' & gt; & Lt; Div & gt; Name: & lt; / Div & gt; & Lt; Input class = 'contact form-name' id = 'ContactForm1_contact-form-name' name = 'name' size = '30 'type =' text 'value =' '/ / gt; & Lt; Div & gt; Email: & lt; / Div & gt; & Lt; Input class = 'contact-form-e-mail' id = 'ContactForm1_contact-form-email' name = 'email' ize = '30 'type =' text 'value =' '/ / gt;   


The best way is to create a PHP script which is run on submitting the form!

  & lt; Form name = 'contact-form' id = "form" method = "POST" verb = "enter PHP URL here" & gt; & Lt; Div & gt; Name: & lt; / Div & gt; & Lt; Input class = 'contact form-name' id = 'ContactForm1_contact-form-name' name = 'name' size = '30 'type =' text 'value =' '/ / gt; & Lt; Div & gt; Email: & lt; / Div & gt; & Lt; Input class = 'contact form-email' id = 'ContactForm1_contact-form-email' name = 'email' size = '30 'type =' text 'value =' '/ / gt; & Lt; Div onclick = "document.getElementById ('form'). Submit ();" & Gt; SUBMIT & lt; / Div & gt;   

Then you create a php script to run your email!

Example of php script:

  & lt? Php $ to = "test@someone.com"; $ Theme = "this is the subject line"; $ Message = '& lt; Html & gt; & Lt; Body & gt; NAME -------- '. Strip_tag ($ _ POST ["name"]) '& lt; Br> Email address-- ' . Strip_tag ($ _ POST ["Email"]) '& lt; Br> & Lt; / Body & gt; & Lt; / Html & gt; '; $ Header = "MIME-version: 1.0" "\ r \ n"; $ Headers = "Content-type: text / html; charset = UTF-8" "\ r \ n"; $ Headers = 'To: anyone, com' "\ r \ n"; Mail ($ to $, $ theme, $ message, $ header); Header ("Location: http://successurlgoeshere.com"); ? & Gt;   

I hope it helps!

Comments

Popular posts from this blog

Java - Error: no suitable method found for add(int, java.lang.String) -

java - JPA TypedQuery: Parameter value element did not match expected type -

c++ - static template member variable has internal linkage but is not defined -