Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 12 of 12
  1. #1
    Regular Coder
    Join Date
    Nov 2009
    Posts
    132
    Thanks
    42
    Thanked 0 Times in 0 Posts

    Tell a Friend Script not working

    I have this sort of referral page on my website... You can view it here: http://www.thepriceoflust.com/pages/about.html Anyway it doesn't work... I was wondering if any of you guys know why... It will let you enter your email address and your friends email address and type up a note but it will never send out an email after you hit send...

  • #2
    Regular Coder
    Join Date
    Feb 2007
    Location
    Canada
    Posts
    924
    Thanks
    10
    Thanked 56 Times in 55 Posts
    Free hosting? or paid?
    Using Sendmail?
    Can you send/receive emails from a contact script?

  • #3
    Regular Coder
    Join Date
    Nov 2009
    Posts
    132
    Thanks
    42
    Thanked 0 Times in 0 Posts
    it is paid hosting... I just found this script on the net for a refer-a-friend page and uploaded it to my about us page... That is all I did... Do I need to put something else in the script?

  • #4
    Master Coder Excavator's Avatar
    Join Date
    Dec 2006
    Location
    Alaska
    Posts
    9,692
    Thanks
    22
    Thanked 1,830 Times in 1,814 Posts
    Hello thepriceoflust,
    Your form has <form action="file.php" method=POST>
    but file.php appears to be your index page. That's why that page loads when you click send.
    Validate often DURING development - Use it like a splelchecker | Debug during Development |Write it for FireFox, ignore IE
    Use the right DocType | Validate your markup | Validate your CSS | Why validating is good | Why tables are bad

  • Users who have thanked Excavator for this post:

    thepriceoflust (11-21-2009)

  • #5
    Regular Coder
    Join Date
    Nov 2009
    Posts
    132
    Thanks
    42
    Thanked 0 Times in 0 Posts
    File.php is not the index page... index.php is...
    Last edited by thepriceoflust; 11-21-2009 at 07:54 PM.

  • #6
    Master Coder Excavator's Avatar
    Join Date
    Dec 2006
    Location
    Alaska
    Posts
    9,692
    Thanks
    22
    Thanked 1,830 Times in 1,814 Posts
    Can you post the contents of file.php here then?


    click on this link - http://www.thepriceoflust.com/pages/file.php
    Validate often DURING development - Use it like a splelchecker | Debug during Development |Write it for FireFox, ignore IE
    Use the right DocType | Validate your markup | Validate your CSS | Why validating is good | Why tables are bad

  • Users who have thanked Excavator for this post:

    thepriceoflust (11-21-2009)

  • #7
    Regular Coder
    Join Date
    Nov 2009
    Posts
    132
    Thanks
    42
    Thanked 0 Times in 0 Posts
    Code:
    <?
    /////////////////////////////////////
    //  PHP Simp Refferal Version 1.0  //
    //                                 //
    //        Copyright 2002           //
    //         Darren Labey            //
    //      All Rights Reserved        //
    //                                 //
    //      This Script May Not Be     //
    //      Modified In Any Way        //
    //      Except To Edit The         //
    //         Variables.              //
    //                                 //
    //   This information here may not //
    //  be taken off as we are allowing//
    //  you to not have the copyright  //
    //  shown on your page.            //
    //                                 //
    //    Any breaches of these        //
    //    conditions will result in    //
    //    legal action.                //
    //                                 //
    //    This script is distributed   //
    //    freely with no warranty free //
    //    of charge.                   //
    //                                 //
    /////////////////////////////////////
    
    // Edit the field below to show your sites url.
    
    $site = "www.thepriceoflust.com";
    
    // No editing.
    
    $email = "$f_femail";
    
    // Replace noreply@yoursite.com with the appropriate information on where the email is coming from.
    
    $from = "admin@thepriceoflust.com";
    
    // No Editing.
    
    $subject = "Hey I wanted To Tell You About $site";
    if ($f_name <> "" and $f_email <> "" and $f_message <> "" and $f_femail <> "" ) {
    mail("$email", "$subject", "Hey! $f_name whose e-mail address is $f_email, wanted to tell you about $site!\n\nMessage From $f_name,\n$f_message", "From: $from");
    
    // Edit the field below to represent the message displayed when the form has been successfully sent. If you want you may use a PHP include to include a message sent page.
    
    $msg = "<center>Thanks $f_name, your friend will be informed about this site!<br><br><font size=\"2\" color=\"ff0000\">Copyright PHP Simp Reffer V1.0</font><br><a href=\"http://darrensscripts.netfirms.com\"><FONT SIZE=\"2\">By Darren's Scripts</font></a></center>";
    } else {
    
    // Edit the field below to tell if the form has not had all fields filled out.
    
    $msg = "All fields are required, push the back button to fill out the rest.";
    }
    ?>
    <p><? echo $msg; ?></p>

  • #8
    Master Coder Excavator's Avatar
    Join Date
    Dec 2006
    Location
    Alaska
    Posts
    9,692
    Thanks
    22
    Thanked 1,830 Times in 1,814 Posts
    Maybe this is a path problem.
    Where exactly is file.php?
    It could be this is all you need to do <form action="../file.php" method="POST">
    Validate often DURING development - Use it like a splelchecker | Debug during Development |Write it for FireFox, ignore IE
    Use the right DocType | Validate your markup | Validate your CSS | Why validating is good | Why tables are bad

  • #9
    Regular Coder
    Join Date
    Nov 2009
    Posts
    132
    Thanks
    42
    Thanked 0 Times in 0 Posts
    I picked up this script on the web some place... I wanted to change my "about" page to a Tell-A-Friend page. This is what I did. I copied the css style coding right to about.tpl and then I put the file.php file in the same folder...

  • #10
    Regular Coder
    Join Date
    Nov 2009
    Posts
    132
    Thanks
    42
    Thanked 0 Times in 0 Posts
    should I put the file.php in the root folder or in the same folder as about.tpl which is in the templates/default folder

  • #11
    Regular Coder
    Join Date
    Nov 2009
    Posts
    132
    Thanks
    42
    Thanked 0 Times in 0 Posts
    I tried to use a different script and that didn't work either... Is there a script that you guys know of that works... Maybe there is something wrong with this one...

  • #12
    Regular Coder
    Join Date
    Nov 2009
    Posts
    132
    Thanks
    42
    Thanked 0 Times in 0 Posts
    Ok maybe I am not installing this correctly... Here is what I have... I want to take my "about us" page and turn it into a "Refer a Friend" page... I found this refferal script online. When I download the script and unzip it I get three different files... One is a readme.txt file which really doesn't tell me anything on how to install this script... The other files I have are a .php file and a .html file... If someone could walk me through the install that would be great... What I did previously was take the .html file ande copy past that to the "about" page... It made the styling of the page look good but I don't think there was coding behind it... Thanks for the help...


  •  

    Posting Permissions

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