kterry;10907145 wrote:I will provide an example.
Alright, I installed debian on a virtual machine, then installed mysql 5.0.77 and could not replicate it. I did some searching around on the internet and found someone who had the exact same problem. http://www.criticalsecurity.net/index.php?showtopic=29768
Below is code example.
<?php
try{
$db = new PDO('mysql:host=localhost;dbname=test;', 'USERNAME', 'PASSWORD');
$sql = "INSERT INTO est (test) VALUES (:test)";
$statement = $db->prepare($sql);
$test = "raw data with ' and more ' and stuff";
$statement->bindParam(':test', $test);
$statement->execute();
} catch(PDOException $e){
echo $e->getMessage();
}
Here is the schema for the table.
CREATE TABLE `test` (
`test` text character set latin1 NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8
Maybe someone running mysqld earlier than 5.0.77 can give this a run and see if it's just patched in that version.
Thanks!