Somebody, Anybody....HELP!!

Status
Not open for further replies.

felicityflowers

New Member
Aug 4, 2005
2,005
578
0
41
Felicity, Ohio
www.felicityflowers.com
State / Prov
Ohio
I know this is a little off topic buuuuut, I need help :)
I am working on a business associate's website (they fired their old web guy and now I was recruited to update their page :boggles: ). I am stuck on the form page. I need the code to send a form to an email address. I have kind of sort of figured it out but, I know you guys are good at this stuff. The form is right but the sending part is the problem. I am racking my brain and pulling out my hair!!!
This is what I am using right now (the part I need help with). What should I use instead?!?

Code:
<form action="mailto:[email protected]" method="POST" enctype="text/plain"><br>
<!--webbot bot="SaveResults" U-File="_private/results.htm" S-Format="HTML/BR" S-Label-Fields="TRUE" B-Reverse-Chronology="FALSE" S-Email-Format="TEXT/PRE" S-Email-Address="[email protected]" B-Email-Label-Fields="TRUE" S-Builtin-Fields startspan --><input TYPE="hidden" NAME="VTI-GROUP" VALUE="0"><!--webbot bot="SaveResults" i-checksum="43374" endspan --><DL>


Thanks in Advance!!
Heather
 
I am very tired right now, but Heather, I'll help you with this tomorrow. :) I'll call you.
 
thanks b, I appreciate it very much. I don't have anything going on but, if you can't find my # pm me and I will give it to you :)
Thanks!!
Heather
 
well, i couldn't help myself...here is to code all "tidied" up...

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2//EN">
<html>
<head>
<title></title>
</head>
<body>
<form action="mailto:[email protected]" method="post"
enctype="text/plain"><br>
<!-- START COMMENT -->
<!--webbot bot="SaveResults" U-
File="_private/results.htm" S-Format="HTML/BR" S-Label-Fields="TRUE" B-Reverse-
Chronology="FALSE" S-Email-Format="TEXT/PRE" S-Email-
Address="[email protected]" B-Email-Label-Fields="TRUE" S-Builtin-Fields
startspan -->
<!-- END COMMENT -->
<input type="hidden" name="VTI-GROUP" value="0">
<!-- START COMMENT -->
<!--webbot
bot="SaveResults" i-checksum="43374" endspan -->
<!-- END COMMENT -->
</form>
</body>
</html>

...this code will create a valid html page. As you can see, the "webbot" code is all commented out, so I am not sure what its trying to accomplish, but perhaps it needs to be uncommented....

FYI, since of course I was posting code, it had bugs...the edit fixed them <sheepish grin>
 
Webbot codes are usually a sign the author is using FrontPage, so hoping for valid code is going to be in vain.

Please let us know if 12bucks' code works for you or not. We'll continue to assist as needed :)

Ryan
 
Thanks Guys!!!
I will try Mark's idea first thing in the AM. I am slammed today with the shop :) I will let you know if it works or not. I am sure anything will work better than the way I did it!!

Thanks Again, I will let you know as soon as I do it!!
:) Heather
 
Sorry, I am on the west coast and got to this late. As Ryan said Heather, if Mark's code works, let us know either way and we'll be here to help you.

There is another way I can teach you useing an .asp file. I can send you the file and the correct /form code, which a lot cleaner than the webbot stuff, but the learning curve is a lil higher. Also, this method will only work if the site is hosted by a windows server and not a linux server, in general.
 
Boo, hiss... ASP = mandatory Microsoft - Not reccommended for beginners, or those with basic hosting packages. I think a simple HTML solution would be best, or PHP as it's much more flexible.

Ryan
 
Agreed about PHP. I just have the asp template I could send her. It is easy. As for the webot or html she has there, I hope she likes spam mail cause spider will crawl her site, pick up that email and she'll get email about extending her... umm ya know. ;)

I would love it, if you could send me a php formMail that you like. I need to update my chicfloral page since it is linux hosted. I'm too lazy to find on online :p I'd be really easy I know. heheheh
 
B,
That is pretty much why the old "web guy" got canned. He was trained in web design but he did a half arse job when designing their site. LOOOOONG story short here is what happened.
My associate has NO CLUE when it comes to the internet. He is about 58 years old and just got a website because he knew he had to. His employee does all the work with it as far as checking emails and what not.

Sooooo, they hadn't been getting their posts from the website so they asked me to check it out. They had over 700 emails in their webmail system and 250 were SPAM. How do I get rid of that bot thing?!?! I know that you aren't supposed to have your email addy so it can be crawled but, not sure how to change the durn thing. B, send me your thingy with instructions. I am going to try Marks right now and see if it works.

Thanks Again!!
:) Heather
 
Here's a sample form I've whipped up. You can edit the html section to have whatever contents you like in the form, and edit the php variables in the top to direct the form output and point the user to a landing page.

Best of all, this will not be spidered, so you won't pick up new SPAM from posting an email address online.

PHP:
<?php 
    $editFormAction = $_SERVER['PHP_SELF'];
    if (isset($_SERVER['QUERY_STRING'])) {
        $editFormAction .= "?" . htmlentities($_SERVER['QUERY_STRING']);
    }
    
    if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form1")) {
        $mybound = "----=_NextPart_000_0074_01C44E26.3D8C5FB0";
        $MailTo = "[email protected]"; //recipient of the form results
        $MailSubject = "Form Submission"; //text in the Subject field of the mail
        $MailHeader = "From: [email protected]\r\n" . "MIME-Version: 1.0\r\n" . "Content-Type: text/html"; //text in the From field of the mail
        $MailBody = "<!DOCTYPE HTML PUBLIC '-//W3C//DTD HTML 4.0 Transitional//EN'> <HTML><HEAD> <META http-equiv=Content-Type content='text/html; charset=iso-8859-1'></HEAD><BODY>";
        ob_start();
        foreach ( $_POST as $key => $value ) {
            print $key . " " . "=" . " " . $value;
            print "<BR/>";
        }
        $thestuff = ob_get_contents();
        ob_end_clean();
        $MailBody .= $thestuff . "</BODY></HTML>";
    
        mail($MailTo, $MailSubject, $MailBody, $MailHeader);  //message send
        
        $insertGoTo = "https://dazlovers.com/thankyou.htm";
        
        if (isset($_SERVER['QUERY_STRING'])) {
            $insertGoTo .= (strpos($insertGoTo, '?')) ? "&" : "?";
            $insertGoTo .= $_SERVER['QUERY_STRING'];
          }    
        header(sprintf("Location: %s", $insertGoTo));
    }
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <title>Dazeal's Form</title>
</head>

<body>
    <form id="form1" name="form1" method="post" action="<?php echo $editFormAction; ?>">
        <div id="Layer1" style="position: absolute; left: 15px; top: 56px; width: 207px; height: 26px; z-index: 1; vertical-align: middle">
            First Name
        </div>
        <div id="Layer2" style="position: absolute; left: 228px; top: 56px; width: 144px; height: 26px; z-index: 2; vertical-align: middle">
            <input name="firstName" type="text" id="firstName" />
        </div>
        <div id="Layer3" style="position: absolute; left: 15px; top: 84px; width: 207px; height: 26px; z-index: 3; vertical-align: middle">
            Last Name
        </div>
        <div id="Layer4" style="position: absolute; left: 228px; top: 84px; width: 144px; height: 26px; z-index: 4; vertical-align: middle">
            <input name="lastName" type="text" id="lastName" />
        </div>
        <div id="Layer5" style="position: absolute; left: 15px; top: 112px; width: 207px; height: 26px; z-index: 5; vertical-align: middle">
            Email Address</div>
        <div id="Layer6" style="position: absolute; left: 228px; top: 112px; width: 144px; height: 26px; z-index: 6; vertical-align: middle">
            <input name="email" type="text" id="email" />
        </div>
        <div id="Layer7" style="position: absolute; left: 15px; top: 140px; width: 207px; height: 26px; z-index: 7; vertical-align: middle">
            How much do you love Dazeal?
        </div>
        <div id="Layer8" style="position: absolute; left: 228px; top: 140px; width: 151px; height: 26px; z-index: 8; vertical-align: middle">
            <label><select name="select">
                        <option value="little">A Little</option>
                        <option value="lot">A Lot</option>
                        <option value="obsessed">More than I can say</option>
                    </select>
            </label>
            <input type="hidden" name="MM_insert" value="form1" />
        </div>
        <div id="Layer9" style="position: absolute; left: 228px; top: 168px; width: 56px; height: 28px; z-index: 9; vertical-align: middle">
            <input type="submit" name="Submit" value="Submit" />
        </div>
        <div id="Layer10" style="position: absolute; left: 10px; top: 15px; width: 1023px; height: 19px; z-index: 10"></div>
    </form>
</body>
</html>
 

Attachments

  • dazeal.zip
    1.4 KB · Views: 3
THANK YOU, THANK YOU, THANK YOU!!
Ryan,
That is more than what I expected. You even fixed up the contents of the actual form. That's awesome!!

Thanks to all of you for your imput. I really appreciate it!

Thanks Again (is that too many thank yous?!?)
:) Heather
 
Status
Not open for further replies.