diff --git a/includes/css.php b/includes/css.php
index 4419bac..0745b4e 100644
--- a/includes/css.php
+++ b/includes/css.php
@@ -25,7 +25,7 @@
         $css_class[] = recstatus_class($item);
     // Category type?
         if ($item->category_type && !preg_match('/unknown/i', $item->category_type))
-            $css_class[] = 'type_'.preg_replace("/[^a-zA-Z0-9\-_]+/", '_', $item->category_type);
+            $css_class[] = 'type_'.preg_replace("/[^a-zA-Z0-9\-_]+/u", '_', $item->category_type);
     // Category cache
         $category = strtolower($item->category);    // user lowercase to avoid a little overhead later
         static $cache = array();
@@ -42,7 +42,7 @@
                     }
                     if (!$details[1])
                         continue;
-                    if (preg_match('/'.$details[1].'/', $category)) {
+                    if (preg_match('/'.$details[1].'/u', $category)) {
                         $css_class[] = $cache[$category] = 'cat_'.$cat;
                         break;
                     }
diff --git a/modules/tv/handler.php b/modules/tv/handler.php
index 66285b6..c048c6c 100644
--- a/modules/tv/handler.php
+++ b/modules/tv/handler.php
@@ -93,11 +93,11 @@
             trigger_error("Failed to open tv category file:  $path", FATAL);
     // Parse the file
         global $Categories;
-        foreach (preg_split('/\n(?=\S)/', $file) as $group) {
-            list($key, $trans, $regex) = preg_split('/\s*\n\s*/', $group);
+        foreach (preg_split('/\n(?=\S)/u', $file) as $group) {
+            list($key, $trans, $regex) = preg_split('/\s*\n\s*/u', $group);
         // Cleanup
-            if (preg_match('/^["\']/', $key))
-                $key = preg_replace('/^(["\'])(.+)\\1$/', '$2', $key);
+            if (preg_match('/^["\']/u', $key))
+                $key = preg_replace('/^(["\'])(.+)\\1$/u', '$2', $key);
         // Store
             $Categories[$key] = array($trans, $regex);
         }
