How to add Mad Libs to your web page

  1. Click here to download the MadLibs.class file.
  2. Put the file in your web directory.
  3. Copy the following text into any web page:
  4. You can change the numbers for "HEIGHT" and "WIDTH" to change the way the applet appears on your page.
  5. Click here to download an example of how to write your own madlibs file.
  6. Write your own Mad Libs, following the example above, and save it as a text file in the same directory as MadLibs.class.
  7. Change the code that you wrote in step 3. Instead of "mymadlibsfile.txt" change it to the name of the file you wrote.
  8. You can also change the line that says SCRAMBLED from "yes" to "no" if you want the words to be read in the same order that they are in your file. 

Please credit me as the author of this program by providing a link to this page. The address is: http://www.apollowebworks.com/russell/java/madlibs

More about Mad-Libs