aboutsummaryrefslogtreecommitdiff
path: root/services/tagservice.php
diff options
context:
space:
mode:
Diffstat (limited to 'services/tagservice.php')
-rw-r--r--services/tagservice.php9
1 files changed, 7 insertions, 2 deletions
diff --git a/services/tagservice.php b/services/tagservice.php
index 83349c6..504d13f 100644
--- a/services/tagservice.php
+++ b/services/tagservice.php
@@ -75,8 +75,13 @@ class TagService {
$this->db->sql_query($query);
return true;
}
-
-
+
+ /* normalize the input tags which could be a string or an array*/
+ function normalize($tags) {
+ //clean tags from strange characters
+ $tags = str_replace(array('"', '\'', '/'), "_", $tags);
+ return $tags;
+ }
function deleteAll() {
$query = 'TRUNCATE TABLE `'. $this->getTableName() .'`';