Jump to content

wizerm

New Members
  • Posts

    9
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

wizerm's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Here is what I have as far as code.... <form action="contacts.php" method="post" name="mailer"> <INPUT type="hidden" name="send" value="no">               <div>                 <label for="sender_name">Your Name:</label>               </div>   <div class="contacts-form-input">               <input type="text" name="sender_name" id="sender_name" onfocus="if(this.value=='Please enter a name'){this.value=''; this.style.color='#94969C';}"  value="" />               </div>   <div>                 <label for="sender_email">Your E-mail:</label>               </div>               <div class="contacts-form-input">   <input type="text" name="sender_email" id="sender_email" onfocus="if(this.value=='Invalid email'){this.value=''; this.style.color='#94969C';}"  value="" />               </div>   <div>                 <label for="mail_body">Message Body:</label>               </div>   <div class="contacts-form-textarea">   <textarea name="mail_body" rows="9" cols="16" id="mail_body"></textarea>   </div>               <div style="padding-top: 15px;"><a href="javascript:document.mailer.send.value='yes';document.mailer.submit();"><img src="images/send_btn.gif" alt="Send" name="SendBtn" border="0" /></a></div>             </form>
  2. Yes it is all I am after. I don't know alot about javascript so I didn't know if I was needing some extra javascript to make it work.
  3. I know this is a PHP forum but wasn't sure where else to turn for help. And since this forum helped out alot last time I figured someone may know what I am looking for hopefully. I am needing to know what I am missing to make this code for my submit button for my php contact form work. I just need to know if I am needing smoe javascript to make the following code work. Thanks for any help. <a href="javascript:document.mailer.send.value='yes';document.mailer.submit();"><img src="images/send_btn.gif" alt="Send" name="SendBtn" border="0" /></a>
  4. Thanks AdRock, I actually figured it out by going about it a different way. Changed the code around a bit. I just have to get it to give the messages about the emailing being recieved or error, to show on a correctly formatted page with the right css and images. Thanks though for the help. Eberyone on this site seems to be very helpful and hopefully I will learn enough PHP that I can be of some help waaaayyyyy down the road...lol.
  5. Here is my new contact page "www.robsaudio.com/contact/index-3.html"which load great but the form doesn't work. I made a file called contact2.php as well. As you can see the post go to contact2.php, but gives an parsing error on line 25. What did I do wrong? Thanks again.
  6. Thank you so much, I really apreciate it. I have had people try to help me in the past with PHP, but they never really explained it well. You explained it and made the lightbulb in my head go off, although dim at times, it still went off and I understand the PHP behind what you said. Thanks again.
  7. <?php // Change the 4 variables below $yourName = 'Kyle Stearnes'; $yourEmail = 'test@robsaudio.com'; $yourSubject = 'testJax'; $referringPage = 'http://www.robsaudio.com/contact/index.html'; // No need to edit below unless you really want to. It's using a simple php mail() function. Use your own if you want function cleanPosUrl ($str) { return stripslashes($str); } if ( isset($_POST['sendContactEmail']) ) { $to = $yourEmail; $subject = $yourSubject.': '.$_POST['posRegard']; $message = cleanPosUrl($_POST['posText']); $headers = "From: ".cleanPosUrl($_POST['posName'])." <".$_POST['posEmail'].">\r\n"; $headers .= 'To: '.$yourName.' <'.$yourEmail.'>'."\r\n"; $mailit = mail($to,$subject,$message,$headers); if ( @$mailit ) { header('Location: '.$referringPage.'?success=true'); } else { header('Location: '.$referringPage.'?error=true'); } } ?> I am sure there are things wrong with it know doubt. Some of the variables are wrong I know, but I messed it up so bad I don't know what to change it to...lol. I wish I knew more.
  8. I don't have anything other than the html page that the form sits on. I messed up the contact.php so much trying to get it to work it was unuseable. Basically I need whatever will make this form work....I feel like an idiot right now....lol.
  9. If someone could please help me with this I would greatly appreciate it. I have been trying to figure this out for lord knows how long and haven't yet. I am new to .php for the most part and can't get this form working. Here is a the code of the page it resides on "www.robsaudio.com/contact/index.html" <div id="page">         <form method="post" action="http://www.robsaudio.com/workspace/mail/contact.php" id="contact">           <p id="result"></p>           <p>             <label for="name" id="lab-name">Name:</label>             <input name="name" type="text" class="required" id="name" tabindex="1" size="30" value="" />           </p>           <p>             <label for="email" id="lab-email">Email:</label>             <input name="email" type="text" class="validate-email required" id="email" tabindex="2" size="30" value="" />           </p>           <p>             <label for="cc" id="cc-author">CC:</label>             <label><input type="checkbox" name="cc" id="cc" /> yes, send a copy to me.</label>           </p>           <p>             <label for="subject" id="lab-subj">Subject:</label>             <input name="subject" type="text" id="subject" tabindex="3" size="30" />           </p>           <p>             <label for="message" id="lab-msg">Message:</label>             <br />             <textarea tabindex="4" id="message" name="message" rows="10" cols="30" class="required"></textarea>           </p>           <p id="contol">             <input value="Send Message" name="send" type="submit" class="btn" />           </p>         </form>       </div> I just need the form to work properly, and with a slim to non knowledge of php I am lost and need to finish this page. Thanks for any help anyone can give.
×
×
  • 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.