diff --git a/include/screenshot.php b/include/screenshot.php
index c088e8a..78a1ef9 100644
--- a/include/screenshot.php
+++ b/include/screenshot.php
@@ -410,14 +410,14 @@ function get_thumbnail($id)
// set img tag
$imgSRC = '
';
+ '" width="'.$oScreenshot->oThumbnailImage->get_width().
+ '" height="'.$oScreenshot->oThumbnailImage->get_height().'">';
$img = 'oScreenshotImage->width.','.
- ($oScreenshot->oScreenshotImage->height+4).
+ ($oScreenshot->oScreenshotImage->get_width() + 20).','.
+ ($oScreenshot->oScreenshotImage->get_height() + 6).
');return false;">'.$imgSRC.'';
// set image link based on user pref