Page 1 of 2 12 LastLast
Results 1 to 10 of 17

Thread: How to create email form? plz help desperately

  1. #1
    Join Date
    Feb 2007
    Posts
    16
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Unhappy How to create email form? plz help desperately

    hello guys,

    am new to scripting but know the designing part very well. I am stuck with an enquiry form which has to be emailed by users online. I am unable to receive any mails in my mailbox. Am I doing something wrong. PLzzz help me in this.

    i am going to send the attachements

    am using frames (though I am unhappy with it)

    plzzz help me with this. I am truely stuck and have high hope with the people in this forum.

    thnx
    Last edited by newj; 02-15-2007 at 11:47 AM. Reason: dont want url

  2. #2
    Join Date
    Nov 2006
    Location
    IA
    Posts
    77
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default It is done

    It is done like this:

    HTML Code:
    <a href="mailto:[COLOR="Red"]your email here in quotes before mailto: and after email[/COLOR]">[COLOR="Red"]Hyperlink text you want visible[/COLOR]</a>

    I'll send an e-mail. plz say if you received it. I'll look at your code too to see what you have

  3. #3
    Join Date
    Nov 2006
    Location
    IA
    Posts
    77
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Post Wait ignore previous post

    The way you have it set up, it is best for you to use javascript. I'll write the code, test it, email it to you and tell you how to set it up.

    Tell me where you put your code together on (whether it waas notepad or html editor(plz specify))
    Last edited by Masterskinnie; 02-09-2007 at 04:56 PM. Reason: something to add

  4. #4
    Join Date
    Sep 2006
    Location
    St. George, UT
    Posts
    2,769
    Thanks
    3
    Thanked 157 Times in 155 Posts

    Default

    I would suggest (if you want to use a form that is) using a server side language along with your form. If you look around the PHP forums, there are tons floating around. Make sure you can run server side scripts with your host, or else this will not work. Otherwise, use the above posted code (the mailto link).

    Hope this helps.
    "Computer games don't affect kids; I mean if Pac-Man affected us as kids, we'd all be running around in darkened rooms, munching magic pills and listening to repetitive electronic music." - Kristian Wilson, Nintendo, Inc, 1989
    TheUnlimitedHost | The Testing Site | Southern Utah Web Hosting and Design

  5. #5
    Join Date
    Feb 2007
    Posts
    16
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Thanks Masterskinnie! I use dreamweaver entirely while doing a site. Is something wrong with my form? can i use PHP in this? how? can u help me in this.
    BTW, I havent got ur email.

  6. #6
    Join Date
    Oct 2006
    Posts
    110
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Hey, I've been having the same problem, and I still haven't gotten an answer on it. Tell me when you guys have a solution.

  7. #7
    Join Date
    Jul 2006
    Location
    Antwerp, Belgium (Europe)
    Posts
    927
    Thanks
    121
    Thanked 2 Times in 2 Posts

    Default

    Nice site, newj, but I wouldn't let the scrollbar float on the right.
    Can you not place it within the content of center.htm ?
    - place "scrollable=yes" in here: <frame src="center.htm" name="centerframe" frameborder="no" marginwidth="776">
    - place in every page that can appear there the following between the head and the body (adapt colors):
    Code:
    <style type="text/css">
    <!--
    
    body
    	{
    	scrollbar-face-color:#eeeeee;
    	scrollbar-arrow-color:white;
    	scrollbar-track-color:white;
    	scrollbar-shadow-color:white;
    	scrollbar-highlight-color:white;
    	scrollbar-3dlight-color:white;
    	scrollbar-darkshadow-Color:white;	
    	background-attachment: fixed;
    }
    
    -->
    </style>
    It will look much better !

  8. #8
    Join Date
    Jul 2006
    Location
    Antwerp, Belgium (Europe)
    Posts
    927
    Thanks
    121
    Thanked 2 Times in 2 Posts

    Default

    Shotgun Ninja,
    Follow thetestingsite's advice:
    I would suggest (if you want to use a form that is) using a server side language along with your form. If you look around the PHP forums, there are tons floating around. Make sure you can run server side scripts with your host, or else this will not work. Otherwise, use the above posted code (the mailto link).

  9. #9
    Join Date
    Mar 2006
    Location
    Illinois, USA
    Posts
    12,164
    Thanks
    265
    Thanked 690 Times in 678 Posts

    Default

    Indeed. Server side language is best. It's a bit of work to learn, but very worth it.

    And the above code for scrollbars is IE-only, so don't rely too heavily on that,
    Daniel - Freelance Web Design | <?php?> | <html>| español | Deutsch | italiano | português | català | un peu de français | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum

  10. #10
    Join Date
    Feb 2007
    Posts
    16
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default how to use the server side

    well how to use the server side? have u seen the zip files that i sent? now how to make that enquiry.htm work??? i used simple javasript
    <FORM name=mobicon onsubmit="return validateForm();" action="mailto:sales@mobiconcommodities.com?sub=from website" target="centerframe" method=post>

    but it alerts the user that his/her email wud be passed on and all and starts with the wizard.

    First one which i used was:

    <html>
    <head>
    <title>Untitled Document</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

    <link href="style.css" rel="stylesheet" type="text/css">
    <style type="text/css">
    <!--
    a:link {
    color: #93A81C;
    }
    -->
    </style>
    </head>

    <body>
    <table width="776" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
    <tr>
    <td width="227" align="left" valign="top" bgcolor="#EAEAEA"><table width="227" border="0" cellspacing="0" cellpadding="0">
    <tr>
    <td><img src="images/trans_bar.gif" width="1" height="30"></td>
    </tr>
    </table></td>
    <td bgcolor="#FFFFFF">&nbsp;</td>
    <td bgcolor="#FFFFFF">&nbsp;</td>
    </tr>
    <tr>
    <td width="227" rowspan="2" align="left" valign="top" bgcolor="#EAEAEA"><table width="201" border="0" cellspacing="0" cellpadding="0">
    <tr>
    <td width="9" rowspan="4"><img src="images/trans_bar.gif" width="9" height="1"></td>
    <td width="9" height="47" align="right" valign="top"><img src="images/greyborder_toplft.gif" width="9" height="47"></td>
    <td width="217" height="47" align="left" valign="top" background="images/bkggreyprod.gif"><img src="images/our-prod_caption.gif" width="193" height="47"></td>
    <td width="9" height="47" align="left" valign="top"><img src="images/greyborder_toprht.gif" width="9" height="47"></td>
    </tr>
    <tr>
    <td width="9" rowspan="2" background="images/greyborder_lft.gif">&nbsp;</td>
    <td width="217" height="178" align="center" valign="top" bgcolor="#FFFFFF"><object classid="clsid27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="185" height="147">
    <param name="movie" value="images/left_pics.swf">
    <param name="quality" value="high">
    <param name="menu" value="false">
    <param name="wmode" value="transparent">
    <embed src="images/left_pics.swf" width="185" height="147" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" menu="false" wmode="transparent"></embed>
    </object></td>
    <td width="9" rowspan="2" background="images/greyborder_rht.gif">&nbsp;</td>
    </tr>
    <tr>
    <td bgcolor="#FFFFFF" width="217"><p><img src="images/anyenquiry_txt.gif" width="193" height="37"></p>
    <div align="left" style="margin-left:15px; margin-rightx">
    <p class="style1"><a href="mailto:sales@mobiconcommodities.com" target="_blank" class="link_text">sales@mobiconcommodities.com</a></p>
    <div align="left" style="margin-down:15px; margin-rightx"> </div>
    </div></td>
    </tr>
    <tr>
    <td width="9" height="9" align="left" valign="top"><img src="images/greyborder_btomlft.gif" width="9" height="9"></td>
    <td height="9" background="images/greyborder_btom.gif" width="217"><img src="images/trans_bar.gif" width="1" height="9"></td>
    <td width="9" height="9" align="right" valign="top"><img src="images/greyborder_btomrht.gif" width="9" height="9"></td>
    </tr>
    </table></td>
    <td width="5" rowspan="2" align="left" valign="top" bgcolor="#FFFFFF"><img src="images/trans_bar.gif" width="5" height="1"></td>
    </tr>
    <tr>
    <td align="left" valign="top" bgcolor="#FFFFFF"><table width="530" border="0" cellpadding="0" cellspacing="0">
    <tr>
    <td width="10" rowspan="4"></td>
    <td height="16" align="right" valign="top"><img src="images/enquiry_txt.gif" width="80" height="16" align="top"></td>
    <td width="10" rowspan="4"><img src="images/trans_bar.gif" width="10" height="1"></td>
    </tr>
    <tr>
    <td width="1" valign="top" bgcolor="#5C97D1"><img src="images/trans_bar.gif" width="1" height="1"></td>
    </tr>
    <tr>
    <td height="7" align="left" valign="top"><img src="images/blue_dot.gif" width="5" height="7"></td>
    </tr>
    <tr>
    <td valign="top"><div align="justify">
    <p class="m_text"><br>
    As a specialist trading company we offer Sugar, Urea and Containerise HMS 1 &amp; 2. These commodities are sourced directly from manufacturers and mandates and can be supplied at any quantity and to any location.</p>
    <p class="m_text">Please email us with your requirements mentioning the following details:</p>
    <table width="100%" border="0" cellspacing="2" cellpadding="5">
    <tr>
    <td valign="top">
    <SCRIPT>
    String.prototype.trim = function()
    {
    // skip leading and trailing whitespace
    // and return everything in between
    return this.replace(/(^\s *)|(\s*$)/g,"")
    }

    function validateEmail(obj)
    {
    //Validates email
    var tempEmail = obj.value.trim();
    var filter = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
    if (filter.test(tempEmail))
    {
    return true;
    }
    else
    {
    alert("Incorrect email address");
    obj.focus();
    return false;
    }
    }


    function validateForm()
    {
    //Email validation
    if(document.mobicon.txtEmail.value.trim() == '')
    {
    alert("Email Id is required");
    document.mobicon.txtEmail.focus();
    return false;
    }
    if(!validateEmail(document.mobicon.txtEmail))
    {
    return false;
    }

    //Name validation
    if(document.mobicon.txtName.value.trim() == '')
    {
    alert("Name is required");
    document.mobicon.txtName.focus();
    return false;
    }
    return true;
    }
    </SCRIPT>
    <FORM name="mobicon" onsubmit="return validateForm();" action="co.php" target="centerframe" method="post">
    <p> <span class="m2_text">YourName*:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>
    <input name="txtName" type="text" id="txtName" size="30" maxlength="100">
    </p>
    <p> <span class="m2_text">Organisation:</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
    <input name="txtOrg" type="text" id="txtOrg" size="30" maxlength="100">
    </p>
    <p><span class="m2_text">Address:</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
    <input name="textAdd" type="text" id="textAdd" value="" size="30">
    </p>
    <p><span class="m2_text">email ID*:</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
    <input name="txtEmail" type="text" id="txtEmail" size="30" maxlength="100">
    </p>
    <p><span class="m2_text">Commodities:</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
    <textarea name="textcommodities" cols="22" rows="4" id="textcommodities"></textarea>
    </p>
    <p><span class="m2_text">Quantity:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
    <input name="texquantity" type="text" id="texquantity" size="30" maxlength="150">
    </p>
    <p><span class="m2_text">Destination:</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
    <input name="textdestination" type="text" id="textdestination" size="30" maxlength="100">
    </p>
    <p><span class="m2_text">Timeframe:</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
    <input name="texttimeframe" type="text" id="texttimeframe" size="30" maxlength="100">
    </p>
    <p><span class="m2_text">Payment Methood:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
    <input name="textpayment" type="text" id="textpayment" size="30" maxlength="100">
    <br>
    (DLC / SBLC / BG / <br>
    TT/ DAP)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span> </p>
    <p><span class="m2_text">Comments:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
    <textarea name="txtcomments" cols="23" rows="4" id="txtcomments"></textarea>
    </p>
    <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;& nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
    <INPUT name="email" type=submit id="email" value="E-mail">
    </p>
    </form></td>
    </tr>
    </table>
    <p></p>
    </div></td>
    </tr>
    </table></td>
    </tr>
    </table>
    </body>
    </html>

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •