Yeah actually there is an error. I used mysql_error(). Could not run query: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'gkwde'' WHERE dex='{71C50C85-E4F2-987A-833F-2B0F00B63224}'' at line 1
But I can't seem to figure out where I have added the extra set of single notes.
Here's the function I use to create my id.
PHP Code:
function create_guid() {
//---------------------------------------------------------------------
// A function to create a unique ID
//---------------------------------------------------------------------
static $guid = '';
$uid = uniqid("", true);
$data = $namespace;
$data .= $_SERVER['REQUEST_TIME'];
$data .= $_SERVER['HTTP_USER_AGENT'];
$data .= $_SERVER['LOCAL_ADDR'];
$data .= $_SERVER['LOCAL_PORT'];
$data .= $_SERVER['REMOTE_ADDR'];
$data .= $_SERVER['REMOTE_PORT'];
$hash = strtoupper(hash('ripemd128', $uid . $guid . md5($data)));
$guid = '{' .
substr($hash, 0, 8) .
'-' .
substr($hash, 8, 4) .
'-' .
substr($hash, 12, 4) .
'-' .
substr($hash, 16, 4) .
'-' .
substr($hash, 20, 12) .
'}';
return $guid;
}
Bookmarks