Moved javascript to seperate file.  Updated some javascript to work with current requests.