Fix for {PER} in queries...
authorRoland Häder <roland@mxchange.org>
Tue, 17 Nov 2009 21:07:42 +0000 (21:07 +0000)
committerRoland Häder <roland@mxchange.org>
Tue, 17 Nov 2009 21:07:42 +0000 (21:07 +0000)
inc/db/lib-mysql3.php

index 13d333d1b2e16f99c1cb5206e88ff7a0470ba18b..14a4b6f9cc8cc5078b1a625c018ffa1f84806066 100644 (file)
@@ -71,6 +71,9 @@ function SQL_QUERY ($sqlString, $F, $L) {
        // Remove \t, \n and \r from queries they may confuse some MySQL version I have heard
        $sqlString = str_replace("\t", ' ', str_replace("\n", ' ', str_replace("\r", ' ', $sqlString)));
 
        // Remove \t, \n and \r from queries they may confuse some MySQL version I have heard
        $sqlString = str_replace("\t", ' ', str_replace("\n", ' ', str_replace("\r", ' ', $sqlString)));
 
+       // Replace {PER}
+       $sqlString = str_replace('{PER}', '%', $sqlString);
+
        // Compile config out
        $sqlString = FILTER_COMPILE_CONFIG($sqlString, true);
 
        // Compile config out
        $sqlString = FILTER_COMPILE_CONFIG($sqlString, true);