View this PageEdit this Page (locked)Attachments to this PageHistory of this PageHomeRecent ChangesSearch the SwikiHelp Guide
Hotspots: Admin Pages | Turn-in Site |
Current Links: Cases Final Project Summer 2007

our embedded squeak

The idea behind embedded Squeak is that a Squeak based server will be able to make method calls and return usable information to be displayed to the web page. I will admit, that my understanding of this is not at expert level, but we were able to get this done with minimal stress.

Our HTML code in our newspaper1.html file is fairly simple:


The strange ? ? tags are the clues to the server that what is inside is Squeak code, which will be run each time the page is produced. So what we did was asked the server to go out and retrieve the articles, and dump them to file after being "webified" through the webGenerate function, and then read the file back in and returned it as a string through the webRead function (refer to the source code for this code). The webified code was in HTML format, so it diplayed perfectly! The only other modification was keeping the same format as the /newspaper page, only pressing the button would just bring you back to the newspaper1.html page. This had the effect of generateing a new newspaper at the push of a button!

This is what our product looked like at this point (with the addition of the checkbox code, which was another project entirely).


and the actual newspaper looked like this.

Link to this Page