#!/usr/local/bin/perl

if($ENV{'HTTP_USER_AGENT'} =~ /MSIE/ && $ENV{'HTTP_USER_AGENT'} =~ /Mac/){ 
} elsif ($ENV{'HTTP_REFERER'} eq "") {
	print "Location: ../index.php", "\n\n";
	exit;
}

open IN, "./common/ajax.js";
while (<IN>) {
	$_ =~ s/\r//g;
	$_ =~ s/\n//g;
	$_ =~ s/\t//g;
	$body .= $_;
}
close IN;

print "Content-Type: application/x-javascript";
print "Pragma: no-cache";
print "Cache-Control: no-cache";
print "Expires: 0\n\n";
print $body;
exit;
