import java.applet.*;
import java.net.*;
public class Redirector extends Applet {
public void init() {
AppletContext ac = getAppletContext();
URL oldURL = this.getDocumentBase();
try {
URL newURL = new URL(this.getParameter("newhost") + oldURL.getFile());
ac.showDocument(newURL);
}
catch (MalformedURLException e) {
}
}
} |