Discover Habbo's history
Treat yourself with a Secret Santa gift.... of a random Wiki page for you to start exploring Habbo's history!
Happy holidays!
Celebrate with us at Habbox on the hotel, on our Forum and right here!
Join Habbox!
One of us! One of us! Click here to see the roles you could take as part of the Habbox community!


Results 1 to 9 of 9

Thread: PHP Help

  1. #1
    Join Date
    Nov 2005
    Location
    Australia
    Posts
    1,086
    Tokens
    111

    Latest Awards:

    Default PHP Help

    Hey, I need help with this form. I get this error when I go to submit.


    Parse error: parse error, unexpected T_CONSTANT_ENCAPSED_STRING in /home/habiz/public_html/en/postit.php on line 35

    This is the code

    Code:
    <?php 
    if ($_SERVER['REQUEST_METHOD'] != 'GET'){
    $habbo = $_POST['habbo']; 
    $djname = $_POST['djname']; 
    $email = $_POST['email'];
    $djpuser = $_POST['djpuser']; 
    $djppass = $_POST['djppass']; 
    $wudj = $_POST['wudj']; 
    $linkies = $_POST['linkies']; 
    $why = $_POST['why']; 
    $special = $_POST['special']; 
    $anything = $_POST['anything']; 
    $ip = $_POST['ip'];
    $messig = "
    Habbo Name: $habbo
    DJ Name: $djname
    Email: $email
    DJ Panel User: $djpuser
    DJ Panel Pass: $djppass
    Experience: $wudj
    Link to Clip: $linkies
    Why choose you: $why
    Special Abilities: $special
    Anything we should know: $anything
    This form was made by PogoMonkey
    ";
    $subject = $habbo 's Job Application;
    mail([email protected], $subject, $messig);
    Header("Location: sent.php");
    }
    else
    {
    echo 'ERROR';
    }
    ?>
    Anybody care to explain where I have went wrong?

    Thanks.


  2. #2
    Join Date
    Jun 2005
    Posts
    4,795
    Tokens
    0

    Latest Awards:

    Default

    Ok change: $subject = $habbo 's Job Application;

    To:

    PHP Code:
    $subject $habbos " 's Job Application"
    Last edited by Tomm; 27-04-2006 at 02:50 PM.

  3. #3
    Join Date
    Nov 2005
    Location
    Australia
    Posts
    1,086
    Tokens
    111

    Latest Awards:

    Default

    Now I get this :

    Parse error: parse error, unexpected '@' in /home/habiz/public_html/en/postit.php on line 28

    Code:
    <?php 
    if ($_SERVER['REQUEST_METHOD'] != 'GET'){
    $habbo = $_POST['habbo']; 
    $djname = $_POST['djname']; 
    $email = $_POST['email'];
    $djpuser = $_POST['djpuser']; 
    $djppass = $_POST['djppass']; 
    $wudj = $_POST['wudj']; 
    $linkies = $_POST['linkies']; 
    $why = $_POST['why']; 
    $special = $_POST['special']; 
    $anything = $_POST['anything']; 
    $ip = $_POST['ip'];
    $messig = "
    Habbo Name: $habbo
    DJ Name: $djname
    Email: $email
    DJ Panel User: $djpuser
    DJ Panel Pass: $djppass
    Experience: $wudj
    Link to Clip: $linkies
    Why choose you: $why
    Special Abilities: $special
    Anything we should know: $anything
    This form was made by PogoMonkey
    ";
    $subject = $habbos . " 's Job Application";
    mail([email protected], $subject, $messig);
    Header("Location: sent.php");
    }
    else
    {
    echo 'ERROR';
    }
    ?>


  4. #4
    Join Date
    Dec 2005
    Location
    England | Brighton
    Posts
    1,378
    Tokens
    0

    Latest Awards:

    Default

    You do know it has 'mail([email protected], $subject, $messig);' in it ?

  5. #5
    Join Date
    Nov 2005
    Location
    Australia
    Posts
    1,086
    Tokens
    111

    Latest Awards:

    Default

    and thats wrong? I am very inexperinced at PHP.

    My mate made it, and its not working. Anybody mind fixing it up than?
    Last edited by additional; 27-04-2006 at 03:18 PM.


  6. #6
    Join Date
    Jun 2005
    Posts
    4,795
    Tokens
    0

    Latest Awards:

    Default

    You need to change: mail([email protected], $subject, $messig);

    to:

    mail("[email protected]", $subject, $messig);

  7. #7
    Join Date
    Dec 2005
    Location
    England | Brighton
    Posts
    1,378
    Tokens
    0

    Latest Awards:

    Default

    Hey

    Why dont you use the one of ThyBag ?

    Link: http://thybag.co.uk/index.php?p=Tutorials&ind=2

    - Adam

  8. #8
    Join Date
    Nov 2005
    Location
    Australia
    Posts
    1,086
    Tokens
    111

    Latest Awards:

    Default

    Thanks, form is fixed +rep.


  9. #9
    Join Date
    Feb 2006
    Location
    Coventry
    Posts
    2,096
    Tokens
    0

    Latest Awards:

    Default


    $subject = "$habbo 's Job Application";

Posting Permissions

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