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!


Page 2 of 2 FirstFirst 12
Results 11 to 15 of 15
  1. #11
    Join Date
    Jul 2008
    Location
    Hastings, UK.
    Posts
    2,050
    Tokens
    0

    Latest Awards:

    Default

    PHP Code:
    addslashes(htmlspecialchars($_POST['email'])) 
    Not keen on that, I'd have something along the lines of..

    PHP Code:
    function streetcleaner($string) { 

    $string htmlspecialchars$string );
    $string addslashes$string );
    $string mysql_real_escape_string$string );
    $string stripslashes$string );

    return 
    $string;
    }

    streetcleaner($_POST["email"]); 

  2. #12
    Join Date
    Nov 2007
    Posts
    1,253
    Tokens
    150

    Latest Awards:

    Default

    It doesn't matter that much calon as its only doing into a mail functions and no databases are present so it would be relativly hard to hack it. Unless they were trying to run the system command to run a shell or something.


    www.fragme.co = a project.

  3. #13
    Join Date
    Apr 2008
    Location
    England.
    Posts
    1,324
    Tokens
    0

    Latest Awards:

    Default

    Quote Originally Posted by Calon View Post
    PHP Code:
    addslashes(htmlspecialchars($_POST['email'])) 
    Not keen on that, I'd have something along the lines of..

    PHP Code:
    function streetcleaner($string) { 

    $string htmlspecialchars$string );
    $string addslashes$string );
    $string mysql_real_escape_string$string );
    $string stripslashes$string );

    return 
    $string;
    }

    streetcleaner($_POST["email"]); 
    I'd probably use that if my script was a lot more bigger and was using databases as it's much more secure than addslashes and specialchars :p Thanks though

  4. #14
    Join Date
    Mar 2008
    Posts
    5,108
    Tokens
    3,780

    Latest Awards:

    Default

    just do htmlentities and mysql_real_escape_string even though it isn't going into a database.

    Should make it pretty secure

  5. #15
    Join Date
    Jul 2008
    Location
    Hastings, UK.
    Posts
    2,050
    Tokens
    0

    Latest Awards:

    Default

    Oh, right.. Never noticed

    You should make them log within the database or something then.

Page 2 of 2 FirstFirst 12

Posting Permissions

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