import javax.swing.*;

public class ShowWeb {
    public static void main(String [] args) throws Exception {
   String url="http://www.yahoo.com";
   if (args.length>0) url=args[0];
   JEditorPane editor = new JEditorPane(url);
   editor.setEditable(false);
   JScrollPane pane = new JScrollPane(editor);
   JFrame f = new JFrame("HTML Demo");
   f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
   f.getContentPane().add(pane);
   f.setSize(800,600);
   f.show();
  }
}
