20130

We covered Python this morning, just the basics.  You should be able to recognize python code now (it doesn’t have semicolons and depends on indentation to recognize blocks).

We also covered HTML / CSS and Javascript in the afternoon.  These are the basic, common bullding blocks for everything on the web (including webpages you see on your smartphones).  You can try looking at the source of the webpages you see and feeling good that you have some knowledge of what that is and what it does.  Most of the HTML you see is generated programmatically, by servers that run software that replies HTML to your web browser.

CSS helps to interpret how that HTML looks like in your browsers.  We saw by tinkering with the CSS, the webpage can look very different.  One way to think of it is that the HTML specifies the page’s logical structure and that the CSS specifies what that structure looks like (its formatting).  Javascript is a programming language in its own right (similar to Python), but which all web browsers know how to execute and run right inside the browser.  It’s usually used to give dynamic effects on the webpage, so you’ll usually see that you need to load some javascript library to achieve some interesting effect on a webpage (e.g., animation, sorting, dynamic styling).

Finally we covered Google App Engine, the hardest part of today’s work.  Here we did the job of generating HTML programmatically in response to requests from your clicks to “run” the program.  The HTML is generated from HTML templates where some values are filled in by the app engine’s python code’s.  In particular, you are using python code (e.g., giftbook.py) to specify classes and handlers for those classes.  The responses that the handlers generate are HTML webpages (e.g., wishlist.html) that have placeholders for the Jinja2 template language to insert the appropriate values from Python.

We don’t expect you to get it all on the first try, but take a look through the code to see what you can understand and what you don’t.  We know it’s difficult to ask questions on what you don’t know — because you don’t know what you don’t know — but try your best.  We’d love for you to ask at least 1 question in our Askbot forum so that we can try to answer your questions offline.

Comments are closed.