0

Whilst wondering around aimlessly, I came across a pack of "Afterworld" cards, and printed on these cards in quite a few places, was this script:

textOutput.append("Date : "+ new Date(usedURLConn.getDate())+"\n");
textOutput.append("Content-Type: "+usedURLConn.getContentType()+"\n");
len = usedURLConn.getContentLength();
textOutput.append("Content length: "+len+"\n\n");

if(len>0)
{
textOutput.append("The file's contents is as follows: \n--------------------\n");
InputStream input = usedURLConn.getInputStream();;
int i=len;
while (((c=input.read()) != -1) && (--i>0))
{
textOutput.append(""+(char)c);
}
input.close();
textOutput.append("\n--------------------\n");
}
else
{
textOutput.append("Sorry! That file is EMPTY, or that file does not exist!");
}
   }
});

}

}

Can anyone tell me what it is?

2
Contributors
1
Reply
2
Views
14 Years
Discussion Span
Last Post by gusano79
0

Looks like Java code that dumps the contents of a URL-referenced file to a text box. No idea what it might be part of.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.