Jump to content

Simple question I think....


wizerm

Recommended Posts

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>
Link to comment
Share on other sites

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>
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.