1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    May 2000
    Rep Power
    Hi I have the following table (real simple):
    CREATE TABLE txttest (comments TEXT);

    I then use a <textarea> to enter text.
    This text then gets inserted into the table above.

    I was told to use:
    before inserting into my database

    This WORKS when I type in something like:
    "this is a comment line"
    (looks like: this+is+a+comment+line)
    if I type in something like:
    "this is a comment line,
    this is another comment line"
    (looks like: this+is+a+comment+line%2C%0D%0Athis+is+another+comment+line)

    I get this error:
    Error in executing INSERT INTO txttest (comments) VALUES('this+is+a+comment+line%2C%0D%0Athis+is+another+comment+line')
    error:1065 Query was empty


  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Novice (500 - 999 posts)

    Join Date
    Jul 2000
    Rep Power
    try addslashes instead of urlencode

Similar Threads

  1. Problem: Displaying image link inside table from MySQL
    By Shadowz in forum PHP Development
    Replies: 4
    Last Post: February 13th, 2004, 01:37 AM
  2. League table problem
    By silverduck in forum MySQL Help
    Replies: 8
    Last Post: February 10th, 2004, 12:38 PM
  3. php/mysql problem creating tables
    By riley in forum PHP Development
    Replies: 3
    Last Post: February 10th, 2004, 05:13 AM
  4. table cell height problem
    By romalong in forum HTML Programming
    Replies: 0
    Last Post: February 1st, 2004, 07:39 PM
  5. Replies: 0
    Last Post: January 30th, 2004, 02:18 PM

IMN logo majestic logo threadwatch logo seochat tools logo