Index: trunk/DataStoreServer/web/cgi/dsgetindex
===================================================================
--- trunk/DataStoreServer/web/cgi/dsgetindex	(revision 24175)
+++ trunk/DataStoreServer/web/cgi/dsgetindex	(revision 25366)
@@ -140,7 +140,9 @@
             # 'text/plain' format
             print header('text/plain', '404 ERROR');
-            #print header('text/plain', '200 OK');
+#           print header('text/plain', '410 GONE');
+#            print header('text/plain', '200 OK');
             print @$stderr_buf;
             print STDERR @$stderr_buf;
+#            exit 410;
         }
     }
@@ -172,17 +174,26 @@
 #
 
-sub print_free_space {
-    use Filesys::Df;
-	# get free space
-	my $ref = df($DS_ROOT);
-	printf '<p>Free space: %.2f G (%.1f%%)</p>',
-		$ref->{bfree}/(1024*1024),
-		100.0*$ref->{bfree}/$ref->{blocks};
-        print "\n";
-}
+#sub print_free_space {
+#    use Filesys::Df;
+#	# get free space
+#	my $ref = df($DS_ROOT);
+#	printf '<p>Free space: %.2f G (%.1f%%)</p>',
+#		$ref->{bfree}/(1024*1024),
+#		100.0*$ref->{bfree}/$ref->{blocks};
+#        print "\n";
+#}
 sub pprint_pre {
 
     print header('text/html', '200 OK');
-    print start_html('Data Store');
+    my $name;
+    # note $fileset is not so we look at the name of the index script to determine the level
+    if ($program eq "dsfsindex") {
+        $name = $fileset;
+    } elsif ($program eq "dsprodindex") {
+        $name = "$product";
+    } else {
+        $name = "";
+    }
+    print start_html("IPP Data Store $name");
 
 
@@ -208,5 +219,5 @@
     print p();
 
-    print_free_space();
+#    print_free_space();
     print end_html();
 }
@@ -241,8 +252,10 @@
             # if this is a file request, use a download cgi
             if ($wpath =~ /\.fits\s*$/) {
-                    $wpath = '/ds-cgi/dsfits.cgi?'.substr($wpath, 4); # strip' /ds/'
+                # This doesn't work through the proxy
+                # The /ds-cgi gets tried on alala
+                #    $wpath = '/ds-cgi/dsfits.cgi?'.substr($wpath, 4); # strip' /ds/'
             }
 
-        print a({-href=>$wpath}, $toks[0]);
+        print a({-href=>$wpath, -type=>'image/x-fits'}, $toks[0]);
     }
 
