Announcement

Collapse
No announcement yet.

Problems Feedback (PHP Coding)

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Problems Feedback (PHP Coding)

    I was just woundering why the script is not working can some help up thanks.
    It just wont send mail.... http://www.coolconnections.com.au/feedback.php

    PHP Code:
    $Your Name$_REQUEST['Name'] ;
    $E-Mail Address $_REQUEST['message'] ;
    $Title $_REQUEST['Title'] ;
    $Phone Number $_REQUEST['Phome Number'] ;
    mail("[email protected]"'"Feedback Form Results",$message, From: $email" );
    header("location: http://www.coolconnections.com.au/feedback.html"); 

  • #2
    1. Don't use spaces in your variable declarations.
    2. Don't declare your variables twice. There is no need for something like $Title = $_REQUEST['Title'];
    3. Read up on the syntax of mail() on www.php.net .
    4. I assume the name, message etc. comes from a form which uses post? Then use $_POST instead of $_REQUEST .

    Comment


    • #3
      For some reason the Buttons just push in and not going to my mailthanks page have no clue its driving me in sane atm. tryed everythink...

      Comment


      • #4
        Originally posted by Raindammit
        For some reason the Buttons just push in and not going to my mailthanks page have no clue its driving me in sane atm. tryed everythink...
        This is not a php issue. You have your submit buttons after you close out your form </form>. Which of course is why the buttons don't even show up in Firefix.

        Comment


        • #5
          By the way, once you get that fixed your going to get this error in mailthanks.php

          PHP Code:
            Parse errorparse errorunexpected ':'expecting ']' /home/cool12/public_html/mailthanks.php on line 36 

          Comment


          • #6
            Originally posted by Icheb
            2. Don't declare your variables twice. There is no need for something like $Title = $_REQUEST['Title'];
            I disagree with that. If register globals is off, he'll need to make that declaration. ANd, of course, if register globals is on he should still make the declaration for security purposes and also should disable register globals.

            Comment


            • #7
              No, he doesn't "need to make that". I don't do it and I don't have any problems. You could give some actual reasons behind your argument, instead of just saying "should do this and should do that".
              Yes, PHP stores the content of variables by reference, so the content of a variable is only stored once even if multiple variables contain that very same content. However, it's still a total waste of processor cycles.

              Comment


              • #8
                Well, post data, or any user suppled data for that matter, should always be validated.

                Comment

                widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
                Working...
                X