Results 1 to 3 of 3

Thread: PHP textform

  1. #1

    Question PHP textform

    I have a question about forms in php and mysql.
    Is a textbox safe to use or can someone run a script through it ?

    If so how can I protect it? With what kind of script?

    what does adslash and stripslash do?

    any help would be greatly received


  2. #2
    Join Date
    Jun 2003
    Janesville, Wi
    I use <textarea> for forms all the time. The entered data is viewed simply as text and added to the variable set by the name value. I have never had a problem like what you asked.

    Stripslahses removed any backslashes from the code. Sometimes, you have \" in the code. The function changes it to ".

    Adslashes adds the backslashes to the code. " -> \"

  3. #3
    Join Date
    Nov 2003
    There is nothing inherently insecure about <textarea>, but you should never blindly execute something the user inputs. If it doesn't need to contain HTML or other code, run it through strip_tags. Also make sure the user isn't injecting SQL queries.

Posting Permissions

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