Moritz Schmidt 10 vuotta sitten
vanhempi
commit
74b7369cf1
2 muutettua tiedostoa jossa 3 lisäystä ja 3 poistoa
  1. 2 2
      functions.php
  2. 1 1
      index.php

+ 2 - 2
functions.php

@@ -28,10 +28,10 @@ function getImageByName($folder) {
 
         // old regex: ([a-zA-Z.*]+)-S([0-9]+)E([0-9]+)-([a-zA-Z0-9.-]+).([a-zA-Z*]+)
         // ([a-zA-Z.*]+)-[S|s]([0-9]+)[E|e]([0-9]+)-([a-zA-Z0-9.-]+)\.([a-zA-Z0-9*]+)
+        // ([a-zA-Z0-9.*]+)-[S|s]([0-9]+)[E|e]([0-9]+)-([a-zA-Z0-9.-]+)\.([a-zA-Z0-9\(\).*\w\,]+)
 
 
-
-        preg_match_all("/([a-zA-Z0-9.*]+)-[S|s]([0-9]+)[E|e]([0-9]+)-([a-zA-Z0-9.-]+)\.([a-zA-Z0-9\(\).*\w]+)/", $folder, $output);
+        preg_match_all("/([a-zA-Z0-9.*]+)-[S|s]([0-9]+)[E|e]([0-9]+)-([a-zA-Z0-9äöüÄÖÜß\-\.\,\w]+)\.([a-zA-Z0-9\(\).*\w\,]+)/", $folder, $output);
         if(sizeof($output[0]) > 0) {
 
             if((string) $output[3][0] != "0") {

+ 1 - 1
index.php

@@ -179,7 +179,7 @@ require('functions.php');
 
                         }
                     } else {
-                        if(preg_match_all("/([a-zA-Z0-9.*]+)-[S|s]([0-9]+)[E|e]([0-9]+)-([a-zA-Z0-9.-]+)\.([a-zA-Z0-9\(\).*\w]+)/", $object, $output)) {
+                        if(preg_match_all("/([a-zA-Z0-9.*]+)-[S|s]([0-9]+)[E|e]([0-9]+)-([a-zA-Z0-9äöüÄÖÜß\-\.\,\w]+)\.([a-zA-Z0-9\(\).*\w\,]+)/", $object, $output)) {
                             echo "<div class=\"col-sm-3 episode\"><div class=\"image-zoom\">";
                             echo "<a href=\"?path=" . $_GET['path'] . "/" . $object . "\">" . "<img class=\"img-responsive\" src=\"" . getImageByName($_GET['path'] . "/" . $object) . "\" alt=\"" . $object . "\">";