SitePoint Sponsor

User Tag List

Results 1 to 5 of 5

Thread: PHP problem

  1. #1
    SitePoint Enthusiast
    Join Date
    Jun 2004
    Location
    Alabama
    Posts
    26
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question PHP problem

    Well, i have created a PHP feedback form that is located here... http://www.eatarock.com/contact.htm
    here is the code i am using for the form:

    <form method="post" action="feedback.php">
    Name: <input name=”name” type=”text” /><br />
    Email: <input name="email" type="text" size="25" /><br />
    Commentsbr />
    <textarea name="comments" rows="15" cols="40">
    </textarea><br />
    <input type="submit" />
    </form>

    that is located in contact.htm..... now here is the code i am using for feedback.php:

    <?php

    $msg = "Name:t$namen";
    $msg .= "Email:t$emailn";
    $msg .= "Comments:t$commentsn";

    $recipient = "admin@eatarock.com";
    $subject = "New Feedback from my site";

    $mailheaders = "From:$emailn";
    $mailheaders .= "Reply-To:$emailnn";

    mail($recipient, $subject, $msg, $mailheaders);
    header("Location: http://www.eatarock.com/thankyou.htm");
    ?>


    for some reason whenever you press submit on the contact form it takes you to feedback.php and says page cannot be displayed.... It is supposed to redirect to thankyou.htm...... I have no clue as to why it is doing this

    Does anyone know how to fix it?

    EDIT: i am hosting on 1and1.com with the MShosting package that 4.99/mo if that makes a diff.

    -Thanks in advance

    Mike
    Last edited by mikeboy99; Jun 15, 2004 at 15:52.

  2. #2
    gingham dress, army boots... silver trophy redux's Avatar
    Join Date
    Apr 2002
    Location
    Salford / Manchester / UK
    Posts
    4,838
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    would be good if this was actually posted in the PHP forum, wouldn't it ?

    anyway, try changing
    Code:
    <input name=”name” type=”text” />
    to
    Code:
    <input name="name" type="text" />
    (notice the difference in the type of double quotes used)
    re·dux (adj.): brought back; returned. used postpositively
    [latin : re-, re- + dux, leader; see duke.]
    WaSP Accessibility Task Force Member
    splintered.co.uk | photographia.co.uk | redux.deviantart.com

  3. #3
    SitePoint Enthusiast
    Join Date
    Jun 2004
    Location
    Alabama
    Posts
    26
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    didnt change anything..... someone hellllllllllllllp
    !!!!!!!!!!!!!!!!!!!!!!one!!!11111!!111111one111!!11

  4. #4
    SitePoint Wizard trampt's Avatar
    Join Date
    Jan 2003
    Location
    Los Angeles, CA
    Posts
    1,997
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by mikeboy99
    EDIT: i am hosting on 1and1.com with the MShosting package that 4.99/mo if that makes a diff.
    Usually MS hosting packages don't support PHP which could be your problem. They can but its not usually standard. Might want to check your hosting package and see if they support PHP.

    Looking quickly at their site it doesn't appear that their MS hosting packages support PHP. Switch it over to their Linux hosting package and you should be good.

  5. #5
    SitePoint Enthusiast
    Join Date
    Jun 2004
    Location
    Alabama
    Posts
    26
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thats an extremely good idea, and i just switched microsoft hosting just has toomany limitations, it sucks balls...... but n e wayz thatnks for all the help!


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
  •