hi I have a plugin script from videoswiper they basically download videos to my site and then add them to my database the problem is when they add the data it does not strip characters from the data so when it adds the video it needs to strip the characters from the title of the video otherwise it kills my database and the video wont play if I go in my phpmyadmin and remove the characters all is well from what I have read it seems this is also a big security issue
it seems the people who supplied me this plugin cant figure it out go figure my question is what can i change to strip the characters " - %# from being inserted into the title field of my database best would be if i could strip all but alpha numeric characters i think ive narrowed it down to this snipet
[code] function safeURL($title)
{
$title = strtolower($title);
$title = preg_replace(’/[^’.$this->cSeprator.‘a-z0-9\s]+/’, ‘’, $title);
$title = preg_replace(’/[’.$this->cSeprator.’\s]+/’, $this->cSeprator, $title);
return trim($title, $this->cSeprator);
} [/code]
but it is beyond my knowledge of scripting to fix this