diff --git a/src/structure/components/com_sportsmanager/views/sportsmanager/view_tools.php b/src/structure/components/com_sportsmanager/views/sportsmanager/view_tools.php
index 59527d7..f582203 100644
--- a/src/structure/components/com_sportsmanager/views/sportsmanager/view_tools.php
+++ b/src/structure/components/com_sportsmanager/views/sportsmanager/view_tools.php
@@ -337,11 +337,55 @@ function bildURL($typ, $id, $fixed_width = 0, $fixed_height = 0, $max_width = 0,
return $sportsmanager_joomla_url . 'images/sportsmanager/' . $typ . '/' . basename($pfad_angepasst);
}
-
-function bildHTML($typ, $id, $fixed_width = 0, $fixed_height = 0, $max_width = 0, $max_height = 0, $zusatz = "", $alternativ = "") {
+/*
+ * #resize=250
+#resize=250,250,blue
+#resize=250,250,blue
+#resize=250,250&sizes=60%,80%,200%
+#resize=250,250,cover&sizes=60%,80%,200%
+#resize=250,250,fill&sizes=60%,80%,200%
+#crop=250,250,center,top
+#crop=250,250
+#crop=250,250,center,bottom
+#crop=250,250,left
+#crop=250,250,right
+ */
+function yoothemeBild($typ, $id, $crop = 'resize=250', $zusatz = "", $alternativ)
+{
global $sportsmanager_joomla_path;
global $sportsmanager_joomla_url;
+ $typ_exploded = explode("/", $typ);
+ $typ = $typ_exploded[0];
+ $typ_prefix = count($typ_exploded) > 1 ? $typ_exploded[1] : "";
+ $pfad = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
+
+ if (is_file($pfad . "png"))
+ $ext = "png";
+ else if (is_file($pfad . "jpg"))
+ $ext = "jpg";
+ else if (!empty($alternativ)) {
+ $id = $alternativ;
+ $pfad = $sportsmanager_joomla_path . "/images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . ".";
+ if (is_file($pfad . "png"))
+ $ext = "png";
+ else if (is_file($pfad . "jpg"))
+ $ext = "jpg";
+ else
+ return null;
+ }
+ else
+ return null;
+
+ $time = filemtime($pfad . $ext);
+
+ $bildpfad = "images/sportsmanager/" . $typ . "/" . $typ_prefix . $id . "." . $ext;
+
+
+ return '
';
+}
+
+function bildHTML($typ, $id, $fixed_width = 0, $fixed_height = 0, $max_width = 0, $max_height = 0, $zusatz = "", $alternativ = "") {
$typ_exploded = explode("/", $typ);
$typ = $typ_exploded[0];
$typ_prefix = count($typ_exploded) > 1 ? $typ_exploded[1] : "";
@@ -387,20 +431,7 @@ function bildHTML($typ, $id, $fixed_width = 0, $fixed_height = 0, $max_width = 0
return null;
}
- /*
- * #resize=250
-#resize=250,250,blue
-#resize=250,250,blue
-#resize=250,250&sizes=60%,80%,200%
-#resize=250,250,cover&sizes=60%,80%,200%
-#resize=250,250,fill&sizes=60%,80%,200%
-#crop=250,250,center,top
-#crop=250,250
-#crop=250,250,center,bottom
-#crop=250,250,left
-#crop=250,250,right
- */
- return '
';
+ return '
';
}
$new_width = $width;