From 41e90aec4671218b072516c70e1d2e9bbfdd7108 Mon Sep 17 00:00:00 2001 From: Chris Morgan Date: Sat, 16 Jun 2007 21:16:12 +0000 Subject: [PATCH] Properly close all of the html frames we opened with html_frame_start(). Fixes a bug where the back link appears inside of a frame and the page rendering time appears in an odd red bar at the bottom of the page --- screenshots.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/screenshots.php b/screenshots.php index 721aeb6..e0978a5 100644 --- a/screenshots.php +++ b/screenshots.php @@ -69,6 +69,9 @@ if($hResult && mysql_num_rows($hResult)) echo "
\n"; while($oRow = mysql_fetch_object($hResult)) { + // if the current version changed then update the current version + // and close the previous html frame if this isn't the + // first frame if(!$aClean['iVersionId'] && $oRow->versionId != $currentVersionId) { if($currentVersionId) @@ -77,7 +80,7 @@ if($hResult && mysql_num_rows($hResult)) echo html_frame_end(); $c=1; } - $currentVersionId=$oRow->versionId; + $currentVersionId = $oRow->versionId; echo html_frame_start("Version ".Version::lookup_name($currentVersionId)); echo "
\n"; } @@ -104,7 +107,8 @@ if($hResult && mysql_num_rows($hResult)) } echo "

\n"; - echo html_frame_end("Click thumbnail to view image in new window."); + echo html_frame_end(); // close the current version we are displaying + echo html_frame_end(); // close the "Screenshot Gallary..." html frame } else { echo "

There are currently no screenshots for the selected version of this application."; echo "
Please consider submitting a screenshot for the selected version yourself.

";