CS2513: Client-Side Programming
Weekly Course Content - Week 16
Chapter 11: Introduction to AJAX
Chapter 11: Updating Web Pages with AJAX
- Describe the steps involved in using Ajax to update data
- Create an HTTP request and interpret an HTTP response
- Request and receive server data using the XMLHttp Request object
- Process data received from a web service and add it to the DOM
- Update app data using JSON-P
JavaScript //Sixth Edition by Sasha Vodnik and Don Gosselin
Chapter 11: Updating Web Pages with AJAX
Required Class Coding Standards
http://www.occc.edu/aphilipp/htm_csp/CS2513_CodingStandards.htm
Video: Lynda.com:
JavaScript and AJAX by Ray Villalobos
1. Getting Started: What is AJAX? (~2:36 minutes)
It might be helpful to review these tutorials - more specifically the one on Parsing: https://www.youtube.com/watch?v=agSSGVgq1hg&index=3&list=PLfdtiltiRHWHKQOby9HEyYtB_Y9g7z6yL
What is JSON? by Codesource
It might be helpful to review these tutorials that were presented in the strings and arrays chapter..
https://www.youtube.com/playlist?list=PLfdtiltiRHWHKQOby9HEyYtB_Y9g7z6yL
- more specifically the one on Parsing: https://www.youtube.com/watch?v=agSSGVgq1hg&index=3&list=PLfdtiltiRHWHKQOby9HEyYtB_Y9g7z6yL
- What is JSON
- Introduction (4:22 min)
- Linting (1:38 min) Note: A site for linting" can be found at http://www.jslint.com/
- Parsing (3:53 min) Note: This video might be more relevant in conjunction with the AJAX chapter.
- Stringify (2:35 min)
" Lint is the name originally given to a particular program that flagged some suspicious and non-portable constructs (likely to be bugs) in language source code. The term is now applied generically to tools that flag suspicious usage in software written in any computer language.
Completed sample code from Chapter 11 JS6eTextCode_Chapter11
Since the files require additional procedures to be viewed, see instructions below
This is going to be a bit more involved to view than most class examples. It cannot be viewed locally unless you are familiar with setting up a server and have access to localhost. (Setting up a server is not a component of this course, but some of you may have experience.) The server must include PHP.
Apollo1 has been configured to include PHP.
Same software as previously indicated.
Inquiring minds that wish to install a web server can download WAMP http://www.wampserver.com/en/ (Apache, MySQL and PHP on Windows), MAMP https://www.mamp.info/en/ (Apache, MySQL and PHP on Mac), or LAMP (Sorry, I do not know Linux so you will be on your own if you decide to use that option)
Chapter Review Questions
Source for quiz and test questions. It is highly recommended that students know the answers.
Chapter 12: Review Questions (.rtf file)
Test 5: Review Sheet
CSP12 - AJAX: Specifications
(Complete, upload to Apollo1, then submit URL in the LMS)
Weekly Quiz: Chapter 11 (Located in the LMS)