diff --git a/app/devices/device_edit.php b/app/devices/device_edit.php index 1b198ee4ea..4c8e5b60b9 100644 --- a/app/devices/device_edit.php +++ b/app/devices/device_edit.php @@ -895,6 +895,7 @@ echo "

\n"; echo "\n"; + echo "\n"; echo "\n"; echo "\n"; echo "\n"; }
\n"; echo " ".$text['label-device_mac_address']."\n"; @@ -935,9 +936,10 @@ echo " ".$text['label-device_template']."\n"; echo "\n"; + echo "
"; $device = new device; $template_dir = $device->get_template_dir(); - echo " \n"; echo " \n"; if (is_dir($template_dir) && @is_array($device_vendors)) { foreach ($device_vendors as $row) { @@ -950,6 +952,8 @@ if (is_dir($template_dir . '/' . $row["name"] .'/'. $dir)) { if ($device_template == $row["name"]."/".$dir) { echo " \n"; + $current_device = escape($dir); + $current_device_path = $template_dir . '/' . $row["name"]; } else { echo " \n"; @@ -963,8 +967,54 @@ } } echo " \n"; + echo " \n"; echo " ".$text['description-device_template']."\n"; + echo " "; + echo "
"; + echo " + + "; + + $device_image_path = $current_device_path . "/"; + $device_image_name = $current_device . ".jpg"; + $device_image_full = $device_image_path . "/" . $current_device . "/" . $device_image_name; + + if (file_exists($device_image_full)) + { + $device_image = base64_encode(file_get_contents($device_image_full)); + + echo "
\n"; + echo ""; + echo "
"; + } echo "