[Scummvm-cvs-logs] SF.net SVN: scummvm: [25763] web/trunk
sev at users.sourceforge.net
sev at users.sourceforge.net
Wed Feb 21 14:36:14 CET 2007
Revision: 25763
http://scummvm.svn.sourceforge.net/scummvm/?rev=25763&view=rev
Author: sev
Date: 2007-02-21 05:36:13 -0800 (Wed, 21 Feb 2007)
Log Message:
-----------
Produce less warnings during exscution.
Fix stupid error.
Modified Paths:
--------------
web/trunk/include/screenshots.php
web/trunk/screenshots.php
Modified: web/trunk/include/screenshots.php
===================================================================
--- web/trunk/include/screenshots.php 2007-02-21 12:34:14 UTC (rev 25762)
+++ web/trunk/include/screenshots.php 2007-02-21 13:36:13 UTC (rev 25763)
@@ -73,6 +73,12 @@
$n = count($cats);
$t = explode(".", $cats[$n - 1]);
$num = $t[0];
+
+ if (!array_key_exists($cats[$n - 3], $scrcatnums) or
+ !array_key_exists($cats[$n - 2], $scrcatnums[$cats[$n - 3]])) {
+ $scrcatnums[$cats[$n - 3]][$cats[$n - 2]] = 0;
+ }
+
if ($scrcatnums[$cats[$n - 3]][$cats[$n - 2]] < $num + 1)
$scrcatnums[$cats[$n - 3]][$cats[$n - 2]] = $num + 1;
}
Modified: web/trunk/screenshots.php
===================================================================
--- web/trunk/screenshots.php 2007-02-21 12:34:14 UTC (rev 25762)
+++ web/trunk/screenshots.php 2007-02-21 13:36:13 UTC (rev 25763)
@@ -13,11 +13,24 @@
html_content_begin('Screenshots');
-$view = $HTTP_GET_VARS['view'];
-$offset = $HTTP_GET_VARS['offset'];
-$cat1 = $HTTP_GET_VARS['cat1'];
-$cat2 = $HTTP_GET_VARS['cat2'];
+$view = $offset = $cat1 = $cat2 = "";
+if (array_key_exists('view', $HTTP_GET_VARS)) {
+ $view = $HTTP_GET_VARS['view'];
+}
+
+if (array_key_exists('offset', $HTTP_GET_VARS)) {
+ $offset = $HTTP_GET_VARS['offset'];
+}
+
+if (array_key_exists('cat1', $HTTP_GET_VARS)) {
+ $cat1 = $HTTP_GET_VARS['cat1'];
+}
+
+if (array_key_exists('cat2', $HTTP_GET_VARS)) {
+ $cat2 = $HTTP_GET_VARS['cat2'];
+}
+
echo '<script src="'.$file_root.'/screenshots.js" type="text/javascript"></script>';
if ($view == "") {
@@ -80,7 +93,7 @@
</div>
<?php
}
-if ($view != -1 && view != "") {
+if ($view != -1 && $view != "") {
display_single_shot($cat1, $cat2, $view);
}
if ($view == -1) {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list