ramses1 Posted August 13, 2012 Share Posted August 13, 2012 I am about to customize a wordpress theme. So far so good but right know I get stuck with the contact form script. (It?s a real nightmare being a php noob). Ok...this is the script: So my dumb question is - What have I to insert for action="" ? Where have I to insert my email address? <div class="iconsidebar"></div>Fill Out The Form Below</p> <!-- Form Code--> <div> <form method="post" action="########" > <input type="text" name="first name" class="sidebarform1" value='Enter your first name' onFocus=" if (this.value == 'Enter your first name') { this.value = ''; }" onBlur="if (this.value == '') { this.value='Enter your first name';} " /> <div style="clear:both;"></div> <input type="text" name="Phone" class="sidebarform1" value='Enter your phone number' onFocus=" if (this.value == 'Enter your phone number') { this.value = ''; }" onBlur="if (this.value == '') { this.value='Enter your phone number';} " /> <div style="clear:both;"></div> <input class="sidebarform1" type="text" name="email" value='Enter your email' onFocus=" if (this.value == 'Enter your email') { this.value = ''; }" onBlur="if (this.value == '') { this.value='Enter your email';} " /> <div style="clear:both;"> <div style="clear:both;"></div><textarea class="sidebarform2" name="Project details" cols="1" rows="7">Enter your message here...</textarea> <div style="clear:both; height: 0px;"></div> <div style="clear:both;"></div> <div style="clear:both; height: 0px;"></div> <div align="right"> <input type="image" value="Submit Your Info" style="color:#000;text-shadow: 0 1px 0 0 #fff;" class="sidebutton" border="0" value="Submit Your Info" /> </div> <div style="clear:both;"></div> </div> </form> </div> <!-- /ENDform --> <p align="center" style="font-size:10px; font-color:#7c4616;">We promise to NOT share your info with anyone.</p> Quote Link to comment https://forums.phpfreaks.com/topic/267042-contact-form-script/ Share on other sites More sharing options...
scootstah Posted August 13, 2012 Share Posted August 13, 2012 In the future, please place code inside tags. The form action is the page which the form will send its data to when someone submits it. Usually, this is the page which will process the form. It is possible that the theme already has functionality in place for that. You would most likely put your email on the page that processes the form, so that it can be emailed out. Again, the theme might already handle this. Quote Link to comment https://forums.phpfreaks.com/topic/267042-contact-form-script/#findComment-1369150 Share on other sites More sharing options...
btherl Posted August 13, 2012 Share Posted August 13, 2012 Your email address must never be in the form - otherwise someone can hijack your form to send spam to other people, just by sending their email address in place of yours. The email address will be stored somewhere else (on the page that processes the form, as scootstah says) I can't help with the action unfortunately as I'm not familiar with Wordpress. But I would assume you don't need to change it from whatever it was before you started customizing.. Quote Link to comment https://forums.phpfreaks.com/topic/267042-contact-form-script/#findComment-1369154 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.