Re: [RESOLVED] ForEach error
Quote:
Originally Posted by dclamp
i was using {} then i sent it to my friend to see if he could fix it and he sent it back like that. I forgot to put back the {}.
You are still not escaping the variable contents in any case. If someone sent a POST request with a value like "' OR true" they could delete all the records in the table. You must at least escape the data and should really use parameterised queries (using a data access library such as mysqli, MDB2 or PDO).
If you are relying on magic quotes to escape the POST data for you then that is another problem which will cause you other issues. Magic quotes should always be off.