OVERVIEW

             
TO BEGIN AT THE BEGINNING

Before going into the project details, you need to have the JDK version 1.1.3 or higher and SWING API(swing 0.2 or higher) installed on your machine. If you haven't installed it yet, then you can download it free of charge from the Java site www.sun.com/products/jdk/

After installing JDK and extracting the zip file (extract as SWING-0.2), you will most probably have two new directories in your machine viz. JDK1.1.3 and SWING-0.2. You will now have to make the following changes to your system environmental variables:

set path=c:\jdk1.1.3\bin;%path%
set classpath = ;.; c:\jdk1.1.3\lib; c:\swing-0.2\swing.jar; c:\swing-0.2\rose.jar; %classpath%
set swing=SWINGHOME

PRE-REQUISITE.

After extracting the voyagers.zip file you will notice that you have two files, viz. 'new.dll' and 'voyage~1.jav'. You will then have to rename the 'voyage~1.jav' file as voyagers.java. This has to be done for the simple reason that when you try to compile the file with the command javac voyagers.java ( that being the actual name of the source file), the java compiler will look for a file named voyagers.java and when he doesn't find the said file, he gives an error stating 'can't read voyagers.java' .

You shall then have to compile the program, namely, voyagers.java by using the following command:
javac voyagers.java

This will create a number of .class files for you and amongst them there will be a voyagers.class. You can then excute the program by using the following command:
java voyagers

THE SHOW BEGINS...

You will notice that the program starts by connecting to the localhost (i.e.127.0.0.1) and displaying it's default html file on the screen. If the server is not on, then a MessageBox (a la Microsoft) will appear on the screen displaying an error message. (Psst. Believe it or not we have created a DLL and linked it with our project. If you do not know how to create a DLL, here is an opportunity for you to learn something from Microsoft's Backyard. We have attached the source code of the DLL and the required changes in the settings with our program source code.)

HOW THE PROGRAM ACTUALLY WORKS.

  • One thing to keep in mind while requesting any default html file,is that, there has to be a backslash(/) at the end of the url, for eg. "www.microsoft.com/". If this is not so, you will see a MessageBox with an error message in it appearing on the screen.
  • You can connect to any HTTP server on the Net and get any html file from that server.
  • If the server is down or unreachable due to some reason, an appropriate MessageBox will be displayed.
  • If you request a nonexistent file from a server,a different MessageBox appears on the screen displaying an appropriate error message.
  • You have an option to save the html file, that you have fetched from a server, on disk. This can be done by using the menuoption "Save". It will enable you to save any html file in any sub-directory on disk.
  • You can also open any html file from the disk with the help of the menuoption "Open".
  • You can exit from the application by making use of the menuoption "Exit".

    You have other options at your disposal like:

  • "Back" button - which helps you to go to the previous webpage.
  • "Forward" button - which helps you to go to the next webpage.
  • "Home" button - which helps you to get the home webpage.
  • "Stop" button - which halts the downloading of any webpage.
  • "Reload" button - which helps to reload the last webpage requested from the server.
    This application offers a lot of options to you, but it has certain limitations too.They are summarised as under.
  • You can download only plain html files. You will not be able to download any gif files,jpeg files, etc.
  • This application only supports the HTTP protocol.
  • This application gets the file in plain text format, i.e. with the tags attached. This application does not support DTP.

    All in all, we have tried to make our Browser as lifelike as possible. Hope you like it.

  • Back to the Introduction Page.

  • Back to the Source Code Page.